Steven Newsom wrote: > > Im using Circlemud bpl14 and want to change the practice to a % instead of > superb, etc.(instead of superb it would read 100%, 90%, etc.)and wanted to > know if anyone has done this and how(found it about 2 months ago and finally > decided to change it and couldnt find it). void list_skills(struct char_data * ch) { int i, sortpos; if (!GET_PRACTICES(ch)) strcpy(buf, "You have no practice sessions remaining.\r\n"); else sprintf(buf, "You have %d practice session%s remaining.\r\n", GET_PRACTICES(ch), (GET_PRACTICES(ch) == 1 ? "" : "s")); sprintf(buf + strlen(buf), "You know of the following %ss:\r\n", SPLSKL(ch)); strcpy(buf2, buf); for (sortpos = 1; sortpos <= MAX_SKILLS; sortpos++) { i = spell_sort_info[sortpos]; if (strlen(buf2) >= MAX_STRING_LENGTH - 32) { strcat(buf2, "**OVERFLOW**\r\n"); break; } if (GET_LEVEL(ch) >= spell_info[i].min_level[(int) GET_CLASS(ch)]) { - sprintf(buf, "%-20s %s\r\n", spell_info[i].name, how_good(GET_SKILL(ch, i))); + sprintf(buf, "%-20s %d%%\r\n", spell_info[i].name, GET_SKILL(ch, i)); strcat(buf2, buf); /* The above, ^ should always be safe to do. */ } } page_string(ch->desc, buf2, 1); } > Also how would I go about it showing all the body parts when I type eq. Like > if I type it now it just says "You are wearing nothing", but I want to change > it so when you type EQ it has something like this > > Worn on Head: <nothing> > Worn on Back: <nothing> > Worn on Hands: <gloves of glory> ACMD(do_equipment) { - int i, found = 0; + int i; send_to_char("You are using:\r\n", ch); for (i = 0; i < NUM_WEARS; i++) { if (GET_EQ(ch, i)) { if (CAN_SEE_OBJ(ch, GET_EQ(ch, i))) { send_to_char(where[i], ch); show_obj_to_char(GET_EQ(ch, i), ch, 1); - found = TRUE; } else { send_to_char(where[i], ch); send_to_char("Something.\r\n", ch); - found = TRUE; } - } + } else { + send_to_char(where[i], ch); + send_to_char("<nothing>", ch); + } } - if (!found) { - send_to_char(" Nothing.\r\n", ch); - } } +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/10/01 PDT