diff -c src.orig/act_comm.c src/act_comm.c *** src.orig/act_comm.c 2001-07-05 08:52:52.000000000 +1000 --- src/act_comm.c 2004-01-20 08:11:23.000000000 +1100 *************** *** 168,174 **** } else { ! strcpy(pbuf2, cnv->new); pbuf2 += cnv->nlen; } pbuf += cnv->olen; --- 168,174 ---- } else { ! strcpy(pbuf2, cnv->lcnv_new); pbuf2 += cnv->nlen; } pbuf += cnv->olen; *************** *** 195,201 **** for (cnv = lng->first_cnv; cnv; cnv = cnv->next) if (!str_prefix(cnv->old, pbuf)) { ! strcpy(pbuf2, cnv->new); pbuf += cnv->olen; pbuf2 += cnv->nlen; break; --- 195,201 ---- for (cnv = lng->first_cnv; cnv; cnv = cnv->next) if (!str_prefix(cnv->old, pbuf)) { ! strcpy(pbuf2, cnv->lcnv_new); pbuf += cnv->olen; pbuf2 += cnv->nlen; break; *************** *** 2530,2536 **** ch_printf( ch, "[%2d %s] %-16s %4s/%4s hp %4s/%4s %s %4s/%4s mv %5s xp\n\r", gch->level, ! IS_NPC(gch) ? "Mob" : class_table[gch->class]->who_name, capitalize( PERS(gch, ch) ), "????", "????", --- 2530,2536 ---- ch_printf( ch, "[%2d %s] %-16s %4s/%4s hp %4s/%4s %s %4s/%4s mv %5s xp\n\r", gch->level, ! IS_NPC(gch) ? "Mob" : class_table[gch->mudclass]->who_name, capitalize( PERS(gch, ch) ), "????", "????", *************** *** 2554,2560 **** ch_printf( ch, "%-2d %2.2s %3.3s", gch->level, buf, ! IS_NPC(gch) ? "Mob" : class_table[gch->class]->who_name ); set_char_color( AT_DGREEN, ch ); send_to_char( "] ", ch ); set_char_color( AT_GREEN, ch ); --- 2554,2560 ---- ch_printf( ch, "%-2d %2.2s %3.3s", gch->level, buf, ! IS_NPC(gch) ? "Mob" : class_table[gch->mudclass]->who_name ); set_char_color( AT_DGREEN, ch ); send_to_char( "] ", ch ); set_char_color( AT_GREEN, ch ); *************** *** 2572,2578 **** set_char_color( AT_BLOOD, ch ); else set_char_color( AT_LBLUE, ch ); ! if ( gch->class != CLASS_WARRIOR ) ch_printf( ch, "%5d/%-5d ", IS_VAMPIRE(gch) ? gch->pcdata->condition[COND_BLOODTHIRST] : gch->mana, IS_VAMPIRE(gch) ? 10 + gch->level : gch->max_mana ); --- 2572,2578 ---- set_char_color( AT_BLOOD, ch ); else set_char_color( AT_LBLUE, ch ); ! if ( gch->mudclass != CLASS_WARRIOR ) ch_printf( ch, "%5d/%-5d ", IS_VAMPIRE(gch) ? gch->pcdata->condition[COND_BLOODTHIRST] : gch->mana, IS_VAMPIRE(gch) ? 10 + gch->level : gch->max_mana ); diff -c src.orig/act_info.c src/act_info.c *** src.orig/act_info.c 2001-07-05 08:52:52.000000000 +1000 --- src/act_info.c 2004-01-20 13:09:29.000000000 +1100 *************** *** 87,113 **** buf[0] = '\0'; if ( IS_OBJ_STAT(obj, ITEM_INVIS) ) strcat( buf, "(Invis) " ); ! if ( (IS_AFFECTED(ch, AFF_DETECT_EVIL) || ch->class==CLASS_PALADIN) && IS_OBJ_STAT(obj, ITEM_EVIL) ) strcat( buf, "(Red Aura) " ); ! if ( ch->class==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming Red) " ); ! if ( ch->class==CLASS_PALADIN && ( !IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming Grey) " ); ! if ( ch->class==CLASS_PALADIN && (!IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming White) " ); ! if ( ch->class==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Red-Grey) " ); ! if ( ch->class==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Red-White) " ); ! if ( ch->class==CLASS_PALADIN && ( !IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Grey-White) " ); --- 87,113 ---- buf[0] = '\0'; if ( IS_OBJ_STAT(obj, ITEM_INVIS) ) strcat( buf, "(Invis) " ); ! if ( (IS_AFFECTED(ch, AFF_DETECT_EVIL) || ch->mudclass==CLASS_PALADIN) && IS_OBJ_STAT(obj, ITEM_EVIL) ) strcat( buf, "(Red Aura) " ); ! if ( ch->mudclass==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming Red) " ); ! if ( ch->mudclass==CLASS_PALADIN && ( !IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming Grey) " ); ! if ( ch->mudclass==CLASS_PALADIN && (!IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Flaming White) " ); ! if ( ch->mudclass==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && !IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Red-Grey) " ); ! if ( ch->mudclass==CLASS_PALADIN && ( IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && !IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Red-White) " ); ! if ( ch->mudclass==CLASS_PALADIN && ( !IS_OBJ_STAT(obj, ITEM_ANTI_EVIL) && IS_OBJ_STAT(obj, ITEM_ANTI_NEUTRAL) && IS_OBJ_STAT(obj, ITEM_ANTI_GOOD)) ) strcat( buf, "(Smouldering Grey-White) " ); *************** *** 580,590 **** if ( IS_AFFECTED(victim, AFF_PASS_DOOR) ) strcat( buf, "(Translucent) "); if ( IS_AFFECTED(victim, AFF_FAERIE_FIRE) ) strcat( buf, "(Pink Aura) " ); if ( IS_EVIL(victim) ! && ( IS_AFFECTED(ch, AFF_DETECT_EVIL) || ch->class==CLASS_PALADIN) ) strcat( buf, "(Red Aura) " ); if ( IS_NEUTRAL(victim) ! && ch->class==CLASS_PALADIN ) strcat( buf, "(Grey Aura) " ); if ( IS_GOOD(victim) ! && ch->class==CLASS_PALADIN ) strcat( buf, "(White Aura) " ); if ( IS_AFFECTED(victim, AFF_BERSERK) ) strcat( buf, "(Wild-eyed) " ); --- 580,590 ---- if ( IS_AFFECTED(victim, AFF_PASS_DOOR) ) strcat( buf, "(Translucent) "); if ( IS_AFFECTED(victim, AFF_FAERIE_FIRE) ) strcat( buf, "(Pink Aura) " ); if ( IS_EVIL(victim) ! && ( IS_AFFECTED(ch, AFF_DETECT_EVIL) || ch->mudclass==CLASS_PALADIN) ) strcat( buf, "(Red Aura) " ); if ( IS_NEUTRAL(victim) ! && ch->mudclass==CLASS_PALADIN ) strcat( buf, "(Grey Aura) " ); if ( IS_GOOD(victim) ! && ch->mudclass==CLASS_PALADIN ) strcat( buf, "(White Aura) " ); if ( IS_AFFECTED(victim, AFF_BERSERK) ) strcat( buf, "(Wild-eyed) " ); *************** *** 836,849 **** race_table[victim->race]->race_name&& race_table[victim->race]->race_name[0] != '\0'? race_table[victim->race]->race_name:"unknown", ! IS_NPC(victim)?victim->classclass>=0? ! npc_class[victim->class] : "unknown":victim->classclass]->who_name&& ! class_table[victim->class]->who_name[0] != '\0'? ! class_table[victim->class]->who_name:"unknown"); /* Fix so it shows what is in class table victim->racerace>=0?npc_race[victim->race] : "unknown", ! victim->classclass>=0?npc_class[victim->class] : "unknown" ); */ } --- 836,849 ---- race_table[victim->race]->race_name&& race_table[victim->race]->race_name[0] != '\0'? race_table[victim->race]->race_name:"unknown", ! IS_NPC(victim)?victim->mudclassmudclass>=0? ! npc_class[victim->mudclass] : "unknown":victim->mudclassmudclass]->who_name&& ! class_table[victim->mudclass]->who_name[0] != '\0'? ! class_table[victim->mudclass]->who_name:"unknown"); /* Fix so it shows what is in class table victim->racerace>=0?npc_race[victim->race] : "unknown", ! victim->mudclassmudclass>=0?npc_class[victim->mudclass] : "unknown" ); */ } *************** *** 937,943 **** CHAR_DATA *victim; OBJ_DATA *obj; ROOM_INDEX_DATA *original; ! char *pdesc; bool doexaprog; sh_int door; int number, cnt; --- 937,943 ---- CHAR_DATA *victim; OBJ_DATA *obj; ROOM_INDEX_DATA *original; ! const char *pdesc; bool doexaprog; sh_int door; int number, cnt; *************** *** 1181,1187 **** */ if ( pexit->to_room && ( IS_AFFECTED( ch, AFF_SCRYING ) ! || ch->class == CLASS_THIEF || IS_SET( pexit->exit_info, EX_xLOOK ) || get_trust(ch) >= LEVEL_IMMORTAL ) ) { --- 1181,1187 ---- */ if ( pexit->to_room && ( IS_AFFECTED( ch, AFF_SCRYING ) ! || ch->mudclass == CLASS_THIEF || IS_SET( pexit->exit_info, EX_xLOOK ) || get_trust(ch) >= LEVEL_IMMORTAL ) ) { *************** *** 1199,1205 **** int percent = LEARNED(ch, skill_lookup("scry") ); if ( !percent ) { ! if ( ch->class == CLASS_THIEF ) percent = 95; else percent = 55; /* 95 was too good -Thoric */ --- 1199,1205 ---- int percent = LEARNED(ch, skill_lookup("scry") ); if ( !percent ) { ! if ( ch->mudclass == CLASS_THIEF ) percent = 95; else percent = 55; /* 95 was too good -Thoric */ *************** *** 1468,1481 **** race_table[victim->race]->race_name&& race_table[victim->race]->race_name[0] != '\0'? race_table[victim->race]->race_name:"unknown", ! IS_NPC(victim)?victim->classclass>=0? ! npc_class[victim->class] : "unknown":victim->classclass]->who_name&& ! class_table[victim->class]->who_name[0] != '\0'? ! class_table[victim->class]->who_name:"unknown"); /* New Change victim->racerace>=0?npc_race[victim->race] : "unknown", ! victim->classclass>=0?npc_class[victim->class] : "unknown" ); */ } show_condition( ch, victim ); --- 1468,1481 ---- race_table[victim->race]->race_name&& race_table[victim->race]->race_name[0] != '\0'? race_table[victim->race]->race_name:"unknown", ! IS_NPC(victim)?victim->mudclassmudclass>=0? ! npc_class[victim->mudclass] : "unknown":victim->mudclassmudclass]->who_name&& ! class_table[victim->mudclass]->who_name[0] != '\0'? ! class_table[victim->mudclass]->who_name:"unknown"); /* New Change victim->racerace>=0?npc_race[victim->race] : "unknown", ! victim->mudclassmudclass>=0?npc_class[victim->mudclass] : "unknown" ); */ } show_condition( ch, victim ); *************** *** 1999,2005 **** default: break; case SUB_HELP_EDIT: ! if ( (pHelp = ch->dest_buf) == NULL ) { bug( "hedit: sub_help_edit: NULL ch->dest_buf", 0 ); stop_editing( ch ); --- 1999,2005 ---- default: break; case SUB_HELP_EDIT: ! if ( (pHelp = (HELP_DATA *) ch->dest_buf) == NULL ) { bug( "hedit: sub_help_edit: NULL ch->dest_buf", 0 ); stop_editing( ch ); *************** *** 2586,2592 **** d = (fGroup ? (whogr ? whogr->d : NULL) : d->prev)) { CHAR_DATA *wch; ! char const *class; if ( (d->connected != CON_PLAYING && d->connected != CON_EDITING) || !can_see( ch, d->character ) || d->original) --- 2586,2592 ---- d = (fGroup ? (whogr ? whogr->d : NULL) : d->prev)) { CHAR_DATA *wch; ! char const *mudclass; if ( (d->connected != CON_PLAYING && d->connected != CON_EDITING) || !can_see( ch, d->character ) || d->original) *************** *** 2596,2602 **** || wch->level > iLevelUpper || ( fPkill && !CAN_PKILL( wch ) ) || ( fImmortalOnly && wch->level < LEVEL_IMMORTAL ) ! || ( fClassRestrict && !rgfClass[wch->class] ) || ( fRaceRestrict && !rgfRace[wch->race] ) || ( fClanMatch && ( pClan != wch->pcdata->clan )) /* SB */ || ( fCouncilMatch && ( pCouncil != wch->pcdata->council )) /* SB */ --- 2596,2602 ---- || wch->level > iLevelUpper || ( fPkill && !CAN_PKILL( wch ) ) || ( fImmortalOnly && wch->level < LEVEL_IMMORTAL ) ! || ( fClassRestrict && !rgfClass[wch->mudclass] ) || ( fRaceRestrict && !rgfRace[wch->race] ) || ( fClanMatch && ( pClan != wch->pcdata->clan )) /* SB */ || ( fCouncilMatch && ( pCouncil != wch->pcdata->council )) /* SB */ *************** *** 2632,2658 **** else strcpy( char_name, wch->name ); ! sprintf( class_text, "%s%2d %s", NOT_AUTHED(wch) ? "N" : " ", wch->level, class_table[wch->class]->who_name ); ! class = class_text; switch ( wch->level ) { default: break; ! case MAX_LEVEL - 0: class = "Supreme Entity"; break; ! case MAX_LEVEL - 1: class = "Infinite"; break; ! case MAX_LEVEL - 2: class = "Eternal"; break; ! case MAX_LEVEL - 3: class = "Ancient"; break; ! case MAX_LEVEL - 4: class = "Exalted God"; break; ! case MAX_LEVEL - 5: class = "Ascendant God"; break; ! case MAX_LEVEL - 6: class = "Greater God"; break; ! case MAX_LEVEL - 7: class = "God"; break; ! case MAX_LEVEL - 8: class = "Lesser God"; break; ! case MAX_LEVEL - 9: class = "Immortal"; break; ! case MAX_LEVEL - 10: class = "Demi God"; break; ! case MAX_LEVEL - 11: class = "Savior"; break; ! case MAX_LEVEL - 12: class = "Creator"; break; ! case MAX_LEVEL - 13: class = "Acolyte"; break; ! case MAX_LEVEL - 14: class = "Neophyte"; break; ! case MAX_LEVEL - 15: class = "Avatar"; break; } if ( !str_cmp( wch->name, sysdata.guild_overseer ) ) --- 2632,2658 ---- else strcpy( char_name, wch->name ); ! sprintf( class_text, "%s%2d %s", NOT_AUTHED(wch) ? "N" : " ", wch->level, class_table[wch->mudclass]->who_name ); ! mudclass = class_text; switch ( wch->level ) { default: break; ! case MAX_LEVEL - 0: mudclass = "Supreme Entity"; break; ! case MAX_LEVEL - 1: mudclass = "Infinite"; break; ! case MAX_LEVEL - 2: mudclass = "Eternal"; break; ! case MAX_LEVEL - 3: mudclass = "Ancient"; break; ! case MAX_LEVEL - 4: mudclass = "Exalted God"; break; ! case MAX_LEVEL - 5: mudclass = "Ascendant God"; break; ! case MAX_LEVEL - 6: mudclass = "Greater God"; break; ! case MAX_LEVEL - 7: mudclass = "God"; break; ! case MAX_LEVEL - 8: mudclass = "Lesser God"; break; ! case MAX_LEVEL - 9: mudclass = "Immortal"; break; ! case MAX_LEVEL - 10: mudclass = "Demi God"; break; ! case MAX_LEVEL - 11: mudclass = "Savior"; break; ! case MAX_LEVEL - 12: mudclass = "Creator"; break; ! case MAX_LEVEL - 13: mudclass = "Acolyte"; break; ! case MAX_LEVEL - 14: mudclass = "Neophyte"; break; ! case MAX_LEVEL - 15: mudclass = "Avatar"; break; } if ( !str_cmp( wch->name, sysdata.guild_overseer ) ) *************** *** 2663,2685 **** extra_title = ""; if ( IS_RETIRED( wch ) ) ! class = "Retired"; else if ( IS_GUEST( wch ) ) ! class = "Guest"; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->leader ) && wch->pcdata->clan->leadrank[0] != '\0' ) ! class = wch->pcdata->clan->leadrank; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->number1 ) && wch->pcdata->clan->onerank[0] != '\0' ) ! class = wch->pcdata->clan->onerank; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->number2 ) && wch->pcdata->clan->tworank[0] != '\0' ) ! class = wch->pcdata->clan->tworank; else if ( wch->pcdata->rank && wch->pcdata->rank[0] != '\0' ) ! class = wch->pcdata->rank; if ( wch->pcdata->clan ) { --- 2663,2685 ---- extra_title = ""; if ( IS_RETIRED( wch ) ) ! mudclass = "Retired"; else if ( IS_GUEST( wch ) ) ! mudclass = "Guest"; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->leader ) && wch->pcdata->clan->leadrank[0] != '\0' ) ! mudclass = wch->pcdata->clan->leadrank; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->number1 ) && wch->pcdata->clan->onerank[0] != '\0' ) ! mudclass = wch->pcdata->clan->onerank; else if ( wch->pcdata->clan && !str_cmp( wch->name, wch->pcdata->clan->number2 ) && wch->pcdata->clan->tworank[0] != '\0' ) ! mudclass = wch->pcdata->clan->tworank; else if ( wch->pcdata->rank && wch->pcdata->rank[0] != '\0' ) ! mudclass = wch->pcdata->rank; if ( wch->pcdata->clan ) { *************** *** 2766,2772 **** MXPTAG ("player '%s'") "%s" MXPTAG ("/player") "%s.%s%s%s\n\r", (fGroup ? whogr->indent : 0), "", ! class, invis_str, (wch->desc && wch->desc->connected) ? "[WRITING] " : "", xIS_SET(wch->act, PLR_AFK) ? "[AFK] " : "", --- 2766,2772 ---- MXPTAG ("player '%s'") "%s" MXPTAG ("/player") "%s.%s%s%s\n\r", (fGroup ? whogr->indent : 0), "", ! mudclass, invis_str, (wch->desc && wch->desc->connected) ? "[WRITING] " : "", xIS_SET(wch->act, PLR_AFK) ? "[AFK] " : "", *************** *** 3230,3240 **** if (!IS_IMMORTAL(ch) && ( skill_table[sn]->guild != CLASS_NONE && ( !IS_GUILDED(ch) ! || (ch->pcdata->clan->class != skill_table[sn]->guild) ) ) ) continue; ! if ( ch->level < skill_table[sn]->skill_level[ch->class] ! || (!IS_IMMORTAL(ch) && skill_table[sn]->skill_level[ch->class] == 0) ) continue; if ( ch->pcdata->learned[sn] <= 0 --- 3230,3240 ---- if (!IS_IMMORTAL(ch) && ( skill_table[sn]->guild != CLASS_NONE && ( !IS_GUILDED(ch) ! || (ch->pcdata->clan->mudclass != skill_table[sn]->guild) ) ) ) continue; ! if ( ch->level < skill_table[sn]->skill_level[ch->mudclass] ! || (!IS_IMMORTAL(ch) && skill_table[sn]->skill_level[ch->mudclass] == 0) ) continue; if ( ch->pcdata->learned[sn] <= 0 *************** *** 3291,3297 **** if ( can_prac && ( ( sn == -1 ) || ( !IS_NPC(ch) ! && ch->level < skill_table[sn]->skill_level[ch->class] /* OUT FOR THIS PORT -SHADDAI && ch->level < skill_table[sn]->race_level[ch->race] */ --- 3291,3297 ---- if ( can_prac && ( ( sn == -1 ) || ( !IS_NPC(ch) ! && ch->level < skill_table[sn]->skill_level[ch->mudclass] /* OUT FOR THIS PORT -SHADDAI && ch->level < skill_table[sn]->race_level[ch->race] */ *************** *** 3339,3345 **** } if ( !IS_NPC(ch) && skill_table[sn]->guild != CLASS_NONE ! && ch->pcdata->clan->class != skill_table[sn]->guild ) { act( AT_TELL, "$n tells you 'That can not be used by your guild.'" mob, NULL, ch, TO_VICT ); --- 3339,3345 ---- } if ( !IS_NPC(ch) && skill_table[sn]->guild != CLASS_NONE ! && ch->pcdata->clan->mudclass != skill_table[sn]->guild ) { act( AT_TELL, "$n tells you 'That can not be used by your guild.'" mob, NULL, ch, TO_VICT ); *************** *** 3355,3362 **** /* * Disabled for now ! if ( mob->level < skill_table[sn]->skill_level[ch->class] ! || mob->level < skill_table[sn]->skill_level[mob->class] ) { act( AT_TELL, "$n tells you 'You must seek another to teach you that...'", mob, NULL, ch, TO_VICT ); --- 3355,3362 ---- /* * Disabled for now ! if ( mob->level < skill_table[sn]->skill_level[ch->mudclass] ! || mob->level < skill_table[sn]->skill_level[mob->mudclass] ) { act( AT_TELL, "$n tells you 'You must seek another to teach you that...'", mob, NULL, ch, TO_VICT ); *************** *** 3364,3370 **** } */ ! adept = class_table[ch->class]->skill_adept * 0.2; if ( ch->pcdata->learned[sn] >= adept ) { --- 3364,3370 ---- } */ ! adept = class_table[ch->mudclass]->skill_adept * 0.2; if ( ch->pcdata->learned[sn] >= adept ) { *************** *** 4313,4319 **** && SPELL_FLAG(skill_table[sn], SF_SECRETSKILL) ) continue; ! if(i==skill_table[sn]->skill_level[ch->class] ) { if( !lFound ) { --- 4313,4319 ---- && SPELL_FLAG(skill_table[sn], SF_SECRETSKILL) ) continue; ! if(i==skill_table[sn]->skill_level[ch->mudclass] ) { if( !lFound ) { *************** *** 4369,4375 **** pager_printf(ch, "%7s: %20.20s \t Current: %-3d Max: %-3d MinPos: %s \n\r", skn, skill_table[sn]->name, ch->pcdata->learned[sn], ! skill_table[sn]->skill_adept[ch->class], buf ); } } --- 4369,4375 ---- pager_printf(ch, "%7s: %20.20s \t Current: %-3d Max: %-3d MinPos: %s \n\r", skn, skill_table[sn]->name, ch->pcdata->learned[sn], ! skill_table[sn]->skill_adept[ch->mudclass], buf ); } } *************** *** 4418,4424 **** victim->sex == SEX_FEMALE ? "female" : "neutral", victim->level, capitalize(race_table[victim->race]->race_name), ! class_table[victim->class]->who_name, get_age(victim) ); pager_printf(ch, " %s is a %sdeadly player", --- 4418,4424 ---- victim->sex == SEX_FEMALE ? "female" : "neutral", victim->level, capitalize(race_table[victim->race]->race_name), ! class_table[victim->mudclass]->who_name, get_age(victim) ); pager_printf(ch, " %s is a %sdeadly player", *************** *** 4715,4729 **** /* reached create a node and at it to the list */ if(i < MAX_IGN) { ! IGNORE_DATA *new; ! CREATE(new, IGNORE_DATA, 1); ! new->name = STRALLOC(capitalize(arg)); ! new->next = NULL; ! new->prev = NULL; ! LINK(new, ch->pcdata->first_ignored, ch->pcdata->last_ignored, next, prev); set_char_color(AT_IGNORE, ch); ! ch_printf(ch,"You now ignore %s.\n\r", new->name); return; } else --- 4715,4729 ---- /* reached create a node and at it to the list */ if(i < MAX_IGN) { ! IGNORE_DATA *mudnew; ! CREATE(mudnew, IGNORE_DATA, 1); ! mudnew->name = STRALLOC(capitalize(arg)); ! mudnew->next = NULL; ! mudnew->prev = NULL; ! LINK(mudnew, ch->pcdata->first_ignored, ch->pcdata->last_ignored, next, prev); set_char_color(AT_IGNORE, ch); ! ch_printf(ch,"You now ignore %s.\n\r", mudnew->name); return; } else diff -c src.orig/act_move.c src/act_move.c *** src.orig/act_move.c 1999-05-28 15:18:59.000000000 +1000 --- src/act_move.c 2004-01-20 08:54:45.000000000 +1100 *************** *** 390,396 **** case 9: return "the northeast"; } ! return ""; } /* --- 390,396 ---- case 9: return "the northeast"; } ! return "<\?\?\?>"; } /* *************** *** 823,829 **** /* for ( iClass = 0; iClass < MAX_CLASS; iClass++ ) { ! if ( iClass != ch->class && to_room->vnum == class_table[iClass]->guild ) { send_to_char( "You aren't allowed in there.\n\r", ch ); --- 823,829 ---- /* for ( iClass = 0; iClass < MAX_CLASS; iClass++ ) { ! if ( iClass != ch->mudclass && to_room->vnum == class_table[iClass]->guild ) { send_to_char( "You aren't allowed in there.\n\r", ch ); *************** *** 1791,1797 **** char arg [ MAX_INPUT_LENGTH ]; if ( !IS_NPC( ch ) ! && ch->level < skill_table[gsn_bashdoor]->skill_level[ch->class] ) { send_to_char( "You're not enough of a warrior to bash doors!\n\r", ch ); return; --- 1791,1797 ---- char arg [ MAX_INPUT_LENGTH ]; if ( !IS_NPC( ch ) ! && ch->level < skill_table[gsn_bashdoor]->skill_level[ch->mudclass] ) { send_to_char( "You're not enough of a warrior to bash doors!\n\r", ch ); return; diff -c src.orig/act_obj.c src/act_obj.c *** src.orig/act_obj.c 2001-07-05 08:52:52.000000000 +1000 --- src/act_obj.c 2004-01-20 13:09:55.000000000 +1100 *************** *** 41,47 **** bool remove_obj args( ( CHAR_DATA *ch, int iWear, bool fReplace ) ); void wear_obj args( ( CHAR_DATA *ch, OBJ_DATA *obj, bool fReplace, sh_int wear_bit ) ); ! char* get_chance_verb args( ( OBJ_DATA *obj ) ); char* get_ed_number args( ( OBJ_DATA *obj, int number ) ); OBJ_DATA* recursive_note_find args( ( OBJ_DATA *obj, char* argument) ); --- 41,47 ---- bool remove_obj args( ( CHAR_DATA *ch, int iWear, bool fReplace ) ); void wear_obj args( ( CHAR_DATA *ch, OBJ_DATA *obj, bool fReplace, sh_int wear_bit ) ); ! const char* get_chance_verb args( ( OBJ_DATA *obj ) ); char* get_ed_number args( ( OBJ_DATA *obj, int number ) ); OBJ_DATA* recursive_note_find args( ( OBJ_DATA *obj, char* argument) ); *************** *** 1426,1448 **** if ( !IS_IMMORTAL(ch) && (( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->class == CLASS_WARRIOR ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->class == CLASS_PALADIN ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_MAGE) ! && ch->class == CLASS_MAGE ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_THIEF) ! && ch->class == CLASS_THIEF ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_VAMPIRE) ! && ch->class == CLASS_VAMPIRE ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_DRUID) ! && ch->class == CLASS_DRUID ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->class == CLASS_RANGER ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_MAGE) ! && ch->class == CLASS_AUGURER ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_CLERIC) ! && ch->class == CLASS_CLERIC )) ) { act( AT_MAGIC, "You are forbidden to use that item.", ch, NULL, NULL, TO_CHAR ); act( AT_ACTION, "$n tries to use $p, but is forbidden to do so.", --- 1426,1448 ---- if ( !IS_IMMORTAL(ch) && (( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->mudclass == CLASS_WARRIOR ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->mudclass == CLASS_PALADIN ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_MAGE) ! && ch->mudclass == CLASS_MAGE ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_THIEF) ! && ch->mudclass == CLASS_THIEF ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_VAMPIRE) ! && ch->mudclass == CLASS_VAMPIRE ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_DRUID) ! && ch->mudclass == CLASS_DRUID ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_WARRIOR) ! && ch->mudclass == CLASS_RANGER ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_MAGE) ! && ch->mudclass == CLASS_AUGURER ) || ( IS_OBJ_STAT(obj, ITEM_ANTI_CLERIC) ! && ch->mudclass == CLASS_CLERIC )) ) { act( AT_MAGIC, "You are forbidden to use that item.", ch, NULL, NULL, TO_CHAR ); act( AT_ACTION, "$n tries to use $p, but is forbidden to do so.", *************** *** 3058,3064 **** OBJ_DATA* returned_obj; bool match = TRUE; char* argcopy; ! char* subject; char arg[MAX_INPUT_LENGTH]; char subj[MAX_STRING_LENGTH]; --- 3058,3064 ---- OBJ_DATA* returned_obj; bool match = TRUE; char* argcopy; ! const char* subject; char arg[MAX_INPUT_LENGTH]; char subj[MAX_STRING_LENGTH]; *************** *** 3119,3125 **** char roll_string[MAX_STRING_LENGTH]; char total_string[MAX_STRING_LENGTH]; ! char* verb; /* char* face_string = NULL; char** face_table = NULL;*/ --- 3119,3125 ---- char roll_string[MAX_STRING_LENGTH]; char total_string[MAX_STRING_LENGTH]; ! const char* verb; /* char* face_string = NULL; char** face_table = NULL;*/ *************** *** 3168,3174 **** ch_printf(ch, "Nice try, but you can only %s %d times.\n\r", verb, numsides); return; } ! face_seen_table = calloc(numsides, sizeof(bool)); if(!face_seen_table) { bug("do_rolldie: cannot allocate memory for face_seen_table array, terminating.\n\r",0); --- 3168,3174 ---- ch_printf(ch, "Nice try, but you can only %s %d times.\n\r", verb, numsides); return; } ! face_seen_table = (bool *) calloc(numsides, sizeof(bool)); if(!face_seen_table) { bug("do_rolldie: cannot allocate memory for face_seen_table array, terminating.\n\r",0); *************** *** 3248,3254 **** return NULL; } ! char* get_chance_verb(OBJ_DATA* obj) { return (obj->action_desc[0] != '\0') ? obj->action_desc : "roll$q"; } --- 3248,3254 ---- return NULL; } ! const char* get_chance_verb(OBJ_DATA* obj) { return (obj->action_desc[0] != '\0') ? obj->action_desc : "roll$q"; } diff -c src.orig/act_wiz.c src/act_wiz.c *** src.orig/act_wiz.c 1999-05-28 15:18:59.000000000 +1000 --- src/act_wiz.c 2004-01-20 09:02:58.000000000 +1100 *************** *** 625,631 **** victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->class]->who_name, IS_PKILL( victim ) ? "Deadly" : "Peaceful" ); return; } --- 625,631 ---- victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->mudclass]->who_name, IS_PKILL( victim ) ? "Deadly" : "Peaceful" ); return; } *************** *** 1634,1640 **** location->area ? location->area->filename : "None????" ); switch( ch->in_room->sector_type ) { ! default: sect = "???!"; break; case SECT_INSIDE: sect = "Inside"; break; case SECT_CITY: sect = "City"; break; case SECT_FIELD: sect = "Field"; break; --- 1634,1640 ---- location->area ? location->area->filename : "None????" ); switch( ch->in_room->sector_type ) { ! default: sect = "\?\?\?!"; break; case SECT_INSIDE: sect = "Inside"; break; case SECT_CITY: sect = "City"; break; case SECT_FIELD: sect = "Field"; break; *************** *** 1892,1903 **** pager_printf_color( ch, "&cLevel : &P%-2d ", victim->level ); pager_printf_color( ch, "&cClass : &w%-2.2d/%-10s &cRace : &w%-2.2d/%-10s\n\r", ! victim->class, ! IS_NPC(victim)?victim->classclass>=0? ! npc_class[victim->class] : "unknown":victim->classclass]->who_name&& ! class_table[victim->class]->who_name[0] != '\0'? ! class_table[victim->class]->who_name:"unknown", victim->race, IS_NPC(victim)?victim->racerace>=0? npc_race[victim->race] : "unknown":victim->racelevel ); pager_printf_color( ch, "&cClass : &w%-2.2d/%-10s &cRace : &w%-2.2d/%-10s\n\r", ! victim->mudclass, ! IS_NPC(victim)?victim->mudclassmudclass>=0? ! npc_class[victim->mudclass] : "unknown":victim->mudclassmudclass]->who_name&& ! class_table[victim->mudclass]->who_name[0] != '\0'? ! class_table[victim->mudclass]->who_name:"unknown", victim->race, IS_NPC(victim)?victim->racerace>=0? npc_race[victim->race] : "unknown":victim->raceguild == victim->pcdata->clan->class && skill_table[sn]->name != NULL) victim->pcdata->learned[sn] = 0; } --- 3547,3553 ---- int sn; for (sn = 0; sn < top_sn; sn++) ! if (skill_table[sn]->guild == victim->pcdata->clan->mudclass && skill_table[sn]->name != NULL) victim->pcdata->learned[sn] = 0; } *************** *** 4175,4181 **** { SET_BIT(victim->pcdata->flags, PCFLAG_NOTITLE); sprintf( buf, "the %s", ! title_table [victim->class] [victim->level] [victim->sex == SEX_FEMALE ? 1 : 0] ); set_title( victim, buf ); send_to_char( "You can't set your own title!\n\r", victim ); --- 4175,4181 ---- { SET_BIT(victim->pcdata->flags, PCFLAG_NOTITLE); sprintf( buf, "the %s", ! title_table [victim->mudclass] [victim->level] [victim->sex == SEX_FEMALE ? 1 : 0] ); set_title( victim, buf ); send_to_char( "You can't set your own title!\n\r", victim ); *************** *** 5046,5065 **** obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_BANNER), 1 ); obj_to_char(obj, victim); ! if ( (victim->class == CLASS_MAGE) || (victim->class == CLASS_THIEF) ! || (victim->class == CLASS_VAMPIRE) || (victim->class == CLASS_AUGURER) ) { obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_DAGGER), 1 ); obj_to_char(obj, victim); } ! else if ((victim->class == CLASS_CLERIC) || (victim->class == CLASS_DRUID)) { obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_MACE), 1 ); obj_to_char(obj, victim); } ! else if ( (victim->class == CLASS_WARRIOR) || ! (victim->class == CLASS_RANGER) || ! (victim->class == CLASS_PALADIN) ) { obj = create_object(get_obj_index(OBJ_VNUM_SCHOOL_SWORD), 1 ); obj_to_char(obj, victim); --- 5046,5065 ---- obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_BANNER), 1 ); obj_to_char(obj, victim); ! if ( (victim->mudclass == CLASS_MAGE) || (victim->mudclass == CLASS_THIEF) ! || (victim->mudclass == CLASS_VAMPIRE) || (victim->mudclass == CLASS_AUGURER) ) { obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_DAGGER), 1 ); obj_to_char(obj, victim); } ! else if ((victim->mudclass == CLASS_CLERIC) || (victim->mudclass == CLASS_DRUID)) { obj = create_object( get_obj_index(OBJ_VNUM_SCHOOL_MACE), 1 ); obj_to_char(obj, victim); } ! else if ( (victim->mudclass == CLASS_WARRIOR) || ! (victim->mudclass == CLASS_RANGER) || ! (victim->mudclass == CLASS_PALADIN) ) { obj = create_object(get_obj_index(OBJ_VNUM_SCHOOL_SWORD), 1 ); obj_to_char(obj, victim); *************** *** 7287,7293 **** { char arg1[MAX_INPUT_LENGTH]; char arg2[MAX_INPUT_LENGTH]; ! struct class_type *class; int cl, low, hi; set_pager_color( AT_PLAIN, ch ); --- 7287,7293 ---- { char arg1[MAX_INPUT_LENGTH]; char arg2[MAX_INPUT_LENGTH]; ! struct class_type *mudclass; int cl, low, hi; set_pager_color( AT_PLAIN, ch ); *************** *** 7300,7335 **** return; } if ( is_number(arg1) && (cl=atoi(arg1)) >= 0 && cl < MAX_CLASS ) ! class = class_table[cl]; else { ! class = NULL; for ( cl = 0; cl < MAX_CLASS && class_table[cl]; cl++ ) if ( !str_cmp(class_table[cl]->who_name, arg1) ) { ! class = class_table[cl]; break; } } ! if ( !class ) { send_to_char( "No such class.\n\r", ch ); return; } pager_printf_color( ch, "&wCLASS: &W%s\n\r&wPrime Attribute: &W%-14s &wWeapon: &W%-5d &wGuild: &W%-5d\n\r", ! class->who_name, affect_loc_name(class->attr_prime), class->weapon, class->guild ); pager_printf_color( ch, "&wSecond Attribute: &W%-14s &wDeficient Attribute: &W%-14s\n\r", ! affect_loc_name(class->attr_second), affect_loc_name(class->attr_deficient) ); pager_printf_color( ch, "&wMax Skill Adept: &W%-3d &wThac0 : &W%-5d &wThac32: &W%d\n\r", ! class->skill_adept, class->thac0_00, class->thac0_32 ); pager_printf_color( ch, "&wHp Min/Hp Max : &W%-2d/%-2d &wMana : &W%-3s &wExpBase: &W%d\n\r", ! class->hp_min, class->hp_max, class->fMana ? "yes" : "no ", class->exp_base ); pager_printf_color( ch, "&wAffected by: &W%s\n\r", ! affect_bit_name( &class->affected ) ); pager_printf_color( ch, "&wResistant to: &W%s\n\r", ! flag_string(class->resist, ris_flags )); pager_printf_color( ch, "&wSusceptible to: &W%s\n\r", ! flag_string(class->suscept, ris_flags ) ); if ( arg2[0] != '\0' ) { int x, y, cnt; --- 7300,7335 ---- return; } if ( is_number(arg1) && (cl=atoi(arg1)) >= 0 && cl < MAX_CLASS ) ! mudclass = class_table[cl]; else { ! mudclass = NULL; for ( cl = 0; cl < MAX_CLASS && class_table[cl]; cl++ ) if ( !str_cmp(class_table[cl]->who_name, arg1) ) { ! mudclass = class_table[cl]; break; } } ! if ( !mudclass ) { send_to_char( "No such class.\n\r", ch ); return; } pager_printf_color( ch, "&wCLASS: &W%s\n\r&wPrime Attribute: &W%-14s &wWeapon: &W%-5d &wGuild: &W%-5d\n\r", ! mudclass->who_name, affect_loc_name(mudclass->attr_prime), mudclass->weapon, mudclass->guild ); pager_printf_color( ch, "&wSecond Attribute: &W%-14s &wDeficient Attribute: &W%-14s\n\r", ! affect_loc_name(mudclass->attr_second), affect_loc_name(mudclass->attr_deficient) ); pager_printf_color( ch, "&wMax Skill Adept: &W%-3d &wThac0 : &W%-5d &wThac32: &W%d\n\r", ! mudclass->skill_adept, mudclass->thac0_00, mudclass->thac0_32 ); pager_printf_color( ch, "&wHp Min/Hp Max : &W%-2d/%-2d &wMana : &W%-3s &wExpBase: &W%d\n\r", ! mudclass->hp_min, mudclass->hp_max, mudclass->fMana ? "yes" : "no ", mudclass->exp_base ); pager_printf_color( ch, "&wAffected by: &W%s\n\r", ! affect_bit_name( &mudclass->affected ) ); pager_printf_color( ch, "&wResistant to: &W%s\n\r", ! flag_string(mudclass->resist, ris_flags )); pager_printf_color( ch, "&wSusceptible to: &W%s\n\r", ! flag_string(mudclass->suscept, ris_flags ) ); if ( arg2[0] != '\0' ) { int x, y, cnt; *************** *** 7405,7411 **** char arg2[MAX_INPUT_LENGTH]; FILE *fpList; char classlist[256]; ! struct class_type *class; int cl, value, i; set_char_color( AT_PLAIN, ch ); --- 7405,7411 ---- char arg2[MAX_INPUT_LENGTH]; FILE *fpList; char classlist[256]; ! struct class_type *mudclass; int cl, value, i; set_char_color( AT_PLAIN, ch ); *************** *** 7424,7450 **** return; } if ( is_number(arg1) && (cl=atoi(arg1)) >= 0 && cl < MAX_CLASS ) ! class = class_table[cl]; else { ! class = NULL; for ( cl = 0; cl < MAX_CLASS && class_table[cl]; cl++ ) { if ( !class_table[cl]->who_name ) continue; if ( !str_cmp(class_table[cl]->who_name, arg1) ) { ! class = class_table[cl]; break; } } } ! if ( !str_cmp( arg2, "create" ) && class ) { send_to_char( "That class already exists!\n\r", ch ); return; } ! if ( !class && str_cmp(arg2, "create") ) { send_to_char( "No such class.\n\r", ch ); return; --- 7424,7450 ---- return; } if ( is_number(arg1) && (cl=atoi(arg1)) >= 0 && cl < MAX_CLASS ) ! mudclass = class_table[cl]; else { ! mudclass = NULL; for ( cl = 0; cl < MAX_CLASS && class_table[cl]; cl++ ) { if ( !class_table[cl]->who_name ) continue; if ( !str_cmp(class_table[cl]->who_name, arg1) ) { ! mudclass = class_table[cl]; break; } } } ! if ( !str_cmp( arg2, "create" ) && mudclass ) { send_to_char( "That class already exists!\n\r", ch ); return; } ! if ( !mudclass && str_cmp(arg2, "create") ) { send_to_char( "No such class.\n\r", ch ); return; *************** *** 7497,7504 **** if ( !str_cmp( arg2, "name" ) ) { ! STRFREE(class->who_name ); ! class->who_name = STRALLOC( argument ); send_to_char( "Done.\n\r", ch ); return; } --- 7497,7504 ---- if ( !str_cmp( arg2, "name" ) ) { ! STRFREE(mudclass->who_name ); ! mudclass->who_name = STRALLOC( argument ); send_to_char( "Done.\n\r", ch ); return; } *************** *** 7510,7516 **** send_to_char( "Invalid second attribute!\n\r", ch ); else { ! class->attr_second = x; send_to_char( "Done.\n\r", ch ); } return; --- 7510,7516 ---- send_to_char( "Invalid second attribute!\n\r", ch ); else { ! mudclass->attr_second = x; send_to_char( "Done.\n\r", ch ); } return; *************** *** 7530,7536 **** if ( value < 0 || value > MAX_BITS ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! xTOGGLE_BIT( class->affected, value ); } send_to_char( "Done.\n\r", ch ); return; --- 7530,7536 ---- if ( value < 0 || value > MAX_BITS ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! xTOGGLE_BIT( mudclass->affected, value ); } send_to_char( "Done.\n\r", ch ); return; *************** *** 7550,7556 **** if ( value < 0 || value > 31 ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! TOGGLE_BIT( class->resist, 1 << value ); } send_to_char( "Done.\n\r", ch ); return; --- 7550,7556 ---- if ( value < 0 || value > 31 ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! TOGGLE_BIT( mudclass->resist, 1 << value ); } send_to_char( "Done.\n\r", ch ); return; *************** *** 7570,7576 **** if ( value < 0 || value > 31 ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! TOGGLE_BIT( class->suscept, 1 << value ); } send_to_char( "Done.\n\r", ch ); return; --- 7570,7576 ---- if ( value < 0 || value > 31 ) ch_printf( ch, "Unknown flag: %s\n\r", arg2 ); else ! TOGGLE_BIT( mudclass->suscept, 1 << value ); } send_to_char( "Done.\n\r", ch ); return; *************** *** 7583,7589 **** send_to_char( "Invalid deficient attribute!\n\r", ch ); else { ! class->attr_deficient = x; send_to_char( "Done.\n\r", ch ); } return; --- 7583,7589 ---- send_to_char( "Invalid deficient attribute!\n\r", ch ); else { ! mudclass->attr_deficient = x; send_to_char( "Done.\n\r", ch ); } return; *************** *** 7596,7654 **** send_to_char( "Invalid prime attribute!\n\r", ch ); else { ! class->attr_prime = x; send_to_char( "Done.\n\r", ch ); } return; } if ( !str_cmp( arg2, "weapon" ) ) { ! class->weapon = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "guild" ) ) { ! class->guild = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "thac0" ) ) { ! class->thac0_00 = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "thac32" ) ) { ! class->thac0_32 = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "hpmin" ) ) { ! class->hp_min = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "hpmax" ) ) { ! class->hp_max = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "mana" ) ) { if ( UPPER(argument[0]) == 'Y' ) ! class->fMana = TRUE; else ! class->fMana = FALSE; send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "expbase" ) ) { ! class->exp_base = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } --- 7596,7654 ---- send_to_char( "Invalid prime attribute!\n\r", ch ); else { ! mudclass->attr_prime = x; send_to_char( "Done.\n\r", ch ); } return; } if ( !str_cmp( arg2, "weapon" ) ) { ! mudclass->weapon = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "guild" ) ) { ! mudclass->guild = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "thac0" ) ) { ! mudclass->thac0_00 = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "thac32" ) ) { ! mudclass->thac0_32 = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "hpmin" ) ) { ! mudclass->hp_min = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "hpmax" ) ) { ! mudclass->hp_max = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "mana" ) ) { if ( UPPER(argument[0]) == 'Y' ) ! mudclass->fMana = TRUE; else ! mudclass->fMana = FALSE; send_to_char( "Done.\n\r", ch ); return; } if ( !str_cmp( arg2, "expbase" ) ) { ! mudclass->exp_base = atoi( argument ); send_to_char( "Done.\n\r", ch ); return; } *************** *** 8866,8872 **** ch->substate = SUB_NONE; return; } ! pproject = ch->dest_buf; STRFREE( pproject->description ); pproject->description = copy_buffer ( ch ); stop_editing( ch ); --- 8866,8872 ---- ch->substate = SUB_NONE; return; } ! pproject = (PROJECT_DATA *) ch->dest_buf; STRFREE( pproject->description ); pproject->description = copy_buffer ( ch ); stop_editing( ch ); diff -c src.orig/ban.c src/ban.c *** src.orig/ban.c 1999-05-28 15:18:59.000000000 +1000 --- src/ban.c 2004-01-20 12:18:50.000000000 +1100 *************** *** 60,66 **** } for ( ; ; ) { ! word = feof (fp) ? "END" : fread_word ( fp ); fMatch = FALSE; switch ( UPPER ( word[0] ) ) { --- 60,66 ---- } for ( ; ; ) { ! word = feof (fp) ? (char *) "END" : fread_word ( fp ); fMatch = FALSE; switch ( UPPER ( word[0] ) ) { *************** *** 975,981 **** return 1; } case SUB_BAN_DESC: ! pban = ch->dest_buf; if ( !pban ) { bug ("do_ban: sub_ban_desc: NULL ch->dest_buf", 0); --- 975,981 ---- return 1; } case SUB_BAN_DESC: ! pban = (BAN_DATA *) ch->dest_buf; if ( !pban ) { bug ("do_ban: sub_ban_desc: NULL ch->dest_buf", 0); *************** *** 1171,1177 **** return FALSE; } for ( ; pban; pban = pban->next ) { ! if ( type == BAN_CLASS && pban->flag == ch->class ) { if ( check_expire( pban ) ) { --- 1171,1177 ---- return FALSE; } for ( ; pban; pban = pban->next ) { ! if ( type == BAN_CLASS && pban->flag == ch->mudclass ) { if ( check_expire( pban ) ) { diff -c src.orig/boards.c src/boards.c *** src.orig/boards.c 1999-05-28 15:18:59.000000000 +1000 --- src/boards.c 2004-01-21 12:34:50.000000000 +1100 *************** *** 430,436 **** stop_editing( ch ); return; } ! ed = ch->dest_buf; STRFREE( ed->description ); ed->description = copy_buffer( ch ); stop_editing( ch ); --- 430,436 ---- stop_editing( ch ); return; } ! ed = (EXTRA_DESCR_DATA *) ch->dest_buf; STRFREE( ed->description ); ed->description = copy_buffer( ch ); stop_editing( ch ); *************** *** 1027,1033 **** if ( !str_cmp( arg, "show" ) ) { ! char *subject, *to_list, *text; if ( ( paper = get_eq_char(ch, WEAR_HOLD) ) == NULL || paper->item_type != ITEM_PAPER ) --- 1027,1033 ---- if ( !str_cmp( arg, "show" ) ) { ! const char *subject, *to_list, *text; if ( ( paper = get_eq_char(ch, WEAR_HOLD) ) == NULL || paper->item_type != ITEM_PAPER ) *************** *** 1053,1059 **** if ( !str_cmp( arg, "post" ) ) { ! char *strtime, *to, *subj, *text/*, *np = NULL*/; #ifdef USE_IMC bool imc = FALSE; #endif --- 1053,1060 ---- if ( !str_cmp( arg, "post" ) ) { ! char *strtime; ! const char *to, *subj, *text/*, *np = NULL*/; #ifdef USE_IMC bool imc = FALSE; #endif *************** *** 1143,1149 **** CREATE( pnote, NOTE_DATA, 1 ); pnote->date = STRALLOC( strtime ); ! pnote->to_list = to ? STRALLOC( to ) : STRALLOC( "all" ); pnote->text = text ? STRALLOC( text ) : STRALLOC( "" ); pnote->subject = subj ? STRALLOC( subj ) : STRALLOC( "" ); pnote->sender = QUICKLINK( ch->name ); --- 1144,1150 ---- CREATE( pnote, NOTE_DATA, 1 ); pnote->date = STRALLOC( strtime ); ! pnote->to_list = to ? STRALLOC( to ) : STRALLOC("all" ); pnote->text = text ? STRALLOC( text ) : STRALLOC( "" ); pnote->subject = subj ? STRALLOC( subj ) : STRALLOC( "" ); pnote->sender = QUICKLINK( ch->name ); *************** *** 1368,1374 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 1369,1378 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) Only in src: boards.c.old diff -c src.orig/build.c src/build.c *** src.orig/build.c 1999-05-28 15:18:59.000000000 +1000 --- src/build.c 2004-01-21 07:33:53.000000000 +1100 *************** *** 458,464 **** return FALSE; } ! int get_otype( char *type ) { int x; --- 458,464 ---- return FALSE; } ! int get_otype( const char *type ) { int x; *************** *** 468,474 **** return -1; } ! int get_aflag( char *flag ) { int x; --- 468,474 ---- return -1; } ! int get_aflag( const char *flag ) { int x; *************** *** 488,494 **** return -1; } ! int get_atype( char *type ) { int x; --- 488,494 ---- return -1; } ! int get_atype( const char *type ) { int x; *************** *** 538,544 **** return -1; } ! int get_exflag( char *flag ) { int x; --- 538,544 ---- return -1; } ! int get_exflag( const char *flag ) { int x; *************** *** 574,580 **** return -1; } ! int get_rflag( char *flag ) { int x; --- 574,580 ---- return -1; } ! int get_rflag( const char *flag ) { int x; *************** *** 594,600 **** return -1; } ! int get_oflag( char *flag ) { int x; --- 594,600 ---- return -1; } ! int get_oflag( const char *flag ) { int x; *************** *** 614,620 **** return -1; } ! int get_wflag( char *flag ) { int x; --- 614,620 ---- return -1; } ! int get_wflag( const char *flag ) { int x; *************** *** 1078,1084 **** ch->substate = SUB_NONE; return; } ! victim = ch->dest_buf; if ( char_died(victim) ) { send_to_char( "Your victim died!\n\r", ch ); --- 1078,1084 ---- ch->substate = SUB_NONE; return; } ! victim = (CHAR_DATA *) ch->dest_buf; if ( char_died(victim) ) { send_to_char( "Your victim died!\n\r", ch ); *************** *** 1103,1109 **** if ( ch->substate == SUB_REPEATCMD ) { ! victim = ch->dest_buf; if ( char_died(victim) ) { --- 1103,1109 ---- if ( ch->substate == SUB_REPEATCMD ) { ! victim = (CHAR_DATA *) ch->dest_buf; if ( char_died(victim) ) { *************** *** 1466,1474 **** ch_printf( ch, "NPC Class range is 0 to %d.\n", MAX_NPC_CLASS-1 ); return; } ! victim->class = value; if ( xIS_SET(victim->act, ACT_PROTOTYPE) ) ! victim->pIndexData->class = value; return; } --- 1466,1474 ---- ch_printf( ch, "NPC Class range is 0 to %d.\n", MAX_NPC_CLASS-1 ); return; } ! victim->mudclass = value; if ( xIS_SET(victim->act, ACT_PROTOTYPE) ) ! victim->pIndexData->mudclass = value; return; } *************** *** 1478,1484 **** ch_printf( ch, "Class range is 0 to %d.\n", MAX_CLASS ); return; } ! victim->class = value; return; } --- 1478,1484 ---- ch_printf( ch, "Class range is 0 to %d.\n", MAX_CLASS ); return; } ! victim->mudclass = value; return; } *************** *** 2793,2799 **** int sn; for (sn = 0; sn < top_sn; sn++) ! if (skill_table[sn]->guild == victim->pcdata->clan->class && skill_table[sn]->name != NULL) victim->pcdata->learned[sn] = 0; } --- 2793,2799 ---- int sn; for (sn = 0; sn < top_sn; sn++) ! if (skill_table[sn]->guild == victim->pcdata->clan->mudclass && skill_table[sn]->name != NULL) victim->pcdata->learned[sn] = 0; } *************** *** 2970,2979 **** * the object and index-object lists, searching through the * extra_descr lists for a matching pointer... */ ! ed = ch->dest_buf; STRFREE( ed->description ); ed->description = copy_buffer( ch ); ! tmpobj = ch->spare_ptr; stop_editing( ch ); ch->dest_buf = tmpobj; ch->substate = ch->tempnum; --- 2970,2979 ---- * the object and index-object lists, searching through the * extra_descr lists for a matching pointer... */ ! ed = (EXTRA_DESCR_DATA *) ch->dest_buf; STRFREE( ed->description ); ed->description = copy_buffer( ch ); ! tmpobj = (OBJ_DATA *) ch->spare_ptr; stop_editing( ch ); ch->dest_buf = tmpobj; ch->substate = ch->tempnum; *************** *** 2987,2993 **** ch->substate = SUB_NONE; return; } ! obj = ch->dest_buf; if ( obj && obj_extracted(obj) ) { send_to_char( "Your object was extracted!\n\r", ch ); --- 2987,2993 ---- ch->substate = SUB_NONE; return; } ! obj = (OBJ_DATA *) ch->dest_buf; if ( obj && obj_extracted(obj) ) { send_to_char( "Your object was extracted!\n\r", ch ); *************** *** 3004,3010 **** obj->pIndexData->description = QUICKLINK( obj->description ); } } ! tmpobj = ch->spare_ptr; stop_editing( ch ); ch->substate = ch->tempnum; ch->dest_buf = tmpobj; --- 3004,3010 ---- obj->pIndexData->description = QUICKLINK( obj->description ); } } ! tmpobj = (OBJ_DATA *) ch->spare_ptr; stop_editing( ch ); ch->substate = ch->tempnum; ch->dest_buf = tmpobj; *************** *** 3016,3022 **** if ( ch->substate == SUB_REPEATCMD ) { ! obj = ch->dest_buf; if ( obj && obj_extracted(obj) ) { send_to_char( "Your object was extracted!\n\r", ch ); --- 3016,3022 ---- if ( ch->substate == SUB_REPEATCMD ) { ! obj = (OBJ_DATA *) ch->dest_buf; if ( obj && obj_extracted(obj) ) { send_to_char( "Your object was extracted!\n\r", ch ); *************** *** 4153,4159 **** default: break; case SUB_ROOM_DESC: ! location = ch->dest_buf; if ( !location ) { bug( "redit: sub_room_desc: NULL ch->dest_buf", 0 ); --- 4153,4159 ---- default: break; case SUB_ROOM_DESC: ! location = (ROOM_INDEX_DATA *) ch->dest_buf; if ( !location ) { bug( "redit: sub_room_desc: NULL ch->dest_buf", 0 ); *************** *** 4165,4171 **** ch->substate = ch->tempnum; return; case SUB_ROOM_EXTRA: ! ed = ch->dest_buf; if ( !ed ) { bug( "redit: sub_room_extra: NULL ch->dest_buf", 0 ); --- 4165,4171 ---- ch->substate = ch->tempnum; return; case SUB_ROOM_EXTRA: ! ed = (EXTRA_DESCR_DATA *) ch->dest_buf; if ( !ed ) { bug( "redit: sub_room_extra: NULL ch->dest_buf", 0 ); *************** *** 5939,5945 **** || pMobIndex->perm_con != 13 || pMobIndex->perm_cha != 13 || pMobIndex->perm_lck != 13 || pMobIndex->hitroll != 0 || pMobIndex->damroll != 0 ! || pMobIndex->race != 0 || pMobIndex->class != 3 || !xIS_EMPTY(pMobIndex->attacks) || !xIS_EMPTY(pMobIndex->defenses) || pMobIndex->height != 0 || pMobIndex->weight != 0 --- 5939,5945 ---- || pMobIndex->perm_con != 13 || pMobIndex->perm_cha != 13 || pMobIndex->perm_lck != 13 || pMobIndex->hitroll != 0 || pMobIndex->damroll != 0 ! || pMobIndex->race != 0 || pMobIndex->mudclass != 3 || !xIS_EMPTY(pMobIndex->attacks) || !xIS_EMPTY(pMobIndex->defenses) || pMobIndex->height != 0 || pMobIndex->weight != 0 *************** *** 5991,5997 **** pMobIndex->saving_spell_staff ); fprintf( fpout, "%d %d %d %d %d %d %d\n", pMobIndex->race, ! pMobIndex->class, pMobIndex->height, pMobIndex->weight, pMobIndex->speaks, --- 5991,5997 ---- pMobIndex->saving_spell_staff ); fprintf( fpout, "%d %d %d %d %d %d %d\n", pMobIndex->race, ! pMobIndex->mudclass, pMobIndex->height, pMobIndex->weight, pMobIndex->speaks, *************** *** 7460,7466 **** ch->substate = SUB_NONE; return; } ! mprog = ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); --- 7460,7466 ---- ch->substate = SUB_NONE; return; } ! mprog = (MPROG_DATA *) ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); *************** *** 7792,7798 **** ch->substate = SUB_NONE; return; } ! mprog = ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); --- 7792,7798 ---- ch->substate = SUB_NONE; return; } ! mprog = (MPROG_DATA *) ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); *************** *** 8095,8101 **** ch->substate = SUB_NONE; return; } ! mprog = ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); --- 8095,8101 ---- ch->substate = SUB_NONE; return; } ! mprog = (MPROG_DATA *) ch->dest_buf; if ( mprog->comlist ) STRFREE( mprog->comlist ); mprog->comlist = copy_buffer( ch ); diff -c src.orig/clans.c src/clans.c *** src.orig/clans.c 1999-05-28 15:18:59.000000000 +1000 --- src/clans.c 2004-01-20 09:13:26.000000000 +1100 *************** *** 156,162 **** fprintf( fp, "IllegalPK %d\n", clan->illegal_pk ); fprintf( fp, "Score %d\n", clan->score ); fprintf( fp, "Type %d\n", clan->clan_type ); ! fprintf( fp, "Class %d\n", clan->class ); fprintf( fp, "Favour %d\n", clan->favour ); fprintf( fp, "Strikes %d\n", clan->strikes ); fprintf( fp, "Members %d\n", clan->members ); --- 156,162 ---- fprintf( fp, "IllegalPK %d\n", clan->illegal_pk ); fprintf( fp, "Score %d\n", clan->score ); fprintf( fp, "Type %d\n", clan->clan_type ); ! fprintf( fp, "Class %d\n", clan->mudclass ); fprintf( fp, "Favour %d\n", clan->favour ); fprintf( fp, "Strikes %d\n", clan->strikes ); fprintf( fp, "Members %d\n", clan->members ); *************** *** 265,271 **** clan->mem_limit = 0; /* Set up defaults */ for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 265,274 ---- clan->mem_limit = 0; /* Set up defaults */ for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 290,296 **** KEY( "ClanObjThree",clan->clanobj3, fread_number( fp ) ); KEY( "ClanObjFour", clan->clanobj4, fread_number( fp ) ); KEY( "ClanObjFive", clan->clanobj5, fread_number( fp ) ); ! KEY( "Class", clan->class, fread_number( fp ) ); break; case 'D': --- 293,299 ---- KEY( "ClanObjThree",clan->clanobj3, fread_number( fp ) ); KEY( "ClanObjFour", clan->clanobj4, fread_number( fp ) ); KEY( "ClanObjFive", clan->clanobj5, fread_number( fp ) ); ! KEY( "Class", clan->mudclass, fread_number( fp ) ); break; case 'D': *************** *** 461,467 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 464,473 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 766,772 **** for ( ; ; ) { ! filename = feof( fpList ) ? "$" : fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; --- 772,781 ---- for ( ; ; ) { ! if (feof (fpList)) ! strcpy (filename, "$"); ! else ! filename = fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; *************** *** 809,815 **** for ( ; ; ) { ! filename = feof( fpList ) ? "$" : fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; --- 818,827 ---- for ( ; ; ) { ! if (feof (fpList)) ! strcpy (filename, "$"); ! else ! filename = fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; *************** *** 955,961 **** if ( clan->clan_type == CLAN_GUILD ) { ! if ( victim->class != clan->class) { send_to_char( "This player's will is not in accordance with your guild.\n\r", ch); return; --- 967,973 ---- if ( clan->clan_type == CLAN_GUILD ) { ! if ( victim->mudclass != clan->mudclass) { send_to_char( "This player's will is not in accordance with your guild.\n\r", ch); return; *************** *** 1024,1030 **** for ( sn = 0; sn < top_sn; sn++ ) { ! if (skill_table[sn]->guild == clan->class && skill_table[sn]->name != NULL ) { victim->pcdata->learned[sn] = GET_ADEPT(victim, sn); --- 1036,1042 ---- for ( sn = 0; sn < top_sn; sn++ ) { ! if (skill_table[sn]->guild == clan->mudclass && skill_table[sn]->name != NULL ) { victim->pcdata->learned[sn] = GET_ADEPT(victim, sn); *************** *** 1211,1217 **** int sn; for ( sn = 0; sn < top_sn; sn++ ) ! if ( skill_table[sn]->guild == victim->pcdata->clan->class && skill_table[sn]->name != NULL ) { victim->pcdata->learned[sn] = 0; --- 1223,1229 ---- int sn; for ( sn = 0; sn < top_sn; sn++ ) ! if ( skill_table[sn]->guild == victim->pcdata->clan->mudclass && skill_table[sn]->name != NULL ) { victim->pcdata->learned[sn] = 0; *************** *** 1538,1544 **** } if ( !str_cmp( arg2, "class" ) ) { ! clan->class = atoi( argument ); send_to_char( "Done.\n\r", ch ); save_clan( clan ); return; --- 1550,1556 ---- } if ( !str_cmp( arg2, "class" ) ) { ! clan->mudclass = atoi( argument ); send_to_char( "Done.\n\r", ch ); save_clan( clan ); return; *************** *** 1831,1838 **** clan->alignment ); if ( clan->clan_type == CLAN_GUILD ) ch_printf_color( ch, " &wClass : &W%d &w(&W%s&w)", ! clan->class, ! clan->classclass]->who_name: "unknown" ); send_to_char( "\n\r", ch ); ch_printf_color( ch, "&wBoard : &W%-5d &wRecall : &W%-5d &wStorage: &W%-5d\n\r", --- 1843,1850 ---- clan->alignment ); if ( clan->clan_type == CLAN_GUILD ) ch_printf_color( ch, " &wClass : &W%d &w(&W%s&w)", ! clan->mudclass, ! clan->mudclassmudclass]->who_name: "unknown" ); send_to_char( "\n\r", ch ); ch_printf_color( ch, "&wBoard : &W%-5d &wRecall : &W%-5d &wStorage: &W%-5d\n\r", *************** *** 2313,2331 **** } /* Check for class, assign percentage based on that. */ ! if (ch->class == CLASS_WARRIOR) chance = 70; ! if (ch->class == CLASS_VAMPIRE) chance = 65; ! if (ch->class == CLASS_RANGER) chance = 60; ! if (ch->class == CLASS_DRUID) chance = 45; ! if (ch->class == CLASS_CLERIC) chance = 35; ! if (ch->class == CLASS_THIEF) chance = 30; ! if (ch->class == CLASS_MAGE) chance = 15; /* Add 3 points to chance for every str point above 15, subtract for --- 2325,2343 ---- } /* Check for class, assign percentage based on that. */ ! if (ch->mudclass == CLASS_WARRIOR) chance = 70; ! if (ch->mudclass == CLASS_VAMPIRE) chance = 65; ! if (ch->mudclass == CLASS_RANGER) chance = 60; ! if (ch->mudclass == CLASS_DRUID) chance = 45; ! if (ch->mudclass == CLASS_CLERIC) chance = 35; ! if (ch->mudclass == CLASS_THIEF) chance = 30; ! if (ch->mudclass == CLASS_MAGE) chance = 15; /* Add 3 points to chance for every str point above 15, subtract for *************** *** 2524,2542 **** } /* Check for class, assign percentage based on that. */ ! if (ch->class == CLASS_WARRIOR) chance = 70; ! if (ch->class == CLASS_VAMPIRE) chance = 65; ! if (ch->class == CLASS_RANGER) chance = 60; ! if (ch->class == CLASS_DRUID) chance = 45; ! if (ch->class == CLASS_CLERIC) chance = 35; ! if (ch->class == CLASS_THIEF) chance = 30; ! if (ch->class == CLASS_MAGE) chance = 15; /* Add 3 points to chance for every str point above 15, subtract for --- 2536,2554 ---- } /* Check for class, assign percentage based on that. */ ! if (ch->mudclass == CLASS_WARRIOR) chance = 70; ! if (ch->mudclass == CLASS_VAMPIRE) chance = 65; ! if (ch->mudclass == CLASS_RANGER) chance = 60; ! if (ch->mudclass == CLASS_DRUID) chance = 45; ! if (ch->mudclass == CLASS_CLERIC) chance = 35; ! if (ch->mudclass == CLASS_THIEF) chance = 30; ! if (ch->mudclass == CLASS_MAGE) chance = 15; /* Add 3 points to chance for every str point above 15, subtract for diff -c src.orig/colorize.c src/colorize.c *** src.orig/colorize.c 1999-05-28 15:18:59.000000000 +1000 --- src/colorize.c 2004-01-20 12:58:35.000000000 +1100 *************** *** 18,23 **** --- 18,24 ---- #include #include + #include #include #include "mud.h" *************** *** 87,93 **** void do_colorize( CHAR_DATA *ch, char *argument ) { #define MAX_COLOR 16 ! static const char colors[MAX_COLOR] = "xrgObpcwzRGYBPCW"; static const char *color_names[MAX_COLOR] = { "black", "blood", "dgreen", "orange", "dblue", "purple", "cyan", "grey", "dgrey", "red", "green", "yellow", "blue", "pink", "lblue", --- 88,102 ---- void do_colorize( CHAR_DATA *ch, char *argument ) { #define MAX_COLOR 16 ! ! static const char colors[MAX_COLOR] = ! { ! 'x', 'r', 'g', 'O', 'b', ! 'p', 'c', 'w', 'z', 'R', ! 'G', 'Y', 'B', 'P', 'C', ! 'W' ! }; ! static const char *color_names[MAX_COLOR] = { "black", "blood", "dgreen", "orange", "dblue", "purple", "cyan", "grey", "dgrey", "red", "green", "yellow", "blue", "pink", "lblue", diff -c src.orig/comm.c src/comm.c *** src.orig/comm.c 2001-07-05 08:52:52.000000000 +1000 --- src/comm.c 2004-01-21 08:57:50.000000000 +1100 *************** *** 73,85 **** int gethostname ( char *name, int namelen ); #endif ! const unsigned char echo_off_str [] = { IAC, WILL, TELOPT_ECHO, '\0' }; ! const unsigned char echo_on_str [] = { IAC, WONT, TELOPT_ECHO, '\0' }; ! const unsigned char go_ahead_str [] = { IAC, GA, '\0' }; ! const unsigned char will_mxp_str [] = { IAC, WILL, TELOPT_MXP, '\0' }; ! const unsigned char start_mxp_str [] = { IAC, SB, TELOPT_MXP, IAC, SE, '\0' }; ! const unsigned char do_mxp_str [] = { IAC, DO, TELOPT_MXP, '\0' }; ! const unsigned char dont_mxp_str [] = { IAC, DONT, TELOPT_MXP, '\0' }; void auth_maxdesc args( ( int *md, fd_set *ins, fd_set *outs, --- 73,91 ---- int gethostname ( char *name, int namelen ); #endif ! // externs - NJG ! bool DONT_UPPER; ! bool MOBtrigger; ! int area_version; ! ! ! const char echo_off_str [] = { IAC, WILL, TELOPT_ECHO, '\0' }; ! const char echo_on_str [] = { IAC, WONT, TELOPT_ECHO, '\0' }; ! const char go_ahead_str [] = { IAC, GA, '\0' }; ! const char will_mxp_str [] = { IAC, WILL, TELOPT_MXP, '\0' }; ! const char start_mxp_str [] = { IAC, SB, TELOPT_MXP, IAC, SE, '\0' }; ! const char do_mxp_str [] = { IAC, DO, TELOPT_MXP, '\0' }; ! const char dont_mxp_str [] = { IAC, DONT, TELOPT_MXP, '\0' }; void auth_maxdesc args( ( int *md, fd_set *ins, fd_set *outs, *************** *** 478,484 **** return fd; } - /* static void SegVio() { CHAR_DATA *ch; --- 484,489 ---- *************** *** 494,505 **** } exit(0); } - */ /* * LAG alarm! -Thoric */ ! void caught_alarm() { char buf[MAX_STRING_LENGTH]; --- 499,509 ---- } exit(0); } /* * LAG alarm! -Thoric */ ! void caught_alarm(int) { char buf[MAX_STRING_LENGTH]; *************** *** 630,636 **** signal( SIGALRM, caught_alarm ); #endif ! /* signal( SIGSEGV, SegVio ); */ gettimeofday( &last_time, NULL ); current_time = (time_t) last_time.tv_sec; --- 634,640 ---- signal( SIGALRM, caught_alarm ); #endif ! // signal( SIGSEGV, SegVio ); gettimeofday( &last_time, NULL ); current_time = (time_t) last_time.tv_sec; *************** *** 866,872 **** struct sockaddr_in sock; struct hostent *from; int desc; ! int size; char bugbuf[MAX_STRING_LENGTH]; #ifdef WIN32 unsigned long arg = 1; --- 870,876 ---- struct sockaddr_in sock; struct hostent *from; int desc; ! socklen_t size; char bugbuf[MAX_STRING_LENGTH]; #ifdef WIN32 unsigned long arg = 1; *************** *** 1204,1210 **** void read_from_buffer( DESCRIPTOR_DATA *d ) { int i, j, k; ! unsigned char * p; /* * Hold horses if pending command already. --- 1208,1214 ---- void read_from_buffer( DESCRIPTOR_DATA *d ) { int i, j, k; ! char * p; /* * Hold horses if pending command already. *************** *** 1219,1225 **** for (p = d->inbuf; *p; p++) ! if (*p == IAC) { if (memcmp (p, do_mxp_str, strlen (do_mxp_str)) == 0) { --- 1223,1229 ---- for (p = d->inbuf; *p; p++) ! if ((unsigned char) *p == IAC) { if (memcmp (p, do_mxp_str, strlen (do_mxp_str)) == 0) { *************** *** 2135,2141 **** if ( toupper(arg[0]) == toupper(class_table[iClass]->who_name[0]) && !str_prefix( arg, class_table[iClass]->who_name ) ) { ! ch->class = iClass; break; } } --- 2139,2145 ---- if ( toupper(arg[0]) == toupper(class_table[iClass]->who_name[0]) && !str_prefix( arg, class_table[iClass]->who_name ) ) { ! ch->mudclass = iClass; break; } } *************** *** 2164,2170 **** { if (iRace != RACE_VAMPIRE && race_table[iRace]->race_name && race_table[iRace]->race_name[0] != '\0' ! && !IS_SET(race_table[iRace]->class_restriction, 1 << ch->class) && str_cmp(race_table[iRace]->race_name,"unused") ) { if ( iRace > 0 ) --- 2168,2174 ---- { if (iRace != RACE_VAMPIRE && race_table[iRace]->race_name && race_table[iRace]->race_name[0] != '\0' ! && !IS_SET(race_table[iRace]->class_restriction, 1 << ch->mudclass) && str_cmp(race_table[iRace]->race_name,"unused") ) { if ( iRace > 0 ) *************** *** 2218,2224 **** if ( iRace == MAX_PC_RACE || !race_table[iRace]->race_name || race_table[iRace]->race_name[0] == '\0' || iRace == RACE_VAMPIRE ! || IS_SET(race_table[iRace]->class_restriction, 1 << ch->class ) || !str_cmp(race_table[iRace]->race_name,"unused") ) { --- 2222,2228 ---- if ( iRace == MAX_PC_RACE || !race_table[iRace]->race_name || race_table[iRace]->race_name[0] == '\0' || iRace == RACE_VAMPIRE ! || IS_SET(race_table[iRace]->class_restriction, 1 << ch->mudclass ) || !str_cmp(race_table[iRace]->race_name,"unused") ) { *************** *** 2252,2258 **** } sprintf( log_buf, "%s@%s new %s %s.", ch->name, d->host, race_table[ch->race]->race_name, ! class_table[ch->class]->who_name ); log_string_plus( log_buf, LOG_COMM, sysdata.log_level); to_channel( log_buf, CHANNEL_MONITOR, "Monitor", LEVEL_IMMORTAL ); write_to_buffer( d, "Press [ENTER] ", 0 ); --- 2256,2262 ---- } sprintf( log_buf, "%s@%s new %s %s.", ch->name, d->host, race_table[ch->race]->race_name, ! class_table[ch->mudclass]->who_name ); log_string_plus( log_buf, LOG_COMM, sysdata.log_level); to_channel( log_buf, CHANNEL_MONITOR, "Monitor", LEVEL_IMMORTAL ); write_to_buffer( d, "Press [ENTER] ", 0 ); *************** *** 2309,2315 **** ch->pcdata->clan_name = STRALLOC( "" ); ch->pcdata->clan = NULL; ! switch ( class_table[ch->class]->attr_prime ) { case APPLY_STR: ch->perm_str = 16; break; case APPLY_INT: ch->perm_int = 16; break; --- 2313,2319 ---- ch->pcdata->clan_name = STRALLOC( "" ); ch->pcdata->clan = NULL; ! switch ( class_table[ch->mudclass]->attr_prime ) { case APPLY_STR: ch->perm_str = 16; break; case APPLY_INT: ch->perm_int = 16; break; *************** *** 2342,2348 **** ch->height = number_range(race_table[ch->race]->height *.9, race_table[ch->race]->height *1.1); ch->weight = number_range(race_table[ch->race]->weight *.9, race_table[ch->race]->weight *1.1); ! if ( ch->class == CLASS_PALADIN ) ch->alignment = 1000; if ( (iLang = skill_lookup( "common" )) < 0 ) --- 2346,2352 ---- ch->height = number_range(race_table[ch->race]->height *.9, race_table[ch->race]->height *1.1); ch->weight = number_range(race_table[ch->race]->weight *.9, race_table[ch->race]->weight *1.1); ! if ( ch->mudclass == CLASS_PALADIN ) ch->alignment = 1000; if ( (iLang = skill_lookup( "common" )) < 0 ) *************** *** 2376,2382 **** ch->mana = UMAX(1,ch->max_mana); ch->move = ch->max_move; sprintf( buf, "the %s", ! title_table [ch->class] [ch->level] [ch->sex == SEX_FEMALE ? 1 : 0] ); set_title( ch, buf ); --- 2380,2386 ---- ch->mana = UMAX(1,ch->max_mana); ch->move = ch->max_move; sprintf( buf, "the %s", ! title_table [ch->mudclass] [ch->level] [ch->sex == SEX_FEMALE ? 1 : 0] ); set_title( ch, buf ); *************** *** 3397,3403 **** int getcolor(char clr) { ! static const char colors[16] = "xrgObpcwzRGYBPCW"; int r; for ( r = 0; r < 16; r++ ) --- 3401,3414 ---- int getcolor(char clr) { ! static const char colors[16] = ! { ! 'x', 'r', 'g', 'O', 'b', ! 'p', 'c', 'w', 'z', 'R', ! 'G', 'Y', 'B', 'P', 'C', ! 'W' ! }; ! int r; for ( r = 0; r < 16; r++ ) diff -c src.orig/db.c src/db.c *** src.orig/db.c 1999-05-28 15:19:00.000000000 +1000 --- src/db.c 2004-01-20 13:01:41.000000000 +1100 *************** *** 1179,1185 **** sscanf( ln, "%d %d %d %d %d %d %d", &x1, &x2, &x3, &x4, &x5, &x6, &x7 ); pMobIndex->race = x1; ! pMobIndex->class = x2; pMobIndex->height = x3; pMobIndex->weight = x4; pMobIndex->speaks = x5; --- 1179,1185 ---- sscanf( ln, "%d %d %d %d %d %d %d", &x1, &x2, &x3, &x4, &x5, &x6, &x7 ); pMobIndex->race = x1; ! pMobIndex->mudclass = x2; pMobIndex->height = x3; pMobIndex->weight = x4; pMobIndex->speaks = x5; *************** *** 1230,1236 **** pMobIndex->perm_con = 13; pMobIndex->perm_lck = 13; pMobIndex->race = 0; ! pMobIndex->class = 3; pMobIndex->xflags = 0; pMobIndex->resistant = 0; pMobIndex->immune = 0; --- 1230,1236 ---- pMobIndex->perm_con = 13; pMobIndex->perm_lck = 13; pMobIndex->race = 0; ! pMobIndex->mudclass = 3; pMobIndex->xflags = 0; pMobIndex->resistant = 0; pMobIndex->immune = 0; *************** *** 2172,2178 **** */ void load_neighbor(AREA_DATA *tarea, FILE *fp) { ! NEIGHBOR_DATA *new; if(!tarea) { --- 2172,2178 ---- */ void load_neighbor(AREA_DATA *tarea, FILE *fp) { ! NEIGHBOR_DATA *mudnew; if(!tarea) { *************** *** 2186,2197 **** return; } ! CREATE(new, NEIGHBOR_DATA, 1); ! new->next = NULL; ! new->prev = NULL; ! new->address = NULL; ! new->name = fread_string(fp); ! LINK(new, tarea->weather->first_neighbor, tarea->weather->last_neighbor, next, prev); --- 2186,2197 ---- return; } ! CREATE(mudnew, NEIGHBOR_DATA, 1); ! mudnew->next = NULL; ! mudnew->prev = NULL; ! mudnew->address = NULL; ! mudnew->name = fread_string(fp); ! LINK(mudnew, tarea->weather->first_neighbor, tarea->weather->last_neighbor, next, prev); *************** *** 2535,2541 **** mob->hitroll = pMobIndex->hitroll; mob->damroll = pMobIndex->damroll; mob->race = pMobIndex->race; ! mob->class = pMobIndex->class; mob->xflags = pMobIndex->xflags; mob->saving_poison_death = pMobIndex->saving_poison_death; mob->saving_wand = pMobIndex->saving_wand; --- 2535,2541 ---- mob->hitroll = pMobIndex->hitroll; mob->damroll = pMobIndex->damroll; mob->race = pMobIndex->race; ! mob->mudclass = pMobIndex->mudclass; mob->xflags = pMobIndex->xflags; mob->saving_poison_death = pMobIndex->saving_poison_death; mob->saving_wand = pMobIndex->saving_wand; *************** *** 2787,2793 **** ch->weight = 180; ch->xflags = 0; ch->race = 0; ! ch->class = 3; ch->speaking = LANG_COMMON; ch->speaks = LANG_COMMON; ch->barenumdie = 1; --- 2787,2793 ---- ch->weight = 180; ch->xflags = 0; ch->race = 0; ! ch->mudclass = 3; ch->speaking = LANG_COMMON; ch->speaks = LANG_COMMON; ch->barenumdie = 1; *************** *** 2947,2953 **** /* * Get an extra description from a list. */ ! char *get_extra_descr( const char *name, EXTRA_DESCR_DATA *ed ) { for ( ; ed; ed = ed->next ) if ( is_name( name, ed->keyword ) ) --- 2947,2953 ---- /* * Get an extra description from a list. */ ! const char *get_extra_descr( char *name, EXTRA_DESCR_DATA *ed ) { for ( ; ed; ed = ed->next ) if ( is_name( name, ed->keyword ) ) *************** *** 4243,4253 **** gfp = fopen( buf, "r" ); if ( gfp ) { ! word = feof( gfp ) ? "End" : fread_word( gfp ); ilevel = fread_number( gfp ); fread_to_eol( gfp ); ! word = feof( gfp ) ? "End" : fread_word( gfp ); ! if ( !str_cmp( word, "Pcflags" ) ) iflags = fread_number( gfp ); else iflags = 0; --- 4243,4259 ---- gfp = fopen( buf, "r" ); if ( gfp ) { ! if (feof (gfp)) ! strcpy (word, "End"); ! else ! word = fread_word( gfp ); ilevel = fread_number( gfp ); fread_to_eol( gfp ); ! if (feof (gfp)) ! strcpy (word, "End"); ! else ! word = fread_word( gfp ); ! if ( !str_cmp( word, "Pcflags" ) ) iflags = fread_number( gfp ); else iflags = 0; *************** *** 5414,5420 **** pMobIndex->perm_con = 13; pMobIndex->perm_lck = 13; pMobIndex->race = 0; ! pMobIndex->class = 3; pMobIndex->xflags = 0; pMobIndex->resistant = 0; pMobIndex->immune = 0; --- 5420,5426 ---- pMobIndex->perm_con = 13; pMobIndex->perm_lck = 13; pMobIndex->race = 0; ! pMobIndex->mudclass = 3; pMobIndex->xflags = 0; pMobIndex->resistant = 0; pMobIndex->immune = 0; *************** *** 5459,5465 **** pMobIndex->perm_con = cMobIndex->perm_con; pMobIndex->perm_lck = cMobIndex->perm_lck; pMobIndex->race = cMobIndex->race; ! pMobIndex->class = cMobIndex->class; pMobIndex->xflags = cMobIndex->xflags; pMobIndex->resistant = cMobIndex->resistant; pMobIndex->immune = cMobIndex->immune; --- 5465,5471 ---- pMobIndex->perm_con = cMobIndex->perm_con; pMobIndex->perm_lck = cMobIndex->perm_lck; pMobIndex->race = cMobIndex->race; ! pMobIndex->mudclass = cMobIndex->mudclass; pMobIndex->xflags = cMobIndex->xflags; pMobIndex->resistant = cMobIndex->resistant; pMobIndex->immune = cMobIndex->immune; *************** *** 6167,6173 **** sys->mud_name = NULL; for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 6173,6182 ---- sys->mud_name = NULL; for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 6966,6972 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 6975,6984 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) diff -c src.orig/deity.c src/deity.c *** src.orig/deity.c 1999-05-28 15:19:00.000000000 +1000 --- src/deity.c 2004-01-20 09:30:28.000000000 +1100 *************** *** 129,135 **** fprintf( fp, "Sdeityobj %d\n", deity->sdeityobj ); fprintf( fp, "Srecall %d\n", deity->srecall ); fprintf( fp, "Race %d\n", deity->race ); ! fprintf( fp, "Class %d\n", deity->class ); fprintf( fp, "Element %d\n", deity->element ); fprintf( fp, "Sex %d\n", deity->sex ); fprintf( fp, "Affected %s\n", print_bitvector(&deity->affected) ); --- 129,135 ---- fprintf( fp, "Sdeityobj %d\n", deity->sdeityobj ); fprintf( fp, "Srecall %d\n", deity->srecall ); fprintf( fp, "Race %d\n", deity->race ); ! fprintf( fp, "Class %d\n", deity->mudclass ); fprintf( fp, "Element %d\n", deity->element ); fprintf( fp, "Sex %d\n", deity->sex ); fprintf( fp, "Affected %s\n", print_bitvector(&deity->affected) ); *************** *** 171,177 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 171,180 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 195,201 **** break; case 'C': ! KEY( "Class", deity->class, fread_number( fp ) ); break; case 'D': --- 198,204 ---- break; case 'C': ! KEY( "Class", deity->mudclass, fread_number( fp ) ); break; case 'D': *************** *** 351,357 **** for ( ; ; ) { ! filename = feof( fpList ) ? "$" : fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; --- 354,363 ---- for ( ; ; ) { ! if (feof (fpList)) ! strcpy (filename, "$"); ! else ! filename = fread_word( fpList ); log_string( filename ); if ( filename[0] == '$' ) break; *************** *** 390,396 **** return; case SUB_DEITYDESC: ! deity = ch->dest_buf; STRFREE( deity->description ); deity->description = copy_buffer( ch ); stop_editing( ch ); --- 396,402 ---- return; case SUB_DEITYDESC: ! deity = (DEITY_DATA *) ch->dest_buf; STRFREE( deity->description ); deity->description = copy_buffer( ch ); stop_editing( ch ); *************** *** 724,731 **** if ( !str_cmp( arg2, "class" ) ) { ! deity->class = atoi( argument ); ! if ( ( deity->class < 0 ) || ( deity->class >= MAX_PC_CLASS ) ) deity->class = -1; send_to_char( "Done.\n\r", ch ); save_deity( deity ); return; --- 730,737 ---- if ( !str_cmp( arg2, "class" ) ) { ! deity->mudclass = atoi( argument ); ! if ( ( deity->mudclass < 0 ) || ( deity->mudclass >= MAX_PC_CLASS ) ) deity->mudclass = -1; send_to_char( "Done.\n\r", ch ); save_deity( deity ); return; *************** *** 888,894 **** ( deity->npcfoe < 0 || deity->npcfoe > MAX_NPC_RACE ) ? "none" : npc_race[deity->npcfoe] ); ch_printf( ch, "Race: %-12sClass: %-11sSex: %-13sRace2: %s\n\r", ( deity->race < 0 || deity->race > MAX_PC_RACE ) ? "none" : race_table[deity->race]->race_name, ! ( deity->class < 0 || deity->class > MAX_PC_CLASS ) ? "none" : class_table[deity->class]->who_name, deity->sex == -1 ? "none" : deity->sex == SEX_MALE ? "male" : deity->sex == SEX_FEMALE ? "female" : "neutral", --- 894,900 ---- ( deity->npcfoe < 0 || deity->npcfoe > MAX_NPC_RACE ) ? "none" : npc_race[deity->npcfoe] ); ch_printf( ch, "Race: %-12sClass: %-11sSex: %-13sRace2: %s\n\r", ( deity->race < 0 || deity->race > MAX_PC_RACE ) ? "none" : race_table[deity->race]->race_name, ! ( deity->mudclass < 0 || deity->mudclass > MAX_PC_CLASS ) ? "none" : class_table[deity->mudclass]->who_name, deity->sex == -1 ? "none" : deity->sex == SEX_MALE ? "male" : deity->sex == SEX_FEMALE ? "female" : "neutral", *************** *** 1010,1017 **** return; } ! if ( ( deity->class != -1 ) ! && ( deity->class != ch->class ) ) { send_to_char( "That deity will not accept your worship due to your class.\n\r", ch ); return; --- 1016,1023 ---- return; } ! if ( ( deity->mudclass != -1 ) ! && ( deity->mudclass != ch->mudclass ) ) { send_to_char( "That deity will not accept your worship due to your class.\n\r", ch ); return; diff -c src.orig/fight.c src/fight.c *** src.orig/fight.c 2001-07-05 08:52:52.000000000 +1000 --- src/fight.c 2004-01-20 09:31:03.000000000 +1100 *************** *** 1127,1134 **** } else { ! thac0_00 = class_table[ch->class]->thac0_00; ! thac0_32 = class_table[ch->class]->thac0_32; } thac0 = interpolate( ch->level, thac0_00, thac0_32 ) - GET_HITROLL(ch); victim_ac = UMAX( -19, (int) (GET_AC(victim) / 10) ); --- 1127,1134 ---- } else { ! thac0_00 = class_table[ch->mudclass]->thac0_00; ! thac0_32 = class_table[ch->mudclass]->thac0_32; } thac0 = interpolate( ch->level, thac0_00, thac0_32 ) - GET_HITROLL(ch); victim_ac = UMAX( -19, (int) (GET_AC(victim) / 10) ); *************** *** 1467,1474 **** } else { ! thac0_00 = class_table[ch->class]->thac0_00; ! thac0_32 = class_table[ch->class]->thac0_32; } thac0 = interpolate( ch->level, thac0_00, thac0_32 ) - GET_HITROLL(ch) + (dist*2); victim_ac = UMAX( -19, (int) (GET_AC(victim) / 10) ); --- 1467,1474 ---- } else { ! thac0_00 = class_table[ch->mudclass]->thac0_00; ! thac0_32 = class_table[ch->mudclass]->thac0_32; } thac0 = interpolate( ch->level, thac0_00, thac0_32 ) - GET_HITROLL(ch) + (dist*2); victim_ac = UMAX( -19, (int) (GET_AC(victim) / 10) ); diff -c src.orig/grub.c src/grub.c *** src.orig/grub.c 1999-05-28 15:19:00.000000000 +1000 --- src/grub.c 2004-01-20 13:04:49.000000000 +1100 *************** *** 444,450 **** typedef struct gr_struct GR_STRUCT; typedef struct go_struct GO_STRUCT; ! int get_otype( char *type ); /* fun prototype for fun in build.c */ struct field_struct /* field table - info re each field */ { --- 444,450 ---- typedef struct gr_struct GR_STRUCT; typedef struct go_struct GO_STRUCT; ! int get_otype( const char *type ); /* fun prototype for fun in build.c */ struct field_struct /* field table - info re each field */ { *************** *** 471,484 **** } go_op [MAX_NUM_OPS]; enum gr_field_type /* enumerates the fields in the input record */ ! {name, sex, class, race, level, room, gold, clan, council, site, last, pkill}; struct gr_struct /* input record containing pfile info */ { char name [MAX_NAME_LENGTH]; char sex; ! char class; char race; char level; short room; --- 471,484 ---- } go_op [MAX_NUM_OPS]; enum gr_field_type /* enumerates the fields in the input record */ ! {name, sex, mudclass, race, level, room, gold, clan, council, site, last, pkill}; struct gr_struct /* input record containing pfile info */ { char name [MAX_NAME_LENGTH]; char sex; ! char mudclass; char race; char level; short room; *************** *** 1301,1308 **** if ( !go_eval_num (r.sex, gr_op[cou].op, gr_op[cou].nval) ) return FALSE; else break; ! case class: ! if ( !go_eval_num (r.class, gr_op[cou].op, gr_op[cou].nval) ) return FALSE; else break; case race: --- 1301,1308 ---- if ( !go_eval_num (r.sex, gr_op[cou].op, gr_op[cou].nval) ) return FALSE; else break; ! case mudclass: ! if ( !go_eval_num (r.mudclass, gr_op[cou].op, gr_op[cou].nval) ) return FALSE; else break; case race: *************** *** 1364,1371 **** if ( go_eval_num (r.sex, gr_op[cou].op, gr_op[cou].nval) ) return TRUE; else break; ! case class: ! if ( go_eval_num (r.class, gr_op[cou].op, gr_op[cou].nval) ) return TRUE; else break; case race: --- 1364,1371 ---- if ( go_eval_num (r.sex, gr_op[cou].op, gr_op[cou].nval) ) return TRUE; else break; ! case mudclass: ! if ( go_eval_num (r.mudclass, gr_op[cou].op, gr_op[cou].nval) ) return TRUE; else break; case race: *************** *** 1505,1511 **** int tot_match = 0; /* total records matched */ GR_STRUCT r; /* input (physical record) */ char sex[] = "NMF"; /* convert sex to text */ ! char class[] = "MCTWVDRAPN"; /* convert class to text */ char race[][3] = /* convert race to text */ {"Hu", "El", "Dw", "Ha", "Px", "Va", "Og", "HO", "HT", "HE", "Gi", "Dr", "SE", "Li", "Gn"}; --- 1505,1511 ---- int tot_match = 0; /* total records matched */ GR_STRUCT r; /* input (physical record) */ char sex[] = "NMF"; /* convert sex to text */ ! char mudclass[] = "MCTWVDRAPN"; /* convert class to text */ char race[][3] = /* convert race to text */ {"Hu", "El", "Dw", "Ha", "Px", "Va", "Og", "HO", "HT", "HE", "Gi", "Dr", "SE", "Li", "Gn"}; *************** *** 1543,1549 **** ch_printf(ch, "%-12s %2hd %c %2s %c %3s %3s %5hd %11ld %-15s %6lu %c\n\r", r.name, r.level, sex[(unsigned char) r.sex], ! race[(unsigned char) r.race], class[(unsigned char) r.class], clan[(unsigned char) r.clan], council[(unsigned char) r.council], r.room, r.gold, r.site, r.last, r.pkill); --- 1543,1549 ---- ch_printf(ch, "%-12s %2hd %c %2s %c %3s %3s %5hd %11ld %-15s %6lu %c\n\r", r.name, r.level, sex[(unsigned char) r.sex], ! race[(unsigned char) r.race], mudclass[(unsigned char) r.mudclass], clan[(unsigned char) r.clan], council[(unsigned char) r.council], r.room, r.gold, r.site, r.last, r.pkill); *************** *** 2018,2024 **** if (!str_cmp(arg1, "mrc")) { MOB_INDEX_DATA *pm; ! sh_int cou, race, class, dis_num, vnum1, vnum2, dis_cou = 0; if ( !*arg2 || !*arg3 || !*arg4 || !*arg5 || !*arg6 || !isdigit(*arg2) || !isdigit(*arg3) || !isdigit(*arg4) --- 2018,2024 ---- if (!str_cmp(arg1, "mrc")) { MOB_INDEX_DATA *pm; ! sh_int cou, race, mudclass, dis_num, vnum1, vnum2, dis_cou = 0; if ( !*arg2 || !*arg3 || !*arg4 || !*arg5 || !*arg6 || !isdigit(*arg2) || !isdigit(*arg3) || !isdigit(*arg4) *************** *** 2030,2041 **** } dis_num = UMIN(atoi (arg2), DIAG_MAX_SIZE); race = atoi (arg3); ! class = atoi (arg4); vnum1 = atoi (arg5); vnum2 = atoi (arg6); /* ch_printf(ch, "dis_num=%d race=%d class=%d vnum1=%d vnum2=%d\n\r", ! dis_num, race, class, vnum1, vnum2); */ send_to_char("\n\r", ch); --- 2030,2041 ---- } dis_num = UMIN(atoi (arg2), DIAG_MAX_SIZE); race = atoi (arg3); ! mudclass = atoi (arg4); vnum1 = atoi (arg5); vnum2 = atoi (arg6); /* ch_printf(ch, "dis_num=%d race=%d class=%d vnum1=%d vnum2=%d\n\r", ! dis_num, race, mudclass, vnum1, vnum2); */ send_to_char("\n\r", ch); *************** *** 2045,2051 **** for (pm = mob_index_hash[cou]; pm; pm = pm->next) { if ( pm->vnum >= vnum1 && pm->vnum <= vnum2 ! && pm->race==race && pm->class==class && dis_cou++ < dis_num ) pager_printf( ch, "%5d %s\n\r", pm->vnum, pm->player_name ); } } --- 2045,2051 ---- for (pm = mob_index_hash[cou]; pm; pm = pm->next) { if ( pm->vnum >= vnum1 && pm->vnum <= vnum2 ! && pm->race==race && pm->mudclass==mudclass && dis_cou++ < dis_num ) pager_printf( ch, "%5d %s\n\r", pm->vnum, pm->player_name ); } } diff -c src.orig/handler.c src/handler.c *** src.orig/handler.c 1999-05-28 15:19:00.000000000 +1000 --- src/handler.c 2004-01-20 13:03:26.000000000 +1100 *************** *** 81,87 **** { if ( IS_NPC(ch) ) return 1000; ! return class_table[ch->class]->exp_base; } /* -Thoric --- 81,87 ---- { if ( IS_NPC(ch) ) return 1000; ! return class_table[ch->mudclass]->exp_base; } /* -Thoric *************** *** 162,172 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_STR ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_STR ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_STR ) max = 16; else max = 20; --- 162,172 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_STR ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_STR ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_STR ) max = 16; else max = 20; *************** *** 183,193 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_INT ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_INT ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_INT ) max = 16; else max = 20; --- 183,193 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_INT ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_INT ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_INT ) max = 16; else max = 20; *************** *** 204,214 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_WIS ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_WIS ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_WIS ) max = 16; else max = 20; --- 204,214 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_WIS ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_WIS ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_WIS ) max = 16; else max = 20; *************** *** 225,235 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_DEX ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_DEX ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_DEX ) max = 16; else max = 20; --- 225,235 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_DEX ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_DEX ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_DEX ) max = 16; else max = 20; *************** *** 246,256 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_CON ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_CON ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_CON ) max = 16; else max = 20; --- 246,256 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_CON ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_CON ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_CON ) max = 16; else max = 20; *************** *** 265,275 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_CHA ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_CHA ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_CHA ) max = 16; else max = 20; --- 265,275 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_CHA ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_CHA ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_CHA ) max = 16; else max = 20; *************** *** 284,294 **** { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->class]->attr_prime == APPLY_LCK ) max = 25; ! else if ( class_table[ch->class]->attr_second == APPLY_LCK ) max = 22; ! else if ( class_table[ch->class]->attr_deficient == APPLY_LCK ) max = 16; else max = 20; --- 284,294 ---- { sh_int max; ! if ( IS_NPC(ch) || class_table[ch->mudclass]->attr_prime == APPLY_LCK ) max = 25; ! else if ( class_table[ch->mudclass]->attr_second == APPLY_LCK ) max = 22; ! else if ( class_table[ch->mudclass]->attr_deficient == APPLY_LCK ) max = 16; else max = 20; *************** *** 365,371 **** /* * See if a string is one of the names of an object. */ ! bool is_name( const char *str, char *namelist ) { char name[MAX_INPUT_LENGTH]; --- 365,371 ---- /* * See if a string is one of the names of an object. */ ! bool is_name( char *str, char *namelist ) { char name[MAX_INPUT_LENGTH]; *************** *** 379,385 **** } } ! bool is_name_prefix( const char *str, char *namelist ) { char name[MAX_INPUT_LENGTH]; --- 379,385 ---- } } ! bool is_name_prefix( char *str, char *namelist ) { char name[MAX_INPUT_LENGTH]; *************** *** 956,964 **** SET_BIT(ch->susceptible, race_table[ch->race]->suscept); /* Add in effects from class */ ! xSET_BITS(ch->affected_by, class_table[ch->class]->affected); ! SET_BIT(ch->resistant, class_table[ch->class]->resist); ! SET_BIT(ch->susceptible, class_table[ch->class]->suscept); /* Add in effects from deities */ if (ch->pcdata->deity) --- 956,964 ---- SET_BIT(ch->susceptible, race_table[ch->race]->suscept); /* Add in effects from class */ ! xSET_BITS(ch->affected_by, class_table[ch->mudclass]->affected); ! SET_BIT(ch->resistant, class_table[ch->mudclass]->resist); ! SET_BIT(ch->susceptible, class_table[ch->mudclass]->suscept); /* Add in effects from deities */ if (ch->pcdata->deity) *************** *** 2806,2812 **** /* * Return ascii name of an affect bit vector. */ ! char *affect_bit_name( EXT_BV *vector ) { static char buf[512]; --- 2806,2812 ---- /* * Return ascii name of an affect bit vector. */ ! const char *affect_bit_name( EXT_BV *vector ) { static char buf[512]; *************** *** 2852,2858 **** /* * Return ascii name of extra flags vector. */ ! char *extra_bit_name( EXT_BV *extra_flags ) { static char buf[512]; --- 2852,2858 ---- /* * Return ascii name of extra flags vector. */ ! const char *extra_bit_name( EXT_BV *extra_flags ) { static char buf[512]; *************** *** 2891,2897 **** /* * Return ascii name of magic flags vector. - Scryn */ ! char *magic_bit_name( int magic_flags ) { static char buf[512]; --- 2891,2897 ---- /* * Return ascii name of magic flags vector. - Scryn */ ! const char *magic_bit_name( int magic_flags ) { static char buf[512]; diff -c src.orig/hashstr.c src/hashstr.c *** src.orig/hashstr.c 1999-05-28 15:19:00.000000000 +1000 --- src/hashstr.c 2004-01-20 13:13:48.000000000 +1100 *************** *** 42,48 **** * If found, increase link count, and return pointer, * otherwise add new string to hash table, and return pointer. */ ! char *str_alloc( char *str ) { register int len, hash, psize; register struct hashstr_data *ptr; --- 42,48 ---- * If found, increase link count, and return pointer, * otherwise add new string to hash table, and return pointer. */ ! char *str_alloc( const char *str ) { register int len, hash, psize; register struct hashstr_data *ptr; diff -c src.orig/ibuild.c src/ibuild.c *** src.orig/ibuild.c 1999-05-28 15:19:00.000000000 +1000 --- src/ibuild.c 2004-01-20 11:26:15.000000000 +1100 *************** *** 59,65 **** { "-", "b", 13, 2, "", NULL, STRING, 0, "rmenu b" }, { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; MENU_DATA mob_help_page_data[] = --- 59,65 ---- { "-", "b", 13, 2, "", NULL, STRING, 0, "rmenu b" }, { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; MENU_DATA mob_help_page_data[] = *************** *** 71,77 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; MENU_DATA obj_help_page_data[] = --- 71,77 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; MENU_DATA obj_help_page_data[] = *************** *** 82,95 **** { "-", "d", 13, 2, "", NULL, STRING, 1, "omenu %s d" }, { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; MENU_DATA control_help_page_data[] = { { "-", "a", 13, 2, "", NULL, STRING, 0, "cmenu a" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "cmenu h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; MENU_DATA room_page_d_data[] = --- 82,95 ---- { "-", "d", 13, 2, "", NULL, STRING, 1, "omenu %s d" }, { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; MENU_DATA control_help_page_data[] = { { "-", "a", 13, 2, "", NULL, STRING, 0, "cmenu a" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "cmenu h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; MENU_DATA room_page_d_data[] = *************** *** 244,250 **** { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 244,250 ---- { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 303,309 **** { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 303,309 ---- { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 320,326 **** { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 320,326 ---- { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 435,441 **** { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, (int)NULL, 0, NULL } }; --- 435,441 ---- { "-", "c", 13, 2, "", NULL, STRING, 0, "rmenu c" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "rmenu h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 587,593 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 587,593 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 677,683 **** { "-", "d", 13, 2, "", NULL, STRING, 1, "omenu %s d" }, { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 677,683 ---- { "-", "d", 13, 2, "", NULL, STRING, 1, "omenu %s d" }, { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 738,744 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 738,744 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 885,891 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 885,891 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 1039,1045 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 1039,1045 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "omenu %s e" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "omenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 1146,1152 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 1, NULL } }; MENU_DATA mob_page_f_data[] = {{ "1", "a", 2, 27, "%1.1s", NULL, STRING, 1, "mset %s race human" }, --- 1146,1152 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 1, NULL } }; MENU_DATA mob_page_f_data[] = {{ "1", "a", 2, 27, "%1.1s", NULL, STRING, 1, "mset %s race human" }, *************** *** 1248,1254 **** { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, (int) NULL, 1, NULL } }; MENU_DATA mob_page_b_data[] = {{ --- 1248,1254 ---- { "-", "e", 13, 2, "", NULL, STRING, 1, "mmenu %s e" }, { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, ! { " ", " ", 0, 0, " ", NULL, 0, 1, NULL } }; MENU_DATA mob_page_b_data[] = {{ *************** *** 1391,1397 **** { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int)NULL, 1, NULL } }; --- 1391,1397 ---- { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 1, NULL } }; *************** *** 1557,1563 **** { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int)NULL, 1, NULL } }; --- 1557,1563 ---- { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 1, NULL } }; *************** *** 1669,1675 **** { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int)NULL, 0, NULL } }; --- 1669,1675 ---- { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 1830,1836 **** { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, (int)NULL, 0, NULL } }; --- 1830,1836 ---- { "-", "f", 13, 2, "", NULL, STRING, 1, "mmenu %s f" }, { "-", "h", 13, 2, "", NULL, STRING, 1, "mmenu %s h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 1863,1869 **** { "-", "a", 13, 2, "", NULL, STRING, 0, "cmenu a" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "cmenu h" }, { ! " ", " ", 0, 0, " ", NULL, (int) NULL, 0, NULL } }; --- 1863,1869 ---- { "-", "a", 13, 2, "", NULL, STRING, 0, "cmenu a" }, { "-", "h", 13, 2, "", NULL, STRING, 0, "cmenu h" }, { ! " ", " ", 0, 0, " ", NULL, 0, 0, NULL } }; *************** *** 2417,2423 **** bug("refresh_page: Get_mob_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_mob_page(ch, idx, page); return; case ROOM_TYPE: switch (ch->inter_page) { --- 2417,2423 ---- bug("refresh_page: Get_mob_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_mob_page(ch, (MOB_INDEX_DATA *) idx, page); return; case ROOM_TYPE: switch (ch->inter_page) { *************** *** 2440,2446 **** bug("refresh_page: Get_room_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_room_page(ch, idx, page); return; case OBJ_TYPE: switch (ch->inter_page) { --- 2440,2446 ---- bug("refresh_page: Get_room_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_room_page(ch, (ROOM_INDEX_DATA *) idx, page); return; case OBJ_TYPE: switch (ch->inter_page) { *************** *** 2469,2475 **** bug("refresh_page: Get_obj_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_obj_page(ch, idx, page); return; case CONTROL_TYPE: switch (ch->inter_page) { --- 2469,2475 ---- bug("refresh_page: Get_obj_index: bad vnum %d.", ch->inter_editing_vnum); send_to_char(" do_refresh_page: bizarre bug! that vnum evaporated \n\r", ch); } ! fill_in_obj_page(ch, (OBJ_INDEX_DATA *) idx, page); return; case CONTROL_TYPE: switch (ch->inter_page) { *************** *** 2518,2524 **** } ! for (i = 0; m_data[i].ptrType != (int)NULL; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) --- 2518,2524 ---- } ! for (i = 0; m_data[i].ptrType != 0; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) *************** *** 2605,2611 **** room_page_c_data[13].data = xit->to_room->name; room_page_c_data[14].data = &(xit->key); if ((pObjIndex = get_obj_index(xit->key)) == NULL) { ! room_page_c_data[15].data = "No (or Unknown) Key"; } else { room_page_c_data[15].data = pObjIndex->name; } --- 2605,2611 ---- room_page_c_data[13].data = xit->to_room->name; room_page_c_data[14].data = &(xit->key); if ((pObjIndex = get_obj_index(xit->key)) == NULL) { ! room_page_c_data[15].data = (char *) "No (or Unknown) Key"; } else { room_page_c_data[15].data = pObjIndex->name; } *************** *** 2665,2671 **** } ! for (i = 0; m_data[i].ptrType != (int)NULL; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) --- 2665,2671 ---- } ! for (i = 0; m_data[i].ptrType != 0; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) *************** *** 2814,2820 **** break; case 'c': m_data = obj_page_c_data; ! obj_page_c_data[0].data = "\\"; tmp[1] = get_affect(idx, APPLY_SAVING_POISON); tmp[2] = get_affect(idx, APPLY_AGE); tmp[3] = get_affect(idx, APPLY_STR); --- 2814,2820 ---- break; case 'c': m_data = obj_page_c_data; ! obj_page_c_data[0].data = (char *) "\\"; tmp[1] = get_affect(idx, APPLY_SAVING_POISON); tmp[2] = get_affect(idx, APPLY_AGE); tmp[3] = get_affect(idx, APPLY_STR); *************** *** 2972,2978 **** } ! for (i = 0; m_data[i].ptrType != (int) NULL; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) --- 2972,2978 ---- } ! for (i = 0; m_data[i].ptrType != 0; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) *************** *** 3345,3368 **** mob_page_a_data[16].data = &(idx->perm_cha); mob_page_a_data[17].data = &(idx->ac); ! mob_page_a_data[18].data = (idx->class == 0) ? check : space; ! mob_page_a_data[19].data = (idx->class == 1) ? check : space; ! mob_page_a_data[20].data = (idx->class == 2) ? check : space; ! mob_page_a_data[21].data = (idx->class == 3) ? check : space; ! mob_page_a_data[22].data = (idx->class == 4) ? check : space; ! mob_page_a_data[23].data = (idx->class == 5) ? check : space; ! mob_page_a_data[24].data = (idx->class == 6) ? check : space; ! mob_page_a_data[25].data = (idx->class == 20) ? check : space; ! mob_page_a_data[26].data = (idx->class == 21) ? check : space; ! mob_page_a_data[27].data = (idx->class == 22) ? check : space; ! mob_page_a_data[28].data = (idx->class == 23) ? check : space; ! mob_page_a_data[29].data = (idx->class == 24) ? check : space; ! mob_page_a_data[30].data = (idx->class == 25) ? check : space; break; } ! for (i = 0; m_data[i].ptrType != (int) NULL; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) --- 3345,3368 ---- mob_page_a_data[16].data = &(idx->perm_cha); mob_page_a_data[17].data = &(idx->ac); ! mob_page_a_data[18].data = (idx->mudclass == 0) ? check : space; ! mob_page_a_data[19].data = (idx->mudclass == 1) ? check : space; ! mob_page_a_data[20].data = (idx->mudclass == 2) ? check : space; ! mob_page_a_data[21].data = (idx->mudclass == 3) ? check : space; ! mob_page_a_data[22].data = (idx->mudclass == 4) ? check : space; ! mob_page_a_data[23].data = (idx->mudclass == 5) ? check : space; ! mob_page_a_data[24].data = (idx->mudclass == 6) ? check : space; ! mob_page_a_data[25].data = (idx->mudclass == 20) ? check : space; ! mob_page_a_data[26].data = (idx->mudclass == 21) ? check : space; ! mob_page_a_data[27].data = (idx->mudclass == 22) ? check : space; ! mob_page_a_data[28].data = (idx->mudclass == 23) ? check : space; ! mob_page_a_data[29].data = (idx->mudclass == 24) ? check : space; ! mob_page_a_data[30].data = (idx->mudclass == 25) ? check : space; break; } ! for (i = 0; m_data[i].ptrType != 0; i++) { sprintf(buf, "\x1B[%d;%dH", m_data[i].x, m_data[i].y); write_to_buffer(ch->desc, buf, strlen(buf)); switch(m_data[i].ptrType) diff -c src.orig/ident.c src/ident.c *** src.orig/ident.c 1999-05-28 15:19:00.000000000 +1000 --- src/ident.c 2004-01-20 11:26:56.000000000 +1100 *************** *** 296,302 **** CHAR_DATA *ch = (d->original ? d->original : d->character); AUTH_DATA *a; struct sockaddr_in us, them; ! int ulen = sizeof(us), tlen = sizeof(them); /* To stop an uninitialized memory read --Shaddai */ us.sin_port = 0; --- 296,302 ---- CHAR_DATA *ch = (d->original ? d->original : d->character); AUTH_DATA *a; struct sockaddr_in us, them; ! socklen_t ulen = sizeof(us), tlen = sizeof(them); /* To stop an uninitialized memory read --Shaddai */ us.sin_port = 0; diff -c src.orig/imm_host.c src/imm_host.c *** src.orig/imm_host.c 1999-05-28 15:19:00.000000000 +1000 --- src/imm_host.c 2004-01-20 12:19:59.000000000 +1100 *************** *** 59,65 **** while ( my_continue ) { ! word = feof (fp) ? "#END" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) --- 59,65 ---- while ( my_continue ) { ! word = feof (fp) ? (char *) "#END" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) *************** *** 110,116 **** for ( ; ; ) { ! word = feof (fp) ? "End" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) --- 110,116 ---- for ( ; ; ) { ! word = feof (fp) ? (char *) "End" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) diff -c src.orig/interp.c src/interp.c *** src.orig/interp.c 2001-07-05 08:52:52.000000000 +1000 --- src/interp.c 2004-01-20 11:35:17.000000000 +1100 *************** *** 467,473 **** } if( m_data ) { ! for(i=0;m_data[i].ptrType!= (int) NULL;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) --- 467,473 ---- } if( m_data ) { ! for(i=0;m_data[i].ptrType!= 0;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) *************** *** 531,537 **** } if( m_data ) { ! for(i=0;m_data[i].ptrType!=(int)NULL;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) --- 531,537 ---- } if( m_data ) { ! for(i=0;m_data[i].ptrType!=0;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) *************** *** 589,595 **** } if( m_data ) { ! for(i=0;m_data[i].ptrType!=(int)NULL;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) --- 589,595 ---- } if( m_data ) { ! for(i=0;m_data[i].ptrType!=0;i++) { /*IF 1st char matches && 2nd CHAR MATCHES...*/ if(! strcmp(m_data[i].sectionNum,command)) *************** *** 963,969 **** /* * Return true if an argument is completely numeric. */ ! bool is_number( char *arg ) { bool first = TRUE; if ( *arg == '\0' ) --- 963,969 ---- /* * Return true if an argument is completely numeric. */ ! bool is_number( const char *arg ) { bool first = TRUE; if ( *arg == '\0' ) diff -c src.orig/magic.c src/magic.c *** src.orig/magic.c 1999-05-28 15:19:00.000000000 +1000 --- src/magic.c 2004-01-20 11:32:33.000000000 +1100 *************** *** 70,76 **** if ( !skill_table[sn]->name ) break; if ( ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->class] && LOWER(name[0]) == LOWER(skill_table[sn]->name[0]) && !str_prefix( name, skill_table[sn]->name ) ) return sn; --- 70,76 ---- if ( !skill_table[sn]->name ) break; if ( ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->mudclass] && LOWER(name[0]) == LOWER(skill_table[sn]->name[0]) && !str_prefix( name, skill_table[sn]->name ) ) return sn; *************** *** 250,256 **** if ( LOWER(name[0]) == LOWER(skill_table[sn]->name[0]) && !str_prefix(name, skill_table[sn]->name) && ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->class] ) return sn; if (first >= top) return -1; --- 250,256 ---- if ( LOWER(name[0]) == LOWER(skill_table[sn]->name[0]) && !str_prefix(name, skill_table[sn]->name) && ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->mudclass] ) return sn; if (first >= top) return -1; *************** *** 272,278 **** if (!str_cmp(name, skill_table[sn]->name) && ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->class] ) return sn; if (first >= top) return -1; --- 272,278 ---- if (!str_cmp(name, skill_table[sn]->name) && ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->mudclass] ) return sn; if (first >= top) return -1; *************** *** 357,368 **** dispel_casting (AFFECT_DATA *paf,CHAR_DATA *ch,CHAR_DATA *victim,int affect, bool dispel) { char buf[MAX_STRING_LENGTH]; ! char *spell; SKILLTYPE *sktmp; bool is_mage = FALSE, has_detect = FALSE; EXT_BV ext_bv = meb(affect); ! if ( IS_NPC ( ch ) || ch->class == CLASS_MAGE ) is_mage = TRUE; if ( IS_AFFECTED (ch, AFF_DETECT_MAGIC) ) has_detect = TRUE; --- 357,368 ---- dispel_casting (AFFECT_DATA *paf,CHAR_DATA *ch,CHAR_DATA *victim,int affect, bool dispel) { char buf[MAX_STRING_LENGTH]; ! const char *spell; SKILLTYPE *sktmp; bool is_mage = FALSE, has_detect = FALSE; EXT_BV ext_bv = meb(affect); ! if ( IS_NPC ( ch ) || ch->mudclass == CLASS_MAGE ) is_mage = TRUE; if ( IS_AFFECTED (ch, AFF_DETECT_MAGIC) ) has_detect = TRUE; *************** *** 609,615 **** struct syl_type { char * old; ! char * new; }; static const struct syl_type syl_table[] = --- 609,615 ---- struct syl_type { char * old; ! char * newthing; }; static const struct syl_type syl_table[] = *************** *** 654,660 **** { if ( !str_prefix( syl_table[iSyl].old, pName ) ) { ! strcat( buf, syl_table[iSyl].new ); break; } } --- 654,660 ---- { if ( !str_prefix( syl_table[iSyl].old, pName ) ) { ! strcat( buf, syl_table[iSyl].newthing ); break; } } *************** *** 669,675 **** for ( rch = ch->in_room->first_person; rch; rch = rch->next_in_room ) { if ( rch != ch ) ! act( AT_MAGIC, ch->class==rch->class ? buf : buf2, ch, NULL, rch, TO_VICT ); } --- 669,675 ---- for ( rch = ch->in_room->first_person; rch; rch = rch->next_in_room ) { if ( rch != ch ) ! act( AT_MAGIC, ch->mudclass==rch->mudclass ? buf : buf2, ch, NULL, rch, TO_VICT ); } *************** *** 1333,1339 **** if ( get_trust(ch) < LEVEL_GOD ) { if ( ( sn = find_spell( ch, arg1, TRUE ) ) < 0 ! || ( !IS_NPC(ch) && ch->level < skill_table[sn]->skill_level[ch->class] ) ) { send_to_char( "You can't do that.\n\r", ch ); return; --- 1333,1339 ---- if ( get_trust(ch) < LEVEL_GOD ) { if ( ( sn = find_spell( ch, arg1, TRUE ) ) < 0 ! || ( !IS_NPC(ch) && ch->level < skill_table[sn]->skill_level[ch->mudclass] ) ) { send_to_char( "You can't do that.\n\r", ch ); return; *************** *** 1447,1453 **** && !IS_IMMORTAL(ch) && skill->guild != CLASS_NONE && (!ch->pcdata->clan ! || skill->guild != ch->pcdata->clan->class) ) { send_to_char( "That is only available to members of a certain guild.\n\r", ch); return; --- 1447,1453 ---- && !IS_IMMORTAL(ch) && skill->guild != CLASS_NONE && (!ch->pcdata->clan ! || skill->guild != ch->pcdata->clan->mudclass) ) { send_to_char( "That is only available to members of a certain guild.\n\r", ch); return; *************** *** 1462,1468 **** } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->class] ) ); /* * Locate targets. --- 1462,1468 ---- } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->mudclass] ) ); /* * Locate targets. *************** *** 1523,1529 **** return; } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->class] ) ); blood = UMAX(1, (mana+4) / 8); if ( IS_VAMPIRE(ch) ) gain_condition( ch, COND_BLOODTHIRST, - UMAX(1, blood / 3) ); --- 1523,1529 ---- return; } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->mudclass] ) ); blood = UMAX(1, (mana+4) / 8); if ( IS_VAMPIRE(ch) ) gain_condition( ch, COND_BLOODTHIRST, - UMAX(1, blood / 3) ); *************** *** 1550,1556 **** return; } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->class] ) ); blood = UMAX(1, (mana+4) / 8); strcpy( staticbuf, ch->alloc_ptr ); target_name = one_argument(staticbuf, arg2); --- 1550,1556 ---- return; } mana = IS_NPC(ch) ? 0 : UMAX(skill->min_mana, ! 100 / ( 2 + ch->level - skill->skill_level[ch->mudclass] ) ); blood = UMAX(1, (mana+4) / 8); strcpy( staticbuf, ch->alloc_ptr ); target_name = one_argument(staticbuf, arg2); *************** *** 2625,2631 **** return rSPELL_FAILED; } ! if ( IS_NPC(ch) || ch->class == CLASS_MAGE ) is_mage = TRUE; if ( is_mage ) --- 2625,2631 ---- return rSPELL_FAILED; } ! if ( IS_NPC(ch) || ch->mudclass == CLASS_MAGE ) is_mage = TRUE; if ( is_mage ) *************** *** 4089,4095 **** send_to_char( "Your muscles seem to atrophy!\n\r", victim ); if ( ch != victim ) { ! if ( ( ( ( !IS_NPC(victim) && class_table[victim->class]->attr_prime == APPLY_STR ) || IS_NPC(victim) ) && get_curr_str(victim) < 25 ) || get_curr_str(victim) < 20 ) --- 4089,4095 ---- send_to_char( "Your muscles seem to atrophy!\n\r", victim ); if ( ch != victim ) { ! if ( ( ( ( !IS_NPC(victim) && class_table[victim->mudclass]->attr_prime == APPLY_STR ) || IS_NPC(victim) ) && get_curr_str(victim) < 25 ) || get_curr_str(victim) < 20 ) *************** *** 5070,5076 **** char buf[MAX_STRING_LENGTH]; AFFECT_DATA af; SKILLTYPE *skill = get_skilltype(sn); ! int try; if (!ch->desc || ch->desc->original) { --- 5070,5076 ---- char buf[MAX_STRING_LENGTH]; AFFECT_DATA af; SKILLTYPE *skill = get_skilltype(sn); ! int trything; if (!ch->desc || ch->desc->original) { *************** *** 5109,5121 **** return rSPELL_FAILED; } ! try = ris_save( victim, level, RIS_CHARM ); if ( IS_AFFECTED(victim, AFF_POSSESS) || IS_AFFECTED(ch, AFF_CHARM) || level < victim->level || victim->desc ! || saves_spell_staff( try, victim ) || !chance(ch, 25) ) { failed_casting( skill, ch, victim, NULL ); --- 5109,5121 ---- return rSPELL_FAILED; } ! trything = ris_save( victim, level, RIS_CHARM ); if ( IS_AFFECTED(victim, AFF_POSSESS) || IS_AFFECTED(ch, AFF_CHARM) || level < victim->level || victim->desc ! || saves_spell_staff( trything, victim ) || !chance(ch, 25) ) { failed_casting( skill, ch, victim, NULL ); diff -c src.orig/Makefile src/Makefile *** src.orig/Makefile 1999-05-28 15:18:59.000000000 +1000 --- src/Makefile 2004-01-21 12:40:33.000000000 +1100 *************** *** 1,4 **** ! CC = gcc #PROF = -p NOCRYPT = --- 1,4 ---- ! CC = g++ #PROF = -p NOCRYPT = *************** *** 25,31 **** #your core files may not be as much of a benefit if you do. #OPT_FLAG = -finline-functions -funroll-loops -fdefer-pop -fstrength-reduce ! C_FLAGS = $(OPT_FLAG) -O -g3 -Wall -Wuninitialized $(PROF) $(NOCRYPT) $(DBUGFLG) -DSMAUG $(SOLARIS_FLAG) $(TIME) $(REG) L_FLAGS = $(OPT_FLAG) $(PROF) $(SOLARIS_LINK) $(NEED_CRYPT) #Uncomment the next three comments below if you want to use IMC --- 25,31 ---- #your core files may not be as much of a benefit if you do. #OPT_FLAG = -finline-functions -funroll-loops -fdefer-pop -fstrength-reduce ! C_FLAGS = $(OPT_FLAG) -g3 -Wall $(PROF) $(NOCRYPT) $(DBUGFLG) -DSMAUG $(SOLARIS_FLAG) $(TIME) $(REG) L_FLAGS = $(OPT_FLAG) $(PROF) $(SOLARIS_LINK) $(NEED_CRYPT) #Uncomment the next three comments below if you want to use IMC diff -c src.orig/mpxset.c src/mpxset.c *** src.orig/mpxset.c 1999-05-28 15:19:00.000000000 +1000 --- src/mpxset.c 2004-01-21 06:53:56.000000000 +1100 *************** *** 21,28 **** #include "mud.h" ! int get_otype args( ( char *type ) ); ! int get_aflag args( ( char *flag ) ); int get_npc_race args( ( char *type ) ); int get_actflag args( ( char *flag ) ); int get_risflag args( ( char *flag ) ); --- 21,28 ---- #include "mud.h" ! int get_otype args( ( const char *type ) ); ! int get_aflag args( ( const char *flag ) ); int get_npc_race args( ( char *type ) ); int get_actflag args( ( char *flag ) ); int get_risflag args( ( char *flag ) ); *************** *** 251,257 **** progbug("MpMset: Invalid npc class", ch); return; } ! victim->class = value; return; } progbug("MpMset: can't set pc class", ch); --- 251,257 ---- progbug("MpMset: Invalid npc class", ch); return; } ! victim->mudclass = value; return; } progbug("MpMset: can't set pc class", ch); diff -c src.orig/mud_comm.c src/mud_comm.c *** src.orig/mud_comm.c 1999-05-28 15:19:00.000000000 +1000 --- src/mud_comm.c 2004-01-20 11:33:32.000000000 +1100 *************** *** 116,122 **** ch_printf( ch, "Lv: %d. Class: %d. Align: %d. AC: %d. Gold: %d. Exp: %d.\n\r", ! victim->level, victim->class, victim->alignment, GET_AC( victim ), victim->gold, victim->exp ); for ( mprg = victim->pIndexData->mudprogs; mprg; mprg = mprg->next ) --- 116,122 ---- ch_printf( ch, "Lv: %d. Class: %d. Align: %d. AC: %d. Gold: %d. Exp: %d.\n\r", ! victim->level, victim->mudclass, victim->alignment, GET_AC( victim ), victim->gold, victim->exp ); for ( mprg = victim->pIndexData->mudprogs; mprg; mprg = mprg->next ) *************** *** 1818,1824 **** return; } ! if(victim->level < skill_table[sn]->skill_level[victim->class] ) { sprintf(buf,"$n attempts to tutor you in %s, but it's beyond your comprehension.",skill_name); act( AT_TELL, buf, ch, NULL, victim, TO_VICT ); --- 1818,1824 ---- return; } ! if(victim->level < skill_table[sn]->skill_level[victim->mudclass] ) { sprintf(buf,"$n attempts to tutor you in %s, but it's beyond your comprehension.",skill_name); act( AT_TELL, buf, ch, NULL, victim, TO_VICT ); *************** *** 1826,1832 **** } /* adept is how high the player can learn it */ ! /* adept = class_table[ch->class]->skill_adept; */ adept = GET_ADEPT(victim,sn); if ( (victim->pcdata->learned[sn] >= adept ) --- 1826,1832 ---- } /* adept is how high the player can learn it */ ! /* adept = class_table[ch->mudclass]->skill_adept; */ adept = GET_ADEPT(victim,sn); if ( (victim->pcdata->learned[sn] >= adept ) *************** *** 2587,2593 **** sprintf( log_buf, "%s@%s new %s %s %s applying...", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->class]->who_name, IS_PKILL( victim ) ? "(Deadly)" : "(Peaceful)" ); /* log_string( log_buf );*/ to_channel( log_buf, CHANNEL_AUTH, "Auth", LEVEL_IMMORTAL ); --- 2587,2593 ---- sprintf( log_buf, "%s@%s new %s %s %s applying...", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->mudclass]->who_name, IS_PKILL( victim ) ? "(Deadly)" : "(Peaceful)" ); /* log_string( log_buf );*/ to_channel( log_buf, CHANNEL_AUTH, "Auth", LEVEL_IMMORTAL ); *************** *** 2639,2645 **** sprintf( log_buf, "%s@%s new %s %s %s applying...", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->class]->who_name, IS_PKILL( victim ) ? "(Deadly)" : "(Peaceful)" ); log_string( log_buf ); to_channel( log_buf, CHANNEL_AUTH, "Auth", LEVEL_IMMORTAL ); --- 2639,2645 ---- sprintf( log_buf, "%s@%s new %s %s %s applying...", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->mudclass]->who_name, IS_PKILL( victim ) ? "(Deadly)" : "(Peaceful)" ); log_string( log_buf ); to_channel( log_buf, CHANNEL_AUTH, "Auth", LEVEL_IMMORTAL ); *************** *** 2664,2670 **** victim->perm_cha = 13; victim->perm_con = 13; victim->perm_lck = 13; ! switch ( class_table[victim->class]->attr_prime ) { case APPLY_STR: victim->perm_str = 16; break; case APPLY_INT: victim->perm_int = 16; break; --- 2664,2670 ---- victim->perm_cha = 13; victim->perm_con = 13; victim->perm_lck = 13; ! switch ( class_table[victim->mudclass]->attr_prime ) { case APPLY_STR: victim->perm_str = 16; break; case APPLY_INT: victim->perm_int = 16; break; diff -c src.orig/mud.h src/mud.h *** src.orig/mud.h 2001-07-05 08:52:52.000000000 +1000 --- src/mud.h 2004-01-21 07:33:27.000000000 +1100 *************** *** 87,93 **** #define unix #else typedef short int sh_int; ! typedef unsigned char bool; #endif /* --- 87,93 ---- #define unix #else typedef short int sh_int; ! //typedef unsigned char bool; #endif /* *************** *** 270,276 **** #define LEVEL_HIGOD LEVEL_GOD /* This is to tell if act uses uppercasestring or not --Shaddai */ ! bool DONT_UPPER; #define SECONDS_PER_TICK 70 --- 270,276 ---- #define LEVEL_HIGOD LEVEL_GOD /* This is to tell if act uses uppercasestring or not --Shaddai */ ! extern bool DONT_UPPER; #define SECONDS_PER_TICK 70 *************** *** 290,296 **** /* * Stuff for area versions --Shaddai */ ! int area_version; #define HAS_SPELL_INDEX -1 #define AREA_VERSION_WRITE 1 --- 290,296 ---- /* * Stuff for area versions --Shaddai */ ! extern int area_version; #define HAS_SPELL_INDEX -1 #define AREA_VERSION_WRITE 1 *************** *** 419,425 **** char *unmorph_other; /* What others see when you unmorph */ char *unmorph_self; /* What you see when you unmorph */ EXT_BV affected_by; /* New affected_by added */ ! int class; /* Classes not allowed to use this */ int defpos; /* Default position */ EXT_BV no_affected_by; /* Prevents affects from being added */ int no_immune; /* Prevents Immunities */ --- 419,425 ---- char *unmorph_other; /* What others see when you unmorph */ char *unmorph_self; /* What you see when you unmorph */ EXT_BV affected_by; /* New affected_by added */ ! int mudclass; /* Classes not allowed to use this */ int defpos; /* Default position */ EXT_BV no_affected_by; /* Prevents affects from being added */ int no_immune; /* Prevents Immunities */ *************** *** 476,482 **** LCNV_DATA * prev; char * old; int olen; ! char * new; int nlen; }; --- 476,482 ---- LCNV_DATA * prev; char * old; int olen; ! char * lcnv_new; int nlen; }; *************** *** 1046,1052 **** char * comlist; }; ! bool MOBtrigger; /* * Per-class stuff. --- 1046,1052 ---- char * comlist; }; ! extern bool MOBtrigger; /* * Per-class stuff. *************** *** 1162,1168 **** int storeroom; /* Vnum of clan's store room */ int guard1; /* Vnum of clan guard type 1 */ int guard2; /* Vnum of clan guard type 2 */ ! int class; /* For guilds */ }; struct council_data --- 1162,1168 ---- int storeroom; /* Vnum of clan's store room */ int guard1; /* Vnum of clan guard type 1 */ int guard2; /* Vnum of clan guard type 2 */ ! int mudclass; /* For guilds */ }; struct council_data *************** *** 1213,1219 **** sh_int dig_corpse; int race; int race2; ! int class; int sex; int npcrace; int npcfoe; --- 1213,1219 ---- sh_int dig_corpse; int race; int race2; ! int mudclass; int sex; int npcrace; int npcfoe; *************** *** 2162,2168 **** sh_int height; sh_int weight; sh_int race; ! sh_int class; sh_int hitroll; sh_int damroll; sh_int perm_str; --- 2162,2168 ---- sh_int height; sh_int weight; sh_int race; ! sh_int mudclass; sh_int hitroll; sh_int damroll; sh_int perm_str; *************** *** 2265,2271 **** sh_int num_fighting; sh_int substate; sh_int sex; ! sh_int class; sh_int race; sh_int level; sh_int trust; --- 2265,2271 ---- sh_int num_fighting; sh_int substate; sh_int sex; ! sh_int mudclass; sh_int race; sh_int level; sh_int trust; *************** *** 3288,3298 **** #define IS_AFFECTED(ch, sn) (xIS_SET((ch)->affected_by, (sn))) #define HAS_BODYPART(ch, part) ((ch)->xflags == 0 || IS_SET((ch)->xflags, (part))) ! #define CAN_CAST(ch) ((ch)->class != 2 && (ch)->class != 3) #define IS_VAMPIRE(ch) (!IS_NPC(ch) \ && ((ch)->race==RACE_VAMPIRE \ ! || (ch)->class==CLASS_VAMPIRE)) #define IS_GOOD(ch) ((ch)->alignment >= 350) #define IS_EVIL(ch) ((ch)->alignment <= -350) #define IS_NEUTRAL(ch) (!IS_GOOD(ch) && !IS_EVIL(ch)) --- 3288,3298 ---- #define IS_AFFECTED(ch, sn) (xIS_SET((ch)->affected_by, (sn))) #define HAS_BODYPART(ch, part) ((ch)->xflags == 0 || IS_SET((ch)->xflags, (part))) ! #define CAN_CAST(ch) ((ch)->mudclass != 2 && (ch)->mudclass != 3) #define IS_VAMPIRE(ch) (!IS_NPC(ch) \ && ((ch)->race==RACE_VAMPIRE \ ! || (ch)->mudclass==CLASS_VAMPIRE)) #define IS_GOOD(ch) ((ch)->alignment >= 350) #define IS_EVIL(ch) ((ch)->alignment <= -350) #define IS_NEUTRAL(ch) (!IS_GOOD(ch) && !IS_EVIL(ch)) *************** *** 3533,3538 **** --- 3533,3540 ---- extern const sh_int rev_dir []; extern const int trap_door []; extern char * const r_flags []; + extern char * const ex_flags []; + extern char * const sec_flags []; extern char * const w_flags []; extern char * const item_w_flags []; extern char * const o_flags []; *************** *** 3567,3572 **** --- 3569,3575 ---- extern char * const windtemp_msg [6][6]; extern char * const precip_msg []; extern char * const wind_msg []; + extern char * const wear_locs []; /* * Global variables. *************** *** 4072,4077 **** --- 4075,4081 ---- DECLARE_DO_FUN( do_supplicate ); DECLARE_DO_FUN( do_switch ); DECLARE_DO_FUN( do_showlayers ); + DECLARE_DO_FUN( do_stltest ); DECLARE_DO_FUN( do_tail ); DECLARE_DO_FUN( do_tamp ); DECLARE_DO_FUN( do_tell ); *************** *** 4590,4596 **** OD * create_object args( ( OBJ_INDEX_DATA *pObjIndex, int level ) ); void clear_char args( ( CHAR_DATA *ch ) ); void free_char args( ( CHAR_DATA *ch ) ); ! char * get_extra_descr args( ( const char *name, EXTRA_DESCR_DATA *ed ) ); MID * get_mob_index args( ( sh_int vnum ) ); OID * get_obj_index args( ( int vnum ) ); RID * get_room_index args( ( int vnum ) ); --- 4594,4600 ---- OD * create_object args( ( OBJ_INDEX_DATA *pObjIndex, int level ) ); void clear_char args( ( CHAR_DATA *ch ) ); void free_char args( ( CHAR_DATA *ch ) ); ! const char * get_extra_descr args( ( char *name, EXTRA_DESCR_DATA *ed ) ); MID * get_mob_index args( ( sh_int vnum ) ); OID * get_obj_index args( ( int vnum ) ); RID * get_room_index args( ( int vnum ) ); *************** *** 4667,4677 **** EDD * SetOExtraProto args( ( OBJ_INDEX_DATA *obj, char *keywords ) ); bool DelOExtraProto args( ( OBJ_INDEX_DATA *obj, char *keywords ) ); void fold_area args( ( AREA_DATA *tarea, char *filename, bool install ) ); ! int get_otype args( ( char *type ) ); ! int get_atype args( ( char *type ) ); ! int get_aflag args( ( char *flag ) ); ! int get_oflag args( ( char *flag ) ); ! int get_wflag args( ( char *flag ) ); void init_area_weather args(( void ) ); void save_weatherdata args( ( void ) ); --- 4671,4681 ---- EDD * SetOExtraProto args( ( OBJ_INDEX_DATA *obj, char *keywords ) ); bool DelOExtraProto args( ( OBJ_INDEX_DATA *obj, char *keywords ) ); void fold_area args( ( AREA_DATA *tarea, char *filename, bool install ) ); ! int get_otype args( ( const char *type ) ); ! int get_atype args( ( const char *type ) ); ! int get_aflag args( ( const char *flag ) ); ! int get_oflag args( ( const char *flag ) ); ! int get_wflag args( ( const char *flag ) ); void init_area_weather args(( void ) ); void save_weatherdata args( ( void ) ); *************** *** 4848,4855 **** bool can_take_proto args( ( CHAR_DATA *ch ) ); int can_carry_n args( ( CHAR_DATA *ch ) ); int can_carry_w args( ( CHAR_DATA *ch ) ); ! bool is_name args( ( const char *str, char *namelist ) ); ! bool is_name_prefix args( ( const char *str, char *namelist ) ); bool nifty_is_name args( ( char *str, char *namelist ) ); bool nifty_is_name_prefix args( ( char *str, char *namelist ) ); void affect_modify args( ( CHAR_DATA *ch, AFFECT_DATA *paf, bool fAdd ) ); --- 4852,4859 ---- bool can_take_proto args( ( CHAR_DATA *ch ) ); int can_carry_n args( ( CHAR_DATA *ch ) ); int can_carry_w args( ( CHAR_DATA *ch ) ); ! bool is_name args( ( char *str, char *namelist ) ); ! bool is_name_prefix args( ( char *str, char *namelist ) ); bool nifty_is_name args( ( char *str, char *namelist ) ); bool nifty_is_name_prefix args( ( char *str, char *namelist ) ); void affect_modify args( ( CHAR_DATA *ch, AFFECT_DATA *paf, bool fAdd ) ); *************** *** 4902,4910 **** bool can_drop_obj args( ( CHAR_DATA *ch, OBJ_DATA *obj ) ); char * item_type_name args( ( OBJ_DATA *obj ) ); char * affect_loc_name args( ( int location ) ); ! char * affect_bit_name args( ( EXT_BV *vector ) ); ! char * extra_bit_name args( ( EXT_BV *extra_flags ) ); ! char * magic_bit_name args( ( int magic_flags ) ); char * pull_type_name args( ( int pulltype ) ); ch_ret check_for_trap args( ( CHAR_DATA *ch, OBJ_DATA *obj, int flag ) ); ch_ret check_room_for_traps args( ( CHAR_DATA *ch, int flag ) ); --- 4906,4914 ---- bool can_drop_obj args( ( CHAR_DATA *ch, OBJ_DATA *obj ) ); char * item_type_name args( ( OBJ_DATA *obj ) ); char * affect_loc_name args( ( int location ) ); ! const char * affect_bit_name args( ( EXT_BV *vector ) ); ! const char * extra_bit_name args( ( EXT_BV *extra_flags ) ); ! const char * magic_bit_name args( ( int magic_flags ) ); char * pull_type_name args( ( int pulltype ) ); ch_ret check_for_trap args( ( CHAR_DATA *ch, OBJ_DATA *obj, int flag ) ); ch_ret check_room_for_traps args( ( CHAR_DATA *ch, int flag ) ); *************** *** 4954,4960 **** /* interp.c */ bool check_pos args( ( CHAR_DATA *ch, sh_int position ) ); void interpret args( ( CHAR_DATA *ch, char *argument ) ); ! bool is_number args( ( char *arg ) ); int number_argument args( ( char *argument, char *arg ) ); char * one_argument args( ( char *argument, char *arg_first ) ); char * one_argument2 args( ( char *argument, char *arg_first ) ); --- 4958,4964 ---- /* interp.c */ bool check_pos args( ( CHAR_DATA *ch, sh_int position ) ); void interpret args( ( CHAR_DATA *ch, char *argument ) ); ! bool is_number args( ( const char *arg ) ); int number_argument args( ( char *argument, char *arg ) ); char * one_argument args( ( char *argument, char *arg_first ) ); char * one_argument2 args( ( char *argument, char *arg_first ) ); *************** *** 5061,5067 **** void weather_update args( ( void ) ); /* hashstr.c */ ! char * str_alloc args( ( char *str ) ); char * quick_link args( ( char *str ) ); int str_free args( ( char *str ) ); void show_hash args( ( int count ) ); --- 5065,5071 ---- void weather_update args( ( void ) ); /* hashstr.c */ ! char * str_alloc args( ( const char *str ) ); char * quick_link args( ( char *str ) ); int str_free args( ( char *str ) ); void show_hash args( ( int count ) ); *************** *** 5348,5354 **** #endif ! #define GET_ADEPT(ch,sn) ( skill_table[(sn)]->skill_adept[(ch)->class]) #define LEARNED(ch,sn) (IS_NPC(ch) ? 80 : URANGE(0, ch->pcdata->learned[sn], 101)) /* Structure and macros for using long bit vectors */ --- 5352,5358 ---- #endif ! #define GET_ADEPT(ch,sn) ( skill_table[(sn)]->skill_adept[(ch)->mudclass]) #define LEARNED(ch,sn) (IS_NPC(ch) ? 80 : URANGE(0, ch->pcdata->learned[sn], 101)) /* Structure and macros for using long bit vectors */ diff -c src.orig/mud_prog.c src/mud_prog.c *** src.orig/mud_prog.c 1999-06-01 03:37:24.000000000 +1000 --- src/mud_prog.c 2004-01-20 12:02:57.000000000 +1100 *************** *** 341,348 **** while ( *p ) ++p; *p = '\0'; ! chck = argv[0] ? argv[0] : ""; ! cvar = argv[1] ? argv[1] : ""; /* * chck contains check, cvar is the variable in the (), opr is the --- 341,348 ---- while ( *p ) ++p; *p = '\0'; ! chck = argv[0] ? argv[0] : (char *) ""; ! cvar = argv[1] ? argv[1] : (char *) ""; /* * chck contains check, cvar is the variable in the (), opr is the *************** *** 953,960 **** if ( !str_cmp(chck, "class") ) { if ( IS_NPC(chkchar) ) ! return mprog_seval(npc_class[chkchar->class], opr, rval, mob); ! return mprog_seval((char *)class_table[chkchar->class]->who_name, opr, rval, mob); } if ( !str_cmp(chck, "weight" ) ) --- 953,960 ---- if ( !str_cmp(chck, "class") ) { if ( IS_NPC(chkchar) ) ! return mprog_seval(npc_class[chkchar->mudclass], opr, rval, mob); ! return mprog_seval((char *)class_table[chkchar->mudclass]->who_name, opr, rval, mob); } if ( !str_cmp(chck, "weight" ) ) *************** *** 3360,3366 **** while ( (runner = room_act_list) != NULL ) { ! ROOM_INDEX_DATA *room = runner->vo; while ( (mpact = room->mpact) != NULL ) { --- 3360,3366 ---- while ( (runner = room_act_list) != NULL ) { ! ROOM_INDEX_DATA *room = (ROOM_INDEX_DATA *) runner->vo; while ( (mpact = room->mpact) != NULL ) { *************** *** 3398,3404 **** while ( (runner = obj_act_list) != NULL ) { ! OBJ_DATA *obj = runner->vo; while ( (mpact = obj->mpact) != NULL ) { --- 3398,3404 ---- while ( (runner = obj_act_list) != NULL ) { ! OBJ_DATA *obj = (OBJ_DATA *) runner->vo; while ( (mpact = obj->mpact) != NULL ) { diff -c src.orig/planes.c src/planes.c *** src.orig/planes.c 1999-05-28 15:19:00.000000000 +1000 --- src/planes.c 2004-01-20 12:19:21.000000000 +1100 *************** *** 162,168 **** CREATE(p, PLANE_DATA, 1); for (;;) { ! word = (feof(fp) ? "End" : fread_word(fp)); fMatch = FALSE; switch(UPPER(*word)) --- 162,168 ---- CREATE(p, PLANE_DATA, 1); for (;;) { ! word = (feof(fp) ? (char *) "End" : fread_word(fp)); fMatch = FALSE; switch(UPPER(*word)) diff -c src.orig/player.c src/player.c *** src.orig/player.c 2001-07-05 08:52:52.000000000 +1000 --- src/player.c 2004-01-20 12:03:36.000000000 +1100 *************** *** 308,314 **** pager_printf(ch, "XP : %-9d Blood: %-5d of %5d MKills: %-5.5d AutoLoot(%c)\n\r", ch->exp, ch->pcdata->condition[COND_BLOODTHIRST], 10 + ch->level, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); ! else if (ch->class == CLASS_WARRIOR) pager_printf(ch, "XP : %-9d MKills: %-5.5d AutoLoot(%c)\n\r", ch->exp, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); else --- 308,314 ---- pager_printf(ch, "XP : %-9d Blood: %-5d of %5d MKills: %-5.5d AutoLoot(%c)\n\r", ch->exp, ch->pcdata->condition[COND_BLOODTHIRST], 10 + ch->level, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); ! else if (ch->mudclass == CLASS_WARRIOR) pager_printf(ch, "XP : %-9d MKills: %-5.5d AutoLoot(%c)\n\r", ch->exp, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); else *************** *** 727,733 **** pager_printf_color(ch, "&CEXP : &W%-9d &CBlood: &R%-5d &Cof &r%5d &CMKills: &W%5d &CAutoLoot(&W%c&C)\n\r", ch->exp, ch->pcdata->condition[COND_BLOODTHIRST], 10 + ch->level, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); ! else if (ch->class == CLASS_WARRIOR) pager_printf_color(ch, "&CEXP : &W%-9d &CMKills: &W%5d &CAutoLoot(&W%c&C)\n\r", ch->exp, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); else --- 727,733 ---- pager_printf_color(ch, "&CEXP : &W%-9d &CBlood: &R%-5d &Cof &r%5d &CMKills: &W%5d &CAutoLoot(&W%c&C)\n\r", ch->exp, ch->pcdata->condition[COND_BLOODTHIRST], 10 + ch->level, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); ! else if (ch->mudclass == CLASS_WARRIOR) pager_printf_color(ch, "&CEXP : &W%-9d &CMKills: &W%5d &CAutoLoot(&W%c&C)\n\r", ch->exp, ch->pcdata->mkills, xIS_SET(ch->act, PLR_AUTOLOOT) ? 'X' : ' '); else *************** *** 1021,1036 **** }; bug("Affect_location_name: unknown location %d.", location); ! return "(???)"; } char * get_class(CHAR_DATA *ch) { ! if ( IS_NPC(ch) && ch->class < MAX_NPC_CLASS && ch->class >= 0) ! return ( npc_class[ch->class] ); ! else if ( !IS_NPC(ch) && ch->class < MAX_PC_CLASS && ch->class >= 0 ) ! return class_table[ch->class]->who_name; return ("Unknown"); } --- 1021,1036 ---- }; bug("Affect_location_name: unknown location %d.", location); ! return "(\?\?\?)"; } char * get_class(CHAR_DATA *ch) { ! if ( IS_NPC(ch) && ch->mudclass < MAX_NPC_CLASS && ch->mudclass >= 0) ! return ( npc_class[ch->mudclass] ); ! else if ( !IS_NPC(ch) && ch->mudclass < MAX_PC_CLASS && ch->mudclass >= 0 ) ! return class_table[ch->mudclass]->who_name; return ("Unknown"); } diff -c src.orig/polymorph.c src/polymorph.c *** src.orig/polymorph.c 1999-05-28 15:19:00.000000000 +1000 --- src/polymorph.c 2004-01-20 12:05:40.000000000 +1100 *************** *** 88,94 **** ch->substate = SUB_NONE; return; } ! morph = ch->dest_buf; STRFREE( morph->description ); morph->description = copy_buffer( ch ); stop_editing( ch ); --- 88,94 ---- ch->substate = SUB_NONE; return; } ! morph = (MORPH_DATA *) ch->dest_buf; STRFREE( morph->description ); morph->description = copy_buffer( ch ); stop_editing( ch ); *************** *** 104,110 **** ch->substate = SUB_NONE; return; } ! morph = ch->dest_buf; STRFREE( morph->help ); morph->help = copy_buffer( ch ); stop_editing( ch ); --- 104,110 ---- ch->substate = SUB_NONE; return; } ! morph = (MORPH_DATA *) ch->dest_buf; STRFREE( morph->help ); morph->help = copy_buffer( ch ); stop_editing( ch ); *************** *** 119,125 **** if ( ch->substate == SUB_REPEATCMD ) { ! morph = ch->dest_buf; if ( !morph ) { send_to_char ("Someone deleted your morph!\n\r", ch); --- 119,125 ---- if ( ch->substate == SUB_REPEATCMD ) { ! morph = (MORPH_DATA *) ch->dest_buf; if ( !morph ) { send_to_char ("Someone deleted your morph!\n\r", ch); *************** *** 876,882 **** ch_printf (ch, "Class range is 0 to %d.\n", MAX_PC_CLASS); return; } ! TOGGLE_BIT ( morph->class, ( 1 << value) ); } else if ( !str_cmp ( arg2, "race" ) ) { --- 876,882 ---- ch_printf (ch, "Class range is 0 to %d.\n", MAX_PC_CLASS); return; } ! TOGGLE_BIT ( morph->mudclass, ( 1 << value) ); } else if ( !str_cmp ( arg2, "race" ) ) { *************** *** 971,977 **** send_to_pager_color(" &BMorph Restrictions\n\r", ch ); send_to_pager_color( "&B[----------------------------------------------------------------------------]\n\r", ch ); pager_printf_color (ch, " &cClasses Allowed : &w%s\n\r", ! class_string (morph->class) ); pager_printf_color (ch, " &cRaces Not Allowed: &w%s\n\r", race_string (morph->race) ); pager_printf_color (ch, " &cSex: &C%s &cPkill: &C%s &cTime From: &C%d &cTime To: &C%d\n\r", --- 971,977 ---- send_to_pager_color(" &BMorph Restrictions\n\r", ch ); send_to_pager_color( "&B[----------------------------------------------------------------------------]\n\r", ch ); pager_printf_color (ch, " &cClasses Allowed : &w%s\n\r", ! class_string (morph->mudclass) ); pager_printf_color (ch, " &cRaces Not Allowed: &w%s\n\r", race_string (morph->race) ); pager_printf_color (ch, " &cSex: &C%s &cPkill: &C%s &cTime From: &C%d &cTime To: &C%d\n\r", *************** *** 1341,1347 **** return FALSE; if ( morph->sex != -1 && morph->sex != ch->sex ) return FALSE; ! if ( morph->class != 0 && !IS_SET( morph->class, (1 << ch->class) ) ) return FALSE; if ( morph->race != 0 && IS_SET( morph->race, (1 << ch->race ) ) ) return FALSE; --- 1341,1347 ---- return FALSE; if ( morph->sex != -1 && morph->sex != ch->sex ) return FALSE; ! if ( morph->mudclass != 0 && !IS_SET( morph->mudclass, (1 << ch->mudclass) ) ) return FALSE; if ( morph->race != 0 && IS_SET( morph->race, (1 << ch->race ) ) ) return FALSE; *************** *** 1558,1565 **** fprintf (fp, "UnmorphSelf %s~\n", morph->unmorph_self ); if ( !xIS_EMPTY(morph->affected_by) ) fprintf (fp, "Affected %s\n", print_bitvector(&morph->affected_by) ); ! if ( morph->class != 0 ) ! fprintf (fp, "Class %s~\n", class_string(morph->class) ); if ( morph->immune != 0 ) fprintf (fp, "Immune %d\n", morph->immune ); if ( !xIS_EMPTY(morph->no_affected_by) ) --- 1558,1565 ---- fprintf (fp, "UnmorphSelf %s~\n", morph->unmorph_self ); if ( !xIS_EMPTY(morph->affected_by) ) fprintf (fp, "Affected %s\n", print_bitvector(&morph->affected_by) ); ! if ( morph->mudclass != 0 ) ! fprintf (fp, "Class %s~\n", class_string(morph->mudclass) ); if ( morph->immune != 0 ) fprintf (fp, "Immune %d\n", morph->immune ); if ( !xIS_EMPTY(morph->no_affected_by) ) *************** *** 1668,1674 **** while (my_continue) { morph = NULL; ! word = feof (fp) ? "#END" : fread_word (fp); fMatch = FALSE; switch (UPPER (word[0])) --- 1668,1674 ---- while (my_continue) { morph = NULL; ! word = feof (fp) ? (char *) "#END" : fread_word (fp); fMatch = FALSE; switch (UPPER (word[0])) *************** *** 1723,1729 **** int i; bool fMatch; ! word = feof (fp) ? "End" : fread_word (fp); if ( !str_cmp ( word, "End" ) ) return NULL; --- 1723,1729 ---- int i; bool fMatch; ! word = feof (fp) ? (char *) "End" : fread_word (fp); if ( !str_cmp ( word, "End" ) ) return NULL; *************** *** 1734,1740 **** for (;;) { ! word = feof (fp) ? "End" : fread_word (fp); fMatch = FALSE; switch (UPPER (word[0])) { --- 1734,1740 ---- for (;;) { ! word = feof (fp) ? (char *) "End" : fread_word (fp); fMatch = FALSE; switch (UPPER (word[0])) { *************** *** 1758,1764 **** for ( i=0; i < MAX_PC_CLASS; i++ ) if ( !str_cmp( temp, class_table[i]->who_name ) ) { ! SET_BIT( morph->class, (1 << i) ); break; } arg = one_argument( arg, temp ); --- 1758,1764 ---- for ( i=0; i < MAX_PC_CLASS; i++ ) if ( !str_cmp( temp, class_table[i]->who_name ) ) { ! SET_BIT( morph->mudclass, (1 << i) ); break; } arg = one_argument( arg, temp ); *************** *** 1981,1987 **** morph->unmorph_other = str_dup ( "" ); morph->unmorph_self = str_dup ( "" ); xCLEAR_BITS(morph->affected_by); ! morph->class = 0; morph->sex = -1; morph->timefrom = -1; morph->timeto = -1; --- 1981,1987 ---- morph->unmorph_other = str_dup ( "" ); morph->unmorph_self = str_dup ( "" ); xCLEAR_BITS(morph->affected_by); ! morph->mudclass = 0; morph->sex = -1; morph->timefrom = -1; morph->timeto = -1; *************** *** 2058,2064 **** morph->unmorph_other = str_dup ( temp->unmorph_other ); morph->unmorph_self = str_dup ( temp->unmorph_self ); morph->affected_by = temp->affected_by; ! morph->class = temp->class; morph->sex = temp->sex; morph->timefrom = temp->timefrom; morph->timeto = temp->timeto; --- 2058,2064 ---- morph->unmorph_other = str_dup ( temp->unmorph_other ); morph->unmorph_self = str_dup ( temp->unmorph_self ); morph->affected_by = temp->affected_by; ! morph->mudclass = temp->mudclass; morph->sex = temp->sex; morph->timefrom = temp->timefrom; morph->timeto = temp->timeto; *************** *** 2384,2390 **** ch->morph = morph; for ( ; ; ) { ! word = feof ( fp ) ? "End" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) --- 2384,2390 ---- ch->morph = morph; for ( ; ; ) { ! word = feof ( fp ) ? (char *) "End" : fread_word (fp); fMatch = FALSE; switch ( UPPER ( word[0] ) ) diff -c src.orig/reset.c src/reset.c *** src.orig/reset.c 1999-05-28 15:19:00.000000000 +1000 --- src/reset.c 2004-01-21 07:34:22.000000000 +1100 *************** *** 46,56 **** CHAR_DATA *ch ) ); int get_wearloc args( ( char *type ) ); int get_trapflag args( ( char *flag ) ); ! int get_exflag args( ( char *flag ) ); ! int get_rflag args( ( char *flag ) ); ! extern char * const wear_locs[]; ! extern char * const ex_flags[]; ! bool is_room_reset args( ( RESET_DATA *pReset, ROOM_INDEX_DATA *aRoom, AREA_DATA *pArea ) ); void add_obj_reset args( ( AREA_DATA *pArea, char cm, OBJ_DATA *obj, --- 46,53 ---- CHAR_DATA *ch ) ); int get_wearloc args( ( char *type ) ); int get_trapflag args( ( char *flag ) ); ! int get_exflag args( ( const char *flag ) ); ! int get_rflag args( ( const char *flag ) ); bool is_room_reset args( ( RESET_DATA *pReset, ROOM_INDEX_DATA *aRoom, AREA_DATA *pArea ) ); void add_obj_reset args( ( AREA_DATA *pArea, char cm, OBJ_DATA *obj, *************** *** 378,386 **** argument = one_argument(argument, arg); if ( !*arg || !str_cmp(arg, "?") ) { ! char *nm = (ch->substate == SUB_REPEATCMD ? "" : (aRoom ? "rreset " : "reset ")); ! char *rn = (aRoom ? "" : " [room#]"); ch_printf(ch, "Syntax: %s\n\r", nm, (aRoom ? "" : "|area")); ch_printf( ch, "Syntax: %sremove <#>\n\r", nm ); --- 375,383 ---- argument = one_argument(argument, arg); if ( !*arg || !str_cmp(arg, "?") ) { ! const char *nm = (ch->substate == SUB_REPEATCMD ? "" : (aRoom ? "rreset " : "reset ")); ! const char *rn = (aRoom ? "" : " [room#]"); ch_printf(ch, "Syntax: %s\n\r", nm, (aRoom ? "" : "|area")); ch_printf( ch, "Syntax: %sremove <#>\n\r", nm ); *************** *** 833,839 **** } if ( !str_cmp(arg, "bit") ) { ! int (*flfunc)(char *type); int flags = 0; char option[MAX_INPUT_LENGTH]; char *parg; --- 830,836 ---- } if ( !str_cmp(arg, "bit") ) { ! int (*flfunc)(const char *type); int flags = 0; char option[MAX_INPUT_LENGTH]; char *parg; *************** *** 1010,1016 **** parg = one_argument(argument, arg); if ( ch->substate == SUB_REPEATCMD ) { ! pArea = ch->dest_buf; if ( pArea && pArea != ch->pcdata->area && pArea != ch->in_room->area ) { AREA_DATA *tmp; --- 1007,1013 ---- parg = one_argument(argument, arg); if ( ch->substate == SUB_REPEATCMD ) { ! pArea = (AREA_DATA *) ch->dest_buf; if ( pArea && pArea != ch->pcdata->area && pArea != ch->in_room->area ) { AREA_DATA *tmp; *************** *** 1078,1084 **** if ( ch->substate == SUB_REPEATCMD ) { ! pRoom = ch->dest_buf; if ( !pRoom ) { send_to_char( "Your room pointer got lost. Reset mode off.\n\r", ch); --- 1075,1081 ---- if ( ch->substate == SUB_REPEATCMD ) { ! pRoom = (ROOM_INDEX_DATA *) ch->dest_buf; if ( !pRoom ) { send_to_char( "Your room pointer got lost. Reset mode off.\n\r", ch); *************** *** 1778,1784 **** else oname = obj->name; sprintf( pbuf, "%s (%d) -> %s (%s) [%d]", oname, pReset->arg1, mname, ! (pReset->command == 'G' ? "carry" : wear_locs[pReset->arg3]), pReset->arg2 ); if ( mob && mob->pShop ) strcat( buf, " (shop)\n\r" ); --- 1775,1781 ---- else oname = obj->name; sprintf( pbuf, "%s (%d) -> %s (%s) [%d]", oname, pReset->arg1, mname, ! (pReset->command == 'G' ? "carry" : wear_locs [pReset->arg3]), pReset->arg2 ); if ( mob && mob->pShop ) strcat( buf, " (shop)\n\r" ); diff -c src.orig/save.c src/save.c *** src.orig/save.c 1999-05-28 15:19:00.000000000 +1000 --- src/save.c 2004-01-20 12:11:22.000000000 +1100 *************** *** 282,288 **** if ( ch->description[0] != '\0' ) fprintf( fp, "Description %s~\n", ch->description ); fprintf( fp, "Sex %d\n", ch->sex ); ! fprintf( fp, "Class %d\n", ch->class ); fprintf( fp, "Race %d\n", ch->race ); fprintf( fp, "Languages %d %d\n", ch->speaks, ch->speaking ); fprintf( fp, "Level %d\n", ch->level ); --- 282,288 ---- if ( ch->description[0] != '\0' ) fprintf( fp, "Description %s~\n", ch->description ); fprintf( fp, "Sex %d\n", ch->sex ); ! fprintf( fp, "Class %d\n", ch->mudclass ); fprintf( fp, "Race %d\n", ch->race ); fprintf( fp, "Languages %d %d\n", ch->speaks, ch->speaking ); fprintf( fp, "Level %d\n", ch->level ); *************** *** 1027,1033 **** killcnt = 0; for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 1027,1033 ---- killcnt = 0; for ( ; ; ) { ! word = feof( fp ) ? (char *) "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 1155,1161 **** break; } ! KEY( "Class", ch->class, fread_number( fp ) ); if ( !str_cmp( word, "Color" ) ) { --- 1155,1161 ---- break; } ! KEY( "Class", ch->mudclass, fread_number( fp ) ); if ( !str_cmp( word, "Color" ) ) { *************** *** 1568,1574 **** * Assumes practices are loaded first too now. -- Altrag */ if ( ch->level < LEVEL_IMMORTAL ) { ! if ( skill_table[sn]->skill_level[ch->class] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; --- 1568,1574 ---- * Assumes practices are loaded first too now. -- Altrag */ if ( ch->level < LEVEL_IMMORTAL ) { ! if ( skill_table[sn]->skill_level[ch->mudclass] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; *************** *** 1598,1604 **** { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->class] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; --- 1598,1604 ---- { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->mudclass] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; *************** *** 1696,1702 **** { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->class] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; --- 1696,1702 ---- { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->mudclass] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; *************** *** 1757,1763 **** { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->class] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; --- 1757,1763 ---- { ch->pcdata->learned[sn] = value; if ( ch->level < LEVEL_IMMORTAL ) ! if ( skill_table[sn]->skill_level[ch->mudclass] >= LEVEL_IMMORTAL ) { ch->pcdata->learned[sn] = 0; ch->practice++; *************** *** 1805,1811 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 1805,1811 ---- for ( ; ; ) { ! word = feof( fp ) ? (char *) "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 2323,2329 **** int inroom = 0; ROOM_INDEX_DATA *pRoomIndex = NULL; ! word = feof( fp ) ? "EndMobile" : fread_word( fp ); if ( !strcmp(word, "Vnum") ) { int vnum; --- 2323,2329 ---- int inroom = 0; ROOM_INDEX_DATA *pRoomIndex = NULL; ! word = feof( fp ) ? (char *) "EndMobile" : fread_word( fp ); if ( !strcmp(word, "Vnum") ) { int vnum; *************** *** 2333,2339 **** if ( !mob ) { for ( ; ; ) { ! word = feof( fp ) ? "EndMobile" : fread_word( fp ); /* So we don't get so many bug messages when something messes up * --Shaddai */ --- 2333,2339 ---- if ( !mob ) { for ( ; ; ) { ! word = feof( fp ) ? (char *) "EndMobile" : fread_word( fp ); /* So we don't get so many bug messages when something messes up * --Shaddai */ *************** *** 2347,2353 **** else { for ( ; ; ) { ! word = feof( fp ) ? "EndMobile" : fread_word( fp ); /* So we don't get so many bug messages when something messes up * --Shaddai */ --- 2347,2353 ---- else { for ( ; ; ) { ! word = feof( fp ) ? (char *) "EndMobile" : fread_word( fp ); /* So we don't get so many bug messages when something messes up * --Shaddai */ *************** *** 2359,2365 **** return NULL; } for ( ; ;) { ! word = feof( fp ) ? "EndMobile" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) { case '*': --- 2359,2365 ---- return NULL; } for ( ; ;) { ! word = feof( fp ) ? (char *) "EndMobile" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) { case '*': diff -c src.orig/skills.c src/skills.c *** src.orig/skills.c 2001-07-05 08:52:52.000000000 +1000 --- src/skills.c 2004-01-20 12:13:45.000000000 +1100 *************** *** 198,204 **** /* && (IS_NPC(ch) || (ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->class])) ) */ break; if (first >= top) --- 198,204 ---- /* && (IS_NPC(ch) || (ch->pcdata->learned[sn] > 0 ! && ch->level >= skill_table[sn]->skill_level[ch->mudclass])) ) */ break; if (first >= top) *************** *** 224,230 **** if ( skill_table[sn]->min_mana ) { mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->class] ) ); blood = UMAX(1, (mana+4) / 8); /* NPCs don't have PCDatas. -- Altrag */ if ( IS_VAMPIRE(ch) ) { --- 224,230 ---- if ( skill_table[sn]->min_mana ) { mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->mudclass] ) ); blood = UMAX(1, (mana+4) / 8); /* NPCs don't have PCDatas. -- Altrag */ if ( IS_VAMPIRE(ch) ) { *************** *** 383,389 **** if ( (number_percent( ) + skill_table[sn]->difficulty * 5) > (IS_NPC(ch) ? 75 : LEARNED(ch, sn)) ) { ! failed_casting( skill_table[sn], ch, vo, obj ); learn_from_failure( ch, sn ); if ( mana ) { --- 383,389 ---- if ( (number_percent( ) + skill_table[sn]->difficulty * 5) > (IS_NPC(ch) ? 75 : LEARNED(ch, sn)) ) { ! failed_casting( skill_table[sn], ch, (CHAR_DATA *) vo, obj ); learn_from_failure( ch, sn ); if ( mana ) { *************** *** 1223,1236 **** if ( !str_cmp( arg2, "level" ) ) { char arg3[MAX_INPUT_LENGTH]; ! int class; argument = one_argument( argument, arg3 ); ! class = atoi( arg3 ); ! if ( class >= MAX_PC_CLASS || class < 0 ) send_to_char( "Not a valid class.\n\r", ch ); else ! skill->skill_level[class] = URANGE(0, atoi(argument), MAX_LEVEL); return; } --- 1223,1236 ---- if ( !str_cmp( arg2, "level" ) ) { char arg3[MAX_INPUT_LENGTH]; ! int mudclass; argument = one_argument( argument, arg3 ); ! mudclass = atoi( arg3 ); ! if ( mudclass >= MAX_PC_CLASS || mudclass < 0 ) send_to_char( "Not a valid class.\n\r", ch ); else ! skill->skill_level[mudclass] = URANGE(0, atoi(argument), MAX_LEVEL); return; } *************** *** 1251,1264 **** if ( !str_cmp( arg2, "adept" ) ) { char arg3[MAX_INPUT_LENGTH]; ! int class; argument = one_argument( argument, arg3 ); ! class = atoi( arg3 ); ! if ( class >= MAX_PC_CLASS || class < 0 ) send_to_char( "Not a valid class.\n\r", ch ); else ! skill->skill_adept[class] = URANGE(0, atoi(argument), 100); return; } --- 1251,1264 ---- if ( !str_cmp( arg2, "adept" ) ) { char arg3[MAX_INPUT_LENGTH]; ! int mudclass; argument = one_argument( argument, arg3 ); ! mudclass = atoi( arg3 ); ! if ( mudclass >= MAX_PC_CLASS || mudclass < 0 ) send_to_char( "Not a valid class.\n\r", ch ); else ! skill->skill_adept[mudclass] = URANGE(0, atoi(argument), 100); return; } *************** *** 1499,1505 **** { /* Fix by Narn to prevent ssetting skills the player shouldn't have. */ if ( skill_table[sn]->name ! && ( victim->level >= skill_table[sn]->skill_level[victim->class] || value == 0 ) ) { if ( value == 100 && !IS_IMMORTAL( victim ) ) --- 1499,1505 ---- { /* Fix by Narn to prevent ssetting skills the player shouldn't have. */ if ( skill_table[sn]->name ! && ( victim->level >= skill_table[sn]->skill_level[victim->mudclass] || value == 0 ) ) { if ( value == 100 && !IS_IMMORTAL( victim ) ) *************** *** 1523,1529 **** if ( IS_NPC(ch) || ch->pcdata->learned[sn] <= 0 ) return; adept = GET_ADEPT(ch,sn); ! sklvl = skill_table[sn]->skill_level[ch->class]; if ( sklvl == 0 ) sklvl = ch->level; if ( ch->pcdata->learned[sn] < adept ) --- 1523,1529 ---- if ( IS_NPC(ch) || ch->pcdata->learned[sn] <= 0 ) return; adept = GET_ADEPT(ch,sn); ! sklvl = skill_table[sn]->skill_level[ch->mudclass]; if ( sklvl == 0 ) sklvl = ch->level; if ( ch->pcdata->learned[sn] < adept ) *************** *** 1541,1548 **** if ( ch->pcdata->learned[sn] == adept ) /* fully learned! */ { gain = 1000 * sklvl; ! if ( ch->class==CLASS_MAGE ) gain *= 5; /* h, mage upgrade */ ! if ( ch->class==CLASS_CLERIC ) gain *= 2; /* h, mage upgrade */ set_char_color( AT_WHITE, ch ); ch_printf( ch, "You are now an adept of %s! You gain %d bonus experience!\n\r", skill_table[sn]->name, gain ); --- 1541,1548 ---- if ( ch->pcdata->learned[sn] == adept ) /* fully learned! */ { gain = 1000 * sklvl; ! if ( ch->mudclass==CLASS_MAGE ) gain *= 5; /* h, mage upgrade */ ! if ( ch->mudclass==CLASS_CLERIC ) gain *= 2; /* h, mage upgrade */ set_char_color( AT_WHITE, ch ); ch_printf( ch, "You are now an adept of %s! You gain %d bonus experience!\n\r", skill_table[sn]->name, gain ); *************** *** 1550,1557 **** else { gain = 20 * sklvl; ! if ( ch->class==CLASS_MAGE ) gain *= 6; /* h, mage upgrade */ ! if ( ch->class==CLASS_CLERIC ) gain *= 3; /* h, mage upgrade */ if ( !ch->fighting && sn != gsn_hide && sn != gsn_sneak ) { set_char_color( AT_WHITE, ch ); --- 1550,1557 ---- else { gain = 20 * sklvl; ! if ( ch->mudclass==CLASS_MAGE ) gain *= 6; /* h, mage upgrade */ ! if ( ch->mudclass==CLASS_CLERIC ) gain *= 3; /* h, mage upgrade */ if ( !ch->fighting && sn != gsn_hide && sn != gsn_sneak ) { set_char_color( AT_WHITE, ch ); *************** *** 2494,2500 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_kick]->skill_level[ch->class] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); --- 2494,2500 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_kick]->skill_level[ch->mudclass] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); *************** *** 2532,2538 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_punch]->skill_level[ch->class] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); --- 2532,2538 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_punch]->skill_level[ch->mudclass] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); *************** *** 2571,2577 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_bite]->skill_level[ch->class] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); --- 2571,2577 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_bite]->skill_level[ch->mudclass] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); *************** *** 2604,2610 **** CHAR_DATA *victim; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_claw]->skill_level[ch->class] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); --- 2604,2610 ---- CHAR_DATA *victim; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_claw]->skill_level[ch->mudclass] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); *************** *** 2643,2649 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_sting]->skill_level[ch->class] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); --- 2643,2649 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_sting]->skill_level[ch->mudclass] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); *************** *** 2682,2688 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_tail]->skill_level[ch->class] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); --- 2682,2688 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_tail]->skill_level[ch->mudclass] ) { send_to_char( "That isn't quite one of your natural skills.\n\r", ch ); *************** *** 2722,2728 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_bash]->skill_level[ch->class] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); --- 2722,2728 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_bash]->skill_level[ch->mudclass] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); *************** *** 2773,2779 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_stun]->skill_level[ch->class] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); --- 2773,2779 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_stun]->skill_level[ch->mudclass] ) { send_to_char( "You better leave the martial arts to fighters.\n\r", ch ); *************** *** 3027,3033 **** } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_disarm]->skill_level[ch->class] ) { send_to_char( "You don't know how to disarm opponents.\n\r", ch ); return; --- 3027,3033 ---- } if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_disarm]->skill_level[ch->mudclass] ) { send_to_char( "You don't know how to disarm opponents.\n\r", ch ); return; *************** *** 3589,3595 **** CHAR_DATA *victim; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_mount]->skill_level[ch->class] ) { send_to_char( "I don't think that would be a good idea...\n\r", ch ); --- 3589,3595 ---- CHAR_DATA *victim; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_mount]->skill_level[ch->mudclass] ) { send_to_char( "I don't think that would be a good idea...\n\r", ch ); *************** *** 3784,3790 **** { int chances; ! if ( victim->class != CLASS_THIEF || !IS_AWAKE( victim ) ) return FALSE; if ( !IS_NPC( victim ) && !victim->pcdata->learned[gsn_tumble] > 0 ) --- 3784,3790 ---- { int chances; ! if ( victim->mudclass != CLASS_THIEF || !IS_AWAKE( victim ) ) return FALSE; if ( !IS_NPC( victim ) && !victim->pcdata->learned[gsn_tumble] > 0 ) *************** *** 3815,3821 **** int percent; if ( !IS_NPC( ch ) ! && ch->level < skill_table[gsn_poison_weapon]->skill_level[ch->class] ) { send_to_char( "What do you think you are, a thief?\n\r", ch ); return; --- 3815,3821 ---- int percent; if ( !IS_NPC( ch ) ! && ch->level < skill_table[gsn_poison_weapon]->skill_level[ch->mudclass] ) { send_to_char( "What do you think you are, a thief?\n\r", ch ); return; *************** *** 3951,3957 **** return; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_scribe]->skill_level[ch->class] ) { send_to_char( "A skill such as this requires more magical ability than that of your class.\n\r", ch ); return; --- 3951,3957 ---- return; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_scribe]->skill_level[ch->mudclass] ) { send_to_char( "A skill such as this requires more magical ability than that of your class.\n\r", ch ); return; *************** *** 3985,3991 **** } mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->class] ) ); mana *=5; --- 3985,3991 ---- } mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->mudclass] ) ); mana *=5; *************** *** 4070,4076 **** return; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_brew]->skill_level[ch->class] ) { send_to_char( "A skill such as this requires more magical ability than that of your class.\n\r", ch ); return; --- 4070,4076 ---- return; if ( !IS_NPC(ch) ! && ch->level < skill_table[gsn_brew]->skill_level[ch->mudclass] ) { send_to_char( "A skill such as this requires more magical ability than that of your class.\n\r", ch ); return; *************** *** 4104,4110 **** } mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->class] ) ); mana *=4; --- 4104,4110 ---- } mana = IS_NPC(ch) ? 0 : UMAX(skill_table[sn]->min_mana, ! 100 / ( 2 + ch->level - skill_table[sn]->skill_level[ch->mudclass] ) ); mana *=4; *************** *** 5318,5324 **** */ if ( !IS_NPC(ch) && !IS_IMMORTAL(ch) ! && ch->level < skill_table[gsn_slice]->skill_level[ch->class] ) { send_to_char("You are not learned in this skill.\n\r", ch ); return; --- 5318,5324 ---- */ if ( !IS_NPC(ch) && !IS_IMMORTAL(ch) ! && ch->level < skill_table[gsn_slice]->skill_level[ch->mudclass] ) { send_to_char("You are not learned in this skill.\n\r", ch ); return; *************** *** 5422,5428 **** } if( !str_prefix(arg, "evasive") ){ ! if( ch->level < skill_table[gsn_style_evasive]->skill_level[ch->class]) { send_to_char( "You have not yet learned enough to fight evasively.\n\r",ch); return; --- 5422,5428 ---- } if( !str_prefix(arg, "evasive") ){ ! if( ch->level < skill_table[gsn_style_evasive]->skill_level[ch->mudclass]) { send_to_char( "You have not yet learned enough to fight evasively.\n\r",ch); return; *************** *** 5446,5452 **** return; } } else if( !str_prefix(arg, "defensive")){ ! if( ch->level < skill_table[gsn_style_defensive]->skill_level[ch->class]) { send_to_char( "You have not yet learned enough to fight defensively.\n\r",ch); return; --- 5446,5452 ---- return; } } else if( !str_prefix(arg, "defensive")){ ! if( ch->level < skill_table[gsn_style_defensive]->skill_level[ch->mudclass]) { send_to_char( "You have not yet learned enough to fight defensively.\n\r",ch); return; *************** *** 5470,5476 **** return; } } else if( !str_prefix(arg,"standard")){ ! if( ch->level < skill_table[gsn_style_standard]->skill_level[ch->class]) { send_to_char( "You have not yet learned enough to fight in the standard style.\n\r",ch); return; --- 5470,5476 ---- return; } } else if( !str_prefix(arg,"standard")){ ! if( ch->level < skill_table[gsn_style_standard]->skill_level[ch->mudclass]) { send_to_char( "You have not yet learned enough to fight in the standard style.\n\r",ch); return; *************** *** 5494,5500 **** return; } } else if( !str_prefix(arg,"aggressive")){ ! if( ch->level < skill_table[gsn_style_aggressive]->skill_level[ch->class]) { send_to_char( "You have not yet learned enough to fight aggressively.\n\r",ch); return; --- 5494,5500 ---- return; } } else if( !str_prefix(arg,"aggressive")){ ! if( ch->level < skill_table[gsn_style_aggressive]->skill_level[ch->mudclass]) { send_to_char( "You have not yet learned enough to fight aggressively.\n\r",ch); return; *************** *** 5518,5524 **** return; } } else if( !str_prefix(arg,"berserk")){ ! if( ch->level < skill_table[gsn_style_berserk]->skill_level[ch->class]) { send_to_char( "You have not yet learned enough to fight as a berserker.\n\r",ch); return; --- 5518,5524 ---- return; } } else if( !str_prefix(arg,"berserk")){ ! if( ch->level < skill_table[gsn_style_berserk]->skill_level[ch->mudclass]) { send_to_char( "You have not yet learned enough to fight as a berserker.\n\r",ch); return; *************** *** 5576,5582 **** char buf[MAX_STRING_LENGTH]; one_argument( argument, arg ); ! if ( IS_NPC(ch) || ch->level < skill_table[gsn_cook]->skill_level[ch->class]) { send_to_char("That skill is beyond your understanding.\n\r", ch ); return; --- 5576,5582 ---- char buf[MAX_STRING_LENGTH]; one_argument( argument, arg ); ! if ( IS_NPC(ch) || ch->level < skill_table[gsn_cook]->skill_level[ch->mudclass]) { send_to_char("That skill is beyond your understanding.\n\r", ch ); return; diff -c src.orig/tables.c src/tables.c *** src.orig/tables.c 1999-05-28 15:19:01.000000000 +1000 --- src/tables.c 2004-01-21 12:40:51.000000000 +1100 *************** *** 1377,1383 **** char buf[MAX_STRING_LENGTH]; char *word; bool fMatch; ! struct class_type *class; int cl = -1; int tlev = 0; FILE *fp; --- 1377,1383 ---- char buf[MAX_STRING_LENGTH]; char *word; bool fMatch; ! struct class_type *mudclass; int cl = -1; int tlev = 0; FILE *fp; *************** *** 1389,1406 **** return FALSE; } ! CREATE( class, struct class_type, 1 ); /* Setup defaults for additions to class structure */ ! class->attr_second = 0; ! class->attr_deficient = 0; ! xCLEAR_BITS(class->affected); ! class->resist = 0; ! class->suscept = 0; for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 1389,1410 ---- return FALSE; } ! CREATE( mudclass, struct class_type, 1 ); /* Setup defaults for additions to class structure */ ! mudclass->attr_second = 0; ! mudclass->attr_deficient = 0; ! xCLEAR_BITS(mudclass->affected); ! mudclass->resist = 0; ! mudclass->suscept = 0; for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); ! fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 1411,1420 **** break; case 'A': ! KEY( "Affected", class->affected, fread_bitvector(fp)); ! KEY( "AttrPrime", class->attr_prime, fread_number( fp ) ); ! KEY( "AttrSecond", class->attr_second, fread_number( fp ) ); ! KEY( "AttrDeficient",class->attr_deficient, fread_number( fp ) ); break; case 'C': --- 1415,1424 ---- break; case 'A': ! KEY( "Affected", mudclass->affected, fread_bitvector(fp)); ! KEY( "AttrPrime", mudclass->attr_prime, fread_number( fp ) ); ! KEY( "AttrSecond", mudclass->attr_second, fread_number( fp ) ); ! KEY( "AttrDeficient",mudclass->attr_deficient, fread_number( fp ) ); break; case 'C': *************** *** 1428,1465 **** if ( cl < 0 || cl >= MAX_CLASS ) { sprintf( buf, "Load_class_file: Class (%s) bad/not found (%d)", ! class->who_name ? class->who_name : "name not found", cl ); bug( buf, 0 ); ! if ( class->who_name ) ! STRFREE( class->who_name ); ! DISPOSE( class ); return FALSE; } ! class_table[cl] = class; return TRUE; } ! KEY( "ExpBase", class->exp_base, fread_number( fp ) ); break; case 'G': ! KEY( "Guild", class->guild, fread_number( fp ) ); break; case 'H': ! KEY( "HpMax", class->hp_max, fread_number( fp ) ); ! KEY( "HpMin", class->hp_min, fread_number( fp ) ); break; case 'M': ! KEY( "Mana", class->fMana, fread_number( fp ) ); break; case 'N': ! KEY( "Name", class->who_name, fread_string( fp ) ); break; case 'R': ! KEY( "Resist", class->resist, fread_number( fp ) ); break; case 'S': --- 1432,1469 ---- if ( cl < 0 || cl >= MAX_CLASS ) { sprintf( buf, "Load_class_file: Class (%s) bad/not found (%d)", ! mudclass->who_name ? mudclass->who_name : "name not found", cl ); bug( buf, 0 ); ! if ( mudclass->who_name ) ! STRFREE( mudclass->who_name ); ! DISPOSE( mudclass ); return FALSE; } ! class_table[cl] = mudclass; return TRUE; } ! KEY( "ExpBase", mudclass->exp_base, fread_number( fp ) ); break; case 'G': ! KEY( "Guild", mudclass->guild, fread_number( fp ) ); break; case 'H': ! KEY( "HpMax", mudclass->hp_max, fread_number( fp ) ); ! KEY( "HpMin", mudclass->hp_min, fread_number( fp ) ); break; case 'M': ! KEY( "Mana", mudclass->fMana, fread_number( fp ) ); break; case 'N': ! KEY( "Name", mudclass->who_name, fread_string( fp ) ); break; case 'R': ! KEY( "Resist", mudclass->resist, fread_number( fp ) ); break; case 'S': *************** *** 1490,1497 **** fMatch = TRUE; break; } ! KEY( "Skilladept", class->skill_adept, fread_number( fp ) ); ! KEY( "Suscept", class->suscept, fread_number( fp ) ); break; case 'T': --- 1494,1501 ---- fMatch = TRUE; break; } ! KEY( "Skilladept", mudclass->skill_adept, fread_number( fp ) ); ! KEY( "Suscept", mudclass->suscept, fread_number( fp ) ); break; case 'T': *************** *** 1520,1531 **** fMatch = TRUE; break; } ! KEY( "Thac0", class->thac0_00, fread_number( fp ) ); ! KEY( "Thac32", class->thac0_32, fread_number( fp ) ); break; case 'W': ! KEY( "Weapon", class->weapon, fread_number( fp ) ); break; } if ( !fMatch ) --- 1524,1535 ---- fMatch = TRUE; break; } ! KEY( "Thac0", mudclass->thac0_00, fread_number( fp ) ); ! KEY( "Thac32", mudclass->thac0_32, fread_number( fp ) ); break; case 'W': ! KEY( "Weapon", mudclass->weapon, fread_number( fp ) ); break; } if ( !fMatch ) *************** *** 1565,1571 **** for ( ; ; ) { ! filename = feof( fpList ) ? "$" : fread_word( fpList ); if ( filename[0] == '$' ) break; --- 1569,1580 ---- for ( ; ; ) { ! ! if (feof (fpList)) ! strcpy (filename, "$"); ! else ! filename = fread_word( fpList ); ! if ( filename[0] == '$' ) break; *************** *** 1595,1627 **** FILE *fpout; char buf[MAX_STRING_LENGTH]; char filename[MAX_INPUT_LENGTH]; ! struct class_type *class = class_table[cl]; int x, y; ! sprintf( filename, "%s%s.class", CLASSDIR, class->who_name ); if ( (fpout=fopen(filename, "w")) == NULL ) { sprintf( buf, "Cannot open: %s for writing", filename ); bug( buf, 0 ); return; } ! fprintf( fpout, "Name %s~\n", class->who_name ); fprintf( fpout, "Class %d\n", cl ); ! fprintf( fpout, "AttrPrime %d\n", class->attr_prime ); ! fprintf( fpout, "AttrSecond %d\n", class->attr_second ); ! fprintf( fpout, "AttrDeficient %d\n", class->attr_deficient ); ! fprintf( fpout, "Weapon %d\n", class->weapon ); ! fprintf( fpout, "Guild %d\n", class->guild ); ! fprintf( fpout, "Skilladept %d\n", class->skill_adept ); ! fprintf( fpout, "Thac0 %d\n", class->thac0_00 ); ! fprintf( fpout, "Thac32 %d\n", class->thac0_32 ); ! fprintf( fpout, "Hpmin %d\n", class->hp_min ); ! fprintf( fpout, "Hpmax %d\n", class->hp_max ); ! fprintf( fpout, "Mana %d\n", class->fMana ); ! fprintf( fpout, "Expbase %d\n", class->exp_base ); ! fprintf( fpout, "Affected %s\n", print_bitvector(&class->affected)); ! fprintf( fpout, "Resist %d\n", class->resist ); ! fprintf( fpout, "Suscept %d\n", class->suscept ); for ( x = 0; x < top_sn; x++ ) { if ( !skill_table[x]->name || skill_table[x]->name[0] == '\0' ) --- 1604,1636 ---- FILE *fpout; char buf[MAX_STRING_LENGTH]; char filename[MAX_INPUT_LENGTH]; ! struct class_type *mudclass = class_table[cl]; int x, y; ! sprintf( filename, "%s%s.class", CLASSDIR, mudclass->who_name ); if ( (fpout=fopen(filename, "w")) == NULL ) { sprintf( buf, "Cannot open: %s for writing", filename ); bug( buf, 0 ); return; } ! fprintf( fpout, "Name %s~\n", mudclass->who_name ); fprintf( fpout, "Class %d\n", cl ); ! fprintf( fpout, "AttrPrime %d\n", mudclass->attr_prime ); ! fprintf( fpout, "AttrSecond %d\n", mudclass->attr_second ); ! fprintf( fpout, "AttrDeficient %d\n", mudclass->attr_deficient ); ! fprintf( fpout, "Weapon %d\n", mudclass->weapon ); ! fprintf( fpout, "Guild %d\n", mudclass->guild ); ! fprintf( fpout, "Skilladept %d\n", mudclass->skill_adept ); ! fprintf( fpout, "Thac0 %d\n", mudclass->thac0_00 ); ! fprintf( fpout, "Thac32 %d\n", mudclass->thac0_32 ); ! fprintf( fpout, "Hpmin %d\n", mudclass->hp_min ); ! fprintf( fpout, "Hpmax %d\n", mudclass->hp_max ); ! fprintf( fpout, "Mana %d\n", mudclass->fMana ); ! fprintf( fpout, "Expbase %d\n", mudclass->exp_base ); ! fprintf( fpout, "Affected %s\n", print_bitvector(&mudclass->affected)); ! fprintf( fpout, "Resist %d\n", mudclass->resist ); ! fprintf( fpout, "Suscept %d\n", mudclass->suscept ); for ( x = 0; x < top_sn; x++ ) { if ( !skill_table[x]->name || skill_table[x]->name[0] == '\0' ) *************** *** 1665,1671 **** for ( ; ; ) { ! filename = feof( fpList ) ? "$" : fread_word( fpList ); if ( filename[0] == '$' ) break; --- 1674,1683 ---- for ( ; ; ) { ! if (feof (fpList)) ! strcpy (filename, "$"); ! else ! filename = fread_word( fpList ); if ( filename[0] == '$' ) break; *************** *** 1783,1789 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 1795,1804 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 2319,2325 **** for ( ; ; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 2334,2343 ---- for ( ; ; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 2363,2372 **** case 'C': if ( !str_cmp( word, "Class" ) ) { ! int class = fread_number( fp ); ! skill->skill_level[class] = fread_number( fp ); ! skill->skill_adept[class] = fread_number( fp ); fMatch = TRUE; break; } --- 2381,2390 ---- case 'C': if ( !str_cmp( word, "Class" ) ) { ! int mudclass = fread_number( fp ); ! skill->skill_level[mudclass] = fread_number( fp ); ! skill->skill_adept[mudclass] = fread_number( fp ); fMatch = TRUE; break; } *************** *** 2700,2706 **** for ( ;; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 2718,2727 ---- for ( ;; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 2825,2831 **** for ( ;; ) { ! word = feof( fp ) ? "End" : fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) --- 2846,2855 ---- for ( ;; ) { ! if (feof (fp)) ! strcpy (word, "End"); ! else ! word = fread_word( fp ); fMatch = FALSE; switch ( UPPER(word[0]) ) *************** *** 2988,2995 **** cnv->old = str_dup(fread_word(fp)); cnv->olen = strlen(cnv->old); ! cnv->new = str_dup(fread_word(fp)); ! cnv->nlen = strlen(cnv->new); fread_to_eol(fp); LINK(cnv, *first_cnv, *last_cnv, next, prev); } --- 3012,3019 ---- cnv->old = str_dup(fread_word(fp)); cnv->olen = strlen(cnv->old); ! cnv->lcnv_new = str_dup(fread_word(fp)); ! cnv->nlen = strlen(cnv->lcnv_new); fread_to_eol(fp); LINK(cnv, *first_cnv, *last_cnv, next, prev); } *************** *** 3052,3061 **** { fprintf(fp, "#%s\n", lng->name); for (cnv = lng->first_precnv; cnv; cnv = cnv->next) ! fprintf(fp, "'%s' '%s'\n", cnv->old, cnv->new); fprintf(fp, "~\n%s~\n", lng->alphabet); for (cnv = lng->first_cnv; cnv; cnv = cnv->next) ! fprintf(fp, "'%s' '%s'\n", cnv->old, cnv->new); fprintf(fp, "\n"); } fprintf(fp, "#end\n\n"); --- 3076,3085 ---- { fprintf(fp, "#%s\n", lng->name); for (cnv = lng->first_precnv; cnv; cnv = cnv->next) ! fprintf(fp, "'%s' '%s'\n", cnv->old, cnv->lcnv_new); fprintf(fp, "~\n%s~\n", lng->alphabet); for (cnv = lng->first_cnv; cnv; cnv = cnv->next) ! fprintf(fp, "'%s' '%s'\n", cnv->old, cnv->lcnv_new); fprintf(fp, "\n"); } fprintf(fp, "#end\n\n"); diff -c src.orig/track.c src/track.c *** src.orig/track.c 1999-05-28 15:19:01.000000000 +1000 --- src/track.c 2004-01-20 12:14:25.000000000 +1100 *************** *** 64,70 **** { BFS_DATA *curr; ! curr = malloc( sizeof(BFS_DATA) ); curr->room = room; curr->dir = dir; curr->next = NULL; --- 64,70 ---- { BFS_DATA *curr; ! curr = (BFS_DATA *) malloc( sizeof(BFS_DATA) ); curr->room = room; curr->dir = dir; curr->next = NULL; *************** *** 101,107 **** { BFS_DATA *curr; ! curr = malloc( sizeof(BFS_DATA) ); curr->room = room; curr->next = room_queue; --- 101,107 ---- { BFS_DATA *curr; ! curr = (BFS_DATA *) malloc( sizeof(BFS_DATA) ); curr->room = room; curr->next = room_queue; diff -c src.orig/update.c src/update.c *** src.orig/update.c 1999-05-28 15:19:01.000000000 +1000 --- src/update.c 2004-01-20 12:15:53.000000000 +1100 *************** *** 82,94 **** /* save_char_obj( ch );*/ sprintf( buf, "the %s", ! title_table [ch->class] [ch->level] [ch->sex == SEX_FEMALE ? 1 : 0] ); set_title( ch, buf ); add_hp = con_app[get_curr_con(ch)].hitp + number_range( ! class_table[ch->class]->hp_min, ! class_table[ch->class]->hp_max ); ! add_mana = class_table[ch->class]->fMana ? number_range(2, (2*get_curr_int(ch)+get_curr_wis(ch))/8) : 0; add_move = number_range( 5, (get_curr_con(ch)+get_curr_dex(ch))/4 ); --- 82,94 ---- /* save_char_obj( ch );*/ sprintf( buf, "the %s", ! title_table [ch->mudclass] [ch->level] [ch->sex == SEX_FEMALE ? 1 : 0] ); set_title( ch, buf ); add_hp = con_app[get_curr_con(ch)].hitp + number_range( ! class_table[ch->mudclass]->hp_min, ! class_table[ch->mudclass]->hp_max ); ! add_mana = class_table[ch->mudclass]->fMana ? number_range(2, (2*get_curr_int(ch)+get_curr_wis(ch))/8) : 0; add_move = number_range( 5, (get_curr_con(ch)+get_curr_dex(ch))/4 ); *************** *** 157,163 **** get_age( ch ), ch->in_room == NULL ? 0 : ch->in_room->vnum, capitalize(race_table[ch->race]->race_name), ! class_table[ch->class]->who_name ); append_to_file( PLEVEL_FILE, buf2 ); } } --- 157,163 ---- get_age( ch ), ch->in_room == NULL ? 0 : ch->in_room->vnum, capitalize(race_table[ch->race]->race_name), ! class_table[ch->mudclass]->who_name ); append_to_file( PLEVEL_FILE, buf2 ); } } *************** *** 410,416 **** switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are STARVING!\n\r", ch ); --- 410,416 ---- switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are STARVING!\n\r", ch ); *************** *** 422,428 **** break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are DYING of THIRST!\n\r", ch ); --- 422,428 ---- break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are DYING of THIRST!\n\r", ch ); *************** *** 465,471 **** switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are really hungry.\n\r", ch ); --- 465,471 ---- switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are really hungry.\n\r", ch ); *************** *** 476,482 **** break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are really thirsty.\n\r", ch ); --- 476,482 ---- break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are really thirsty.\n\r", ch ); *************** *** 510,516 **** switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are hungry.\n\r", ch ); --- 510,516 ---- switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are hungry.\n\r", ch ); *************** *** 518,524 **** break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are thirsty.\n\r", ch ); --- 518,524 ---- break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You are thirsty.\n\r", ch ); *************** *** 540,546 **** switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are a mite peckish.\n\r", ch ); --- 540,546 ---- switch ( iCond ) { case COND_FULL: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_HUNGRY, ch ); send_to_char( "You are a mite peckish.\n\r", ch ); *************** *** 548,554 **** break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->class != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You could use a sip of something refreshing.\n\r", ch ); --- 548,554 ---- break; case COND_THIRST: ! if ( ch->level < LEVEL_AVATAR && ch->mudclass != CLASS_VAMPIRE ) { set_char_color( AT_THIRSTY, ch ); send_to_char( "You could use a sip of something refreshing.\n\r", ch ); *************** *** 593,599 **** } /* Nephandi alignment restrictions -h */ ! if(ch->class == CLASS_NEPHANDI){ if(ch->alignment>-250){ set_char_color( AT_BLOOD, ch ); send_to_char( "Damn you heathen! Go forth and do evil or suffer the consequences!\n\r", ch ); --- 593,599 ---- } /* Nephandi alignment restrictions -h */ ! if(ch->mudclass == CLASS_NEPHANDI){ if(ch->alignment>-250){ set_char_color( AT_BLOOD, ch ); send_to_char( "Damn you heathen! Go forth and do evil or suffer the consequences!\n\r", ch ); *************** *** 604,610 **** /* Paladins need some restrictions, this is where we crunch 'em -h */ ! if(ch->class == CLASS_PALADIN){ if(ch->alignment<250){ set_char_color( AT_BLOOD, ch ); send_to_char( "You are wracked with guilt and remorse for your craven actions!\n\r", ch ); --- 604,610 ---- /* Paladins need some restrictions, this is where we crunch 'em -h */ ! if(ch->mudclass == CLASS_PALADIN){ if(ch->alignment<250){ set_char_color( AT_BLOOD, ch ); send_to_char( "You are wracked with guilt and remorse for your craven actions!\n\r", ch ); *************** *** 1056,1062 **** gain_condition( ch, COND_DRUNK, -1 ); gain_condition( ch, COND_FULL, -1 + race_table[ch->race]->hunger_mod ); ! if ( ch->class == CLASS_VAMPIRE && ch->level >= 10 ) { if ( time_info.hour < 21 && time_info.hour > 5 ) gain_condition( ch, COND_BLOODTHIRST, -1 ); --- 1056,1062 ---- gain_condition( ch, COND_DRUNK, -1 ); gain_condition( ch, COND_FULL, -1 + race_table[ch->race]->hunger_mod ); ! if ( ch->mudclass == CLASS_VAMPIRE && ch->level >= 10 ) { if ( time_info.hour < 21 && time_info.hour > 5 ) gain_condition( ch, COND_BLOODTHIRST, -1 ); *************** *** 1693,1699 **** /* check mobprog act queue */ while ( (apdtmp = mob_act_list) != NULL ) { ! wch = mob_act_list->vo; if ( !char_died(wch) && wch->mpactnum > 0 ) { MPROG_ACT_LIST * tmp_act; --- 1693,1699 ---- /* check mobprog act queue */ while ( (apdtmp = mob_act_list) != NULL ) { ! wch = (CHAR_DATA *) mob_act_list->vo; if ( !char_died(wch) && wch->mpactnum > 0 ) { MPROG_ACT_LIST * tmp_act; *************** *** 1865,1871 **** for ( vch = ch->in_room->first_person; vch; vch = vch->next_in_room ) if ( number_percent() < 10 ) rvch = vch; ! check_social( ch, "puke", (rvch ? rvch->name : "") ); } ch->position = position; --- 1865,1871 ---- for ( vch = ch->in_room->first_person; vch; vch = vch->next_in_room ) if ( number_percent() < 10 ) rvch = vch; ! check_social( ch, "puke", (rvch ? rvch->name : (char *) "") ); } ch->position = position; *************** *** 1964,1970 **** } sprintf( log_buf, " %s@%s new %s %s", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->class]->who_name ); /* log_string( log_buf ); */ to_channel( log_buf, CHANNEL_AUTH, "Auth", 1); } --- 1964,1970 ---- } sprintf( log_buf, " %s@%s new %s %s", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->mudclass]->who_name ); /* log_string( log_buf ); */ to_channel( log_buf, CHANNEL_AUTH, "Auth", 1); } *************** *** 1987,1993 **** found_hit = TRUE; sprintf( buf, " %s@%s new %s %s\n\r", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->class]->who_name ); strcat (log_buf, buf); } } --- 1987,1993 ---- found_hit = TRUE; sprintf( buf, " %s@%s new %s %s\n\r", victim->name, victim->desc->host, race_table[victim->race]->race_name, ! class_table[victim->mudclass]->who_name ); strcat (log_buf, buf); } }