- Added noclip2 cheat. This is similar to noclip, except it also adds nogravity and the ability to fly through 3D floors.

SVN r3832 (trunk)
This commit is contained in:
Randy Heit 2012-08-22 21:31:48 +00:00
commit a505352da3
9 changed files with 72 additions and 11 deletions

View file

@ -1985,7 +1985,9 @@ explode:
}
if (mo->z > mo->floorz && !(mo->flags2 & MF2_ONMOBJ) &&
(!(mo->flags2 & MF2_FLY) || !(mo->flags & MF_NOGRAVITY)) && !mo->waterlevel)
!mo->IsNoClip2() &&
(!(mo->flags2 & MF2_FLY) || !(mo->flags & MF_NOGRAVITY)) &&
!mo->waterlevel)
{ // [RH] Friction when falling is available for larger aircontrols
if (player != NULL && level.airfriction != FRACUNIT)
{
@ -2228,7 +2230,10 @@ void P_ZMovement (AActor *mo, fixed_t oldfloorz)
}
if (mo->player && (mo->flags & MF_NOGRAVITY) && (mo->z > mo->floorz))
{
mo->z += finesine[(FINEANGLES/80*level.maptime)&FINEMASK]/8;
if (!mo->IsNoClip2())
{
mo->z += finesine[(FINEANGLES/80*level.maptime)&FINEMASK]/8;
}
mo->velz = FixedMul (mo->velz, FRICTION_FLY);
}
if (mo->waterlevel && !(mo->flags & MF_NOGRAVITY))