half-physical-damage from gas spore explosion should only affect you

- <Someone> noticed the fix for applying half physical damage to gas spore
explosions affected damage to all monsters, not just you
This commit is contained in:
cohrs
2002-03-27 02:31:21 +00:00
parent ea18afa4dd
commit 6cdf92851e
3 changed files with 4 additions and 2 deletions

View File

@@ -21,6 +21,7 @@ fix iron ball cases that could put the chain in solid rock
discovering a mimic on a closed door location should not unblock the location
don't drop corpse when a monster kills another monster on an inaccessible
location (i.e. behave like xkilled behaves)
half-physical-damage from gas spore explosion should only affect you
Platform- and/or Interface-Specific Fixes

View File

@@ -314,7 +314,8 @@ int expltype;
if (Invulnerable) {
damu = 0;
You("are unharmed!");
}
} else if (Half_physical_damage && adtyp == AD_PHYS)
damu = (damu+1) / 2;
if (adtyp == AD_FIRE) (void) burnarmor(&youmonst);
destroy_item(SCROLL_CLASS, (int) adtyp);
destroy_item(SPBOOK_CLASS, (int) adtyp);

View File

@@ -1419,13 +1419,13 @@ boolean was_swallowed; /* digestion */
else if(mdat->mattk[i].damd)
tmp = d((int)mdat->mlevel+1, (int)mdat->mattk[i].damd);
else tmp = 0;
if (Half_physical_damage) tmp = (tmp+1) / 2;
if (was_swallowed && magr) {
if (magr == &youmonst) {
There("is an explosion in your %s!",
body_part(STOMACH));
Sprintf(killer_buf, "%s explosion",
s_suffix(mdat->mname));
if (Half_physical_damage) tmp = (tmp+1) / 2;
losehp(tmp, killer_buf, KILLED_BY_AN);
} else {
if (flags.soundok) You_hear("an explosion.");