diff -rcw crossfire-0.94.0.old/common/living.c crossfire-0.94.0/common/living.c *** crossfire-0.94.0.old/common/living.c Sat Feb 7 21:26:15 1998 --- crossfire-0.94.0/common/living.c Sat Mar 7 19:19:01 1998 *************** *** 873,879 **** void fix_player(object *op) { int i,j; ! float f,max=9,added_speed=0,bonus_speed=0, sp_tmp; float M,W,s,D,K,S,M2; int weapon_weight=0,weapon_speed=0; int best_wc=0, best_ac=0, wc=0; --- 873,879 ---- void fix_player(object *op) { int i,j; ! float f,max=9,added_speed=0,bonus_speed=0, sp_tmp,speed_reduce_from_disease=1; float M,W,s,D,K,S,M2; int weapon_weight=0,weapon_speed=0; int best_wc=0, best_ac=0, wc=0; *************** *** 922,927 **** --- 922,928 ---- if(!QUERY_FLAG(op,FLAG_USE_ARMOUR) && op->type==PLAYER) + /* for players which cannot use armour, they gain AC -1 per 3 levels. */ op->stats.ac=MAX(-10,op->arch->clone.stats.ac - op->level/3); else op->stats.ac=op->arch->clone.stats.ac; *************** *** 949,961 **** || (tmp->type == SHIELD) || (tmp->type == RING) || (tmp->type == BOOTS) || (tmp->type == GLOVES) || (tmp->type == AMULET ) || (tmp->type == GIRDLE) ! || (tmp->type == BRACERS ) || (tmp->type == CLOAK)){ op->contr->digestion += tmp->stats.food; op->contr->gen_hp += tmp->stats.hp; op->contr->gen_sp += tmp->stats.sp; op->contr->gen_grace += tmp->stats.grace; } } op->protected|=tmp->protected; op->vulnerable|=tmp->vulnerable; if (tmp->type!=BOW) { --- 950,970 ---- || (tmp->type == SHIELD) || (tmp->type == RING) || (tmp->type == BOOTS) || (tmp->type == GLOVES) || (tmp->type == AMULET ) || (tmp->type == GIRDLE) ! || (tmp->type == BRACERS ) || (tmp->type == CLOAK) ! ||(tmp->type == DISEASE)){ op->contr->digestion += tmp->stats.food; op->contr->gen_hp += tmp->stats.hp; op->contr->gen_sp += tmp->stats.sp; op->contr->gen_grace += tmp->stats.grace; } } + + if(tmp->type==SYMPTOM) { + speed_reduce_from_disease = tmp->last_sp / 100.0; + if(speed_reduce_from_disease ==0) speed_reduce_from_disease = 1; + } + + op->protected|=tmp->protected; op->vulnerable|=tmp->vulnerable; if (tmp->type!=BOW) { *************** *** 1272,1277 **** --- 1281,1287 ---- /* Put a lower limit on speed. Note with this speed, you move once every * 100 ticks or so. This amounts to once every 12 seconds of realtime. */ + op->speed = op->speed * speed_reduce_from_disease; if (op->speed<0.01 && op->type==PLAYER) op->speed=0.01; if(op->type == PLAYER) { diff -rcw crossfire-0.94.0.old/config/crosssite.def crossfire-0.94.0/config/crosssite.def *** crossfire-0.94.0.old/config/crosssite.def Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/config/crosssite.def Tue Mar 3 10:40:10 1998 *************** *** 36,47 **** * (mwedel@pyramid.com) */ - /* #define XPM_PIX #define Xpm_LibDir /usr/local/lib/ ! */ /* If your include files are someplace odd */ ! /*#define Xpm_Include /usr/local/include*/ /* Automatically install after successfull compilation? */ --- 36,46 ---- * (mwedel@pyramid.com) */ #define XPM_PIX #define Xpm_LibDir /usr/local/lib/ ! /* If your include files are someplace odd */ ! #define Xpm_Include /usr/local/include /* Automatically install after successfull compilation? */ *************** *** 51,59 **** * This is a top root directory of all game staff as in UNIX-style * overall. */ ! #define CTop /home/hugin/a/crossfire/crossfire ! /* #define CTop /net/contrib/crossfire */ ! /*#define CTop /usr/local/games/crossfire*/ /* Binaries location If this is undefined, it default to the standard location for X binaries on your machine. */ --- 50,56 ---- * This is a top root directory of all game staff as in UNIX-style * overall. */ ! #define CTop /home/tesla/peterm/crossfire /* Binaries location If this is undefined, it default to the standard location for X binaries on your machine. */ Only in crossfire-0.94.0/crossedit/Cnv: Makefile Only in crossfire-0.94.0/crossedit/bitmaps: Makefile Only in crossfire-0.94.0/crossedit/doc: Makefile Only in crossfire-0.94.0/crossedit/include: Makefile Only in crossfire-0.94.0/doc/playbook: Makefile Only in crossfire-0.94.0/doc/playbook-html: Makefile Only in crossfire-0.94.0/doc/spell-docs: Makefile Only in crossfire-0.94.0/doc/spoiler: Makefile Only in crossfire-0.94.0/doc/spoiler-html: Makefile diff -rcw crossfire-0.94.0.old/include/config.h crossfire-0.94.0/include/config.h *** crossfire-0.94.0.old/include/config.h Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/include/config.h Tue Mar 3 10:41:09 1998 *************** *** 76,82 **** * knows where to find the information. */ ! #define RECYCLE_TMP_MAPS /* Set this if you want to activate the new client/server code. * Being that eutl dependencies have been removed, we now select it in --- 76,82 ---- * knows where to find the information. */ ! /*#define RECYCLE_TMP_MAPS*/ /* Set this if you want to activate the new client/server code. * Being that eutl dependencies have been removed, we now select it in diff -rcw crossfire-0.94.0.old/include/define.h crossfire-0.94.0/include/define.h *** crossfire-0.94.0.old/include/define.h Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/include/define.h Fri Mar 6 14:50:41 1998 *************** *** 230,235 **** --- 230,238 ---- #define POWER_CRYSTAL 156 #define CORPSE 157 + #define DISEASE 158 + #define SYMPTOM 159 + #define WINUPPER (-5) #define WINLOWER 5 *************** *** 314,320 **** #define NRSPELLPATHS 20 ! #define NROFREALSPELLS 171 /* Number of different spells */ #define NROFSKILLS 32 /* match to the number of elements in skills[] array */ --- 317,323 ---- #define NRSPELLPATHS 20 ! #define NROFREALSPELLS 180 /* Number of different spells */ #define NROFSKILLS 32 /* match to the number of elements in skills[] array */ diff -rcw crossfire-0.94.0.old/include/spellist.h crossfire-0.94.0/include/spellist.h *** crossfire-0.94.0.old/include/spellist.h Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/include/spellist.h Fri Mar 6 19:48:28 1998 *************** *** 380,386 **** {"medium snowstorm", 3,10, 20, 10, 0, 0, 6, 1, 0, 0, 0, PATH_FROST, "snowball_m",}, {"large snowstorm", 5,16, 10, 15, 0, 0, 2, 1, 0, 0, 0, ! PATH_FROST, "snowball_l",} /* 170 */ }; /* peterm: the following defines the parameters for all the --- 380,405 ---- {"medium snowstorm", 3,10, 20, 10, 0, 0, 6, 1, 0, 0, 0, PATH_FROST, "snowball_m",}, {"large snowstorm", 5,16, 10, 15, 0, 0, 2, 1, 0, 0, 0, ! PATH_FROST, "snowball_l",}, /* 170 */ ! {"cure disease", 5,30, 0, 10, 3, 5, 1, 0, 0, 1, 1, ! PATH_RESTORE,NULL}, ! {"cause red death", 20,100, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"ebola"}, ! {"cause flu", 2, 10, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"flu"}, ! {"cause black death", 15, 85, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"bubonic_plague"}, ! {"cause leprosy", 5, 20, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"leprosy"}, ! {"cause smallpox", 20,100, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"smallpox"}, ! {"cause plague", 20,100, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"pneumonic_plague"}, ! {"cause anthrax", 12, 75, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"anthrax"}, ! {"cause typhoid", 15, 85, 0, 10, 0, 0, 0, 1, 0, 1, 0, ! PATH_WOUNDING,"typhoid"} ! }; /* peterm: the following defines the parameters for all the *************** *** 571,577 **** { 0, 0, 0, 4, 12}, /* cause many wounds */ { 8, 6, 3, 0, 24}, /*small snowstorm*/ { 8, 10, 3, 0, 24}, /*medium snowstorm*/ ! { 8, 14, 4, 0, 32} /*large snowstorm*/ }; char *spellpathnames[NRSPELLPATHS] = { --- 590,606 ---- { 0, 0, 0, 4, 12}, /* cause many wounds */ { 8, 6, 3, 0, 24}, /*small snowstorm*/ { 8, 10, 3, 0, 24}, /*medium snowstorm*/ ! { 8, 14, 4, 0, 32}, /*large snowstorm*/ ! { 0, 0, 0, 0, 0}, /*cure disease*/ ! { 0, 0, 1, 1, 24}, /*cause red death*/ ! { 0, 0, 3, 5, 10}, /*cause flu*/ ! { 0, 0, 3, 10, 20}, /*cause black death*/ ! { 0, 0, 1, 1, 10}, /*cause leprosy*/ ! { 0, 0, 1, 4, 10}, /*cause smallpox*/ ! { 0, 0, 1, 5, 24}, /*cause plague*/ ! { 0, 0, 1, 10, 10}, /*cause anthrax*/ ! { 0, 0, 1, 10, 24} /*cause typhoid*/ ! }; char *spellpathnames[NRSPELLPATHS] = { diff -rcw crossfire-0.94.0.old/include/spells.h crossfire-0.94.0/include/spells.h *** crossfire-0.94.0.old/include/spells.h Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/include/spells.h Fri Mar 6 14:59:34 1998 *************** *** 149,155 **** SP_BULLET_SWARM, SP_BULLET_STORM, SP_CAUSE_MANY, /* 165 */ SP_S_SNOWSTORM, SP_M_SNOWSTORM, ! SP_L_SNOWSTORM }; --- 149,159 ---- SP_BULLET_SWARM, SP_BULLET_STORM, SP_CAUSE_MANY, /* 165 */ SP_S_SNOWSTORM, SP_M_SNOWSTORM, ! SP_L_SNOWSTORM, SP_CURE_DISEASE, SP_CAUSE_EBOLA, /* 170 */ ! SP_CAUSE_FLU, SP_CAUSE_PLAGUE, ! ! SP_CAUSE_LEPROSY, SP_CAUSE_SMALLPOX, SP_CAUSE_PNEUMONIC_PLAGUE, /* 175 */ ! SP_CAUSE_ANTHRAX, SP_CAUSE_TYPHOID }; diff -rcw crossfire-0.94.0.old/include/sproto.h crossfire-0.94.0/include/sproto.h *** crossfire-0.94.0.old/include/sproto.h Sat Feb 7 21:26:21 1998 --- crossfire-0.94.0/include/sproto.h Fri Mar 6 20:07:55 1998 *************** *** 780,784 **** --- 780,798 ---- extern void draw_bw ( object *pl ); extern void draw_color_pix ( object *pl ); + extern int move_disease(object *disease) ; + extern int remove_symptoms(object *disease) ; + extern object * find_symptom(object *disease) ; + extern int check_infection(object *disease) ; + extern int infect_object(object *victim, object *disease) ; + extern int do_symptoms(object *disease) ; + extern int grant_immunity(object *disease) ; + extern int move_symptom(object *symptom) ; + extern int check_physically_infect(object *victim, object *hitter); + extern int cure_disease(object *sufferer, object *caster); + extern int reduce_symptoms(object *sufferer, int reduction); + extern int cast_cause_disease(object *op, object *caster, int dir, archetype *disease_arch, int type); + + #endif /* __STDC__ */ #endif /* __CEXTRACT__ */ Only in crossfire-0.94.0/lib: arch diff -rcw crossfire-0.94.0.old/lib/archetypes crossfire-0.94.0/lib/archetypes *** crossfire-0.94.0.old/lib/archetypes Sat Feb 7 21:26:22 1998 --- crossfire-0.94.0/lib/archetypes Sun Mar 8 16:04:29 1998 *************** *** 4169,4174 **** --- 4169,4735 ---- x 4 y 3 end + Object anthrax + name anthrax + type 158 + attacktype 1048576 + invisible 1 + wc 5 + magic 1 + Str -3 + Con -4 + Dex -3 + maxhp 100 + dam -5 + maxgrace 20 + food -1 + speed 0.05 + last_sp 50 + maxsp 0 + ac 0 + last_eat 0 + exp 1000 + hp 1 + sp 1 + msg + You feel feverish. Your muscles spasm oddly.... Breathing is difficult. + endmsg + race * + level 12 + end + Object arthritis + name arthritis + type 158 + invisible 1 + attacktype 1048576 + wc 5 + magic 0 + Str -1 + Dex -2 + maxhp 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 1 + last_eat 0 + exp 10000 + msg + Your joints are swollen. You feel less dextrous and weaker. + endmsg + race * + level 7 + end + Object atheletes_foot + name athelete's foot + type 158 + invisible 1 + attacktype 1 + wc 1 + magic 1 + Dex -1 + maxhp 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 0 + last_eat 0 + exp 100 + msg + Your feet itch. They burn. + endmsg + race * + level 5 + end + Object diahrrea + name the runs + type 158 + invisible 1 + attacktype 1 + other_arch disgusting_puddle + wc 0 + magic 0 + maxhp 1 + dam 0 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + last_eat 0 + exp 100 + msg + You can't control your sphincter. + You have a messy accident. Yuck! + endmsg + race * + level 5 + end + Object disgusting_puddle + name stinking puddle of diarrhea + type 72 + face icor.111 + food 1 + weight 20 + end + Object trap_diseased_needle + name diseased needle + type 154 + face needle.111 + randomitems needle_diseases + speed 1 + hp 1 + msg + You are pricked by a needle! + endmsg + anim + needle.111 + needle.111 + mina + level 1 + is_animated 0 + invisible 1 + no_pick 1 + walk_on 1 + editable 32 + attacktype 1 + dam 10 + Cha 20 + end + Object ebola + name Ebola + type 158 + invisible 1 + attacktype 1048576 + wc 10 + magic 1 + Str -3 + Con -4 + Dex -2 + Wis -2 + Int -4 + Cha -7 + maxhp 5 + dam -10 + maxgrace 15 + food -1 + speed 0.05 + last_sp 50 + maxsp 0 + ac 0 + last_eat 0 + exp 10000 + hp 1 + sp 1 + msg + Blood leaks out of your eyes and your pores! + endmsg + race * + level 10 + end + Object egg_disease + name egg disease + type 158 + invisible 1 + attacktype 1 + other_arch chicken_egg + wc 0 + magic 0 + maxhp 1 + dam 0 + maxgrace -1 + food -1 + speed 0.001 + last_sp 0 + maxsp 0 + last_eat 0 + exp 100 + msg + Buck, buck, buck, buck! You lay an EGG!! + You feel ridiculous. + endmsg + race * + level 5 + end + Object chicken_egg + name egg + type 72 + face ant_egg.111 + food 10 + weight 20 + end + Object flaming_fart + name flaming farts + type 158 + invisible 1 + attacktype 1 + other_arch burnout + wc 0 + magic 0 + maxhp 1 + dam 0 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + last_eat 0 + exp 100 + msg + You blow a great fart. It ignites. My God, the REEK! + endmsg + race * + level 5 + end + Object flu + name flu + type 158 + invisible 1 + attacktype 1048576 + wc 20 + magic 3 + Str -1 + Con -1 + Dex -1 + Wis -1 + Int -1 + Cha -1 + maxhp 10 + dam 1 + maxgrace 6 + food -1 + speed 0.05 + last_sp 50 + maxsp 0 + ac 0 + last_eat 0 + exp 100 + hp 1 + sp 1 + msg + You have aches and fever, and you feel nauseous. + endmsg + race * + level 2 + end + Object immunity + title immunity + face bone_head.111 + type 98 + invisible 1 + end + Object incontinence + name lack of bladder control + type 158 + invisible 1 + attacktype 1 + other_arch reeking_urine + wc 0 + magic 0 + maxhp 1 + dam 0 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + last_eat 0 + exp 100 + msg + You can't control your bladder. + You have a messy accident. Yuck! + endmsg + race * + level 5 + end + Object reeking_urine + name reeking puddle of urine + type 72 + face residue.111 + food 1 + weight 20 + end + Object insanity + name insanity + type 158 + invisible 1 + attacktype 32 + wc 10 + magic 0 + Wis -1 + Int -1 + maxhp 1 + dam 1 + maxgrace -1 + food -1 + speed 0.001 + last_sp 0 + maxsp 0 + ac 3 + last_eat 0 + exp 10000 + msg + You start gibbering incoherently. You forget where you are and + what you were doing. + endmsg + race * + level 15 + end + Object leprosy + name leprosy + type 158 + invisible 1 + attacktype 1048576 + other_arch leprous_skin + wc 10 + magic 0 + Str -1 + Con -1 + Dex -1 + Cha -2 + maxhp 1 + dam 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 5 + last_eat 0 + exp 1000 + hp 1 + sp 1 + msg + Splotches are spreading around your body. You feel disgusted + with yourself. A piece of skin flakes off and falls to the ground. + endmsg + race * + level 5 + end + Object leprous_skin + name leprous flake of skin + type 72 + food 5 + weight 7 + end + Object bubonic_plague + name Black Death + type 158 + attacktype 1048576 + invisible 1 + wc 10 + magic 1 + Str -3 + Con -4 + Dex -3 + Cha -4 + maxhp 7 + dam -11 + maxgrace 10 + food -1 + speed 0.05 + last_sp 50 + maxsp 0 + ac 0 + last_eat 0 + exp 10000 + hp 1 + sp 1 + msg + You have aches and fever, and you feel nauseous. + endmsg + race * + level 15 + end + Object pneumonic_plague + name pneumonic plague + type 158 + attacktype 1048576 + invisible 1 + wc 20 + magic 4 + Str -3 + Con -4 + Dex -3 + Cha -4 + maxhp 7 + dam -11 + maxgrace 15 + food -1 + speed 0.05 + last_sp 50 + maxsp 0 + ac 0 + last_eat 0 + exp 10000 + hp 1 + sp 1 + msg + You cough up some nasty green phlegm. + endmsg + race * + level 15 + end + Object scurvy + name scurvy + type 158 + invisible 1 + attacktype 1 + other_arch tooth + wc 0 + Con -1 + magic 0 + maxhp 1 + dam 0 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + last_eat 0 + exp 100 + msg + You spit out a tooth. Better increase that dietary vitamin C! + endmsg + race * + level 5 + end + Object smallpox + name smallpox + type 158 + invisible 1 + attacktype 1048576 + wc 20 + magic 3 + Str -1 + Con -4 + Dex -1 + maxhp 5 + dam -10 + maxgrace 15 + food -1 + speed 0.08 + last_sp 0 + maxsp 0 + ac 0 + last_eat 0 + exp 10000 + hp 1 + sp 1 + msg + You have a nasty rash all over you. Are those pustules? + endmsg + race * + level 20 + end + Object symptom + face bone_head.111 + type 159 + invisible 1 + speed 0.001 + end + Object tapeworms + name tapeworms + type 158 + invisible 1 + attacktype 1 + wc 1 + magic 1 + maxhp 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 0 + last_eat 1 + exp 100 + msg + You feel more hungry than usual. You also feel an urge + to refer to yourself in plural. + endmsg + race * + level 5 + end + Object tooth_decay + name tooth decay + type 158 + other_arch tooth + invisible 1 + attacktype 1 + wc 1 + magic 1 + Cha -1 + maxhp 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 0 + last_eat 0 + exp 100 + msg + A tooth wiggles loose and falls to the ground. You should + brush more. Have I mentioned that your breath is disgusting, too? + endmsg + race * + level 5 + end + Object typhoid + name typhoid + type 158 + attacktype 1048576 + invisible 1 + wc 5 + magic 1 + Str -3 + Con -4 + Dex -3 + maxhp 5 + dam -7 + maxgrace 20 + food -1 + speed 0.05 + last_sp 30 + maxsp 0 + ac 0 + last_eat 0 + exp 1000 + hp 1 + sp 1 + msg + You feel feverish. Your muscles spasm oddly.... Breathing is difficult. + endmsg + race * + level 12 + end + Object warts + name warts + type 158 + invisible 1 + attacktype 1 + wc 1 + magic 1 + Cha -1 + maxhp 1 + maxgrace -1 + food -1 + speed 0.005 + last_sp 0 + maxsp 0 + ac 0 + last_eat 0 + exp 100 + msg + You have warts. They are ugly and annoying. + endmsg + race * + level 5 + end Object door_0 name door randomitems door Only in crossfire-0.94.0/lib: archetypes.old diff -rcw crossfire-0.94.0.old/lib/crossfire.bdf crossfire-0.94.0/lib/crossfire.bdf *** crossfire-0.94.0.old/lib/crossfire.bdf Sat Feb 7 21:26:22 1998 --- crossfire-0.94.0/lib/crossfire.bdf Sun Mar 8 16:05:15 1998 *************** *** 1,5 **** STARTFONT 2.1 ! COMMENT This font was assembled using xbmtobdf on Sun Feb 1 20:50:30 1998 FONT crossfire SIZE 24 75 75 FONTBOUNDINGBOX 0 0 0 0 --- 1,5 ---- STARTFONT 2.1 ! COMMENT This font was assembled using xbmtobdf on Sun Mar 8 16:05:13 1998 FONT crossfire SIZE 24 75 75 FONTBOUNDINGBOX 0 0 0 0 diff -rcw crossfire-0.94.0.old/lib/treasures crossfire-0.94.0/lib/treasures *** crossfire-0.94.0.old/lib/treasures Sat Feb 7 21:26:22 1998 --- crossfire-0.94.0/lib/treasures Sun Mar 8 15:52:08 1998 *************** *** 289,294 **** --- 289,322 ---- chance 10 end # traps! --peterm + treasureone needle_diseases + arch warts + chance 20 + more + arch atheletes_foot + chance 5 + more + arch tooth_decay + chance 5 + more + arch tapeworms + chance 20 + more + arch egg_disease + chance 20 + more + arch diarrhea + chance 20 + more + arch incontinence + chance 20 + more + arch scurvy + chance 20 + more + arch flaming_fart + chance 20 + end treasureone traps list physical_traps chance 50 *************** *** 297,302 **** --- 325,333 ---- chance 50 end treasureone physical_traps + arch trap_diseased_needle + chance 70 + more arch trap_blades chance 33 more *************** *** 2733,2738 **** --- 2764,2771 ---- arch ability_bomb end treasure demilich + arch insanity + more arch ability_paralyze more arch ability_fear *************** *** 3118,3127 **** --- 3151,3164 ---- treasure spectre arch ectoplasm more + arch arthritis + more list lich_old end treasure lich arch lich_dust + more + arch leprosy more list lich_old end diff -rcw crossfire-0.94.0.old/server/Imakefile crossfire-0.94.0/server/Imakefile *** crossfire-0.94.0.old/server/Imakefile Sat Feb 7 21:26:18 1998 --- crossfire-0.94.0/server/Imakefile Thu Mar 5 18:56:35 1998 *************** *** 86,92 **** swamp.o\ swap.o\ time.o\ ! xio.o SRCS = $(OBJS:.o=.c) --- 86,93 ---- swamp.o\ swap.o\ time.o\ ! xio.o\ ! disease.o SRCS = $(OBJS:.o=.c) diff -rcw crossfire-0.94.0.old/server/attack.c crossfire-0.94.0/server/attack.c *** crossfire-0.94.0.old/server/attack.c Sat Feb 7 21:26:18 1998 --- crossfire-0.94.0/server/attack.c Fri Mar 6 13:12:35 1998 *************** *** 499,505 **** } } ! /* This returns the amount of damage hitter does to op with the appropriate` * attacktype. Only 1 attacktype should be set at a time. This doesn't * damage the player, but returns how much it should take. However, it will * do other effects (paralyzation, slow, etc.) --- 499,505 ---- } } ! /* This returns the amount of damage hitter does to op with the appropriate * attacktype. Only 1 attacktype should be set at a time. This doesn't * damage the player, but returns how much it should take. However, it will * do other effects (paralyzation, slow, etc.) *************** *** 544,549 **** --- 544,551 ---- if (attacktype & AT_PHYSICAL) { if (op->armour) dam=((100-op->armour)*dam/100); + /* here also check for diseases */ + check_physically_infect(op,hitter); /* Don't need to do anything for magic, fire, electricity, cold */ } else if (attacktype & (AT_CONFUSION|AT_POISON|AT_SLOW|AT_PARALYZE|AT_FEAR|AT_CANCELLATION| Only in crossfire-0.94.0/server: disease.c diff -rcw crossfire-0.94.0.old/server/ericserver.c crossfire-0.94.0/server/ericserver.c *** crossfire-0.94.0.old/server/ericserver.c Sat Feb 7 21:26:18 1998 --- crossfire-0.94.0/server/ericserver.c Tue Mar 3 10:53:57 1998 *************** *** 901,907 **** long cid; fd_set tmp_read, tmp_exceptions; struct sockaddr_in addr; ! intt addrlen=sizeof(struct sockaddr); /* Start at connection 1, being that 0 is the what listens on the port. */ for(i=1;istats.exp * -0.20)); if(op->stats.food < 0) op->stats.food = 500; diff -rcw crossfire-0.94.0.old/server/rune.c crossfire-0.94.0/server/rune.c *** crossfire-0.94.0.old/server/rune.c Sat Feb 7 21:26:19 1998 --- crossfire-0.94.0/server/rune.c Sun Mar 8 15:04:26 1998 *************** *** 189,196 **** void rune_attack(object *op,object *victim) { ! if(victim) hit_player(victim,op->stats.dam,op,op->attacktype); else hit_map(op,0,op->attacktype); } /* This function generalizes attacks by runes/traps. This ought to make --- 189,207 ---- void rune_attack(object *op,object *victim) { ! if(victim) { ! hit_player(victim,op->stats.dam,op,op->attacktype); ! /* if there's a disease in the needle, put it in the player */ ! if(op->randomitems!=NULL) create_treasure(op->randomitems,op,GT_INVENTORY, ! victim->map->difficulty,0); ! if(op->inv) { ! object *disease=op->inv; ! remove_ob(op->inv); ! insert_ob_in_ob(disease,victim); ! } ! } else hit_map(op,0,op->attacktype); + } /* This function generalizes attacks by runes/traps. This ought to make diff -rcw crossfire-0.94.0.old/server/spell_effect.c crossfire-0.94.0/server/spell_effect.c *** crossfire-0.94.0.old/server/spell_effect.c Sat Feb 7 21:26:19 1998 --- crossfire-0.94.0/server/spell_effect.c Sun Mar 8 13:33:26 1998 *************** *** 899,904 **** --- 899,908 ---- if(tmp==NULL) return 0; switch(spell_type) { + case SP_CURE_DISEASE: + heal = 0; + cure_disease(tmp,op); + break; case SP_MINOR_HEAL: heal=(RANDOM()%7)+1; new_draw_info(NDI_UNIQUE, 0,tmp, "Your wounds start to close."); *************** *** 943,948 **** --- 947,953 ---- case SP_RESTORATION: /* does cure poison, cure madness, heal,and removes depletion, food=999. */ cast_heal(op,dir,SP_CURE_POISON); cast_heal(op,dir,SP_CURE_CONFUSION); + cast_heal(op,dir,SP_CURE_DISEASE); tmp->stats.food=999; #if 0 /* Leave removing depletion to the restore potion. */ *************** *** 960,965 **** --- 965,971 ---- as a side effect. */ return 1; } + reduce_symptoms(tmp,heal); if (tmp->stats.hp==tmp->stats.maxhp) return 0; tmp->stats.hp+=heal; *************** *** 2955,2957 **** --- 2961,3055 ---- return 1; } + + /* cast_cause_disease: this spell looks along from the + player and infects someone. */ + + int cast_cause_disease(object *op, object *caster, int dir, archetype *disease_arch, int type) { + int x,y,i; + object *walk; + + x = op->x; y = op->y; + + + /* search in a line for a victim */ + for(i=0;i<5;i++) { + x += freearr_x[dir]; y+= freearr_y[dir]; + if(out_of_map(op->map,x,y)) continue; + /* search this square for a victim */ + for(walk=get_map_ob(op->map,x,y);walk;walk=walk->above) + if(QUERY_FLAG(walk,FLAG_MONSTER) + || !(walk->type==PLAYER)) { /* found a victim */ + + object *disease = arch_to_object(disease_arch); + set_owner(disease,op); + disease->stats.exp = 0; + disease->level = op->level; + + /*do level adjustments */ + if(disease->stats.wc) + disease->stats.wc += SP_level_strength_adjust(op,caster,type)/2; + + if(disease->magic) + disease->magic += SP_level_strength_adjust(op,caster,type)/4; + + if(disease->stats.maxhp>0) + disease->stats.maxhp += SP_level_strength_adjust(op,caster,type); + + if(disease->stats.maxgrace>0) + disease->stats.maxgrace += SP_level_strength_adjust(op,caster,type); + + if(disease->stats.dam) { + if(disease->stats.dam > 0) + disease->stats.dam += SP_level_dam_adjust(op,caster,type); + else disease->stats.dam -= SP_level_dam_adjust(op,caster,type); + } + + if(disease->last_sp) { + disease->last_sp -= 2*SP_level_dam_adjust(op,caster,type); + if(disease->last_sp <1) disease->last_sp = 1; + } + + if(disease->stats.maxsp) { + if(disease->stats.maxsp > 0) + disease->stats.maxsp += SP_level_dam_adjust(op,caster,type); + else disease->stats.maxsp -= SP_level_dam_adjust(op,caster,type); + } + + if(disease->stats.ac) + disease->stats.ac += SP_level_dam_adjust(op,caster,type); + + if(disease->last_eat) + disease->last_eat -= SP_level_dam_adjust(op,caster,type); + + if(disease->stats.hp) + disease->stats.hp -= SP_level_dam_adjust(op,caster,type); + + if(disease->stats.sp) + disease->stats.sp -= SP_level_dam_adjust(op,caster,type); + + + if(infect_object(walk,disease)) { + char buf[128]; + object *flash; /* visual effect for inflicting disease */ + sprintf(buf,"You inflict %s on %s!",disease->name,walk->name); + free_object(disease); /* don't need this one anymore */ + new_draw_info(NDI_UNIQUE,0,op,buf); + flash=get_archetype("detect_magic"); + flash->x = x; + flash->y = y; + flash->map = walk->map; + insert_ob_in_map(flash,walk->map); + return 1; + } + free_object(disease); + } + } + new_draw_info(NDI_UNIQUE,0,op,"No one caught anything!"); + return 0; + } + + + + + diff -rcw crossfire-0.94.0.old/server/spell_util.c crossfire-0.94.0/server/spell_util.c *** crossfire-0.94.0.old/server/spell_util.c Sat Feb 7 21:26:19 1998 --- crossfire-0.94.0/server/spell_util.c Fri Mar 6 20:06:51 1998 *************** *** 520,525 **** --- 520,526 ---- case SP_CURE_POISON: case SP_CURE_CONFUSION: case SP_CURE_BLINDNESS: + case SP_CURE_DISEASE: success = cast_heal(op,dir,type); break; case SP_REGENERATE_SPELLPOINTS: *************** *** 740,745 **** --- 741,756 ---- success = cast_create_missile(op,caster,dir,stringarg); break; + case SP_CAUSE_EBOLA: + case SP_CAUSE_FLU: + case SP_CAUSE_PLAGUE: + case SP_CAUSE_LEPROSY: + case SP_CAUSE_SMALLPOX: + case SP_CAUSE_PNEUMONIC_PLAGUE: + case SP_CAUSE_ANTHRAX: + case SP_CAUSE_TYPHOID: + success = cast_cause_disease(op,caster,dir,spellarch[type],type); + break; } play_sound_map(op->map, op->x, op->y, SOUND_CAST_SPELL_0 + type); #ifdef CASTING_TIME diff -rcw crossfire-0.94.0.old/server/time.c crossfire-0.94.0/server/time.c *** crossfire-0.94.0.old/server/time.c Sat Feb 7 21:26:19 1998 --- crossfire-0.94.0/server/time.c Thu Mar 5 17:36:35 1998 *************** *** 729,734 **** --- 729,740 ---- case POISONING: poison_more(op); return 0; + case DISEASE: + move_disease(op); + return 0; + case SYMPTOM: + move_symptom(op); + return 0; case WORD_OF_RECALL: execute_wor(op); return 0;