mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-31 05:30:48 +00:00
(Hopefully) cover all cases for resetting rock usability
This commit is contained in:
parent
9431497f7d
commit
e57b0f7126
2 changed files with 12 additions and 11 deletions
|
@ -975,6 +975,7 @@ static boolean PIT_CheckThing(mobj_t *thing)
|
||||||
P_SetPlayerMobjState(tmthing, S_PLAY_WALK);
|
P_SetPlayerMobjState(tmthing, S_PLAY_WALK);
|
||||||
tmthing->player->powers[pw_carry] = CR_ROLLOUT;
|
tmthing->player->powers[pw_carry] = CR_ROLLOUT;
|
||||||
P_SetTarget(&tmthing->tracer, thing);
|
P_SetTarget(&tmthing->tracer, thing);
|
||||||
|
P_SetObjectMomZ(thing, tmthing->momz, true);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
22
src/p_user.c
22
src/p_user.c
|
@ -948,17 +948,6 @@ void P_DoPlayerPain(player_t *player, mobj_t *source, mobj_t *inflictor)
|
||||||
if (player->powers[pw_carry] == CR_ROPEHANG)
|
if (player->powers[pw_carry] == CR_ROPEHANG)
|
||||||
P_SetTarget(&player->mo->tracer, NULL);
|
P_SetTarget(&player->mo->tracer, NULL);
|
||||||
|
|
||||||
if (player->powers[pw_carry] == CR_ROLLOUT)
|
|
||||||
{
|
|
||||||
if (player->mo->tracer && !P_MobjWasRemoved(player->mo->tracer))
|
|
||||||
{
|
|
||||||
player->mo->tracer->flags |= MF_PUSHABLE;
|
|
||||||
P_SetTarget(&player->mo->tracer->target, NULL);
|
|
||||||
}
|
|
||||||
P_SetTarget(&player->mo->tracer, NULL);
|
|
||||||
player->powers[pw_carry] = CR_NONE;
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
{
|
||||||
angle_t ang;
|
angle_t ang;
|
||||||
fixed_t fallbackspeed;
|
fixed_t fallbackspeed;
|
||||||
|
@ -1042,6 +1031,17 @@ void P_ResetPlayer(player_t *player)
|
||||||
{
|
{
|
||||||
player->pflags &= ~(PF_SPINNING|PF_STARTDASH|PF_STARTJUMP|PF_JUMPED|PF_NOJUMPDAMAGE|PF_GLIDING|PF_THOKKED|PF_CANCARRY|PF_SHIELDABILITY|PF_BOUNCING);
|
player->pflags &= ~(PF_SPINNING|PF_STARTDASH|PF_STARTJUMP|PF_JUMPED|PF_NOJUMPDAMAGE|PF_GLIDING|PF_THOKKED|PF_CANCARRY|PF_SHIELDABILITY|PF_BOUNCING);
|
||||||
|
|
||||||
|
if (player->powers[pw_carry] == CR_ROLLOUT)
|
||||||
|
{
|
||||||
|
if (player->mo->tracer && !P_MobjWasRemoved(player->mo->tracer))
|
||||||
|
{
|
||||||
|
player->mo->tracer->flags |= MF_PUSHABLE;
|
||||||
|
P_SetTarget(&player->mo->tracer->target, NULL);
|
||||||
|
}
|
||||||
|
P_SetTarget(&player->mo->tracer, NULL);
|
||||||
|
player->powers[pw_carry] = CR_NONE;
|
||||||
|
}
|
||||||
|
|
||||||
if (!(player->powers[pw_carry] == CR_NIGHTSMODE || player->powers[pw_carry] == CR_NIGHTSFALL || player->powers[pw_carry] == CR_BRAKGOOP || player->powers[pw_carry] == CR_MINECART))
|
if (!(player->powers[pw_carry] == CR_NIGHTSMODE || player->powers[pw_carry] == CR_NIGHTSFALL || player->powers[pw_carry] == CR_BRAKGOOP || player->powers[pw_carry] == CR_MINECART))
|
||||||
player->powers[pw_carry] = CR_NONE;
|
player->powers[pw_carry] = CR_NONE;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue