Fix fault exit conditions triggering before hitlag ended

This commit is contained in:
AJ Martinez 2024-01-19 16:40:22 -07:00
parent fb20f7b036
commit 9cbeca9595
2 changed files with 4 additions and 3 deletions

View file

@ -8706,7 +8706,7 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
player->nextringaward = 99; // Next time we need to award superring, spawn the first one instantly.
}
if (player->pflags & PF_VOID) // Returning from FAULT VOID
if (player->pflags & PF_VOID && player->mo->hitlag == 0) // Returning from FAULT VOID
{
player->pflags &= ~PF_VOID;
player->mo->renderflags &= ~RF_DONTDRAW;

View file

@ -1920,8 +1920,9 @@ static void K_HandleLapIncrement(player_t *player)
player->mo->renderflags |= RF_DONTDRAW;
player->mo->flags |= MF_NOCLIPTHING;
player->nocontrol = UINT16_MAX;
player->hyudorotimer = UINT16_MAX;
player->speed = 0;
player->mo->momx = 0;
player->mo->momy = 0;
player->mo->momz = 0;
K_StripItems(player);
player->faultflash = TICRATE/3;
ClearFakePlayerSkin(player);