mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-02-24 14:31:02 +00:00
K_SpawnOvertimeLaser: only move laser height with player if player goes above the top of the lasers
This commit is contained in:
parent
cd87a8c59d
commit
8ef03f29e5
1 changed files with 4 additions and 0 deletions
|
|
@ -570,6 +570,8 @@ void K_RunPaperItemSpawners(void)
|
|||
|
||||
static void K_SpawnOvertimeLaser(fixed_t x, fixed_t y, fixed_t scale)
|
||||
{
|
||||
const fixed_t heightPadding = 346 * scale;
|
||||
|
||||
UINT8 i, j;
|
||||
|
||||
for (i = 0; i <= r_splitscreen; i++)
|
||||
|
|
@ -586,10 +588,12 @@ static void K_SpawnOvertimeLaser(fixed_t x, fixed_t y, fixed_t scale)
|
|||
if (player->mo->eflags & MFE_VERTICALFLIP)
|
||||
{
|
||||
zpos = player->mo->z + player->mo->height;
|
||||
zpos = min(zpos + heightPadding, player->mo->ceilingz);
|
||||
}
|
||||
else
|
||||
{
|
||||
zpos = player->mo->z;
|
||||
zpos = max(zpos - heightPadding, player->mo->floorz);
|
||||
}
|
||||
|
||||
flip = P_MobjFlip(player->mo);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue