mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-25 05:41:42 +00:00
Merge branch 'fix-cr_player-positioning' into 'next'
Fix CR_PLAYER interpolation in reverse gravity See merge request STJr/SRB2!2423
This commit is contained in:
commit
63fd343a97
1 changed files with 6 additions and 4 deletions
10
src/p_user.c
10
src/p_user.c
|
@ -8829,6 +8829,8 @@ void P_MovePlayer(player_t *player)
|
||||||
player->mo->height = P_GetPlayerSpinHeight(player);
|
player->mo->height = P_GetPlayerSpinHeight(player);
|
||||||
atspinheight = true;
|
atspinheight = true;
|
||||||
}
|
}
|
||||||
|
else if (player->powers[pw_carry] == CR_PLAYER || player->powers[pw_carry] == CR_PTERABYTE) // You're slightly shorter while being carried
|
||||||
|
player->mo->height = FixedDiv(P_GetPlayerHeight(player), FixedDiv(14*FRACUNIT,10*FRACUNIT));
|
||||||
else
|
else
|
||||||
player->mo->height = P_GetPlayerHeight(player);
|
player->mo->height = P_GetPlayerHeight(player);
|
||||||
|
|
||||||
|
@ -12850,9 +12852,9 @@ void P_PlayerAfterThink(player_t *player)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (tails->player)
|
if (tails->player)
|
||||||
P_TryMove(player->mo, tails->x + P_ReturnThrustX(tails, tails->player->drawangle, 4*FRACUNIT), tails->y + P_ReturnThrustY(tails, tails->player->drawangle, 4*FRACUNIT), true);
|
P_TryMove(player->mo, tails->x + P_ReturnThrustX(tails, tails->player->drawangle, 4*tails->scale), tails->y + P_ReturnThrustY(tails, tails->player->drawangle, 4*tails->scale), true);
|
||||||
else
|
else
|
||||||
P_TryMove(player->mo, tails->x + P_ReturnThrustX(tails, tails->angle, 4*FRACUNIT), tails->y + P_ReturnThrustY(tails, tails->angle, 4*FRACUNIT), true);
|
P_TryMove(player->mo, tails->x + P_ReturnThrustX(tails, tails->angle, 4*tails->scale), tails->y + P_ReturnThrustY(tails, tails->angle, 4*tails->scale), true);
|
||||||
player->mo->momx = tails->momx;
|
player->mo->momx = tails->momx;
|
||||||
player->mo->momy = tails->momy;
|
player->mo->momy = tails->momy;
|
||||||
player->mo->momz = tails->momz;
|
player->mo->momz = tails->momz;
|
||||||
|
@ -12866,7 +12868,7 @@ void P_PlayerAfterThink(player_t *player)
|
||||||
P_SetPlayerAngle(player, player->mo->angle);
|
P_SetPlayerAngle(player, player->mo->angle);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (P_AproxDistance(player->mo->x - tails->x, player->mo->y - tails->y) > player->mo->radius)
|
if (P_AproxDistance(player->mo->x - tails->x, player->mo->y - tails->y) > tails->radius)
|
||||||
player->powers[pw_carry] = CR_NONE;
|
player->powers[pw_carry] = CR_NONE;
|
||||||
|
|
||||||
if (player->powers[pw_carry] == CR_PLAYER)
|
if (player->powers[pw_carry] == CR_PLAYER)
|
||||||
|
@ -13087,7 +13089,7 @@ void P_PlayerAfterThink(player_t *player)
|
||||||
player->mo->momy = ptera->momy;
|
player->mo->momy = ptera->momy;
|
||||||
player->mo->momz = ptera->momz;
|
player->mo->momz = ptera->momz;
|
||||||
|
|
||||||
if (P_AproxDistance(player->mo->x - ptera->x - ptera->watertop, player->mo->y - ptera->y - ptera->waterbottom) > player->mo->radius)
|
if (P_AproxDistance(player->mo->x - ptera->x - ptera->watertop, player->mo->y - ptera->y - ptera->waterbottom) > ptera->radius)
|
||||||
goto dropoff;
|
goto dropoff;
|
||||||
|
|
||||||
ptera->watertop >>= 1;
|
ptera->watertop >>= 1;
|
||||||
|
|
Loading…
Reference in a new issue