diff --git a/src/p_map.c b/src/p_map.c index 2f17be8f3..cc9209ea8 100644 --- a/src/p_map.c +++ b/src/p_map.c @@ -2884,7 +2884,7 @@ static boolean P_ThingHeightClip(mobj_t *thing) if (thing->z != oldz) { if (thing->player) - P_PlayerHitFloor(thing->player, false); + P_PlayerHitFloor(thing->player, !onfloor); } // debug: be sure it falls to the floor diff --git a/src/p_slopes.c b/src/p_slopes.c index f89dd3c96..b06460084 100644 --- a/src/p_slopes.c +++ b/src/p_slopes.c @@ -716,9 +716,11 @@ void P_HandleSlopeLanding(mobj_t *thing, pslope_t *slope) vector3_t mom; // Ditto. if (slope->flags & SL_NOPHYSICS) { // No physics, no need to make anything complicated. - if (P_MobjFlip(thing)*(thing->momz) < 0) { // falling, land on slope - //thing->momz = -P_MobjFlip(thing); + if (P_MobjFlip(thing)*(thing->momz) < 0) // falling, land on slope + { thing->standingslope = slope; + if (!thing->player || !(thing->player->pflags & PF_BOUNCING)) + thing->momz = -P_MobjFlip(thing); } return; } @@ -732,9 +734,9 @@ void P_HandleSlopeLanding(mobj_t *thing, pslope_t *slope) if (P_MobjFlip(thing)*mom.z < 0) { // falling, land on slope thing->momx = mom.x; thing->momy = mom.y; - //thing->momz = -P_MobjFlip(thing); - thing->standingslope = slope; + if (!thing->player || !(thing->player->pflags & PF_BOUNCING)) + thing->momz = -P_MobjFlip(thing); } } diff --git a/src/p_user.c b/src/p_user.c index e27967405..a490c57f7 100644 --- a/src/p_user.c +++ b/src/p_user.c @@ -2198,7 +2198,7 @@ boolean P_PlayerHitFloor(player_t *player, boolean dorollstuff) { if ((player->charability2 == CA2_SPINDASH) && !(player->pflags & PF_THOKKED) && (player->cmd.buttons & BT_USE) && (FixedHypot(player->mo->momx, player->mo->momy) > (5*player->mo->scale))) player->pflags |= PF_SPINNING; - else + else if (!(player->pflags & PF_STARTDASH)) player->pflags &= ~PF_SPINNING; } @@ -2217,7 +2217,7 @@ boolean P_PlayerHitFloor(player_t *player, boolean dorollstuff) player->skidtime = TICRATE; player->mo->tics = -1; } - else + else if (!player->skidtime) player->pflags &= ~PF_GLIDING; } else if (player->charability2 == CA2_MELEE && player->panim == PA_ABILITY2) @@ -2268,7 +2268,7 @@ boolean P_PlayerHitFloor(player_t *player, boolean dorollstuff) } else if (player->charability2 == CA2_GUNSLINGER && player->panim == PA_ABILITY2) ; - else if (player->pflags & PF_JUMPED || player->powers[pw_tailsfly] || player->mo->state-states == S_PLAY_FLY_TIRED) + else if (player->panim != PA_IDLE && player->panim != PA_WALK && player->panim != PA_RUN && player->panim != PA_DASH) { if (player->cmomx || player->cmomy) {