mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Fix misaligned instawhip objects when under gravflip
This commit is contained in:
parent
a9408fd62d
commit
cfc8aaa068
1 changed files with 5 additions and 0 deletions
|
|
@ -64,6 +64,7 @@ void Obj_SpawnInstaWhipRecharge(player_t *player, angle_t angleOffset)
|
|||
// This was previously used to delay the visual, back when this was VFX for a cooldown
|
||||
// instead of VFX for a charge. We want to instantly bail out of that state now.
|
||||
x->tics = 1;
|
||||
x->eflags &= ~MFE_VERTICALFLIP; // Fix the visual being misaligned.
|
||||
x->renderflags |= RF_SLOPESPLAT | RF_NOSPLATBILLBOARD;
|
||||
|
||||
P_SetTarget(&recharge_target(x), player->mo);
|
||||
|
|
@ -92,6 +93,10 @@ void Obj_InstaWhipRechargeThink(mobj_t *x)
|
|||
void Obj_SpawnInstaWhipReject(player_t *player)
|
||||
{
|
||||
mobj_t *x = P_SpawnMobjFromMobj(player->mo, 0, 0, 0, MT_INSTAWHIP_REJECT);
|
||||
x->eflags &= ~MFE_VERTICALFLIP;
|
||||
// Fixes an issue with gravflip misplacing the object for the first tic.
|
||||
if (player->mo->eflags & MFE_VERTICALFLIP)
|
||||
P_SetOrigin(x, player->mo->x, player->mo->y, player->mo->z);
|
||||
|
||||
P_SetTarget(&recharge_target(x), player->mo);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue