Merge branch 'anim-fix' into skins-fix

This commit is contained in:
TehRealSalt 2019-05-02 02:51:17 -04:00
commit e314aeb1ab
2 changed files with 3 additions and 3 deletions

View file

@ -5241,7 +5241,7 @@ void G_ReadMetalTic(mobj_t *metal)
speed = FixedDiv(P_AproxDistance(oldmetal.momx, oldmetal.momy), metal->scale)>>FRACBITS;
// Use speed to decide an appropriate state
if (speed > 28) // default skin runspeed
if (speed > 20) // default skin runspeed
statetype = 2;
else if (speed > 1) // stopspeed
statetype = 1;

View file

@ -1634,7 +1634,7 @@ void K_KartMoveAnimation(player_t *player)
P_SetPlayerMobjState(player->mo, S_KART_DRIFT1_R);
}
// Run frames - S_KART_RUN1 S_KART_RUN1_L S_KART_RUN1_R
else if (player->speed > FixedMul(player->runspeed, player->mo->scale))
else if (player->speed > (20*player->mo->scale))
{
if (cmd->driftturn < 0 && !(player->mo->state >= &states[S_KART_RUN1_R] && player->mo->state <= &states[S_KART_RUN2_R]))
P_SetPlayerMobjState(player->mo, S_KART_RUN1_R);
@ -1644,7 +1644,7 @@ void K_KartMoveAnimation(player_t *player)
P_SetPlayerMobjState(player->mo, S_KART_RUN1);
}
// Walk frames - S_KART_WALK1 S_KART_WALK1_L S_KART_WALK1_R
else if (player->speed <= FixedMul(player->runspeed, player->mo->scale))
else if (player->speed <= (20*player->mo->scale))
{
if (cmd->driftturn < 0 && !(player->mo->state >= &states[S_KART_WALK1_R] && player->mo->state <= &states[S_KART_WALK2_R]))
P_SetPlayerMobjState(player->mo, S_KART_WALK1_R);