mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 15:02:01 +00:00
- Added A_SetSize(double newradius, double newheight = -1).
- Changes the calling actor's radius and height.
This commit is contained in:
parent
2fea46a719
commit
3023af8223
2 changed files with 17 additions and 0 deletions
|
@ -6846,3 +6846,19 @@ DEFINE_ACTION_FUNCTION(AActor, A_CheckTerrain)
|
|||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(AActor, A_SetSize)
|
||||
{
|
||||
PARAM_SELF_PROLOGUE(AActor);
|
||||
PARAM_FLOAT(newradius);
|
||||
PARAM_FLOAT_DEF(newheight);
|
||||
|
||||
if (newradius < 0.) newradius = self->radius;
|
||||
if (newheight < 0.) newheight = self->Height;
|
||||
|
||||
self->UnlinkFromWorld();
|
||||
self->radius = newradius;
|
||||
self->Height = newheight;
|
||||
self->LinkToWorld();
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -793,6 +793,7 @@ class Actor : Thinker native
|
|||
native bool A_CopySpriteFrame(int from, int to, int flags = 0);
|
||||
native bool A_SetVisibleRotation(double anglestart = 0, double angleend = 0, double pitchstart = 0, double pitchend = 0, int flags = 0, int ptr = AAPTR_DEFAULT);
|
||||
native void A_SetTranslation(name transname);
|
||||
native void A_SetSize(double newradius, double newheight = -1);
|
||||
|
||||
native void A_RearrangePointers(int newtarget, int newmaster = AAPTR_DEFAULT, int newtracer = AAPTR_DEFAULT, int flags=0);
|
||||
native void A_TransferPointer(int ptr_source, int ptr_recepient, int sourcefield, int recepientfield=AAPTR_DEFAULT, int flags=0);
|
||||
|
|
Loading…
Reference in a new issue