mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-18 07:22:28 +00:00
Slow climbing down underwater
This commit is contained in:
parent
b93c2467e7
commit
46ba988541
1 changed files with 12 additions and 2 deletions
14
src/p_user.c
14
src/p_user.c
|
@ -5979,7 +5979,12 @@ static void P_3dMovement(player_t *player)
|
||||||
if (player->climbing)
|
if (player->climbing)
|
||||||
{
|
{
|
||||||
if (cmd->forwardmove)
|
if (cmd->forwardmove)
|
||||||
P_SetObjectMomZ(player->mo, FixedDiv(cmd->forwardmove*FRACUNIT, 15*FRACUNIT>>1), false);
|
{
|
||||||
|
if (player->mo->eflags & MFE_UNDERWATER)
|
||||||
|
P_SetObjectMomZ(player->mo, FixedDiv(cmd->forwardmove*FRACUNIT, 10*FRACUNIT), false);
|
||||||
|
else
|
||||||
|
P_SetObjectMomZ(player->mo, FixedDiv(cmd->forwardmove*FRACUNIT, 15*FRACUNIT>>1), false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (!analogmove
|
else if (!analogmove
|
||||||
&& cmd->forwardmove != 0 && !(player->pflags & PF_GLIDING || player->exiting
|
&& cmd->forwardmove != 0 && !(player->pflags & PF_GLIDING || player->exiting
|
||||||
|
@ -6013,7 +6018,12 @@ static void P_3dMovement(player_t *player)
|
||||||
}
|
}
|
||||||
// Sideways movement
|
// Sideways movement
|
||||||
if (player->climbing)
|
if (player->climbing)
|
||||||
P_InstaThrust(player->mo, player->mo->angle-ANGLE_90, FixedDiv(cmd->sidemove*player->mo->scale, 15*FRACUNIT>>1));
|
{
|
||||||
|
if (player->mo->eflags & MFE_UNDERWATER)
|
||||||
|
P_InstaThrust(player->mo, player->mo->angle-ANGLE_90, FixedDiv(cmd->sidemove*player->mo->scale, 10*FRACUNIT));
|
||||||
|
else
|
||||||
|
P_InstaThrust(player->mo, player->mo->angle-ANGLE_90, FixedDiv(cmd->sidemove*player->mo->scale, 15*FRACUNIT>>1));
|
||||||
|
}
|
||||||
// Analog movement control
|
// Analog movement control
|
||||||
else if (analogmove)
|
else if (analogmove)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue