mirror of
https://github.com/GTAmodding/re3.git
synced 2024-12-25 17:15:41 +00:00
defined out asserts.
This commit is contained in:
parent
d9a3533438
commit
af6e132b37
48 changed files with 156 additions and 6 deletions
|
@ -84,4 +84,7 @@ public:
|
||||||
return (CAnimBlendAssociation*)((uint8*)l - offsetof(CAnimBlendAssociation, link));
|
return (CAnimBlendAssociation*)((uint8*)l - offsetof(CAnimBlendAssociation, link));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CAnimBlendAssociation) == 0x40, "CAnimBlendAssociation: error");
|
static_assert(sizeof(CAnimBlendAssociation) == 0x40, "CAnimBlendAssociation: error");
|
||||||
|
#endif
|
|
@ -24,4 +24,7 @@ public:
|
||||||
void Uncompress(void);
|
void Uncompress(void);
|
||||||
void RemoveUncompressedData(void);
|
void RemoveUncompressedData(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CAnimBlendHierarchy) == 0x28, "CAnimBlendHierarchy: error");
|
static_assert(sizeof(CAnimBlendHierarchy) == 0x28, "CAnimBlendHierarchy: error");
|
||||||
|
#endif
|
|
@ -26,4 +26,7 @@ public:
|
||||||
void GetCurrentTranslation(CVector &trans, float weight);
|
void GetCurrentTranslation(CVector &trans, float weight);
|
||||||
void GetEndTranslation(CVector &trans, float weight);
|
void GetEndTranslation(CVector &trans, float weight);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CAnimBlendNode) == 0x1C, "CAnimBlendNode: error");
|
static_assert(sizeof(CAnimBlendNode) == 0x1C, "CAnimBlendNode: error");
|
||||||
|
#endif
|
|
@ -20,7 +20,9 @@ public:
|
||||||
// no methods
|
// no methods
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(cAudioCollision) == 40, "cAudioCollision: error");
|
static_assert(sizeof(cAudioCollision) == 40, "cAudioCollision: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class cAudioCollisionManager
|
class cAudioCollisionManager
|
||||||
{
|
{
|
||||||
|
@ -35,4 +37,6 @@ public:
|
||||||
void AddCollisionToRequestedQueue();
|
void AddCollisionToRequestedQueue();
|
||||||
};
|
};
|
||||||
|
|
||||||
static_assert(sizeof(cAudioCollisionManager) == 852, "cAudioCollisionManager: error");
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
|
static_assert(sizeof(cAudioCollisionManager) == 852, "cAudioCollisionManager: error");
|
||||||
|
#endif
|
|
@ -52,7 +52,9 @@ public:
|
||||||
uint8 m_AudioEvents;
|
uint8 m_AudioEvents;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(tAudioEntity) == 40, "tAudioEntity: error");
|
static_assert(sizeof(tAudioEntity) == 40, "tAudioEntity: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class tPedComment
|
class tPedComment
|
||||||
{
|
{
|
||||||
|
@ -135,7 +137,9 @@ public:
|
||||||
float m_fVelocityChange;
|
float m_fVelocityChange;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(cVehicleParams) == 0x18, "cVehicleParams: error");
|
static_assert(sizeof(cVehicleParams) == 0x18, "cVehicleParams: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -119,4 +119,7 @@ public:
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
};
|
};
|
||||||
static_assert(sizeof(CAutoPilot) == 0x70, "CAutoPilot: error");
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
|
static_assert(sizeof(CAutoPilot) == 0x70, "CAutoPilot: error");
|
||||||
|
#endif
|
|
@ -172,7 +172,9 @@ class CGarage
|
||||||
friend class CCamera;
|
friend class CCamera;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CGarage) == 140, "CGarage");
|
static_assert(sizeof(CGarage) == 140, "CGarage");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CGarages
|
class CGarages
|
||||||
{
|
{
|
||||||
|
|
|
@ -41,7 +41,10 @@ struct CPedPathNode
|
||||||
CPedPathNode* prev;
|
CPedPathNode* prev;
|
||||||
CPedPathNode* next;
|
CPedPathNode* next;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPedPathNode) == 0x10, "CPedPathNode: error");
|
static_assert(sizeof(CPedPathNode) == 0x10, "CPedPathNode: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CPedPath {
|
class CPedPath {
|
||||||
public:
|
public:
|
||||||
|
@ -221,7 +224,11 @@ public:
|
||||||
|
|
||||||
void DisplayPathData(void);
|
void DisplayPathData(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPathFind) == 0x49bf4, "CPathFind: error");
|
static_assert(sizeof(CPathFind) == 0x49bf4, "CPathFind: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
extern CPathFind ThePaths;
|
extern CPathFind ThePaths;
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,9 @@ public:
|
||||||
~CPhone() { }
|
~CPhone() { }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPhone) == 0x34, "CPhone: error");
|
static_assert(sizeof(CPhone) == 0x34, "CPhone: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CPhoneInfo {
|
class CPhoneInfo {
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -47,7 +47,9 @@ private:
|
||||||
void Remove();
|
void Remove();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPickup) == 0x1C, "CPickup: error");
|
static_assert(sizeof(CPickup) == 0x1C, "CPickup: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
struct tPickupMessage
|
struct tPickupMessage
|
||||||
{
|
{
|
||||||
|
|
|
@ -108,7 +108,10 @@ class CReplay
|
||||||
CMatrix camera_pos;
|
CMatrix camera_pos;
|
||||||
CVector player_pos;
|
CVector player_pos;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(tGeneralPacket) == 88, "tGeneralPacket: error");
|
static_assert(sizeof(tGeneralPacket) == 88, "tGeneralPacket: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
struct tClockPacket
|
struct tClockPacket
|
||||||
{
|
{
|
||||||
|
|
|
@ -260,9 +260,12 @@ public:
|
||||||
void Process_FollowPed_Rotation(const CVector &CameraTarget, float TargetOrientation, float, float);
|
void Process_FollowPed_Rotation(const CVector &CameraTarget, float TargetOrientation, float, float);
|
||||||
void Process_FollowCar_SA(const CVector &CameraTarget, float TargetOrientation, float, float);
|
void Process_FollowCar_SA(const CVector &CameraTarget, float TargetOrientation, float, float);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CCam) == 0x1A4, "CCam: wrong size");
|
static_assert(sizeof(CCam) == 0x1A4, "CCam: wrong size");
|
||||||
static_assert(offsetof(CCam, Alpha) == 0xA8, "CCam: error");
|
static_assert(offsetof(CCam, Alpha) == 0xA8, "CCam: error");
|
||||||
static_assert(offsetof(CCam, Front) == 0x140, "CCam: error");
|
static_assert(offsetof(CCam, Front) == 0x140, "CCam: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CCamPathSplines
|
class CCamPathSplines
|
||||||
{
|
{
|
||||||
|
@ -637,6 +640,8 @@ uint32 unknown; // some counter having to do with music
|
||||||
bool IsSphereVisible(const CVector ¢er, float radius);
|
bool IsSphereVisible(const CVector ¢er, float radius);
|
||||||
bool IsBoxVisible(RwV3d *box, const CMatrix *mat);
|
bool IsBoxVisible(RwV3d *box, const CMatrix *mat);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(offsetof(CCamera, DistanceToWater) == 0xe4, "CCamera: error");
|
static_assert(offsetof(CCamera, DistanceToWater) == 0xe4, "CCamera: error");
|
||||||
static_assert(offsetof(CCamera, m_WideScreenOn) == 0x70, "CCamera: error");
|
static_assert(offsetof(CCamera, m_WideScreenOn) == 0x70, "CCamera: error");
|
||||||
static_assert(offsetof(CCamera, WorldViewerBeingUsed) == 0x75, "CCamera: error");
|
static_assert(offsetof(CCamera, WorldViewerBeingUsed) == 0x75, "CCamera: error");
|
||||||
|
@ -650,6 +655,7 @@ static_assert(offsetof(CCamera, m_PreviousCameraPosition) == 0x6B0, "CCamera: er
|
||||||
static_assert(offsetof(CCamera, m_vecCutSceneOffset) == 0x6F8, "CCamera: error");
|
static_assert(offsetof(CCamera, m_vecCutSceneOffset) == 0x6F8, "CCamera: error");
|
||||||
static_assert(offsetof(CCamera, m_arrPathArray) == 0x7a8, "CCamera: error");
|
static_assert(offsetof(CCamera, m_arrPathArray) == 0x7a8, "CCamera: error");
|
||||||
static_assert(sizeof(CCamera) == 0xE9D8, "CCamera: wrong size");
|
static_assert(sizeof(CCamera) == 0xE9D8, "CCamera: wrong size");
|
||||||
|
#endif
|
||||||
|
|
||||||
extern CCamera TheCamera;
|
extern CCamera TheCamera;
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,10 @@ struct CdReadInfo
|
||||||
HANDLE hFile;
|
HANDLE hFile;
|
||||||
OVERLAPPED Overlapped;
|
OVERLAPPED Overlapped;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CdReadInfo, 0x30);
|
VALIDATE_SIZE(CdReadInfo, 0x30);
|
||||||
|
#endif
|
||||||
|
|
||||||
char gCdImageNames[MAX_CDIMAGES+1][64];
|
char gCdImageNames[MAX_CDIMAGES+1][64];
|
||||||
int32 gNumImages;
|
int32 gNumImages;
|
||||||
|
|
|
@ -25,8 +25,9 @@ struct Queue
|
||||||
int32 size;
|
int32 size;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(Queue, 0x10);
|
VALIDATE_SIZE(Queue, 0x10);
|
||||||
|
#endif
|
||||||
|
|
||||||
void CdStreamInitThread(void);
|
void CdStreamInitThread(void);
|
||||||
void CdStreamInit(int32 numChannels);
|
void CdStreamInit(int32 numChannels);
|
||||||
|
|
|
@ -31,4 +31,7 @@ public:
|
||||||
bool IsWithinArea(float x1, float y1, float x2, float y2);
|
bool IsWithinArea(float x1, float y1, float x2, float y2);
|
||||||
bool IsWithinArea(float x1, float y1, float z1, float x2, float y2, float z2);
|
bool IsWithinArea(float x1, float y1, float z1, float x2, float y2, float z2);
|
||||||
};
|
};
|
||||||
static_assert(sizeof(CPlaceable) == 0x4C, "CPlaceable: error");
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
|
static_assert(sizeof(CPlaceable) == 0x4C, "CPlaceable: error");
|
||||||
|
#endif
|
|
@ -80,4 +80,7 @@ public:
|
||||||
|
|
||||||
~CPlayerInfo() { };
|
~CPlayerInfo() { };
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPlayerInfo) == 0x13C, "CPlayerInfo: error");
|
static_assert(sizeof(CPlayerInfo) == 0x13C, "CPlayerInfo: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -54,4 +54,6 @@ public:
|
||||||
static void SetMaximumWantedLevel(int32 level);
|
static void SetMaximumWantedLevel(int32 level);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CWanted) == 0x204, "CWanted: error");
|
static_assert(sizeof(CWanted) == 0x204, "CWanted: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -45,7 +45,11 @@ class CSector
|
||||||
public:
|
public:
|
||||||
CPtrList m_lists[NUMSECTORENTITYLISTS];
|
CPtrList m_lists[NUMSECTORENTITYLISTS];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CSector) == 0x28, "CSector: error");
|
static_assert(sizeof(CSector) == 0x28, "CSector: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CEntity;
|
class CEntity;
|
||||||
struct CColPoint;
|
struct CColPoint;
|
||||||
|
|
|
@ -226,7 +226,11 @@ void re3_assert(const char *expr, const char *filename, unsigned int lineno, con
|
||||||
#define _TODO(x)
|
#define _TODO(x)
|
||||||
#define _TODOCONST(x) (x)
|
#define _TODOCONST(x) (x)
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
#define VALIDATE_SIZE(struc, size) static_assert(sizeof(struc) == size, "Invalid structure size of " #struc)
|
#define VALIDATE_SIZE(struc, size) static_assert(sizeof(struc) == size, "Invalid structure size of " #struc)
|
||||||
|
#else
|
||||||
|
#define VALIDATE_SIZE(struc, size)
|
||||||
|
#endif
|
||||||
#define VALIDATE_OFFSET(struc, member, offset) static_assert(offsetof(struc, member) == offset, "The offset of " #member " in " #struc " is not " #offset "...")
|
#define VALIDATE_OFFSET(struc, member, offset) static_assert(offsetof(struc, member) == offset, "The offset of " #member " in " #struc " is not " #offset "...")
|
||||||
|
|
||||||
#define PERCENT(x, p) ((float(x) * (float(p) / 100.0f)))
|
#define PERCENT(x, p) ((float(x) * (float(p) / 100.0f)))
|
||||||
|
|
|
@ -16,4 +16,7 @@ public:
|
||||||
|
|
||||||
virtual bool GetIsATreadable(void) { return false; }
|
virtual bool GetIsATreadable(void) { return false; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CBuilding) == 0x64, "CBuilding: error");
|
static_assert(sizeof(CBuilding) == 0x64, "CBuilding: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -15,4 +15,7 @@ public:
|
||||||
static void *operator new(size_t);
|
static void *operator new(size_t);
|
||||||
static void operator delete(void*, size_t);
|
static void operator delete(void*, size_t);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CDummy) == 0x68, "CDummy: error");
|
static_assert(sizeof(CDummy) == 0x68, "CDummy: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -172,4 +172,7 @@ public:
|
||||||
|
|
||||||
static void AddSteamsFromGround(CPtrList& list);
|
static void AddSteamsFromGround(CPtrList& list);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CEntity) == 0x64, "CEntity: error");
|
static_assert(sizeof(CEntity) == 0x64, "CEntity: error");
|
||||||
|
#endif
|
|
@ -160,4 +160,7 @@ public:
|
||||||
bool CheckCollision(void);
|
bool CheckCollision(void);
|
||||||
bool CheckCollision_SimpleCar(void);
|
bool CheckCollision_SimpleCar(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPhysical) == 0x128, "CPhysical: error");
|
static_assert(sizeof(CPhysical) == 0x128, "CPhysical: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -12,4 +12,7 @@ public:
|
||||||
|
|
||||||
bool GetIsATreadable(void) { return true; }
|
bool GetIsATreadable(void) { return true; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CTreadable) == 0x94, "CTreadable: error");
|
static_assert(sizeof(CTreadable) == 0x94, "CTreadable: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -70,4 +70,6 @@ public:
|
||||||
uint16 GetNumRefs() const { return m_refCount; }
|
uint16 GetNumRefs() const { return m_refCount; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CBaseModelInfo) == 0x30, "CBaseModelInfo: error");
|
static_assert(sizeof(CBaseModelInfo) == 0x30, "CBaseModelInfo: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -50,4 +50,7 @@ public:
|
||||||
static RwFrame *FillFrameArrayCB(RwFrame *frame, void *data);
|
static RwFrame *FillFrameArrayCB(RwFrame *frame, void *data);
|
||||||
static RwFrame *GetFrameFromId(RpClump *clump, int32 id);
|
static RwFrame *GetFrameFromId(RpClump *clump, int32 id);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CClumpModelInfo) == 0x34, "CClumpModelInfo: error");
|
static_assert(sizeof(CClumpModelInfo) == 0x34, "CClumpModelInfo: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -49,4 +49,7 @@ public:
|
||||||
void SetRelatedModel(CSimpleModelInfo *m){
|
void SetRelatedModel(CSimpleModelInfo *m){
|
||||||
m_atomics[2] = (RpAtomic*)m; }
|
m_atomics[2] = (RpAtomic*)m; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CSimpleModelInfo) == 0x4C, "CSimpleModelInfo: error");
|
static_assert(sizeof(CSimpleModelInfo) == 0x4C, "CSimpleModelInfo: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -17,4 +17,7 @@ public:
|
||||||
void SetOtherTimeModel(int32 other) { m_otherTimeModelID = other; }
|
void SetOtherTimeModel(int32 other) { m_otherTimeModelID = other; }
|
||||||
CTimeModelInfo *FindOtherTimeModel(void);
|
CTimeModelInfo *FindOtherTimeModel(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CTimeModelInfo) == 0x58, "CTimeModelInfo: error");
|
static_assert(sizeof(CTimeModelInfo) == 0x58, "CTimeModelInfo: error");
|
||||||
|
#endif
|
|
@ -123,4 +123,7 @@ public:
|
||||||
static int GetMaximumNumberOfPassengersFromNumberOfDoors(int id);
|
static int GetMaximumNumberOfPassengersFromNumberOfDoors(int id);
|
||||||
static void SetComponentsToUse(int8 c1, int8 c2) { ms_compsToUse[0] = c1; ms_compsToUse[1] = c2; }
|
static void SetComponentsToUse(int8 c1, int8 c2) { ms_compsToUse[0] = c1; ms_compsToUse[1] = c2; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CVehicleModelInfo) == 0x1F8, "CVehicleModelInfo: error");
|
static_assert(sizeof(CVehicleModelInfo) == 0x1F8, "CVehicleModelInfo: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -10,4 +10,7 @@ public:
|
||||||
CDummyObject(void) {}
|
CDummyObject(void) {}
|
||||||
CDummyObject(CObject *obj);
|
CDummyObject(CObject *obj);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CDummyObject) == 0x68, "CDummyObject: error");
|
static_assert(sizeof(CDummyObject) == 0x68, "CDummyObject: error");
|
||||||
|
#endif
|
|
@ -97,4 +97,7 @@ public:
|
||||||
static void DeleteAllTempObjects();
|
static void DeleteAllTempObjects();
|
||||||
static void DeleteAllTempObjectsInArea(CVector point, float fRadius);
|
static void DeleteAllTempObjectsInArea(CVector point, float fRadius);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CObject) == 0x198, "CObject: error");
|
static_assert(sizeof(CObject) == 0x198, "CObject: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -8,4 +8,7 @@ class CDummyPed : CDummy
|
||||||
int32 pedType;
|
int32 pedType;
|
||||||
int32 unknown;
|
int32 unknown;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CDummyPed) == 0x70, "CDummyPed: error");
|
static_assert(sizeof(CDummyPed) == 0x70, "CDummyPed: error");
|
||||||
|
#endif
|
|
@ -64,4 +64,7 @@ public:
|
||||||
bool LookAtPosition(CVector const& pos);
|
bool LookAtPosition(CVector const& pos);
|
||||||
bool RestoreLookAt(void);
|
bool RestoreLookAt(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPedIK) == 0x28, "CPedIK: error");
|
static_assert(sizeof(CPedIK) == 0x28, "CPedIK: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -89,4 +89,7 @@ public:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(C2dEffect) == 0x34, "C2dEffect: error");
|
static_assert(sizeof(C2dEffect) == 0x34, "C2dEffect: error");
|
||||||
|
#endif
|
|
@ -38,7 +38,10 @@ struct CRegisteredCorona
|
||||||
|
|
||||||
void Update(void);
|
void Update(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CRegisteredCorona) == 0x80, "CRegisteredCorona: error");
|
static_assert(sizeof(CRegisteredCorona) == 0x80, "CRegisteredCorona: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CCoronas
|
class CCoronas
|
||||||
{
|
{
|
||||||
|
|
|
@ -21,7 +21,9 @@ public:
|
||||||
void Render(void);
|
void Render(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CFallingGlassPane, 0x70);
|
VALIDATE_SIZE(CFallingGlassPane, 0x70);
|
||||||
|
#endif
|
||||||
|
|
||||||
enum
|
enum
|
||||||
{
|
{
|
||||||
|
|
|
@ -91,4 +91,6 @@ public:
|
||||||
static void AddYardieDoorSmoke(CVector const &vecPos, CMatrix const &matMatrix);
|
static void AddYardieDoorSmoke(CVector const &vecPos, CMatrix const &matMatrix);
|
||||||
};
|
};
|
||||||
|
|
||||||
VALIDATE_SIZE(CParticle, 0x68);
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
|
VALIDATE_SIZE(CParticle, 0x68);
|
||||||
|
#endif
|
|
@ -64,8 +64,10 @@ struct tParticleSystemData
|
||||||
RwRaster **m_ppRaster;
|
RwRaster **m_ppRaster;
|
||||||
CParticle *m_pParticles;
|
CParticle *m_pParticles;
|
||||||
};
|
};
|
||||||
VALIDATE_SIZE(tParticleSystemData, 0x88);
|
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
|
VALIDATE_SIZE(tParticleSystemData, 0x88);
|
||||||
|
#endif
|
||||||
|
|
||||||
class cParticleSystemMgr
|
class cParticleSystemMgr
|
||||||
{
|
{
|
||||||
|
@ -125,6 +127,8 @@ public:
|
||||||
void RangeCheck(tParticleSystemData *pData) { }
|
void RangeCheck(tParticleSystemData *pData) { }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(cParticleSystemMgr, 0x2420);
|
VALIDATE_SIZE(cParticleSystemMgr, 0x2420);
|
||||||
|
#endif
|
||||||
|
|
||||||
extern cParticleSystemMgr mod_ParticleSystemManager;
|
extern cParticleSystemMgr mod_ParticleSystemManager;
|
|
@ -51,7 +51,10 @@ public:
|
||||||
CStoredShadow()
|
CStoredShadow()
|
||||||
{ }
|
{ }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CStoredShadow, 0x30);
|
VALIDATE_SIZE(CStoredShadow, 0x30);
|
||||||
|
#endif
|
||||||
|
|
||||||
class CPolyBunch
|
class CPolyBunch
|
||||||
{
|
{
|
||||||
|
@ -65,7 +68,10 @@ public:
|
||||||
CPolyBunch()
|
CPolyBunch()
|
||||||
{ }
|
{ }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CPolyBunch, 0x6C);
|
VALIDATE_SIZE(CPolyBunch, 0x6C);
|
||||||
|
#endif
|
||||||
|
|
||||||
class CStaticShadow
|
class CStaticShadow
|
||||||
{
|
{
|
||||||
|
@ -93,7 +99,10 @@ public:
|
||||||
|
|
||||||
void Free();
|
void Free();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CStaticShadow, 0x40);
|
VALIDATE_SIZE(CStaticShadow, 0x40);
|
||||||
|
#endif
|
||||||
|
|
||||||
class CPermanentShadow
|
class CPermanentShadow
|
||||||
{
|
{
|
||||||
|
@ -115,7 +124,9 @@ public:
|
||||||
CPermanentShadow()
|
CPermanentShadow()
|
||||||
{ }
|
{ }
|
||||||
};
|
};
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(CPermanentShadow, 0x38);
|
VALIDATE_SIZE(CPermanentShadow, 0x38);
|
||||||
|
#endif
|
||||||
|
|
||||||
class CPtrList;
|
class CPtrList;
|
||||||
class CAutomobile;
|
class CAutomobile;
|
||||||
|
|
|
@ -90,7 +90,9 @@ static psGlobalType PsGlobal;
|
||||||
#include "Sprite2d.h"
|
#include "Sprite2d.h"
|
||||||
#include "AnimViewer.h"
|
#include "AnimViewer.h"
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
VALIDATE_SIZE(psGlobalType, 0x28);
|
VALIDATE_SIZE(psGlobalType, 0x28);
|
||||||
|
#endif
|
||||||
|
|
||||||
// DirectShow interfaces
|
// DirectShow interfaces
|
||||||
IGraphBuilder *pGB = nil;
|
IGraphBuilder *pGB = nil;
|
||||||
|
|
|
@ -12,8 +12,11 @@ struct CKeyEntry
|
||||||
wchar *value;
|
wchar *value;
|
||||||
char key[8];
|
char key[8];
|
||||||
};
|
};
|
||||||
|
|
||||||
// If this fails, CKeyArray::Load will have to be fixed
|
// If this fails, CKeyArray::Load will have to be fixed
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CKeyEntry) == 12, "CKeyEntry: error");
|
static_assert(sizeof(CKeyEntry) == 12, "CKeyEntry: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CKeyArray
|
class CKeyArray
|
||||||
{
|
{
|
||||||
|
|
|
@ -197,7 +197,9 @@ public:
|
||||||
static void SetAllTaxiLights(bool set);
|
static void SetAllTaxiLights(bool set);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CAutomobile) == 0x5A8, "CAutomobile: error");
|
static_assert(sizeof(CAutomobile) == 0x5A8, "CAutomobile: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
inline uint8 GetCarDoorFlag(int32 carnode) {
|
inline uint8 GetCarDoorFlag(int32 carnode) {
|
||||||
switch (carnode) {
|
switch (carnode) {
|
||||||
|
|
|
@ -72,7 +72,9 @@ public:
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CBoat) == 0x484, "CBoat: error");
|
static_assert(sizeof(CBoat) == 0x484, "CBoat: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
extern float MAX_WAKE_LENGTH;
|
extern float MAX_WAKE_LENGTH;
|
||||||
extern float MIN_WAKE_INTERVAL;
|
extern float MIN_WAKE_INTERVAL;
|
||||||
|
|
|
@ -72,7 +72,9 @@ public:
|
||||||
float GetHeightToDropoffHeight() { return m_fDropoffHeight + (m_bIsCrusher ? 7.0f : 2.0f); }
|
float GetHeightToDropoffHeight() { return m_fDropoffHeight + (m_bIsCrusher ? 7.0f : 2.0f); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CCrane) == 128, "CCrane: error");
|
static_assert(sizeof(CCrane) == 128, "CCrane: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
class CCranes
|
class CCranes
|
||||||
{
|
{
|
||||||
|
|
|
@ -95,4 +95,7 @@ public:
|
||||||
|
|
||||||
static void ActivateHeli(bool activate);
|
static void ActivateHeli(bool activate);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CHeli) == 0x33C, "CHeli: error");
|
static_assert(sizeof(CHeli) == 0x33C, "CHeli: error");
|
||||||
|
#endif
|
||||||
|
|
|
@ -63,7 +63,10 @@ public:
|
||||||
static bool HasCesnaBeenDestroyed(void);
|
static bool HasCesnaBeenDestroyed(void);
|
||||||
static bool HasDropOffCesnaBeenShotDown(void);
|
static bool HasDropOffCesnaBeenShotDown(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CPlane) == 0x29C, "CPlane: error");
|
static_assert(sizeof(CPlane) == 0x29C, "CPlane: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
extern float LandingPoint;
|
extern float LandingPoint;
|
||||||
extern float TakeOffPoint;
|
extern float TakeOffPoint;
|
||||||
|
|
|
@ -91,4 +91,7 @@ public:
|
||||||
float *totalLength, float *totalDuration, CTrainInterpolationLine *interpLines, bool rightRail);
|
float *totalLength, float *totalDuration, CTrainInterpolationLine *interpLines, bool rightRail);
|
||||||
static void UpdateTrains(void);
|
static void UpdateTrains(void);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CTrain) == 0x2E4, "CTrain: error");
|
static_assert(sizeof(CTrain) == 0x2E4, "CTrain: error");
|
||||||
|
#endif
|
|
@ -291,9 +291,11 @@ public:
|
||||||
static bool m_bDisableMouseSteering;
|
static bool m_bDisableMouseSteering;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef CHECK_STRUCT_SIZES
|
||||||
static_assert(sizeof(CVehicle) == 0x288, "CVehicle: error");
|
static_assert(sizeof(CVehicle) == 0x288, "CVehicle: error");
|
||||||
static_assert(offsetof(CVehicle, m_pCurGroundEntity) == 0x1E0, "CVehicle: error");
|
static_assert(offsetof(CVehicle, m_pCurGroundEntity) == 0x1E0, "CVehicle: error");
|
||||||
static_assert(offsetof(CVehicle, m_nAlarmState) == 0x1A0, "CVehicle: error");
|
static_assert(offsetof(CVehicle, m_nAlarmState) == 0x1A0, "CVehicle: error");
|
||||||
static_assert(offsetof(CVehicle, m_nLastWeaponDamage) == 0x228, "CVehicle: error");
|
static_assert(offsetof(CVehicle, m_nLastWeaponDamage) == 0x228, "CVehicle: error");
|
||||||
|
#endif
|
||||||
|
|
||||||
void DestroyVehicleAndDriverAndPassengers(CVehicle* pVehicle);
|
void DestroyVehicleAndDriverAndPassengers(CVehicle* pVehicle);
|
||||||
|
|
Loading…
Reference in a new issue