mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Also prevent fastfall on ebrake ground-to-air
This commit is contained in:
parent
1871cad1d9
commit
c7bae4a06b
2 changed files with 5 additions and 4 deletions
|
|
@ -108,7 +108,7 @@ typedef enum
|
|||
PF_SHRINKACTIVE = 1<<29, // "Shrink me" cheat is in effect. (Can't be disabled mid-race)
|
||||
|
||||
PF_VOID = 1<<30, // Removed from reality! When leaving hitlag, reenable visibility+collision and kill speed.
|
||||
PF_FASTFALLBOUNCED = 1<<31, // Just bounced from a fastfall. Ignore fastfall attempts until input's lifted.
|
||||
PF_NOFASTFALL = 1<<31, // Has already done ebrake/fastfall behavior for this input. Fastfalling needs a new input to prevent unwanted bounces on unexpected airtime.
|
||||
|
||||
// up to 1<<31 is free
|
||||
} pflags_t;
|
||||
|
|
|
|||
|
|
@ -10095,7 +10095,7 @@ static void K_KartSpindash(player_t *player)
|
|||
if (K_PlayerEBrake(player) == false)
|
||||
{
|
||||
player->spindash = 0;
|
||||
player->pflags &= ~PF_FASTFALLBOUNCED;
|
||||
player->pflags &= ~PF_NOFASTFALL;
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -10107,7 +10107,7 @@ static void K_KartSpindash(player_t *player)
|
|||
}
|
||||
else if (onGround == false)
|
||||
{
|
||||
if (player->pflags & PF_FASTFALLBOUNCED)
|
||||
if (player->pflags & PF_NOFASTFALL)
|
||||
return;
|
||||
// Update fastfall.
|
||||
player->fastfall = player->mo->momz;
|
||||
|
|
@ -10127,6 +10127,8 @@ static void K_KartSpindash(player_t *player)
|
|||
return;
|
||||
}
|
||||
|
||||
player->pflags |= PF_NOFASTFALL;
|
||||
|
||||
if (player->speed == 0 && player->steering != 0 && leveltime % 8 == 0)
|
||||
{
|
||||
// Rubber burn turn sfx
|
||||
|
|
@ -10231,7 +10233,6 @@ boolean K_FastFallBounce(player_t *player)
|
|||
|
||||
player->fastfall = 0;
|
||||
player->fastfallBase = 0;
|
||||
player->pflags |= PF_FASTFALLBOUNCED;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue