diff --git a/src/dobjtype.cpp b/src/dobjtype.cpp index c981a00e96..190f92597b 100644 --- a/src/dobjtype.cpp +++ b/src/dobjtype.cpp @@ -69,6 +69,7 @@ PString *TypeString; PName *TypeName; PSound *TypeSound; PColor *TypeColor; +PStatePointer *TypeState; // PRIVATE DATA DEFINITIONS ------------------------------------------------ @@ -267,6 +268,7 @@ void PType::StaticInit() TypeTable.AddType(TypeName = new PName); TypeTable.AddType(TypeSound = new PSound); TypeTable.AddType(TypeColor = new PColor); + TypeTable.AddType(TypeState = new PStatePointer); } @@ -447,6 +449,23 @@ PColor::PColor() assert(sizeof(PalEntry) == __alignof(PalEntry)); } +/* PStatePointer **********************************************************/ + +IMPLEMENT_CLASS(PStatePointer) + +//========================================================================== +// +// PStatePointer Default Constructor +// +//========================================================================== + +PStatePointer::PStatePointer() +: PInt(sizeof(FState *), true) +{ + Align = __alignof(FState *); +} + + /* PPointer ***************************************************************/ IMPLEMENT_POINTY_CLASS(PPointer) diff --git a/src/dobjtype.h b/src/dobjtype.h index 67e3f5f4fc..edaaae4f24 100644 --- a/src/dobjtype.h +++ b/src/dobjtype.h @@ -291,6 +291,13 @@ public: // Pointers ----------------------------------------------------------------- +class PStatePointer : public PInt +{ + DECLARE_CLASS(PStatePointer, PInt); +public: + PStatePointer(); +}; + class PPointer : public PInt { DECLARE_CLASS(PPointer, PInt); @@ -618,5 +625,6 @@ extern PString *TypeString; extern PName *TypeName; extern PSound *TypeSound; extern PColor *TypeColor; +extern PStatePointer *TypeState; #endif