I am trying to add a reroll stats code to my mud, I got the right info in my
structs.h and class.c and db.c they compile with no errors but my
interpreter.c wont compile it says
interpreter.c: in function 'nany':
interpreter.c:1571: duplicate case value
interpreter.c:1542: this is the first entry for that value
I'm not sure whats wrong here so but here's the code
case CON_QCLASS:
load_result = parse_class(*arg);
if (load_result == CLASS_UNDEFINED) {
SEND_TO_Q("\r\nThat's not a class.\r\nClass: ", d);
return;
} else
GET_CLASS(d->character) = load_result;
/* Made changes here, might not be right.*/
SEND_TO_Q("\r\nPress enter to roll your stats.", d);
STATE(d) = CON_QROLLSTATS;
break;
case CON_QROLLSTATS:
switch (*arg) {
case 'y':
break;
case 'N':
default:
/*roll_real_abils(d->character);*/
sprintf(buf, "\r\nStr: [%d/%d] Int: [%d] Wis: [%d] Dex:"
" [%d] Con: [%d] Cha: [%d]",
GET_STR(d->character), GET_ADD(d->character),
GET_INT(d->character), GET_WIS(d->character),
GET_DEX(d->character), GET_CON(d->character),
GET_CHA(d->character));
SEND_TO_Q(buf, d);
SEND_TO_Q("\r\n\r\nKeep these stats? (y/N)", d);
return;
}
/* if (d->pos < 0)
* d->pos = create_entry(GET_NAME(d->character));
*/
if (GET_PFILEPOS(d->character) < 0)
GET_PFILEPOS(d->character) = create_entry(GET_NAME(d->character));
init_char(d->character);
save_char(d->character, NOWHERE);
SEND_TO_Q(motd, d);
SEND_TO_Q("\r\n\n*** PRESS RETURN: ", d);
STATE(d) = CON_RMOTD;
I left a little extra code on each end so you could figure out it's location
I'm using bpl14 I would REALLY apreciate the help:)
-Andre
+------------------------------------------------------------+
| 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/11/01 PDT