mirror of
https://git.do.srb2.org/KartKrew/Kart-Public.git
synced 2024-12-27 04:41:23 +00:00
Merge branch 'anim-fix' into 'v1'
Fix wheel animations See merge request KartKrew/Kart!144
This commit is contained in:
commit
071b335d57
2 changed files with 4 additions and 4 deletions
|
@ -5283,7 +5283,7 @@ void G_ReadMetalTic(mobj_t *metal)
|
||||||
speed = FixedDiv(P_AproxDistance(oldmetal.momx, oldmetal.momy), metal->scale)>>FRACBITS;
|
speed = FixedDiv(P_AproxDistance(oldmetal.momx, oldmetal.momy), metal->scale)>>FRACBITS;
|
||||||
|
|
||||||
// Use speed to decide an appropriate state
|
// Use speed to decide an appropriate state
|
||||||
if (speed > 28) // default skin runspeed
|
if (speed > 20) // default skin runspeed
|
||||||
statetype = 2;
|
statetype = 2;
|
||||||
else if (speed > 1) // stopspeed
|
else if (speed > 1) // stopspeed
|
||||||
statetype = 1;
|
statetype = 1;
|
||||||
|
|
|
@ -1668,7 +1668,7 @@ void K_KartMoveAnimation(player_t *player)
|
||||||
P_SetPlayerMobjState(player->mo, S_KART_DRIFT1_R);
|
P_SetPlayerMobjState(player->mo, S_KART_DRIFT1_R);
|
||||||
}
|
}
|
||||||
// Run frames - S_KART_RUN1 S_KART_RUN1_L S_KART_RUN1_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]))
|
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);
|
P_SetPlayerMobjState(player->mo, S_KART_RUN1_R);
|
||||||
|
@ -1678,7 +1678,7 @@ void K_KartMoveAnimation(player_t *player)
|
||||||
P_SetPlayerMobjState(player->mo, S_KART_RUN1);
|
P_SetPlayerMobjState(player->mo, S_KART_RUN1);
|
||||||
}
|
}
|
||||||
// Walk frames - S_KART_WALK1 S_KART_WALK1_L S_KART_WALK1_R
|
// 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]))
|
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);
|
P_SetPlayerMobjState(player->mo, S_KART_WALK1_R);
|
||||||
|
@ -8325,7 +8325,7 @@ static void K_drawKartFirstPerson(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
if (stplyr->speed < FixedMul(stplyr->runspeed, stplyr->mo->scale) && (leveltime & 1) && !splitscreen)
|
if (stplyr->speed < (20*stplyr->mo->scale) && (leveltime & 1) && !splitscreen)
|
||||||
y++;
|
y++;
|
||||||
// the following isn't EXPLICITLY right, it just gets the result we want, but i'm too lazy to look up the right way to do it
|
// the following isn't EXPLICITLY right, it just gets the result we want, but i'm too lazy to look up the right way to do it
|
||||||
if (stplyr->mo->flags2 & MF2_SHADOW)
|
if (stplyr->mo->flags2 & MF2_SHADOW)
|
||||||
|
|
Loading…
Reference in a new issue