mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-02-22 03:51:11 +00:00
fixed: AActor's members must all be native.
The morph code added 4 scripted ones, but AActor's size must be known at compile time.
This commit is contained in:
parent
572ba9f515
commit
347cb724e3
4 changed files with 21 additions and 6 deletions
|
@ -1362,18 +1362,23 @@ public:
|
||||||
DVector3 Prev;
|
DVector3 Prev;
|
||||||
DRotator PrevAngles;
|
DRotator PrevAngles;
|
||||||
DAngle PrevFOV;
|
DAngle PrevFOV;
|
||||||
int PrevPortalGroup;
|
|
||||||
TArray<FDynamicLight *> AttachedLights;
|
TArray<FDynamicLight *> AttachedLights;
|
||||||
TDeletingArray<FLightDefaults *> UserLights;
|
TDeletingArray<FLightDefaults *> UserLights;
|
||||||
|
int PrevPortalGroup;
|
||||||
|
|
||||||
// When was this actor spawned?
|
// When was this actor spawned?
|
||||||
int SpawnTime;
|
int SpawnTime;
|
||||||
uint32_t SpawnOrder;
|
uint32_t SpawnOrder;
|
||||||
|
|
||||||
|
int UnmorphTime;
|
||||||
|
int MorphFlags;
|
||||||
|
int PremorphProperties;
|
||||||
|
PClassActor* MorphExitFlash;
|
||||||
// landing speed from a jump with normal gravity (squats the player's view)
|
// landing speed from a jump with normal gravity (squats the player's view)
|
||||||
// (note: this is put into AActor instead of the PlayerPawn because non-players also use the value)
|
// (note: this is put into AActor instead of the PlayerPawn because non-players also use the value)
|
||||||
double LandingSpeed;
|
double LandingSpeed;
|
||||||
|
|
||||||
|
|
||||||
// ThingIDs
|
// ThingIDs
|
||||||
void SetTID (int newTID);
|
void SetTID (int newTID);
|
||||||
|
|
||||||
|
|
|
@ -393,7 +393,13 @@ void AActor::Serialize(FSerializer &arc)
|
||||||
A("userlights", UserLights)
|
A("userlights", UserLights)
|
||||||
A("WorldOffset", WorldOffset)
|
A("WorldOffset", WorldOffset)
|
||||||
("modelData", modelData)
|
("modelData", modelData)
|
||||||
A("LandingSpeed", LandingSpeed);
|
A("LandingSpeed", LandingSpeed)
|
||||||
|
|
||||||
|
("unmorphtime", UnmorphTime)
|
||||||
|
("morphflags", MorphFlags)
|
||||||
|
("premorphproperties", PremorphProperties)
|
||||||
|
("morphexitflash", MorphExitFlash);
|
||||||
|
|
||||||
|
|
||||||
SerializeTerrain(arc, "floorterrain", floorterrain, &def->floorterrain);
|
SerializeTerrain(arc, "floorterrain", floorterrain, &def->floorterrain);
|
||||||
SerializeArgs(arc, "args", args, def->args, special);
|
SerializeArgs(arc, "args", args, def->args, special);
|
||||||
|
|
|
@ -2126,6 +2126,10 @@ DEFINE_FIELD(AActor, ShadowAimFactor)
|
||||||
DEFINE_FIELD(AActor, ShadowPenaltyFactor)
|
DEFINE_FIELD(AActor, ShadowPenaltyFactor)
|
||||||
DEFINE_FIELD(AActor, AutomapOffsets)
|
DEFINE_FIELD(AActor, AutomapOffsets)
|
||||||
DEFINE_FIELD(AActor, LandingSpeed)
|
DEFINE_FIELD(AActor, LandingSpeed)
|
||||||
|
DEFINE_FIELD(AActor, UnmorphTime)
|
||||||
|
DEFINE_FIELD(AActor, MorphFlags)
|
||||||
|
DEFINE_FIELD(AActor, PremorphProperties)
|
||||||
|
DEFINE_FIELD(AActor, MorphExitFlash)
|
||||||
|
|
||||||
DEFINE_FIELD_X(FCheckPosition, FCheckPosition, thing);
|
DEFINE_FIELD_X(FCheckPosition, FCheckPosition, thing);
|
||||||
DEFINE_FIELD_X(FCheckPosition, FCheckPosition, pos);
|
DEFINE_FIELD_X(FCheckPosition, FCheckPosition, pos);
|
||||||
|
|
|
@ -35,10 +35,10 @@ extend class Actor
|
||||||
MPROP_INVIS = 1 << 6,
|
MPROP_INVIS = 1 << 6,
|
||||||
}
|
}
|
||||||
|
|
||||||
int UnmorphTime;
|
native int UnmorphTime;
|
||||||
EMorphFlags MorphFlags;
|
native int MorphFlags;
|
||||||
class<Actor> MorphExitFlash;
|
native class<Actor> MorphExitFlash;
|
||||||
EPremorphProperty PremorphProperties;
|
native int PremorphProperties;
|
||||||
|
|
||||||
// Players still track these separately for legacy reasons.
|
// Players still track these separately for legacy reasons.
|
||||||
void SetMorphStyle(EMorphFlags flags)
|
void SetMorphStyle(EMorphFlags flags)
|
||||||
|
|
Loading…
Reference in a new issue