mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 12:31:54 +00:00
Use damage stumble for stumble sectors / terrain again (allows DI)
This commit is contained in:
parent
7b10e4e2bd
commit
140f9846aa
2 changed files with 8 additions and 2 deletions
|
|
@ -505,7 +505,11 @@ void K_ProcessTerrainEffect(mobj_t *mo)
|
||||||
if (dmg & DMG_STUMBLE && !G_CompatLevel(0x0010))
|
if (dmg & DMG_STUMBLE && !G_CompatLevel(0x0010))
|
||||||
{
|
{
|
||||||
if (player->mo->hitlag == 0 && (player->mo->momz >= 0) == (P_MobjFlip(player->mo) >= 0))
|
if (player->mo->hitlag == 0 && (player->mo->momz >= 0) == (P_MobjFlip(player->mo) >= 0))
|
||||||
K_StumblePlayer(player);
|
{
|
||||||
|
player->pflags2 |= PF2_ALWAYSDAMAGED;
|
||||||
|
P_DamageMobj(mo, NULL, NULL, 1, dmg);
|
||||||
|
player->pflags2 &= ~PF2_ALWAYSDAMAGED;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -5432,7 +5432,9 @@ static void P_EvaluateDamageType(player_t *player, sector_t *sector, boolean isT
|
||||||
{
|
{
|
||||||
if (isTouching && player->mo->hitlag == 0 && (player->mo->momz >= 0) == (P_MobjFlip(player->mo) >= 0))
|
if (isTouching && player->mo->hitlag == 0 && (player->mo->momz >= 0) == (P_MobjFlip(player->mo) >= 0))
|
||||||
{
|
{
|
||||||
K_StumblePlayer(player);
|
player->pflags2 |= PF2_ALWAYSDAMAGED;
|
||||||
|
P_DamageMobj(player->mo, NULL, NULL, 1, DMG_STUMBLE);
|
||||||
|
player->pflags2 &= ~PF2_ALWAYSDAMAGED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue