Thread: [SlashMUD-commits] slashmudx/src living_object.h, 1.57, 1.58 player_overrides.c, 1.46, 1.47 self_te
Status: Alpha
Brought to you by:
koryn
From: Koryn G. <ko...@us...> - 2008-05-01 10:10:50
|
Update of /cvsroot/slashmud/slashmudx/src In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv32638/src Modified Files: living_object.h player_overrides.c self_test.c Log Message: Fix for light self-test. Index: player_overrides.c =================================================================== RCS file: /cvsroot/slashmud/slashmudx/src/player_overrides.c,v retrieving revision 1.46 retrieving revision 1.47 diff -C2 -d -r1.46 -r1.47 *** player_overrides.c 24 Sep 2007 10:10:46 -0000 1.46 --- player_overrides.c 1 May 2008 10:10:32 -0000 1.47 *************** *** 386,390 **** else if (strcmp(token, "guild-name") == 0) { ! self->living_data.mGuild = replace_string(self->living_data.mGuild, (const char*) remainder); } else --- 386,390 ---- else if (strcmp(token, "guild-name") == 0) { ! self->living_data.mGuildName = replace_string(self->living_data.mGuildName, (const char*) remainder); } else *************** *** 450,456 **** } ! if (self->living_data.mGuild) { ! snprintf(line, kSaveBufferBytes, "guild-name %s", self->living_data.mGuild); kg_save_text_add_line(save_text, line); } --- 450,456 ---- } ! if (self->living_data.mGuildName) { ! snprintf(line, kSaveBufferBytes, "guild-name %s", self->living_data.mGuildName); kg_save_text_add_line(save_text, line); } Index: living_object.h =================================================================== RCS file: /cvsroot/slashmud/slashmudx/src/living_object.h,v retrieving revision 1.57 retrieving revision 1.58 diff -C2 -d -r1.57 -r1.58 *** living_object.h 25 Apr 2008 05:26:14 -0000 1.57 --- living_object.h 1 May 2008 10:10:32 -0000 1.58 *************** *** 64,95 **** PursePtr mPurse; KeyringPtr mKeyring; ! const char* mCurrentLanguage; const char* mApparentLanguage; const char* mEnterMessage; - const char* mApparentEnterMessage; const char* mExitMessage; - const char* mApparentExitMessage; const char* mTeleportInMessage; - const char* mApparentTeleportInMessage; const char* mTeleportOutMessage; - const char* mApparentTeleportOutMessage; - const char* mApparentClassName; - const char* mApparentRaceName; - const char* mUnknownRaceName; const char* mUnknownClassName; ! unsigned int mKills; ! unsigned int mHitpoints; ! unsigned int mSpellpoints; ! unsigned int mKillpoints; ! unsigned int mSpendpoints; unsigned int mAgeSeconds; - unsigned int mLastAgeSeconds; /* Time at which mAgeSeconds was last updated. */ - unsigned int mGoodAlignment; - unsigned int mBadAlignment; - unsigned int mHealingTime; - unsigned int mStunLevel; unsigned int mApparentHeight; unsigned int mBodyHitChanceSum; unsigned int mClassLevel; /* State for class. */ int mWimpy; /* Negative wimpy means wimpy is off, |wimpy| = previous value of wimpy. */ --- 64,95 ---- PursePtr mPurse; KeyringPtr mKeyring; ! const char* mApparentClassName; ! const char* mApparentEnterMessage; ! const char* mApparentExitMessage; const char* mApparentLanguage; + const char* mApparentRaceName; + const char* mApparentTeleportInMessage; + const char* mApparentTeleportOutMessage; + const char* mCurrentLanguage; const char* mEnterMessage; const char* mExitMessage; const char* mTeleportInMessage; const char* mTeleportOutMessage; const char* mUnknownClassName; ! const char* mUnknownRaceName; unsigned int mAgeSeconds; unsigned int mApparentHeight; + unsigned int mBadAlignment; unsigned int mBodyHitChanceSum; unsigned int mClassLevel; /* State for class. */ + unsigned int mGoodAlignment; + unsigned int mHealingTime; + unsigned int mHitpoints; + unsigned int mKillpoints; + unsigned int mKills; + unsigned int mLastAgeSeconds; /* Time at which mAgeSeconds was last updated. */ + unsigned int mSpellpoints; + unsigned int mSpendpoints; + unsigned int mStunLevel; int mWimpy; /* Negative wimpy means wimpy is off, |wimpy| = previous value of wimpy. */ Index: self_test.c =================================================================== RCS file: /cvsroot/slashmud/slashmudx/src/self_test.c,v retrieving revision 1.63 retrieving revision 1.64 diff -C2 -d -r1.63 -r1.64 *** self_test.c 21 Apr 2008 03:57:00 -0000 1.63 --- self_test.c 1 May 2008 10:10:32 -0000 1.64 *************** *** 2392,2395 **** --- 2392,2396 ---- int light; int monster_light; + int base_monster_light; int daylight __attribute__ ((unused)) = time_manager_is_light(); *************** *** 2428,2434 **** /* Check the light calculations. */ light = virtual_calculate_light((BasePtr) quarantine); ! monster_light = virtual_calculate_light((BasePtr) monster); ! assert(0 == monster_light); ! assert(light == (monster_light + daylight)); /* Add light to the monster and recheck. */ --- 2429,2434 ---- /* Check the light calculations. */ light = virtual_calculate_light((BasePtr) quarantine); ! base_monster_light = virtual_calculate_light((BasePtr) monster); ! assert(light == (base_monster_light + daylight)); /* Add light to the monster and recheck. */ *************** *** 2436,2440 **** light = virtual_calculate_light((BasePtr) quarantine); monster_light = virtual_calculate_light((BasePtr) monster); ! assert(4 == monster_light); assert(light == (monster_light + daylight)); --- 2436,2441 ---- light = virtual_calculate_light((BasePtr) quarantine); monster_light = virtual_calculate_light((BasePtr) monster); ! assert(monster_light >= 4); ! assert(monster_light == (4 + base_monster_light)); assert(light == (monster_light + daylight)); *************** *** 2443,2447 **** light = virtual_calculate_light((BasePtr) quarantine); monster_light = virtual_calculate_light((BasePtr) monster); ! assert(2 == monster_light); assert(light == (monster_light + daylight)); --- 2444,2449 ---- light = virtual_calculate_light((BasePtr) quarantine); monster_light = virtual_calculate_light((BasePtr) monster); ! assert(monster_light >= 2); ! assert(monster_light == (2 + base_monster_light)); assert(light == (monster_light + daylight)); |