Revert change to P_SlopeLaunch

Don't call slopelaunch just from object z difference if the slope has no physics.
This commit is contained in:
Sryder 2018-11-26 23:10:24 +00:00
parent 683ebec120
commit ab5dc3226b
2 changed files with 4 additions and 2 deletions

View File

@ -1938,7 +1938,9 @@ void P_XYMovement(mobj_t *mo)
FIXED_TO_FLOAT(AngleFixed(newangle)),
FIXED_TO_FLOAT(AngleFixed(oldangle-newangle))
);*/
} else if (predictedz-mo->z > abs(slopemom.z/2)) { // Now check if we were supposed to stick to this slope
// Sryder 2018-11-26: Don't launch here if it's a slope without physics, we stick to those like glue anyway
} else if (predictedz-mo->z > abs(slopemom.z/2)
&& !(mo->standingslope->flags & SL_NOPHYSICS)) { // Now check if we were supposed to stick to this slope
//CONS_Printf("%d-%d > %d\n", (predictedz), (mo->z), (slopemom.z/2));
P_SlopeLaunch(mo);
}

View File

@ -812,10 +812,10 @@ void P_SlopeLaunch(mobj_t *mo)
mo->momy = slopemom.y;
mo->momz = slopemom.z;
#endif
}
//CONS_Printf("Launched off of slope.\n");
mo->standingslope = NULL;
}
}
// Function to help handle landing on slopes