- Updated <pitch>/flat/roll/wall sprites submission to 2.9+. (ZDoom compatibility submission. )

- FLATSPRITE: An actor becomes flat as if they were a decal on the floor.
- PITCHFLATSPRITE: A flat sprite tilts up and down based on pitch.
- WALLSPRITE: Similar to a Y billboarded sprite. The degree of the flattening is determined by the FlatAngle property.
- ROLLSPRITE: The sprite of the actor is affected by the Roll property.
This commit is contained in:
MajorCooke 2016-05-01 08:45:50 -05:00
commit a8248433e9
6 changed files with 36 additions and 4 deletions

View file

@ -6881,3 +6881,25 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_FaceMovementDirection)
}
ACTION_RETURN_BOOL(true);
}
//===========================================================================
//
// A_SetFlatAngle
//
// Set actor's flat angle (in degrees). GZDoom only. Requires the
// (PITCH)FLATSPRITE flag to have any visible effect.
//
//===========================================================================
DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_SetFlatAngle)
{
PARAM_ACTION_PROLOGUE;
PARAM_FLOAT_OPT(flatangle) { flatangle = 0; }
PARAM_INT_OPT(ptr) { ptr = AAPTR_DEFAULT; }
AActor *ref = COPY_AAPTR(self, ptr);
if (ref != NULL)
{
ref->FlatAngle = flatangle;
}
return 0;
}