From: fgsfds Date: Mon, 12 Aug 2019 00:21:16 +0000 (+0300) Subject: Game: Don't catch fire underwater in any circumstances X-Git-Url: http://deadsoftware.ru/gitweb?a=commitdiff_plain;h=bba5c4a7b77b3be25c3b872b21c96e28a57cee32;p=d2df-sdl.git Game: Don't catch fire underwater in any circumstances --- diff --git a/src/game/g_monsters.pas b/src/game/g_monsters.pas index a19fa4b..a70364b 100644 --- a/src/game/g_monsters.pas +++ b/src/game/g_monsters.pas @@ -4663,6 +4663,8 @@ begin if FMonsterType in [MONSTER_SOUL, MONSTER_VILE] then exit; // àð÷è íå ãîðÿò, ÷åðåïà óæå ãîðÿò if Timeout <= 0 then exit; + if g_Obj_CollidePanel(@FObj, 0, 0, PANEL_WATER or PANEL_ACID1 or PANEL_ACID2) then + exit; // íå ïîäãîðàåì â âîäå íà âñÿêèé ñëó÷àé if FFireTime <= 0 then g_Sound_PlayExAt('SOUND_IGNITE', FObj.X, FObj.Y); FFireTime := Timeout; diff --git a/src/game/g_player.pas b/src/game/g_player.pas index b99c03d..d4b6bdd 100644 --- a/src/game/g_player.pas +++ b/src/game/g_player.pas @@ -3197,6 +3197,8 @@ begin exit; if (FMegaRulez[MR_SUIT] > gTime) or (FMegaRulez[MR_INVUL] > gTime) then exit; // Íå çàãîðàåìñÿ êîãäà åñòü çàùèòà + if g_Obj_CollidePanel(@FObj, 0, 0, PANEL_WATER or PANEL_ACID1 or PANEL_ACID2) then + exit; // Íå ïîäãîðàåì â âîäå íà âñÿêèé ñëó÷àé if FFireTime <= 0 then g_Sound_PlayExAt('SOUND_IGNITE', FObj.X, FObj.Y); FFireTime := Timeout;