mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-12-22 07:52:30 +00:00
Fix horn and and hitconfirm anim for fallback follower
This commit is contained in:
parent
009034e848
commit
d1ec829d5f
2 changed files with 14 additions and 6 deletions
|
|
@ -766,14 +766,18 @@ void K_FollowerHornTaunt(player_t *taunter, player_t *victim, boolean mysticmelo
|
|||
if (
|
||||
taunter == NULL
|
||||
|| victim == NULL
|
||||
|| taunter->followerskin < 0
|
||||
|| taunter->followerskin < -1
|
||||
|| taunter->followerskin >= numfollowers
|
||||
)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
const follower_t *fl = &followers[taunter->followerskin];
|
||||
follower_t *fl;
|
||||
if (taunter->followerskin == -1) /// mmm spaghetti
|
||||
fl = &followers[K_FollowerAvailable("Goddess")]; // special case for checking for fallback follower for autoring
|
||||
else
|
||||
fl = &followers[taunter->followerskin];
|
||||
|
||||
// Restrict mystic melody special status
|
||||
if (mysticmelodyspecial == true)
|
||||
|
|
|
|||
12
src/k_kart.c
12
src/k_kart.c
|
|
@ -2866,10 +2866,15 @@ void K_TryHurtSoundExchange(mobj_t *victim, mobj_t *attacker)
|
|||
attacker->player->confirmVictimDelay = TICRATE/2;
|
||||
|
||||
if (attacker->player->follower != NULL
|
||||
&& attacker->player->followerskin >= 0
|
||||
&& attacker->player->followerskin >= -1
|
||||
&& attacker->player->followerskin < numfollowers)
|
||||
{
|
||||
const follower_t *fl = &followers[attacker->player->followerskin];
|
||||
follower_t *fl;
|
||||
if (attacker->player->followerskin == -1) /// mmm spaghetti
|
||||
fl = &followers[K_FollowerAvailable("Goddess")]; // special case for checking for fallback follower for autoring
|
||||
else
|
||||
fl = &followers[attacker->player->followerskin];
|
||||
|
||||
attacker->player->follower->movecount = fl->hitconfirmtime; // movecount is used to play the hitconfirm animation for followers.
|
||||
}
|
||||
}
|
||||
|
|
@ -12612,8 +12617,7 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
|||
if (
|
||||
player->pflags & PF_AUTORING
|
||||
&& leveltime > starttime
|
||||
&& !(cmd->buttons & BT_BRAKE)
|
||||
&& K_GetKartButtons(player)
|
||||
&& K_GetForwardMove(player)
|
||||
&& P_IsObjectOnGround(player->mo)
|
||||
)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue