From d7e9ba54399a26420bb640d1f60146eff1a3cc8b Mon Sep 17 00:00:00 2001 From: ineed bots Date: Mon, 28 Aug 2023 20:26:49 -0600 Subject: [PATCH] Added a few types --- src/game/clientscript_public.hpp | 1838 ++++ src/game/enums.hpp | 4168 +++++++++ src/game/game.cpp | 1 - src/game/game.hpp | 4 - src/game/structs.hpp | 13277 ++++++++++++++++++++++++++++- src/game/xasset.hpp | 5422 ++++++++++++ src/stdinc.hpp | 3 + 7 files changed, 24668 insertions(+), 45 deletions(-) create mode 100644 src/game/clientscript_public.hpp create mode 100644 src/game/enums.hpp create mode 100644 src/game/xasset.hpp diff --git a/src/game/clientscript_public.hpp b/src/game/clientscript_public.hpp new file mode 100644 index 0000000..8de640b --- /dev/null +++ b/src/game/clientscript_public.hpp @@ -0,0 +1,1838 @@ +#pragma once + +#ifdef __cplusplus +namespace game +{ +#endif + + enum VariableType + { + VAR_UNDEFINED = 0x0, + VAR_POINTER = 0x1, + VAR_STRING = 0x2, + VAR_ISTRING = 0x3, + VAR_VECTOR = 0x4, + VAR_FLOAT = 0x5, + VAR_INTEGER = 0x6, + VAR_CODEPOS = 0x7, + VAR_PRECODEPOS = 0x8, + VAR_FUNCTION = 0x9, + VAR_STACK = 0xA, + VAR_ANIMATION = 0xB, + VAR_DEVELOPER_CODEPOS = 0xC, + VAR_THREAD = 0xD, + VAR_NOTIFY_THREAD = 0xE, + VAR_TIME_THREAD = 0xF, + VAR_CHILD_THREAD = 0x10, + VAR_OBJECT = 0x11, + VAR_DEAD_ENTITY = 0x12, + VAR_ENTITY = 0x13, + VAR_ARRAY = 0x14, + VAR_DEAD_THREAD = 0x15, + VAR_COUNT = 0x16, + VAR_THREAD_LIST = 0x17, + VAR_ENDON_LIST = 0x18, + }; + + enum ai_animmode_t + { + AI_ANIM_UNKNOWN = 0x0, + AI_ANIM_MOVE_CODE = 0x1, + AI_ANIM_USE_POS_DELTAS = 0x2, + AI_ANIM_USE_ANGLE_DELTAS = 0x3, + AI_ANIM_USE_BOTH_DELTAS = 0x4, + AI_ANIM_USE_BOTH_DELTAS_NOCLIP = 0x5, + AI_ANIM_USE_BOTH_DELTAS_NOGRAVITY = 0x6, + AI_ANIM_USE_BOTH_DELTAS_ZONLY_PHYSICS = 0x7, + AI_ANIM_NOPHYSICS = 0x8, + AI_ANIM_POINT_RELATIVE = 0x9, + }; + + enum ai_orient_mode_t + { + AI_ORIENT_INVALID = 0x0, + AI_ORIENT_DONT_CHANGE = 0x1, + AI_ORIENT_TO_MOTION = 0x2, + AI_ORIENT_TO_ENEMY = 0x3, + AI_ORIENT_TO_ENEMY_OR_MOTION = 0x4, + AI_ORIENT_TO_ENEMY_OR_MOTION_SIDESTEP = 0x5, + AI_ORIENT_TO_GOAL = 0x6, + AI_ORIENT_COUNT = 0x7, + }; + + struct VariableStackBuffer + { + const char * pos; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 size; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 bufLen; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 localId; //OFS: 0x8 SIZE: 0x2 + unsigned __int8 time; //OFS: 0xA SIZE: 0x1 + char buf[1]; //OFS: 0xB SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(VariableStackBuffer, 0xC); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, pos, 0x0); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, size, 0x4); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, bufLen, 0x6); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, localId, 0x8); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, time, 0xA); + ASSERT_STRUCT_OFFSET(VariableStackBuffer, buf, 0xB); + + union VariableUnion + { + int intValue; //OFS: 0x0 SIZE: 0x4 + float floatValue; //OFS: 0x1 SIZE: 0x4 + unsigned int stringValue; //OFS: 0x2 SIZE: 0x4 + const float * vectorValue; //OFS: 0x3 SIZE: 0x4 + const char * codePosValue; //OFS: 0x4 SIZE: 0x4 + unsigned int pointerValue; //OFS: 0x5 SIZE: 0x4 + VariableStackBuffer * stackValue; //OFS: 0x6 SIZE: 0x4 + unsigned int entityOffset; //OFS: 0x7 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VariableUnion, 0x4); + + struct VariableValue + { + VariableUnion u; //OFS: 0x0 SIZE: 0x4 + VariableType type; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VariableValue, 0x8); + ASSERT_STRUCT_OFFSET(VariableValue, u, 0x0); + ASSERT_STRUCT_OFFSET(VariableValue, type, 0x4); + + struct scrVmGlob_t + { + VariableValue eval_stack[2]; //OFS: 0x0 SIZE: 0x10 + char * dialog_error_message; //OFS: 0x10 SIZE: 0x4 + int loading; //OFS: 0x14 SIZE: 0x4 + int starttime; //OFS: 0x18 SIZE: 0x4 + unsigned int localVarsStack[2048]; //OFS: 0x1C SIZE: 0x2000 + }; + ASSERT_STRUCT_SIZE(scrVmGlob_t, 0x201C); + ASSERT_STRUCT_OFFSET(scrVmGlob_t, eval_stack, 0x0); + ASSERT_STRUCT_OFFSET(scrVmGlob_t, dialog_error_message, 0x10); + ASSERT_STRUCT_OFFSET(scrVmGlob_t, loading, 0x14); + ASSERT_STRUCT_OFFSET(scrVmGlob_t, starttime, 0x18); + ASSERT_STRUCT_OFFSET(scrVmGlob_t, localVarsStack, 0x1C); + + struct function_stack_t + { + const char * pos; //OFS: 0x0 SIZE: 0x4 + unsigned int localId; //OFS: 0x4 SIZE: 0x4 + unsigned int localVarCount; //OFS: 0x8 SIZE: 0x4 + VariableValue * top; //OFS: 0xC SIZE: 0x4 + VariableValue * startTop; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(function_stack_t, 0x14); + ASSERT_STRUCT_OFFSET(function_stack_t, pos, 0x0); + ASSERT_STRUCT_OFFSET(function_stack_t, localId, 0x4); + ASSERT_STRUCT_OFFSET(function_stack_t, localVarCount, 0x8); + ASSERT_STRUCT_OFFSET(function_stack_t, top, 0xC); + ASSERT_STRUCT_OFFSET(function_stack_t, startTop, 0x10); + + struct function_frame_t + { + function_stack_t _fs; //OFS: 0x0 SIZE: 0x14 + VariableType topType; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(function_frame_t, 0x18); + ASSERT_STRUCT_OFFSET(function_frame_t, _fs, 0x0); + ASSERT_STRUCT_OFFSET(function_frame_t, topType, 0x14); + + struct scrVmPub_t + { + unsigned int * localVars; //OFS: 0x0 SIZE: 0x4 + VariableValue * maxstack; //OFS: 0x4 SIZE: 0x4 + int function_count; //OFS: 0x8 SIZE: 0x4 + function_frame_t * function_frame; //OFS: 0xC SIZE: 0x4 + VariableValue * top; //OFS: 0x10 SIZE: 0x4 + bool debugCode; //OFS: 0x14 SIZE: 0x1 + bool abort_on_error; //OFS: 0x15 SIZE: 0x1 + char terminal_error; //OFS: 0x16 SIZE: 0x1 + char field_17; //OFS: 0x17 SIZE: 0x1 + unsigned int inparamcount; //OFS: 0x18 SIZE: 0x4 + unsigned int outparamcount; //OFS: 0x1C SIZE: 0x4 + function_frame_t function_frame_start[32]; //OFS: 0x20 SIZE: 0x300 + VariableValue stack[2048]; //OFS: 0x320 SIZE: 0x4000 + }; + ASSERT_STRUCT_SIZE(scrVmPub_t, 0x4320); + ASSERT_STRUCT_OFFSET(scrVmPub_t, localVars, 0x0); + ASSERT_STRUCT_OFFSET(scrVmPub_t, maxstack, 0x4); + ASSERT_STRUCT_OFFSET(scrVmPub_t, function_count, 0x8); + ASSERT_STRUCT_OFFSET(scrVmPub_t, function_frame, 0xC); + ASSERT_STRUCT_OFFSET(scrVmPub_t, top, 0x10); + ASSERT_STRUCT_OFFSET(scrVmPub_t, debugCode, 0x14); + ASSERT_STRUCT_OFFSET(scrVmPub_t, abort_on_error, 0x15); + ASSERT_STRUCT_OFFSET(scrVmPub_t, terminal_error, 0x16); + ASSERT_STRUCT_OFFSET(scrVmPub_t, field_17, 0x17); + ASSERT_STRUCT_OFFSET(scrVmPub_t, inparamcount, 0x18); + ASSERT_STRUCT_OFFSET(scrVmPub_t, outparamcount, 0x1C); + ASSERT_STRUCT_OFFSET(scrVmPub_t, function_frame_start, 0x20); + ASSERT_STRUCT_OFFSET(scrVmPub_t, stack, 0x320); + + union Variable_u + { + unsigned __int16 prev; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 prevSibling; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(Variable_u, 0x2); + + struct __declspec(align(2)) Variable + { + unsigned __int16 id; //OFS: 0x0 SIZE: 0x2 + Variable_u u; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(Variable, 0x4); + ASSERT_STRUCT_OFFSET(Variable, id, 0x0); + ASSERT_STRUCT_OFFSET(Variable, u, 0x2); + + union ObjectInfo_u + { + unsigned __int16 entnum; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 size; //OFS: 0x1 SIZE: 0x2 + unsigned __int16 nextEntId; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 self; //OFS: 0x3 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ObjectInfo_u, 0x2); + + struct __declspec(align(2)) ObjectInfo + { + unsigned __int16 refCount; //OFS: 0x0 SIZE: 0x2 + ObjectInfo_u u; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ObjectInfo, 0x4); + ASSERT_STRUCT_OFFSET(ObjectInfo, refCount, 0x0); + ASSERT_STRUCT_OFFSET(ObjectInfo, u, 0x2); + + union VariableValueInternal_u + { + unsigned __int16 next; //OFS: 0x0 SIZE: 0x2 + VariableUnion u; //OFS: 0x1 SIZE: 0x4 + ObjectInfo o; //OFS: 0x2 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VariableValueInternal_u, 0x4); + + struct VariableValueInternal_w_bits + { + unsigned int type : 5; + unsigned int status : 2; + unsigned int unk1 : 1; + unsigned int name : 24; + }; + + union VariableValueInternal_w + { + unsigned int status; //OFS: 0x0 SIZE: 0x4 + unsigned int type; //OFS: 0x1 SIZE: 0x4 + unsigned int name; //OFS: 0x2 SIZE: 0x4 + unsigned int classnum; //OFS: 0x3 SIZE: 0x4 + unsigned int notifyName; //OFS: 0x4 SIZE: 0x4 + unsigned int waitTime; //OFS: 0x5 SIZE: 0x4 + unsigned int parentLocalId; //OFS: 0x6 SIZE: 0x4 + VariableValueInternal_w_bits bits; + }; + ASSERT_STRUCT_SIZE(VariableValueInternal_w, 0x4); + + union VariableValueInternal_v + { + unsigned __int16 next; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 index; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(VariableValueInternal_v, 0x2); + + struct VariableValueInternal + { + Variable hash; //OFS: 0x0 SIZE: 0x4 + VariableValueInternal_u u; //OFS: 0x4 SIZE: 0x4 + VariableValueInternal_w w; //OFS: 0x8 SIZE: 0x4 + VariableValueInternal_v v; //OFS: 0xC SIZE: 0x2 + unsigned __int16 nextSibling; //OFS: 0xE SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(VariableValueInternal, 0x10); + ASSERT_STRUCT_OFFSET(VariableValueInternal, hash, 0x0); + ASSERT_STRUCT_OFFSET(VariableValueInternal, u, 0x4); + ASSERT_STRUCT_OFFSET(VariableValueInternal, w, 0x8); + ASSERT_STRUCT_OFFSET(VariableValueInternal, v, 0xC); + ASSERT_STRUCT_OFFSET(VariableValueInternal, nextSibling, 0xE); + + struct scrVarGlob_t + { + VariableValueInternal parentVariables[24576]; //OFS: 0x0 SIZE: 0x60000 + VariableValueInternal childVariables[65536]; //OFS: 0x60000 SIZE: 0x100000 + }; + ASSERT_STRUCT_SIZE(scrVarGlob_t, 0x160000); + ASSERT_STRUCT_OFFSET(scrVarGlob_t, parentVariables, 0x0); + ASSERT_STRUCT_OFFSET(scrVarGlob_t, childVariables, 0x60000); + + union HashEntry_u + { + unsigned int prev; //OFS: 0x0 SIZE: 0x4 + unsigned int str; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(HashEntry_u, 0x4); + + struct HashEntry + { + unsigned int status_next; //OFS: 0x0 SIZE: 0x4 + HashEntry_u u; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(HashEntry, 0x8); + ASSERT_STRUCT_OFFSET(HashEntry, status_next, 0x0); + ASSERT_STRUCT_OFFSET(HashEntry, u, 0x4); + + struct __declspec(align(64)) scrStringGlob_t + { + HashEntry hashTable[25000]; //OFS: 0x0 SIZE: 0x30D40 + bool inited; //OFS: 0x30D40 SIZE: 0x1 + HashEntry * nextFreeEntry; //OFS: 0x30D44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scrStringGlob_t, 0x30D80); + ASSERT_STRUCT_OFFSET(scrStringGlob_t, hashTable, 0x0); + ASSERT_STRUCT_OFFSET(scrStringGlob_t, inited, 0x30D40); + ASSERT_STRUCT_OFFSET(scrStringGlob_t, nextFreeEntry, 0x30D44); + + struct HunkUser + { + HunkUser * current; //OFS: 0x0 SIZE: 0x4 + HunkUser * next; //OFS: 0x4 SIZE: 0x4 + int maxSize; //OFS: 0x8 SIZE: 0x4 + int end; //OFS: 0xC SIZE: 0x4 + int pos; //OFS: 0x10 SIZE: 0x4 + int locked; //OFS: 0x14 SIZE: 0x4 + char * name; //OFS: 0x18 SIZE: 0x4 + bool fixed; //OFS: 0x1C SIZE: 0x1 + bool tempMem; //OFS: 0x1D SIZE: 0x1 + bool debugMem; //OFS: 0x1E SIZE: 0x1 + int type; //OFS: 0x20 SIZE: 0x4 + unsigned __int8 buf[1]; //OFS: 0x24 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(HunkUser, 0x28); + ASSERT_STRUCT_OFFSET(HunkUser, current, 0x0); + ASSERT_STRUCT_OFFSET(HunkUser, next, 0x4); + ASSERT_STRUCT_OFFSET(HunkUser, maxSize, 0x8); + ASSERT_STRUCT_OFFSET(HunkUser, end, 0xC); + ASSERT_STRUCT_OFFSET(HunkUser, pos, 0x10); + ASSERT_STRUCT_OFFSET(HunkUser, locked, 0x14); + ASSERT_STRUCT_OFFSET(HunkUser, name, 0x18); + ASSERT_STRUCT_OFFSET(HunkUser, fixed, 0x1C); + ASSERT_STRUCT_OFFSET(HunkUser, tempMem, 0x1D); + ASSERT_STRUCT_OFFSET(HunkUser, debugMem, 0x1E); + ASSERT_STRUCT_OFFSET(HunkUser, type, 0x20); + ASSERT_STRUCT_OFFSET(HunkUser, buf, 0x24); + + struct scrVarPub_t + { + char * fieldBuffer; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 canonicalStrCount; //OFS: 0x4 SIZE: 0x2 + bool developer; //OFS: 0x6 SIZE: 0x1 + bool developer_script; //OFS: 0x7 SIZE: 0x1 + bool evaluate; //OFS: 0x8 SIZE: 0x1 + char * error_message; //OFS: 0xC SIZE: 0x4 + int error_index; //OFS: 0x10 SIZE: 0x4 + unsigned int time; //OFS: 0x14 SIZE: 0x4 + unsigned int timeArrayId; //OFS: 0x18 SIZE: 0x4 + unsigned int pauseArrayId; //OFS: 0x1C SIZE: 0x4 + unsigned int levelId; //OFS: 0x20 SIZE: 0x4 + unsigned int gameId; //OFS: 0x24 SIZE: 0x4 + unsigned int animId; //OFS: 0x28 SIZE: 0x4 + unsigned int freeEntList; //OFS: 0x2C SIZE: 0x4 + unsigned int tempVariable; //OFS: 0x30 SIZE: 0x4 + bool bInited; //OFS: 0x34 SIZE: 0x1 + unsigned __int16 savecount; //OFS: 0x36 SIZE: 0x2 + unsigned int checksum; //OFS: 0x38 SIZE: 0x4 + unsigned int entId; //OFS: 0x3C SIZE: 0x4 + unsigned int entFieldName; //OFS: 0x40 SIZE: 0x4 + HunkUser * programHunkUser; //OFS: 0x44 SIZE: 0x4 + char * programBuffer; //OFS: 0x48 SIZE: 0x4 + char * endScriptBuffer; //OFS: 0x4C SIZE: 0x4 + unsigned __int16 saveIdMap[24574]; //OFS: 0x50 SIZE: 0xBFFC + unsigned __int16 saveIdMapRev[24574]; //OFS: 0xC04C SIZE: 0xBFFC + }; + ASSERT_STRUCT_SIZE(scrVarPub_t, 0x18048); + ASSERT_STRUCT_OFFSET(scrVarPub_t, fieldBuffer, 0x0); + ASSERT_STRUCT_OFFSET(scrVarPub_t, canonicalStrCount, 0x4); + ASSERT_STRUCT_OFFSET(scrVarPub_t, developer, 0x6); + ASSERT_STRUCT_OFFSET(scrVarPub_t, developer_script, 0x7); + ASSERT_STRUCT_OFFSET(scrVarPub_t, evaluate, 0x8); + ASSERT_STRUCT_OFFSET(scrVarPub_t, error_message, 0xC); + ASSERT_STRUCT_OFFSET(scrVarPub_t, error_index, 0x10); + ASSERT_STRUCT_OFFSET(scrVarPub_t, time, 0x14); + ASSERT_STRUCT_OFFSET(scrVarPub_t, timeArrayId, 0x18); + ASSERT_STRUCT_OFFSET(scrVarPub_t, pauseArrayId, 0x1C); + ASSERT_STRUCT_OFFSET(scrVarPub_t, levelId, 0x20); + ASSERT_STRUCT_OFFSET(scrVarPub_t, gameId, 0x24); + ASSERT_STRUCT_OFFSET(scrVarPub_t, animId, 0x28); + ASSERT_STRUCT_OFFSET(scrVarPub_t, freeEntList, 0x2C); + ASSERT_STRUCT_OFFSET(scrVarPub_t, tempVariable, 0x30); + ASSERT_STRUCT_OFFSET(scrVarPub_t, bInited, 0x34); + ASSERT_STRUCT_OFFSET(scrVarPub_t, savecount, 0x36); + ASSERT_STRUCT_OFFSET(scrVarPub_t, checksum, 0x38); + ASSERT_STRUCT_OFFSET(scrVarPub_t, entId, 0x3C); + ASSERT_STRUCT_OFFSET(scrVarPub_t, entFieldName, 0x40); + ASSERT_STRUCT_OFFSET(scrVarPub_t, programHunkUser, 0x44); + ASSERT_STRUCT_OFFSET(scrVarPub_t, programBuffer, 0x48); + ASSERT_STRUCT_OFFSET(scrVarPub_t, endScriptBuffer, 0x4C); + ASSERT_STRUCT_OFFSET(scrVarPub_t, saveIdMap, 0x50); + ASSERT_STRUCT_OFFSET(scrVarPub_t, saveIdMapRev, 0xC04C); + + struct SourceBufferInfo + { + const char * codePos; //OFS: 0x0 SIZE: 0x4 + char * buf; //OFS: 0x4 SIZE: 0x4 + const char * sourceBuf; //OFS: 0x8 SIZE: 0x4 + int len; //OFS: 0xC SIZE: 0x4 + int sortedIndex; //OFS: 0x10 SIZE: 0x4 + bool archive; //OFS: 0x14 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SourceBufferInfo, 0x18); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, codePos, 0x0); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, buf, 0x4); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, sourceBuf, 0x8); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, len, 0xC); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, sortedIndex, 0x10); + ASSERT_STRUCT_OFFSET(SourceBufferInfo, archive, 0x14); + + struct scrParserPub_t + { + SourceBufferInfo * sourceBufferLookup; //OFS: 0x0 SIZE: 0x4 + unsigned int sourceBufferLookupLen; //OFS: 0x4 SIZE: 0x4 + const char * scriptfilename; //OFS: 0x8 SIZE: 0x4 + const char * sourceBuf; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scrParserPub_t, 0x10); + ASSERT_STRUCT_OFFSET(scrParserPub_t, sourceBufferLookup, 0x0); + ASSERT_STRUCT_OFFSET(scrParserPub_t, sourceBufferLookupLen, 0x4); + ASSERT_STRUCT_OFFSET(scrParserPub_t, scriptfilename, 0x8); + ASSERT_STRUCT_OFFSET(scrParserPub_t, sourceBuf, 0xC); + + struct MemoryNode + { + unsigned __int16 prev; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 next; //OFS: 0x2 SIZE: 0x2 + unsigned int padding[2]; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(MemoryNode, 0xC); + ASSERT_STRUCT_OFFSET(MemoryNode, prev, 0x0); + ASSERT_STRUCT_OFFSET(MemoryNode, next, 0x2); + ASSERT_STRUCT_OFFSET(MemoryNode, padding, 0x4); + + struct scrMemTreeGlob_t + { + MemoryNode nodes[65536]; //OFS: 0x0 SIZE: 0xC0000 + unsigned __int8 leftBits[256]; //OFS: 0xC0000 SIZE: 0x100 + unsigned __int8 numBits[256]; //OFS: 0xC0100 SIZE: 0x100 + unsigned __int8 logBits[256]; //OFS: 0xC0200 SIZE: 0x100 + unsigned __int16 head[17]; //OFS: 0xC0300 SIZE: 0x22 + _BYTE gap_C0322[93]; //OFS: 0xC0322 SIZE: 0x5D + char field_C037F; //OFS: 0xC037F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(scrMemTreeGlob_t, 0xC0380); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, nodes, 0x0); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, leftBits, 0xC0000); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, numBits, 0xC0100); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, logBits, 0xC0200); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, head, 0xC0300); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, gap_C0322, 0xC0322); + ASSERT_STRUCT_OFFSET(scrMemTreeGlob_t, field_C037F, 0xC037F); + + struct OpcodeLookup + { + const char * codePos; //OFS: 0x0 SIZE: 0x4 + unsigned int sourcePosIndex; //OFS: 0x4 SIZE: 0x4 + unsigned int sourcePosCount; //OFS: 0x8 SIZE: 0x4 + int profileTime; //OFS: 0xC SIZE: 0x4 + int profileBuiltInTime; //OFS: 0x10 SIZE: 0x4 + int profileUsage; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(OpcodeLookup, 0x18); + ASSERT_STRUCT_OFFSET(OpcodeLookup, codePos, 0x0); + ASSERT_STRUCT_OFFSET(OpcodeLookup, sourcePosIndex, 0x4); + ASSERT_STRUCT_OFFSET(OpcodeLookup, sourcePosCount, 0x8); + ASSERT_STRUCT_OFFSET(OpcodeLookup, profileTime, 0xC); + ASSERT_STRUCT_OFFSET(OpcodeLookup, profileBuiltInTime, 0x10); + ASSERT_STRUCT_OFFSET(OpcodeLookup, profileUsage, 0x14); + + struct SourceLookup + { + unsigned int sourcePos; //OFS: 0x0 SIZE: 0x4 + int type; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SourceLookup, 0x8); + ASSERT_STRUCT_OFFSET(SourceLookup, sourcePos, 0x0); + ASSERT_STRUCT_OFFSET(SourceLookup, type, 0x4); + + struct SaveSourceBufferInfo + { + char * sourceBuf; //OFS: 0x0 SIZE: 0x4 + int len; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SaveSourceBufferInfo, 0x8); + ASSERT_STRUCT_OFFSET(SaveSourceBufferInfo, sourceBuf, 0x0); + ASSERT_STRUCT_OFFSET(SaveSourceBufferInfo, len, 0x4); + + struct scrParserGlob_t + { + OpcodeLookup * opcodeLookup; //OFS: 0x0 SIZE: 0x4 + unsigned int opcodeLookupMaxLen; //OFS: 0x4 SIZE: 0x4 + unsigned int opcodeLookupLen; //OFS: 0x8 SIZE: 0x4 + SourceLookup * sourcePosLookup; //OFS: 0xC SIZE: 0x4 + unsigned int sourcePosLookupMaxLen; //OFS: 0x10 SIZE: 0x4 + unsigned int sourcePosLookupLen; //OFS: 0x14 SIZE: 0x4 + unsigned int sourceBufferLookupMaxLen; //OFS: 0x18 SIZE: 0x4 + const unsigned __int8 * currentCodePos; //OFS: 0x1C SIZE: 0x4 + unsigned int currentSourcePosCount; //OFS: 0x20 SIZE: 0x4 + SaveSourceBufferInfo * saveSourceBufferLookup; //OFS: 0x24 SIZE: 0x4 + unsigned int saveSourceBufferLookupLen; //OFS: 0x28 SIZE: 0x4 + int delayedSourceIndex; //OFS: 0x2C SIZE: 0x4 + int threadStartSourceIndex; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scrParserGlob_t, 0x34); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, opcodeLookup, 0x0); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, opcodeLookupMaxLen, 0x4); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, opcodeLookupLen, 0x8); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, sourcePosLookup, 0xC); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, sourcePosLookupMaxLen, 0x10); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, sourcePosLookupLen, 0x14); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, sourceBufferLookupMaxLen, 0x18); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, currentCodePos, 0x1C); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, currentSourcePosCount, 0x20); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, saveSourceBufferLookup, 0x24); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, saveSourceBufferLookupLen, 0x28); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, delayedSourceIndex, 0x2C); + ASSERT_STRUCT_OFFSET(scrParserGlob_t, threadStartSourceIndex, 0x30); + + struct scrMemTreePub_t + { + scrMemTreeGlob_t * mt_buffer; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scrMemTreePub_t, 0x4); + ASSERT_STRUCT_OFFSET(scrMemTreePub_t, mt_buffer, 0x0); + + struct CaseStatementInfo + { + unsigned int name; //OFS: 0x0 SIZE: 0x4 + const char * codePos; //OFS: 0x4 SIZE: 0x4 + unsigned int sourcePos; //OFS: 0x8 SIZE: 0x4 + CaseStatementInfo * next; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CaseStatementInfo, 0x10); + ASSERT_STRUCT_OFFSET(CaseStatementInfo, name, 0x0); + ASSERT_STRUCT_OFFSET(CaseStatementInfo, codePos, 0x4); + ASSERT_STRUCT_OFFSET(CaseStatementInfo, sourcePos, 0x8); + ASSERT_STRUCT_OFFSET(CaseStatementInfo, next, 0xC); + + struct BreakStatementInfo + { + const char * codePos; //OFS: 0x0 SIZE: 0x4 + const char * nextCodePos; //OFS: 0x4 SIZE: 0x4 + BreakStatementInfo * next; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BreakStatementInfo, 0xC); + ASSERT_STRUCT_OFFSET(BreakStatementInfo, codePos, 0x0); + ASSERT_STRUCT_OFFSET(BreakStatementInfo, nextCodePos, 0x4); + ASSERT_STRUCT_OFFSET(BreakStatementInfo, next, 0x8); + + struct ContinueStatementInfo + { + const char * codePos; //OFS: 0x0 SIZE: 0x4 + const char * nextCodePos; //OFS: 0x4 SIZE: 0x4 + ContinueStatementInfo * next; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ContinueStatementInfo, 0xC); + ASSERT_STRUCT_OFFSET(ContinueStatementInfo, codePos, 0x0); + ASSERT_STRUCT_OFFSET(ContinueStatementInfo, nextCodePos, 0x4); + ASSERT_STRUCT_OFFSET(ContinueStatementInfo, next, 0x8); + + struct scr_localVar_t + { + unsigned int name; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scr_localVar_t, 0x4); + ASSERT_STRUCT_OFFSET(scr_localVar_t, name, 0x0); + + struct scr_block_s + { + int abortLevel; //OFS: 0x0 SIZE: 0x4 + int localVarsCreateCount; //OFS: 0x4 SIZE: 0x4 + int localVarsPublicCount; //OFS: 0x8 SIZE: 0x4 + int localVarsCount; //OFS: 0xC SIZE: 0x4 + unsigned __int8 localVarsInitBits[8]; //OFS: 0x10 SIZE: 0x8 + scr_localVar_t localVars[64]; //OFS: 0x18 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(scr_block_s, 0x118); + ASSERT_STRUCT_OFFSET(scr_block_s, abortLevel, 0x0); + ASSERT_STRUCT_OFFSET(scr_block_s, localVarsCreateCount, 0x4); + ASSERT_STRUCT_OFFSET(scr_block_s, localVarsPublicCount, 0x8); + ASSERT_STRUCT_OFFSET(scr_block_s, localVarsCount, 0xC); + ASSERT_STRUCT_OFFSET(scr_block_s, localVarsInitBits, 0x10); + ASSERT_STRUCT_OFFSET(scr_block_s, localVars, 0x18); + + struct PrecacheEntry + { + unsigned __int16 filename; //OFS: 0x0 SIZE: 0x2 + bool include; //OFS: 0x2 SIZE: 0x1 + unsigned int sourcePos; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PrecacheEntry, 0x8); + ASSERT_STRUCT_OFFSET(PrecacheEntry, filename, 0x0); + ASSERT_STRUCT_OFFSET(PrecacheEntry, include, 0x2); + ASSERT_STRUCT_OFFSET(PrecacheEntry, sourcePos, 0x4); + + union sval_u + { + char type; //OFS: 0x0 SIZE: 0x1 + unsigned int stringValue; //OFS: 0x1 SIZE: 0x4 + unsigned int idValue; //OFS: 0x2 SIZE: 0x4 + float floatValue; //OFS: 0x3 SIZE: 0x4 + int intValue; //OFS: 0x4 SIZE: 0x4 + sval_u * node; //OFS: 0x5 SIZE: 0x4 + unsigned int sourcePosValue; //OFS: 0x6 SIZE: 0x4 + const char * codePosValue; //OFS: 0x7 SIZE: 0x4 + const char * debugString; //OFS: 0x8 SIZE: 0x4 + scr_block_s * block; //OFS: 0x9 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sval_u, 0x4); + + struct VariableCompileValue + { + VariableValue value; //OFS: 0x0 SIZE: 0x8 + sval_u sourcePos; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VariableCompileValue, 0xC); + ASSERT_STRUCT_OFFSET(VariableCompileValue, value, 0x0); + ASSERT_STRUCT_OFFSET(VariableCompileValue, sourcePos, 0x8); + + struct scrCompileGlob_t + { + char * codePos; //OFS: 0x0 SIZE: 0x4 + char * prevOpcodePos; //OFS: 0x4 SIZE: 0x4 + unsigned int filePosId; //OFS: 0x8 SIZE: 0x4 + unsigned int fileCountId; //OFS: 0xC SIZE: 0x4 + int cumulOffset; //OFS: 0x10 SIZE: 0x4 + int maxOffset; //OFS: 0x14 SIZE: 0x4 + int maxCallOffset; //OFS: 0x18 SIZE: 0x4 + bool bConstRefCount; //OFS: 0x1C SIZE: 0x1 + bool in_developer_thread; //OFS: 0x1D SIZE: 0x1 + unsigned int developer_thread_sourcePos; //OFS: 0x20 SIZE: 0x4 + bool firstThread[2]; //OFS: 0x24 SIZE: 0x2 + CaseStatementInfo * currentCaseStatement; //OFS: 0x28 SIZE: 0x4 + bool bCanBreak; //OFS: 0x2C SIZE: 0x1 + BreakStatementInfo * currentBreakStatement; //OFS: 0x30 SIZE: 0x4 + bool bCanContinue; //OFS: 0x34 SIZE: 0x1 + ContinueStatementInfo * currentContinueStatement; //OFS: 0x38 SIZE: 0x4 + scr_block_s ** breakChildBlocks; //OFS: 0x3C SIZE: 0x4 + int * breakChildCount; //OFS: 0x40 SIZE: 0x4 + scr_block_s * breakBlock; //OFS: 0x44 SIZE: 0x4 + scr_block_s ** continueChildBlocks; //OFS: 0x48 SIZE: 0x4 + int * continueChildCount; //OFS: 0x4C SIZE: 0x4 + bool forceNotCreate; //OFS: 0x50 SIZE: 0x1 + PrecacheEntry * precachescriptList; //OFS: 0x54 SIZE: 0x4 + VariableCompileValue value_start[32]; //OFS: 0x58 SIZE: 0x180 + }; + ASSERT_STRUCT_SIZE(scrCompileGlob_t, 0x1D8); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, codePos, 0x0); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, prevOpcodePos, 0x4); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, filePosId, 0x8); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, fileCountId, 0xC); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, cumulOffset, 0x10); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, maxOffset, 0x14); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, maxCallOffset, 0x18); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, bConstRefCount, 0x1C); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, in_developer_thread, 0x1D); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, developer_thread_sourcePos, 0x20); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, firstThread, 0x24); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, currentCaseStatement, 0x28); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, bCanBreak, 0x2C); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, currentBreakStatement, 0x30); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, bCanContinue, 0x34); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, currentContinueStatement, 0x38); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, breakChildBlocks, 0x3C); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, breakChildCount, 0x40); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, breakBlock, 0x44); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, continueChildBlocks, 0x48); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, continueChildCount, 0x4C); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, forceNotCreate, 0x50); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, precachescriptList, 0x54); + ASSERT_STRUCT_OFFSET(scrCompileGlob_t, value_start, 0x58); + + struct scrCompilePub_t + { + int value_count; //OFS: 0x0 SIZE: 0x4 + int far_function_count; //OFS: 0x4 SIZE: 0x4 + unsigned int loadedscripts; //OFS: 0x8 SIZE: 0x4 + unsigned int scriptsPos; //OFS: 0xC SIZE: 0x4 + unsigned int scriptsCount; //OFS: 0x10 SIZE: 0x4 + unsigned int builtinFunc; //OFS: 0x14 SIZE: 0x4 + unsigned int builtinMeth; //OFS: 0x18 SIZE: 0x4 + unsigned __int16 canonicalStrings[65536]; //OFS: 0x1C SIZE: 0x20000 + const char * in_ptr; //OFS: 0x2001C SIZE: 0x4 + const char * parseBuf; //OFS: 0x20020 SIZE: 0x4 + bool script_loading; //OFS: 0x20024 SIZE: 0x1 + bool allowedBreakpoint; //OFS: 0x20025 SIZE: 0x1 + int developer_statement; //OFS: 0x20028 SIZE: 0x4 + char * opcodePos; //OFS: 0x2002C SIZE: 0x4 + unsigned int programLen; //OFS: 0x20030 SIZE: 0x4 + int func_table_size; //OFS: 0x20034 SIZE: 0x4 + int func_table[1024]; //OFS: 0x20038 SIZE: 0x1000 + }; + ASSERT_STRUCT_SIZE(scrCompilePub_t, 0x21038); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, value_count, 0x0); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, far_function_count, 0x4); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, loadedscripts, 0x8); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, scriptsPos, 0xC); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, scriptsCount, 0x10); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, builtinFunc, 0x14); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, builtinMeth, 0x18); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, canonicalStrings, 0x1C); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, in_ptr, 0x2001C); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, parseBuf, 0x20020); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, script_loading, 0x20024); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, allowedBreakpoint, 0x20025); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, developer_statement, 0x20028); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, opcodePos, 0x2002C); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, programLen, 0x20030); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, func_table_size, 0x20034); + ASSERT_STRUCT_OFFSET(scrCompilePub_t, func_table, 0x20038); + + struct __declspec(align(2)) XAnimParent + { + unsigned __int16 flags; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 children; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XAnimParent, 0x4); + ASSERT_STRUCT_OFFSET(XAnimParent, flags, 0x0); + ASSERT_STRUCT_OFFSET(XAnimParent, children, 0x2); + + struct XAnimEntry + { + unsigned __int16 bCreated; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 numAnims; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 parent; //OFS: 0x4 SIZE: 0x2 + __int16 field_6; //OFS: 0x6 SIZE: 0x2 + XAnimParent animParent; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimEntry, 0xC); + ASSERT_STRUCT_OFFSET(XAnimEntry, bCreated, 0x0); + ASSERT_STRUCT_OFFSET(XAnimEntry, numAnims, 0x2); + ASSERT_STRUCT_OFFSET(XAnimEntry, parent, 0x4); + ASSERT_STRUCT_OFFSET(XAnimEntry, field_6, 0x6); + ASSERT_STRUCT_OFFSET(XAnimEntry, animParent, 0x8); + + struct XAnim_s + { + char * debugName; //OFS: 0x0 SIZE: 0x4 + unsigned int size; //OFS: 0x4 SIZE: 0x4 + char ** debugAnimNames; //OFS: 0x8 SIZE: 0x4 + XAnimEntry entries[1]; //OFS: 0xC SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(XAnim_s, 0x18); + ASSERT_STRUCT_OFFSET(XAnim_s, debugName, 0x0); + ASSERT_STRUCT_OFFSET(XAnim_s, size, 0x4); + ASSERT_STRUCT_OFFSET(XAnim_s, debugAnimNames, 0x8); + ASSERT_STRUCT_OFFSET(XAnim_s, entries, 0xC); + + struct scr_animtree_t + { + XAnim_s * anims; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scr_animtree_t, 0x4); + ASSERT_STRUCT_OFFSET(scr_animtree_t, anims, 0x0); + + struct scrAnimPub_t + { + unsigned int animtrees; //OFS: 0x0 SIZE: 0x4 + unsigned int animtree_node; //OFS: 0x4 SIZE: 0x4 + unsigned int animTreeNames; //OFS: 0x8 SIZE: 0x4 + scr_animtree_t xanim_lookup[2][128]; //OFS: 0xC SIZE: 0x400 + unsigned int xanim_num[2]; //OFS: 0x40C SIZE: 0x8 + unsigned int animTreeIndex; //OFS: 0x414 SIZE: 0x4 + bool animtree_loading; //OFS: 0x418 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(scrAnimPub_t, 0x41C); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, animtrees, 0x0); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, animtree_node, 0x4); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, animTreeNames, 0x8); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, xanim_lookup, 0xC); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, xanim_num, 0x40C); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, animTreeIndex, 0x414); + ASSERT_STRUCT_OFFSET(scrAnimPub_t, animtree_loading, 0x418); + + struct scrAnimGlob_t + { + char * start; //OFS: 0x0 SIZE: 0x4 + char * pos; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 using_xanim_lookup[2][128]; //OFS: 0x8 SIZE: 0x200 + int bAnimCheck; //OFS: 0x208 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scrAnimGlob_t, 0x20C); + ASSERT_STRUCT_OFFSET(scrAnimGlob_t, start, 0x0); + ASSERT_STRUCT_OFFSET(scrAnimGlob_t, pos, 0x4); + ASSERT_STRUCT_OFFSET(scrAnimGlob_t, using_xanim_lookup, 0x8); + ASSERT_STRUCT_OFFSET(scrAnimGlob_t, bAnimCheck, 0x208); + + struct cscr_data_t + { + int delete_; //OFS: 0x0 SIZE: 0x4 + int initstructs; //OFS: 0x4 SIZE: 0x4 + int createstruct; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + int statechange; //OFS: 0x10 SIZE: 0x4 + int maprestart; //OFS: 0x14 SIZE: 0x4 + int localclientconnect; //OFS: 0x18 SIZE: 0x4 + int localclientdisconnect; //OFS: 0x1C SIZE: 0x4 + int entityspawned; //OFS: 0x20 SIZE: 0x4 + int scriptmodelspawned; //OFS: 0x24 SIZE: 0x4 + int playfootstep; //OFS: 0x28 SIZE: 0x4 + int activateexploder; //OFS: 0x2C SIZE: 0x4 + int deactivateexploder; //OFS: 0x30 SIZE: 0x4 + int levelnotify; //OFS: 0x34 SIZE: 0x4 + int field_38; //OFS: 0x38 SIZE: 0x4 + int field_3C; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cscr_data_t, 0x40); + ASSERT_STRUCT_OFFSET(cscr_data_t, delete_, 0x0); + ASSERT_STRUCT_OFFSET(cscr_data_t, initstructs, 0x4); + ASSERT_STRUCT_OFFSET(cscr_data_t, createstruct, 0x8); + ASSERT_STRUCT_OFFSET(cscr_data_t, field_C, 0xC); + ASSERT_STRUCT_OFFSET(cscr_data_t, statechange, 0x10); + ASSERT_STRUCT_OFFSET(cscr_data_t, maprestart, 0x14); + ASSERT_STRUCT_OFFSET(cscr_data_t, localclientconnect, 0x18); + ASSERT_STRUCT_OFFSET(cscr_data_t, localclientdisconnect, 0x1C); + ASSERT_STRUCT_OFFSET(cscr_data_t, entityspawned, 0x20); + ASSERT_STRUCT_OFFSET(cscr_data_t, scriptmodelspawned, 0x24); + ASSERT_STRUCT_OFFSET(cscr_data_t, playfootstep, 0x28); + ASSERT_STRUCT_OFFSET(cscr_data_t, activateexploder, 0x2C); + ASSERT_STRUCT_OFFSET(cscr_data_t, deactivateexploder, 0x30); + ASSERT_STRUCT_OFFSET(cscr_data_t, levelnotify, 0x34); + ASSERT_STRUCT_OFFSET(cscr_data_t, field_38, 0x38); + ASSERT_STRUCT_OFFSET(cscr_data_t, field_3C, 0x3C); + + struct __declspec(align(2)) cscr_const_t + { + unsigned __int16 movedone; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 rotatedone; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 entityshutdown; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 front_left; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 front_right; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 back_left; //OFS: 0xA SIZE: 0x2 + unsigned __int16 back_right; //OFS: 0xC SIZE: 0x2 + unsigned __int16 middle_left; //OFS: 0xE SIZE: 0x2 + unsigned __int16 middle_right; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 fraction; //OFS: 0x12 SIZE: 0x2 + unsigned __int16 position; //OFS: 0x14 SIZE: 0x2 + unsigned __int16 entity; //OFS: 0x16 SIZE: 0x2 + unsigned __int16 normal; //OFS: 0x18 SIZE: 0x2 + unsigned __int16 surfacetype; //OFS: 0x1A SIZE: 0x2 + unsigned __int16 weapon_fired; //OFS: 0x1C SIZE: 0x2 + unsigned __int16 none; //OFS: 0x1E SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(cscr_const_t, 0x20); + ASSERT_STRUCT_OFFSET(cscr_const_t, movedone, 0x0); + ASSERT_STRUCT_OFFSET(cscr_const_t, rotatedone, 0x2); + ASSERT_STRUCT_OFFSET(cscr_const_t, entityshutdown, 0x4); + ASSERT_STRUCT_OFFSET(cscr_const_t, front_left, 0x6); + ASSERT_STRUCT_OFFSET(cscr_const_t, front_right, 0x8); + ASSERT_STRUCT_OFFSET(cscr_const_t, back_left, 0xA); + ASSERT_STRUCT_OFFSET(cscr_const_t, back_right, 0xC); + ASSERT_STRUCT_OFFSET(cscr_const_t, middle_left, 0xE); + ASSERT_STRUCT_OFFSET(cscr_const_t, middle_right, 0x10); + ASSERT_STRUCT_OFFSET(cscr_const_t, fraction, 0x12); + ASSERT_STRUCT_OFFSET(cscr_const_t, position, 0x14); + ASSERT_STRUCT_OFFSET(cscr_const_t, entity, 0x16); + ASSERT_STRUCT_OFFSET(cscr_const_t, normal, 0x18); + ASSERT_STRUCT_OFFSET(cscr_const_t, surfacetype, 0x1A); + ASSERT_STRUCT_OFFSET(cscr_const_t, weapon_fired, 0x1C); + ASSERT_STRUCT_OFFSET(cscr_const_t, none, 0x1E); + + struct __declspec(align(2)) scr_entref_t + { + unsigned __int16 entnum; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 classnum; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 client; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(scr_entref_t, 0x6); + ASSERT_STRUCT_OFFSET(scr_entref_t, entnum, 0x0); + ASSERT_STRUCT_OFFSET(scr_entref_t, classnum, 0x2); + ASSERT_STRUCT_OFFSET(scr_entref_t, client, 0x4); + + struct __declspec(align(2)) scr_const_t + { + unsigned __int16 _; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 active2; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 j_spine4; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 j_helmet; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 j_head; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 all; //OFS: 0xA SIZE: 0x2 + unsigned __int16 allies; //OFS: 0xC SIZE: 0x2 + unsigned __int16 axis; //OFS: 0xE SIZE: 0x2 + unsigned __int16 bad_path; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 begin_firing; //OFS: 0x12 SIZE: 0x2 + unsigned __int16 unknown_location; //OFS: 0x14 SIZE: 0x2 + unsigned __int16 cancel_location; //OFS: 0x16 SIZE: 0x2 + unsigned __int16 confirm_location; //OFS: 0x18 SIZE: 0x2 + unsigned __int16 regroup_location; //OFS: 0x1A SIZE: 0x2 + unsigned __int16 defend_location; //OFS: 0x1C SIZE: 0x2 + unsigned __int16 clear_squadcommand; //OFS: 0x1E SIZE: 0x2 + unsigned __int16 squadleader_changed; //OFS: 0x20 SIZE: 0x2 + unsigned __int16 squad_disbanded; //OFS: 0x22 SIZE: 0x2 + unsigned __int16 deployed_turret; //OFS: 0x24 SIZE: 0x2 + unsigned __int16 crouch; //OFS: 0x26 SIZE: 0x2 + unsigned __int16 current; //OFS: 0x28 SIZE: 0x2 + unsigned __int16 damage; //OFS: 0x2A SIZE: 0x2 + unsigned __int16 dead; //OFS: 0x2C SIZE: 0x2 + unsigned __int16 death; //OFS: 0x2E SIZE: 0x2 + unsigned __int16 disconnect; //OFS: 0x30 SIZE: 0x2 + unsigned __int16 death_or_disconnect; //OFS: 0x32 SIZE: 0x2 + unsigned __int16 detonate; //OFS: 0x34 SIZE: 0x2 + unsigned __int16 direct; //OFS: 0x36 SIZE: 0x2 + unsigned __int16 dlight; //OFS: 0x38 SIZE: 0x2 + unsigned __int16 done; //OFS: 0x3A SIZE: 0x2 + unsigned __int16 empty; //OFS: 0x3C SIZE: 0x2 + unsigned __int16 end_firing; //OFS: 0x3E SIZE: 0x2 + unsigned __int16 enter_vehicle; //OFS: 0x40 SIZE: 0x2 + unsigned __int16 entity; //OFS: 0x42 SIZE: 0x2 + unsigned __int16 exit_vehicle; //OFS: 0x44 SIZE: 0x2 + unsigned __int16 change_seat; //OFS: 0x46 SIZE: 0x2 + unsigned __int16 vehicle_death; //OFS: 0x48 SIZE: 0x2 + unsigned __int16 explode; //OFS: 0x4A SIZE: 0x2 + unsigned __int16 failed; //OFS: 0x4C SIZE: 0x2 + unsigned __int16 free; //OFS: 0x4E SIZE: 0x2 + unsigned __int16 fraction; //OFS: 0x50 SIZE: 0x2 + unsigned __int16 goal; //OFS: 0x52 SIZE: 0x2 + unsigned __int16 goal_changed; //OFS: 0x54 SIZE: 0x2 + unsigned __int16 goal_yaw; //OFS: 0x56 SIZE: 0x2 + unsigned __int16 grenade; //OFS: 0x58 SIZE: 0x2 + unsigned __int16 grenade_danger; //OFS: 0x5A SIZE: 0x2 + unsigned __int16 grenade_fire; //OFS: 0x5C SIZE: 0x2 + unsigned __int16 grenade_launcher_fire; //OFS: 0x5E SIZE: 0x2 + unsigned __int16 grenade_pullback; //OFS: 0x60 SIZE: 0x2 + unsigned __int16 info_notnull; //OFS: 0x62 SIZE: 0x2 + unsigned __int16 invisible; //OFS: 0x64 SIZE: 0x2 + unsigned __int16 key1; //OFS: 0x66 SIZE: 0x2 + unsigned __int16 key2; //OFS: 0x68 SIZE: 0x2 + unsigned __int16 killanimscript; //OFS: 0x6A SIZE: 0x2 + unsigned __int16 left; //OFS: 0x6C SIZE: 0x2 + unsigned __int16 left_tread; //OFS: 0x6E SIZE: 0x2 + unsigned __int16 light; //OFS: 0x70 SIZE: 0x2 + unsigned __int16 movedone; //OFS: 0x72 SIZE: 0x2 + unsigned __int16 noclass; //OFS: 0x74 SIZE: 0x2 + unsigned __int16 none; //OFS: 0x76 SIZE: 0x2 + unsigned __int16 normal; //OFS: 0x78 SIZE: 0x2 + unsigned __int16 player; //OFS: 0x7A SIZE: 0x2 + unsigned __int16 position; //OFS: 0x7C SIZE: 0x2 + unsigned __int16 projectile_impact; //OFS: 0x7E SIZE: 0x2 + unsigned __int16 prone; //OFS: 0x80 SIZE: 0x2 + unsigned __int16 right; //OFS: 0x82 SIZE: 0x2 + unsigned __int16 right_tread; //OFS: 0x84 SIZE: 0x2 + unsigned __int16 tank_armor; //OFS: 0x86 SIZE: 0x2 + unsigned __int16 reload; //OFS: 0x88 SIZE: 0x2 + unsigned __int16 reload_start; //OFS: 0x8A SIZE: 0x2 + unsigned __int16 rocket; //OFS: 0x8C SIZE: 0x2 + unsigned __int16 rotatedone; //OFS: 0x8E SIZE: 0x2 + unsigned __int16 script_brushmodel; //OFS: 0x90 SIZE: 0x2 + unsigned __int16 script_model; //OFS: 0x92 SIZE: 0x2 + unsigned __int16 script_origin; //OFS: 0x94 SIZE: 0x2 + unsigned __int16 snd_enveffectsprio_level; //OFS: 0x96 SIZE: 0x2 + unsigned __int16 snd_enveffectsprio_shellshock; //OFS: 0x98 SIZE: 0x2 + unsigned __int16 snd_busvolprio_holdbreath; //OFS: 0x9A SIZE: 0x2 + unsigned __int16 snd_busvolprio_pain; //OFS: 0x9C SIZE: 0x2 + unsigned __int16 snd_busvolprio_shellshock; //OFS: 0x9E SIZE: 0x2 + unsigned __int16 stand; //OFS: 0xA0 SIZE: 0x2 + unsigned __int16 suppression; //OFS: 0xA2 SIZE: 0x2 + unsigned __int16 suppression_end; //OFS: 0xA4 SIZE: 0x2 + unsigned __int16 surfacetype; //OFS: 0xA6 SIZE: 0x2 + unsigned __int16 tag_aim; //OFS: 0xA8 SIZE: 0x2 + unsigned __int16 tag_aim_animated; //OFS: 0xAA SIZE: 0x2 + unsigned __int16 tag_brass; //OFS: 0xAC SIZE: 0x2 + unsigned __int16 tag_butt; //OFS: 0xAE SIZE: 0x2 + unsigned __int16 tag_clip; //OFS: 0xB0 SIZE: 0x2 + unsigned __int16 tag_flash; //OFS: 0xB2 SIZE: 0x2 + unsigned __int16 tag_flash_11; //OFS: 0xB4 SIZE: 0x2 + unsigned __int16 tag_flash_2; //OFS: 0xB6 SIZE: 0x2 + unsigned __int16 tag_flash_22; //OFS: 0xB8 SIZE: 0x2 + unsigned __int16 tag_flash_3; //OFS: 0xBA SIZE: 0x2 + unsigned __int16 tag_fx; //OFS: 0xBC SIZE: 0x2 + unsigned __int16 tag_inhand2; //OFS: 0xBE SIZE: 0x2 + unsigned __int16 tag_knife_attach; //OFS: 0xC0 SIZE: 0x2 + unsigned __int16 tag_knife_fx; //OFS: 0xC2 SIZE: 0x2 + unsigned __int16 tag_bayonet; //OFS: 0xC4 SIZE: 0x2 + unsigned __int16 tag_laser; //OFS: 0xC6 SIZE: 0x2 + unsigned __int16 tag_origin; //OFS: 0xC8 SIZE: 0x2 + unsigned __int16 tag_weapon; //OFS: 0xCA SIZE: 0x2 + unsigned __int16 tag_player2; //OFS: 0xCC SIZE: 0x2 + unsigned __int16 tag_camera; //OFS: 0xCE SIZE: 0x2 + unsigned __int16 tag_weapon_right; //OFS: 0xD0 SIZE: 0x2 + unsigned __int16 tag_gasmask; //OFS: 0xD2 SIZE: 0x2 + unsigned __int16 tag_gasmask2; //OFS: 0xD4 SIZE: 0x2 + unsigned __int16 tag_sync; //OFS: 0xD6 SIZE: 0x2 + unsigned __int16 tag_wake; //OFS: 0xD8 SIZE: 0x2 + unsigned __int16 target_script_trigger; //OFS: 0xDA SIZE: 0x2 + unsigned __int16 tempEntity; //OFS: 0xDC SIZE: 0x2 + unsigned __int16 top; //OFS: 0xDE SIZE: 0x2 + unsigned __int16 touch; //OFS: 0xE0 SIZE: 0x2 + unsigned __int16 trigger; //OFS: 0xE2 SIZE: 0x2 + unsigned __int16 trigger_use; //OFS: 0xE4 SIZE: 0x2 + unsigned __int16 trigger_use_touch; //OFS: 0xE6 SIZE: 0x2 + unsigned __int16 trigger_damage; //OFS: 0xE8 SIZE: 0x2 + unsigned __int16 trigger_lookat; //OFS: 0xEA SIZE: 0x2 + unsigned __int16 trigger_radius; //OFS: 0xEC SIZE: 0x2 + unsigned __int16 truck_cam; //OFS: 0xEE SIZE: 0x2 + unsigned __int16 weapon_change_on_turret; //OFS: 0xF0 SIZE: 0x2 + unsigned __int16 weapon_change; //OFS: 0xF2 SIZE: 0x2 + unsigned __int16 weapon_change_complete; //OFS: 0xF4 SIZE: 0x2 + unsigned __int16 weapon_fired; //OFS: 0xF6 SIZE: 0x2 + unsigned __int16 weapon_pvp_attack; //OFS: 0xF8 SIZE: 0x2 + unsigned __int16 worldspawn; //OFS: 0xFA SIZE: 0x2 + unsigned __int16 flashbang; //OFS: 0xFC SIZE: 0x2 + unsigned __int16 flash; //OFS: 0xFE SIZE: 0x2 + unsigned __int16 smoke; //OFS: 0x100 SIZE: 0x2 + unsigned __int16 night_vision_on; //OFS: 0x102 SIZE: 0x2 + unsigned __int16 night_vision_off; //OFS: 0x104 SIZE: 0x2 + unsigned __int16 back_low; //OFS: 0x106 SIZE: 0x2 + unsigned __int16 back_mid; //OFS: 0x108 SIZE: 0x2 + unsigned __int16 back_up; //OFS: 0x10A SIZE: 0x2 + unsigned __int16 head; //OFS: 0x10C SIZE: 0x2 + unsigned __int16 j_mainroot; //OFS: 0x10E SIZE: 0x2 + unsigned __int16 neck; //OFS: 0x110 SIZE: 0x2 + unsigned __int16 pelvis; //OFS: 0x112 SIZE: 0x2 + unsigned __int16 j_head2; //OFS: 0x114 SIZE: 0x2 + unsigned __int16 MOD_UNKNOWN; //OFS: 0x116 SIZE: 0x2 + unsigned __int16 MOD_PISTOL_BULLET; //OFS: 0x118 SIZE: 0x2 + unsigned __int16 MOD_RIFLE_BULLET; //OFS: 0x11A SIZE: 0x2 + unsigned __int16 MOD_GRENADE; //OFS: 0x11C SIZE: 0x2 + unsigned __int16 MOD_GRENADE_SPLASH; //OFS: 0x11E SIZE: 0x2 + unsigned __int16 MOD_PROJECTILE; //OFS: 0x120 SIZE: 0x2 + unsigned __int16 MOD_PROJECTILE_SPLASH; //OFS: 0x122 SIZE: 0x2 + unsigned __int16 MOD_MELEE; //OFS: 0x124 SIZE: 0x2 + unsigned __int16 MOD_BAYONET; //OFS: 0x126 SIZE: 0x2 + unsigned __int16 MOD_HEAD_SHOT; //OFS: 0x128 SIZE: 0x2 + unsigned __int16 MOD_CRUSH; //OFS: 0x12A SIZE: 0x2 + unsigned __int16 MOD_TELEFRAG; //OFS: 0x12C SIZE: 0x2 + unsigned __int16 MOD_FALLING; //OFS: 0x12E SIZE: 0x2 + unsigned __int16 MOD_SUICIDE; //OFS: 0x130 SIZE: 0x2 + unsigned __int16 MOD_TRIGGER_HURT; //OFS: 0x132 SIZE: 0x2 + unsigned __int16 MOD_EXPLOSIVE; //OFS: 0x134 SIZE: 0x2 + unsigned __int16 MOD_IMPACT; //OFS: 0x136 SIZE: 0x2 + unsigned __int16 MOD_BURNED; //OFS: 0x138 SIZE: 0x2 + unsigned __int16 MOD_HIT_BY_OBJECT; //OFS: 0x13A SIZE: 0x2 + unsigned __int16 MOD_DROWN; //OFS: 0x13C SIZE: 0x2 + unsigned __int16 script_vehicle; //OFS: 0x13E SIZE: 0x2 + unsigned __int16 script_vehicle_collision; //OFS: 0x140 SIZE: 0x2 + unsigned __int16 script_vehicle_collmap; //OFS: 0x142 SIZE: 0x2 + unsigned __int16 script_vehicle_corpse; //OFS: 0x144 SIZE: 0x2 + unsigned __int16 turret_fire; //OFS: 0x146 SIZE: 0x2 + unsigned __int16 turret_on_target; //OFS: 0x148 SIZE: 0x2 + unsigned __int16 turret_not_on_target; //OFS: 0x14A SIZE: 0x2 + unsigned __int16 turret_on_vistarget; //OFS: 0x14C SIZE: 0x2 + unsigned __int16 turret_no_vis; //OFS: 0x14E SIZE: 0x2 + unsigned __int16 turret_rotate_stopped; //OFS: 0x150 SIZE: 0x2 + unsigned __int16 turret_deactivate; //OFS: 0x152 SIZE: 0x2 + unsigned __int16 turretstatechange; //OFS: 0x154 SIZE: 0x2 + unsigned __int16 turretownerchange; //OFS: 0x156 SIZE: 0x2 + unsigned __int16 reached_end_node; //OFS: 0x158 SIZE: 0x2 + unsigned __int16 reached_wait_node; //OFS: 0x15A SIZE: 0x2 + unsigned __int16 reached_wait_speed; //OFS: 0x15C SIZE: 0x2 + unsigned __int16 near_goal; //OFS: 0x15E SIZE: 0x2 + unsigned __int16 veh_collision; //OFS: 0x160 SIZE: 0x2 + unsigned __int16 veh_predictedcollision; //OFS: 0x162 SIZE: 0x2 + unsigned __int16 script_camera; //OFS: 0x164 SIZE: 0x2 + unsigned __int16 begin; //OFS: 0x166 SIZE: 0x2 + unsigned __int16 curve_nodehit; //OFS: 0x168 SIZE: 0x2 + unsigned __int16 curve_start; //OFS: 0x16A SIZE: 0x2 + unsigned __int16 curve_end; //OFS: 0x16C SIZE: 0x2 + unsigned __int16 tag_enter_driver; //OFS: 0x16E SIZE: 0x2 + unsigned __int16 tag_enter_gunner1; //OFS: 0x170 SIZE: 0x2 + unsigned __int16 tag_enter_gunner2; //OFS: 0x172 SIZE: 0x2 + unsigned __int16 tag_enter_gunner3; //OFS: 0x174 SIZE: 0x2 + unsigned __int16 tag_enter_gunner4; //OFS: 0x176 SIZE: 0x2 + unsigned __int16 tag_enter_passenger; //OFS: 0x178 SIZE: 0x2 + unsigned __int16 tag_enter_passenger2; //OFS: 0x17A SIZE: 0x2 + unsigned __int16 tag_enter_passenger3; //OFS: 0x17C SIZE: 0x2 + unsigned __int16 tag_enter_passenger4; //OFS: 0x17E SIZE: 0x2 + unsigned __int16 tag_player; //OFS: 0x180 SIZE: 0x2 + unsigned __int16 tag_passenger1; //OFS: 0x182 SIZE: 0x2 + unsigned __int16 tag_passenger2; //OFS: 0x184 SIZE: 0x2 + unsigned __int16 tag_passenger3; //OFS: 0x186 SIZE: 0x2 + unsigned __int16 tag_passenger4; //OFS: 0x188 SIZE: 0x2 + unsigned __int16 tag_gunner1; //OFS: 0x18A SIZE: 0x2 + unsigned __int16 tag_gunner2; //OFS: 0x18C SIZE: 0x2 + unsigned __int16 tag_gunner3; //OFS: 0x18E SIZE: 0x2 + unsigned __int16 tag_gunner4; //OFS: 0x190 SIZE: 0x2 + unsigned __int16 tag_gunner_barrel1; //OFS: 0x192 SIZE: 0x2 + unsigned __int16 tag_gunner_barrel2; //OFS: 0x194 SIZE: 0x2 + unsigned __int16 tag_gunner_barrel3; //OFS: 0x196 SIZE: 0x2 + unsigned __int16 tag_gunner_barrel4; //OFS: 0x198 SIZE: 0x2 + unsigned __int16 tag_gunner_turret1; //OFS: 0x19A SIZE: 0x2 + unsigned __int16 tag_gunner_turret2; //OFS: 0x19C SIZE: 0x2 + unsigned __int16 tag_gunner_turret3; //OFS: 0x19E SIZE: 0x2 + unsigned __int16 tag_gunner_turret4; //OFS: 0x1A0 SIZE: 0x2 + unsigned __int16 tag_flash_gunner1; //OFS: 0x1A2 SIZE: 0x2 + unsigned __int16 tag_flash_gunner2; //OFS: 0x1A4 SIZE: 0x2 + unsigned __int16 tag_flash_gunner3; //OFS: 0x1A6 SIZE: 0x2 + unsigned __int16 tag_flash_gunner4; //OFS: 0x1A8 SIZE: 0x2 + unsigned __int16 tag_flash_gunner1a; //OFS: 0x1AA SIZE: 0x2 + unsigned __int16 tag_flash_gunner2a; //OFS: 0x1AC SIZE: 0x2 + unsigned __int16 tag_flash_gunner3a; //OFS: 0x1AE SIZE: 0x2 + unsigned __int16 tag_flash_gunner4a; //OFS: 0x1B0 SIZE: 0x2 + unsigned __int16 tag_gunner_brass1; //OFS: 0x1B2 SIZE: 0x2 + unsigned __int16 tag_gunner_hands1; //OFS: 0x1B4 SIZE: 0x2 + unsigned __int16 tag_wheel_front_left; //OFS: 0x1B6 SIZE: 0x2 + unsigned __int16 tag_wheel_front_right; //OFS: 0x1B8 SIZE: 0x2 + unsigned __int16 tag_wheel_back_left; //OFS: 0x1BA SIZE: 0x2 + unsigned __int16 tag_wheel_back_right; //OFS: 0x1BC SIZE: 0x2 + unsigned __int16 tag_wheel_middle_left; //OFS: 0x1BE SIZE: 0x2 + unsigned __int16 tag_wheel_middle_right; //OFS: 0x1C0 SIZE: 0x2 + unsigned __int16 vampire_health_regen; //OFS: 0x1C2 SIZE: 0x2 + unsigned __int16 vampire_kill; //OFS: 0x1C4 SIZE: 0x2 + unsigned __int16 morphine_shot; //OFS: 0x1C6 SIZE: 0x2 + unsigned __int16 morphine_revive; //OFS: 0x1C8 SIZE: 0x2 + unsigned __int16 freelook; //OFS: 0x1CA SIZE: 0x2 + unsigned __int16 intermission; //OFS: 0x1CC SIZE: 0x2 + unsigned __int16 playing; //OFS: 0x1CE SIZE: 0x2 + unsigned __int16 spectator; //OFS: 0x1D0 SIZE: 0x2 + unsigned __int16 action_notify_attack; //OFS: 0x1D2 SIZE: 0x2 + unsigned __int16 action_notify_melee; //OFS: 0x1D4 SIZE: 0x2 + unsigned __int16 action_notify_use_reload; //OFS: 0x1D6 SIZE: 0x2 + unsigned __int16 always; //OFS: 0x1D8 SIZE: 0x2 + unsigned __int16 auto_ai; //OFS: 0x1DA SIZE: 0x2 + unsigned __int16 auto_nonai; //OFS: 0x1DC SIZE: 0x2 + unsigned __int16 back_left; //OFS: 0x1DE SIZE: 0x2 + unsigned __int16 back_right; //OFS: 0x1E0 SIZE: 0x2 + unsigned __int16 begin_custom_anim; //OFS: 0x1E2 SIZE: 0x2 + unsigned __int16 bullethit; //OFS: 0x1E4 SIZE: 0x2 + unsigned __int16 count; //OFS: 0x1E6 SIZE: 0x2 + unsigned __int16 corner_approach; //OFS: 0x1E8 SIZE: 0x2 + unsigned __int16 damage_notdone; //OFS: 0x1EA SIZE: 0x2 + unsigned __int16 deathplant; //OFS: 0x1EC SIZE: 0x2 + unsigned __int16 front_left; //OFS: 0x1EE SIZE: 0x2 + unsigned __int16 front_right; //OFS: 0x1F0 SIZE: 0x2 + unsigned __int16 tag_inhand; //OFS: 0x1F2 SIZE: 0x2 + unsigned __int16 high_priority; //OFS: 0x1F4 SIZE: 0x2 + unsigned __int16 info_player_deathmatch; //OFS: 0x1F6 SIZE: 0x2 + unsigned __int16 infinite_energy; //OFS: 0x1F8 SIZE: 0x2 + unsigned __int16 low_priority; //OFS: 0x1FA SIZE: 0x2 + unsigned __int16 manual; //OFS: 0x1FC SIZE: 0x2 + unsigned __int16 manual_ai; //OFS: 0x1FE SIZE: 0x2 + unsigned __int16 max_time; //OFS: 0x200 SIZE: 0x2 + unsigned __int16 menuresponse; //OFS: 0x202 SIZE: 0x2 + unsigned __int16 middle_left; //OFS: 0x204 SIZE: 0x2 + unsigned __int16 middle_right; //OFS: 0x206 SIZE: 0x2 + unsigned __int16 min_energy; //OFS: 0x208 SIZE: 0x2 + unsigned __int16 min_time; //OFS: 0x20A SIZE: 0x2 + unsigned __int16 neutral; //OFS: 0x20C SIZE: 0x2 + unsigned __int16 never; //OFS: 0x20E SIZE: 0x2 + unsigned __int16 pickup; //OFS: 0x210 SIZE: 0x2 + unsigned __int16 receiver; //OFS: 0x212 SIZE: 0x2 + unsigned __int16 sound_blend; //OFS: 0x214 SIZE: 0x2 + unsigned __int16 tag_wingtipl; //OFS: 0x216 SIZE: 0x2 + unsigned __int16 tag_wingtipr; //OFS: 0x218 SIZE: 0x2 + unsigned __int16 tag_wingmidl; //OFS: 0x21A SIZE: 0x2 + unsigned __int16 tag_wingmidr; //OFS: 0x21C SIZE: 0x2 + unsigned __int16 tag_prop; //OFS: 0x21E SIZE: 0x2 + unsigned __int16 tag_end; //OFS: 0x220 SIZE: 0x2 + unsigned __int16 tag_tailtop; //OFS: 0x222 SIZE: 0x2 + unsigned __int16 tag_tailbottom; //OFS: 0x224 SIZE: 0x2 + unsigned __int16 tag_detach; //OFS: 0x226 SIZE: 0x2 + unsigned __int16 tag_passenger; //OFS: 0x228 SIZE: 0x2 + unsigned __int16 tag_enter_back; //OFS: 0x22A SIZE: 0x2 + unsigned __int16 tag_detach2; //OFS: 0x22C SIZE: 0x2 + unsigned __int16 tag_popout; //OFS: 0x22E SIZE: 0x2 + unsigned __int16 tag_body; //OFS: 0x230 SIZE: 0x2 + unsigned __int16 tag_turret; //OFS: 0x232 SIZE: 0x2 + unsigned __int16 tag_turret_base; //OFS: 0x234 SIZE: 0x2 + unsigned __int16 tag_barrel; //OFS: 0x236 SIZE: 0x2 + unsigned __int16 tag_weapon_left; //OFS: 0x238 SIZE: 0x2 + unsigned __int16 human; //OFS: 0x23A SIZE: 0x2 + unsigned __int16 custom; //OFS: 0x23C SIZE: 0x2 + unsigned __int16 angle_deltas; //OFS: 0x23E SIZE: 0x2 + unsigned __int16 bulletwhizby; //OFS: 0x240 SIZE: 0x2 + unsigned __int16 dog; //OFS: 0x242 SIZE: 0x2 + unsigned __int16 enemy; //OFS: 0x244 SIZE: 0x2 + unsigned __int16 enemy_visible; //OFS: 0x246 SIZE: 0x2 + unsigned __int16 face_angle; //OFS: 0x248 SIZE: 0x2 + unsigned __int16 face_current; //OFS: 0x24A SIZE: 0x2 + unsigned __int16 face_default; //OFS: 0x24C SIZE: 0x2 + unsigned __int16 face_direction; //OFS: 0x24E SIZE: 0x2 + unsigned __int16 face_enemy; //OFS: 0x250 SIZE: 0x2 + unsigned __int16 face_enemy_or_motion; //OFS: 0x252 SIZE: 0x2 + unsigned __int16 face_goal; //OFS: 0x254 SIZE: 0x2 + unsigned __int16 face_motion; //OFS: 0x256 SIZE: 0x2 + unsigned __int16 face_point; //OFS: 0x258 SIZE: 0x2 + unsigned __int16 gravity; //OFS: 0x25A SIZE: 0x2 + unsigned __int16 groundEntChanged; //OFS: 0x25C SIZE: 0x2 + unsigned __int16 gunshot; //OFS: 0x25E SIZE: 0x2 + unsigned __int16 obstacle; //OFS: 0x260 SIZE: 0x2 + unsigned __int16 movemode; //OFS: 0x262 SIZE: 0x2 + unsigned __int16 node_out_of_range; //OFS: 0x264 SIZE: 0x2 + unsigned __int16 node_relinquished; //OFS: 0x266 SIZE: 0x2 + unsigned __int16 node_taken; //OFS: 0x268 SIZE: 0x2 + unsigned __int16 node_not_safe; //OFS: 0x26A SIZE: 0x2 + unsigned __int16 noclip; //OFS: 0x26C SIZE: 0x2 + unsigned __int16 nogravity; //OFS: 0x26E SIZE: 0x2 + unsigned __int16 nophysics; //OFS: 0x270 SIZE: 0x2 + unsigned __int16 pain; //OFS: 0x272 SIZE: 0x2 + unsigned __int16 run; //OFS: 0x274 SIZE: 0x2 + unsigned __int16 runto_arrived; //OFS: 0x276 SIZE: 0x2 + unsigned __int16 silenced_shot; //OFS: 0x278 SIZE: 0x2 + unsigned __int16 spawned; //OFS: 0x27A SIZE: 0x2 + unsigned __int16 start_move; //OFS: 0x27C SIZE: 0x2 + unsigned __int16 stop; //OFS: 0x27E SIZE: 0x2 + unsigned __int16 stop_soon; //OFS: 0x280 SIZE: 0x2 + unsigned __int16 tag_eye; //OFS: 0x282 SIZE: 0x2 + unsigned __int16 walk; //OFS: 0x284 SIZE: 0x2 + unsigned __int16 world; //OFS: 0x286 SIZE: 0x2 + unsigned __int16 zonly_physics; //OFS: 0x288 SIZE: 0x2 + unsigned __int16 j_ankle_le; //OFS: 0x28A SIZE: 0x2 + unsigned __int16 j_ankle_ri; //OFS: 0x28C SIZE: 0x2 + unsigned __int16 j_ball_le; //OFS: 0x28E SIZE: 0x2 + unsigned __int16 j_ball_ri; //OFS: 0x290 SIZE: 0x2 + unsigned __int16 j_palm_le; //OFS: 0x292 SIZE: 0x2 + unsigned __int16 j_palm_ri; //OFS: 0x294 SIZE: 0x2 + unsigned __int16 broken; //OFS: 0x296 SIZE: 0x2 + unsigned __int16 destructible; //OFS: 0x298 SIZE: 0x2 + unsigned __int16 snapacknowledged; //OFS: 0x29A SIZE: 0x2 + unsigned __int16 disconnected; //OFS: 0x29C SIZE: 0x2 + unsigned __int16 cinematic; //OFS: 0x29E SIZE: 0x2 + unsigned __int16 uicinematic; //OFS: 0x2A0 SIZE: 0x2 + unsigned __int16 logo; //OFS: 0x2A2 SIZE: 0x2 + unsigned __int16 connecting; //OFS: 0x2A4 SIZE: 0x2 + unsigned __int16 challenging; //OFS: 0x2A6 SIZE: 0x2 + unsigned __int16 connected; //OFS: 0x2A8 SIZE: 0x2 + unsigned __int16 sendingstats; //OFS: 0x2AA SIZE: 0x2 + unsigned __int16 loading; //OFS: 0x2AC SIZE: 0x2 + unsigned __int16 primed; //OFS: 0x2AE SIZE: 0x2 + unsigned __int16 active; //OFS: 0x2B0 SIZE: 0x2 + unsigned __int16 map_restart; //OFS: 0x2B2 SIZE: 0x2 + unsigned __int16 orientdone; //OFS: 0x2B4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(scr_const_t, 0x2B6); + ASSERT_STRUCT_OFFSET(scr_const_t, _, 0x0); + ASSERT_STRUCT_OFFSET(scr_const_t, active2, 0x2); + ASSERT_STRUCT_OFFSET(scr_const_t, j_spine4, 0x4); + ASSERT_STRUCT_OFFSET(scr_const_t, j_helmet, 0x6); + ASSERT_STRUCT_OFFSET(scr_const_t, j_head, 0x8); + ASSERT_STRUCT_OFFSET(scr_const_t, all, 0xA); + ASSERT_STRUCT_OFFSET(scr_const_t, allies, 0xC); + ASSERT_STRUCT_OFFSET(scr_const_t, axis, 0xE); + ASSERT_STRUCT_OFFSET(scr_const_t, bad_path, 0x10); + ASSERT_STRUCT_OFFSET(scr_const_t, begin_firing, 0x12); + ASSERT_STRUCT_OFFSET(scr_const_t, unknown_location, 0x14); + ASSERT_STRUCT_OFFSET(scr_const_t, cancel_location, 0x16); + ASSERT_STRUCT_OFFSET(scr_const_t, confirm_location, 0x18); + ASSERT_STRUCT_OFFSET(scr_const_t, regroup_location, 0x1A); + ASSERT_STRUCT_OFFSET(scr_const_t, defend_location, 0x1C); + ASSERT_STRUCT_OFFSET(scr_const_t, clear_squadcommand, 0x1E); + ASSERT_STRUCT_OFFSET(scr_const_t, squadleader_changed, 0x20); + ASSERT_STRUCT_OFFSET(scr_const_t, squad_disbanded, 0x22); + ASSERT_STRUCT_OFFSET(scr_const_t, deployed_turret, 0x24); + ASSERT_STRUCT_OFFSET(scr_const_t, crouch, 0x26); + ASSERT_STRUCT_OFFSET(scr_const_t, current, 0x28); + ASSERT_STRUCT_OFFSET(scr_const_t, damage, 0x2A); + ASSERT_STRUCT_OFFSET(scr_const_t, dead, 0x2C); + ASSERT_STRUCT_OFFSET(scr_const_t, death, 0x2E); + ASSERT_STRUCT_OFFSET(scr_const_t, disconnect, 0x30); + ASSERT_STRUCT_OFFSET(scr_const_t, death_or_disconnect, 0x32); + ASSERT_STRUCT_OFFSET(scr_const_t, detonate, 0x34); + ASSERT_STRUCT_OFFSET(scr_const_t, direct, 0x36); + ASSERT_STRUCT_OFFSET(scr_const_t, dlight, 0x38); + ASSERT_STRUCT_OFFSET(scr_const_t, done, 0x3A); + ASSERT_STRUCT_OFFSET(scr_const_t, empty, 0x3C); + ASSERT_STRUCT_OFFSET(scr_const_t, end_firing, 0x3E); + ASSERT_STRUCT_OFFSET(scr_const_t, enter_vehicle, 0x40); + ASSERT_STRUCT_OFFSET(scr_const_t, entity, 0x42); + ASSERT_STRUCT_OFFSET(scr_const_t, exit_vehicle, 0x44); + ASSERT_STRUCT_OFFSET(scr_const_t, change_seat, 0x46); + ASSERT_STRUCT_OFFSET(scr_const_t, vehicle_death, 0x48); + ASSERT_STRUCT_OFFSET(scr_const_t, explode, 0x4A); + ASSERT_STRUCT_OFFSET(scr_const_t, failed, 0x4C); + ASSERT_STRUCT_OFFSET(scr_const_t, free, 0x4E); + ASSERT_STRUCT_OFFSET(scr_const_t, fraction, 0x50); + ASSERT_STRUCT_OFFSET(scr_const_t, goal, 0x52); + ASSERT_STRUCT_OFFSET(scr_const_t, goal_changed, 0x54); + ASSERT_STRUCT_OFFSET(scr_const_t, goal_yaw, 0x56); + ASSERT_STRUCT_OFFSET(scr_const_t, grenade, 0x58); + ASSERT_STRUCT_OFFSET(scr_const_t, grenade_danger, 0x5A); + ASSERT_STRUCT_OFFSET(scr_const_t, grenade_fire, 0x5C); + ASSERT_STRUCT_OFFSET(scr_const_t, grenade_launcher_fire, 0x5E); + ASSERT_STRUCT_OFFSET(scr_const_t, grenade_pullback, 0x60); + ASSERT_STRUCT_OFFSET(scr_const_t, info_notnull, 0x62); + ASSERT_STRUCT_OFFSET(scr_const_t, invisible, 0x64); + ASSERT_STRUCT_OFFSET(scr_const_t, key1, 0x66); + ASSERT_STRUCT_OFFSET(scr_const_t, key2, 0x68); + ASSERT_STRUCT_OFFSET(scr_const_t, killanimscript, 0x6A); + ASSERT_STRUCT_OFFSET(scr_const_t, left, 0x6C); + ASSERT_STRUCT_OFFSET(scr_const_t, left_tread, 0x6E); + ASSERT_STRUCT_OFFSET(scr_const_t, light, 0x70); + ASSERT_STRUCT_OFFSET(scr_const_t, movedone, 0x72); + ASSERT_STRUCT_OFFSET(scr_const_t, noclass, 0x74); + ASSERT_STRUCT_OFFSET(scr_const_t, none, 0x76); + ASSERT_STRUCT_OFFSET(scr_const_t, normal, 0x78); + ASSERT_STRUCT_OFFSET(scr_const_t, player, 0x7A); + ASSERT_STRUCT_OFFSET(scr_const_t, position, 0x7C); + ASSERT_STRUCT_OFFSET(scr_const_t, projectile_impact, 0x7E); + ASSERT_STRUCT_OFFSET(scr_const_t, prone, 0x80); + ASSERT_STRUCT_OFFSET(scr_const_t, right, 0x82); + ASSERT_STRUCT_OFFSET(scr_const_t, right_tread, 0x84); + ASSERT_STRUCT_OFFSET(scr_const_t, tank_armor, 0x86); + ASSERT_STRUCT_OFFSET(scr_const_t, reload, 0x88); + ASSERT_STRUCT_OFFSET(scr_const_t, reload_start, 0x8A); + ASSERT_STRUCT_OFFSET(scr_const_t, rocket, 0x8C); + ASSERT_STRUCT_OFFSET(scr_const_t, rotatedone, 0x8E); + ASSERT_STRUCT_OFFSET(scr_const_t, script_brushmodel, 0x90); + ASSERT_STRUCT_OFFSET(scr_const_t, script_model, 0x92); + ASSERT_STRUCT_OFFSET(scr_const_t, script_origin, 0x94); + ASSERT_STRUCT_OFFSET(scr_const_t, snd_enveffectsprio_level, 0x96); + ASSERT_STRUCT_OFFSET(scr_const_t, snd_enveffectsprio_shellshock, 0x98); + ASSERT_STRUCT_OFFSET(scr_const_t, snd_busvolprio_holdbreath, 0x9A); + ASSERT_STRUCT_OFFSET(scr_const_t, snd_busvolprio_pain, 0x9C); + ASSERT_STRUCT_OFFSET(scr_const_t, snd_busvolprio_shellshock, 0x9E); + ASSERT_STRUCT_OFFSET(scr_const_t, stand, 0xA0); + ASSERT_STRUCT_OFFSET(scr_const_t, suppression, 0xA2); + ASSERT_STRUCT_OFFSET(scr_const_t, suppression_end, 0xA4); + ASSERT_STRUCT_OFFSET(scr_const_t, surfacetype, 0xA6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_aim, 0xA8); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_aim_animated, 0xAA); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_brass, 0xAC); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_butt, 0xAE); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_clip, 0xB0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash, 0xB2); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_11, 0xB4); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_2, 0xB6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_22, 0xB8); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_3, 0xBA); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_fx, 0xBC); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_inhand2, 0xBE); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_knife_attach, 0xC0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_knife_fx, 0xC2); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_bayonet, 0xC4); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_laser, 0xC6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_origin, 0xC8); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_weapon, 0xCA); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_player2, 0xCC); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_camera, 0xCE); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_weapon_right, 0xD0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gasmask, 0xD2); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gasmask2, 0xD4); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_sync, 0xD6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wake, 0xD8); + ASSERT_STRUCT_OFFSET(scr_const_t, target_script_trigger, 0xDA); + ASSERT_STRUCT_OFFSET(scr_const_t, tempEntity, 0xDC); + ASSERT_STRUCT_OFFSET(scr_const_t, top, 0xDE); + ASSERT_STRUCT_OFFSET(scr_const_t, touch, 0xE0); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger, 0xE2); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger_use, 0xE4); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger_use_touch, 0xE6); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger_damage, 0xE8); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger_lookat, 0xEA); + ASSERT_STRUCT_OFFSET(scr_const_t, trigger_radius, 0xEC); + ASSERT_STRUCT_OFFSET(scr_const_t, truck_cam, 0xEE); + ASSERT_STRUCT_OFFSET(scr_const_t, weapon_change_on_turret, 0xF0); + ASSERT_STRUCT_OFFSET(scr_const_t, weapon_change, 0xF2); + ASSERT_STRUCT_OFFSET(scr_const_t, weapon_change_complete, 0xF4); + ASSERT_STRUCT_OFFSET(scr_const_t, weapon_fired, 0xF6); + ASSERT_STRUCT_OFFSET(scr_const_t, weapon_pvp_attack, 0xF8); + ASSERT_STRUCT_OFFSET(scr_const_t, worldspawn, 0xFA); + ASSERT_STRUCT_OFFSET(scr_const_t, flashbang, 0xFC); + ASSERT_STRUCT_OFFSET(scr_const_t, flash, 0xFE); + ASSERT_STRUCT_OFFSET(scr_const_t, smoke, 0x100); + ASSERT_STRUCT_OFFSET(scr_const_t, night_vision_on, 0x102); + ASSERT_STRUCT_OFFSET(scr_const_t, night_vision_off, 0x104); + ASSERT_STRUCT_OFFSET(scr_const_t, back_low, 0x106); + ASSERT_STRUCT_OFFSET(scr_const_t, back_mid, 0x108); + ASSERT_STRUCT_OFFSET(scr_const_t, back_up, 0x10A); + ASSERT_STRUCT_OFFSET(scr_const_t, head, 0x10C); + ASSERT_STRUCT_OFFSET(scr_const_t, j_mainroot, 0x10E); + ASSERT_STRUCT_OFFSET(scr_const_t, neck, 0x110); + ASSERT_STRUCT_OFFSET(scr_const_t, pelvis, 0x112); + ASSERT_STRUCT_OFFSET(scr_const_t, j_head2, 0x114); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_UNKNOWN, 0x116); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_PISTOL_BULLET, 0x118); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_RIFLE_BULLET, 0x11A); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_GRENADE, 0x11C); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_GRENADE_SPLASH, 0x11E); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_PROJECTILE, 0x120); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_PROJECTILE_SPLASH, 0x122); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_MELEE, 0x124); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_BAYONET, 0x126); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_HEAD_SHOT, 0x128); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_CRUSH, 0x12A); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_TELEFRAG, 0x12C); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_FALLING, 0x12E); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_SUICIDE, 0x130); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_TRIGGER_HURT, 0x132); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_EXPLOSIVE, 0x134); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_IMPACT, 0x136); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_BURNED, 0x138); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_HIT_BY_OBJECT, 0x13A); + ASSERT_STRUCT_OFFSET(scr_const_t, MOD_DROWN, 0x13C); + ASSERT_STRUCT_OFFSET(scr_const_t, script_vehicle, 0x13E); + ASSERT_STRUCT_OFFSET(scr_const_t, script_vehicle_collision, 0x140); + ASSERT_STRUCT_OFFSET(scr_const_t, script_vehicle_collmap, 0x142); + ASSERT_STRUCT_OFFSET(scr_const_t, script_vehicle_corpse, 0x144); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_fire, 0x146); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_on_target, 0x148); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_not_on_target, 0x14A); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_on_vistarget, 0x14C); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_no_vis, 0x14E); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_rotate_stopped, 0x150); + ASSERT_STRUCT_OFFSET(scr_const_t, turret_deactivate, 0x152); + ASSERT_STRUCT_OFFSET(scr_const_t, turretstatechange, 0x154); + ASSERT_STRUCT_OFFSET(scr_const_t, turretownerchange, 0x156); + ASSERT_STRUCT_OFFSET(scr_const_t, reached_end_node, 0x158); + ASSERT_STRUCT_OFFSET(scr_const_t, reached_wait_node, 0x15A); + ASSERT_STRUCT_OFFSET(scr_const_t, reached_wait_speed, 0x15C); + ASSERT_STRUCT_OFFSET(scr_const_t, near_goal, 0x15E); + ASSERT_STRUCT_OFFSET(scr_const_t, veh_collision, 0x160); + ASSERT_STRUCT_OFFSET(scr_const_t, veh_predictedcollision, 0x162); + ASSERT_STRUCT_OFFSET(scr_const_t, script_camera, 0x164); + ASSERT_STRUCT_OFFSET(scr_const_t, begin, 0x166); + ASSERT_STRUCT_OFFSET(scr_const_t, curve_nodehit, 0x168); + ASSERT_STRUCT_OFFSET(scr_const_t, curve_start, 0x16A); + ASSERT_STRUCT_OFFSET(scr_const_t, curve_end, 0x16C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_driver, 0x16E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_gunner1, 0x170); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_gunner2, 0x172); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_gunner3, 0x174); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_gunner4, 0x176); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_passenger, 0x178); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_passenger2, 0x17A); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_passenger3, 0x17C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_passenger4, 0x17E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_player, 0x180); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_passenger1, 0x182); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_passenger2, 0x184); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_passenger3, 0x186); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_passenger4, 0x188); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner1, 0x18A); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner2, 0x18C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner3, 0x18E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner4, 0x190); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_barrel1, 0x192); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_barrel2, 0x194); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_barrel3, 0x196); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_barrel4, 0x198); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_turret1, 0x19A); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_turret2, 0x19C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_turret3, 0x19E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_turret4, 0x1A0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner1, 0x1A2); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner2, 0x1A4); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner3, 0x1A6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner4, 0x1A8); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner1a, 0x1AA); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner2a, 0x1AC); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner3a, 0x1AE); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_flash_gunner4a, 0x1B0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_brass1, 0x1B2); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_gunner_hands1, 0x1B4); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_front_left, 0x1B6); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_front_right, 0x1B8); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_back_left, 0x1BA); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_back_right, 0x1BC); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_middle_left, 0x1BE); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wheel_middle_right, 0x1C0); + ASSERT_STRUCT_OFFSET(scr_const_t, vampire_health_regen, 0x1C2); + ASSERT_STRUCT_OFFSET(scr_const_t, vampire_kill, 0x1C4); + ASSERT_STRUCT_OFFSET(scr_const_t, morphine_shot, 0x1C6); + ASSERT_STRUCT_OFFSET(scr_const_t, morphine_revive, 0x1C8); + ASSERT_STRUCT_OFFSET(scr_const_t, freelook, 0x1CA); + ASSERT_STRUCT_OFFSET(scr_const_t, intermission, 0x1CC); + ASSERT_STRUCT_OFFSET(scr_const_t, playing, 0x1CE); + ASSERT_STRUCT_OFFSET(scr_const_t, spectator, 0x1D0); + ASSERT_STRUCT_OFFSET(scr_const_t, action_notify_attack, 0x1D2); + ASSERT_STRUCT_OFFSET(scr_const_t, action_notify_melee, 0x1D4); + ASSERT_STRUCT_OFFSET(scr_const_t, action_notify_use_reload, 0x1D6); + ASSERT_STRUCT_OFFSET(scr_const_t, always, 0x1D8); + ASSERT_STRUCT_OFFSET(scr_const_t, auto_ai, 0x1DA); + ASSERT_STRUCT_OFFSET(scr_const_t, auto_nonai, 0x1DC); + ASSERT_STRUCT_OFFSET(scr_const_t, back_left, 0x1DE); + ASSERT_STRUCT_OFFSET(scr_const_t, back_right, 0x1E0); + ASSERT_STRUCT_OFFSET(scr_const_t, begin_custom_anim, 0x1E2); + ASSERT_STRUCT_OFFSET(scr_const_t, bullethit, 0x1E4); + ASSERT_STRUCT_OFFSET(scr_const_t, count, 0x1E6); + ASSERT_STRUCT_OFFSET(scr_const_t, corner_approach, 0x1E8); + ASSERT_STRUCT_OFFSET(scr_const_t, damage_notdone, 0x1EA); + ASSERT_STRUCT_OFFSET(scr_const_t, deathplant, 0x1EC); + ASSERT_STRUCT_OFFSET(scr_const_t, front_left, 0x1EE); + ASSERT_STRUCT_OFFSET(scr_const_t, front_right, 0x1F0); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_inhand, 0x1F2); + ASSERT_STRUCT_OFFSET(scr_const_t, high_priority, 0x1F4); + ASSERT_STRUCT_OFFSET(scr_const_t, info_player_deathmatch, 0x1F6); + ASSERT_STRUCT_OFFSET(scr_const_t, infinite_energy, 0x1F8); + ASSERT_STRUCT_OFFSET(scr_const_t, low_priority, 0x1FA); + ASSERT_STRUCT_OFFSET(scr_const_t, manual, 0x1FC); + ASSERT_STRUCT_OFFSET(scr_const_t, manual_ai, 0x1FE); + ASSERT_STRUCT_OFFSET(scr_const_t, max_time, 0x200); + ASSERT_STRUCT_OFFSET(scr_const_t, menuresponse, 0x202); + ASSERT_STRUCT_OFFSET(scr_const_t, middle_left, 0x204); + ASSERT_STRUCT_OFFSET(scr_const_t, middle_right, 0x206); + ASSERT_STRUCT_OFFSET(scr_const_t, min_energy, 0x208); + ASSERT_STRUCT_OFFSET(scr_const_t, min_time, 0x20A); + ASSERT_STRUCT_OFFSET(scr_const_t, neutral, 0x20C); + ASSERT_STRUCT_OFFSET(scr_const_t, never, 0x20E); + ASSERT_STRUCT_OFFSET(scr_const_t, pickup, 0x210); + ASSERT_STRUCT_OFFSET(scr_const_t, receiver, 0x212); + ASSERT_STRUCT_OFFSET(scr_const_t, sound_blend, 0x214); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wingtipl, 0x216); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wingtipr, 0x218); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wingmidl, 0x21A); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_wingmidr, 0x21C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_prop, 0x21E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_end, 0x220); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_tailtop, 0x222); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_tailbottom, 0x224); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_detach, 0x226); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_passenger, 0x228); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_enter_back, 0x22A); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_detach2, 0x22C); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_popout, 0x22E); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_body, 0x230); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_turret, 0x232); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_turret_base, 0x234); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_barrel, 0x236); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_weapon_left, 0x238); + ASSERT_STRUCT_OFFSET(scr_const_t, human, 0x23A); + ASSERT_STRUCT_OFFSET(scr_const_t, custom, 0x23C); + ASSERT_STRUCT_OFFSET(scr_const_t, angle_deltas, 0x23E); + ASSERT_STRUCT_OFFSET(scr_const_t, bulletwhizby, 0x240); + ASSERT_STRUCT_OFFSET(scr_const_t, dog, 0x242); + ASSERT_STRUCT_OFFSET(scr_const_t, enemy, 0x244); + ASSERT_STRUCT_OFFSET(scr_const_t, enemy_visible, 0x246); + ASSERT_STRUCT_OFFSET(scr_const_t, face_angle, 0x248); + ASSERT_STRUCT_OFFSET(scr_const_t, face_current, 0x24A); + ASSERT_STRUCT_OFFSET(scr_const_t, face_default, 0x24C); + ASSERT_STRUCT_OFFSET(scr_const_t, face_direction, 0x24E); + ASSERT_STRUCT_OFFSET(scr_const_t, face_enemy, 0x250); + ASSERT_STRUCT_OFFSET(scr_const_t, face_enemy_or_motion, 0x252); + ASSERT_STRUCT_OFFSET(scr_const_t, face_goal, 0x254); + ASSERT_STRUCT_OFFSET(scr_const_t, face_motion, 0x256); + ASSERT_STRUCT_OFFSET(scr_const_t, face_point, 0x258); + ASSERT_STRUCT_OFFSET(scr_const_t, gravity, 0x25A); + ASSERT_STRUCT_OFFSET(scr_const_t, groundEntChanged, 0x25C); + ASSERT_STRUCT_OFFSET(scr_const_t, gunshot, 0x25E); + ASSERT_STRUCT_OFFSET(scr_const_t, obstacle, 0x260); + ASSERT_STRUCT_OFFSET(scr_const_t, movemode, 0x262); + ASSERT_STRUCT_OFFSET(scr_const_t, node_out_of_range, 0x264); + ASSERT_STRUCT_OFFSET(scr_const_t, node_relinquished, 0x266); + ASSERT_STRUCT_OFFSET(scr_const_t, node_taken, 0x268); + ASSERT_STRUCT_OFFSET(scr_const_t, node_not_safe, 0x26A); + ASSERT_STRUCT_OFFSET(scr_const_t, noclip, 0x26C); + ASSERT_STRUCT_OFFSET(scr_const_t, nogravity, 0x26E); + ASSERT_STRUCT_OFFSET(scr_const_t, nophysics, 0x270); + ASSERT_STRUCT_OFFSET(scr_const_t, pain, 0x272); + ASSERT_STRUCT_OFFSET(scr_const_t, run, 0x274); + ASSERT_STRUCT_OFFSET(scr_const_t, runto_arrived, 0x276); + ASSERT_STRUCT_OFFSET(scr_const_t, silenced_shot, 0x278); + ASSERT_STRUCT_OFFSET(scr_const_t, spawned, 0x27A); + ASSERT_STRUCT_OFFSET(scr_const_t, start_move, 0x27C); + ASSERT_STRUCT_OFFSET(scr_const_t, stop, 0x27E); + ASSERT_STRUCT_OFFSET(scr_const_t, stop_soon, 0x280); + ASSERT_STRUCT_OFFSET(scr_const_t, tag_eye, 0x282); + ASSERT_STRUCT_OFFSET(scr_const_t, walk, 0x284); + ASSERT_STRUCT_OFFSET(scr_const_t, world, 0x286); + ASSERT_STRUCT_OFFSET(scr_const_t, zonly_physics, 0x288); + ASSERT_STRUCT_OFFSET(scr_const_t, j_ankle_le, 0x28A); + ASSERT_STRUCT_OFFSET(scr_const_t, j_ankle_ri, 0x28C); + ASSERT_STRUCT_OFFSET(scr_const_t, j_ball_le, 0x28E); + ASSERT_STRUCT_OFFSET(scr_const_t, j_ball_ri, 0x290); + ASSERT_STRUCT_OFFSET(scr_const_t, j_palm_le, 0x292); + ASSERT_STRUCT_OFFSET(scr_const_t, j_palm_ri, 0x294); + ASSERT_STRUCT_OFFSET(scr_const_t, broken, 0x296); + ASSERT_STRUCT_OFFSET(scr_const_t, destructible, 0x298); + ASSERT_STRUCT_OFFSET(scr_const_t, snapacknowledged, 0x29A); + ASSERT_STRUCT_OFFSET(scr_const_t, disconnected, 0x29C); + ASSERT_STRUCT_OFFSET(scr_const_t, cinematic, 0x29E); + ASSERT_STRUCT_OFFSET(scr_const_t, uicinematic, 0x2A0); + ASSERT_STRUCT_OFFSET(scr_const_t, logo, 0x2A2); + ASSERT_STRUCT_OFFSET(scr_const_t, connecting, 0x2A4); + ASSERT_STRUCT_OFFSET(scr_const_t, challenging, 0x2A6); + ASSERT_STRUCT_OFFSET(scr_const_t, connected, 0x2A8); + ASSERT_STRUCT_OFFSET(scr_const_t, sendingstats, 0x2AA); + ASSERT_STRUCT_OFFSET(scr_const_t, loading, 0x2AC); + ASSERT_STRUCT_OFFSET(scr_const_t, primed, 0x2AE); + ASSERT_STRUCT_OFFSET(scr_const_t, active, 0x2B0); + ASSERT_STRUCT_OFFSET(scr_const_t, map_restart, 0x2B2); + ASSERT_STRUCT_OFFSET(scr_const_t, orientdone, 0x2B4); + + struct scr_animscript_t + { + int func; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 name; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(scr_animscript_t, 0x8); + ASSERT_STRUCT_OFFSET(scr_animscript_t, func, 0x0); + ASSERT_STRUCT_OFFSET(scr_animscript_t, name, 0x4); + + struct AnimScriptList + { + scr_animscript_t combat; //OFS: 0x0 SIZE: 0x8 + scr_animscript_t concealment_crouch; //OFS: 0x8 SIZE: 0x8 + scr_animscript_t concealment_prone; //OFS: 0x10 SIZE: 0x8 + scr_animscript_t concealment_stand; //OFS: 0x18 SIZE: 0x8 + scr_animscript_t cover_arrival; //OFS: 0x20 SIZE: 0x8 + scr_animscript_t cover_crouch; //OFS: 0x28 SIZE: 0x8 + scr_animscript_t cover_left; //OFS: 0x30 SIZE: 0x8 + scr_animscript_t cover_prone; //OFS: 0x38 SIZE: 0x8 + scr_animscript_t cover_right; //OFS: 0x40 SIZE: 0x8 + scr_animscript_t cover_stand; //OFS: 0x48 SIZE: 0x8 + scr_animscript_t cover_wide_left; //OFS: 0x50 SIZE: 0x8 + scr_animscript_t cover_wide_right; //OFS: 0x58 SIZE: 0x8 + scr_animscript_t death; //OFS: 0x60 SIZE: 0x8 + scr_animscript_t grenade_return_throw; //OFS: 0x68 SIZE: 0x8 + scr_animscript_t init; //OFS: 0x70 SIZE: 0x8 + scr_animscript_t pain; //OFS: 0x78 SIZE: 0x8 + scr_animscript_t move; //OFS: 0x80 SIZE: 0x8 + scr_animscript_t scripted; //OFS: 0x88 SIZE: 0x8 + scr_animscript_t stop; //OFS: 0x90 SIZE: 0x8 + scr_animscript_t grenade_cower; //OFS: 0x98 SIZE: 0x8 + scr_animscript_t flashed; //OFS: 0xA0 SIZE: 0x8 + scr_animscript_t weapons[128]; //OFS: 0xA8 SIZE: 0x400 + }; + ASSERT_STRUCT_SIZE(AnimScriptList, 0x4A8); + ASSERT_STRUCT_OFFSET(AnimScriptList, combat, 0x0); + ASSERT_STRUCT_OFFSET(AnimScriptList, concealment_crouch, 0x8); + ASSERT_STRUCT_OFFSET(AnimScriptList, concealment_prone, 0x10); + ASSERT_STRUCT_OFFSET(AnimScriptList, concealment_stand, 0x18); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_arrival, 0x20); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_crouch, 0x28); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_left, 0x30); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_prone, 0x38); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_right, 0x40); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_stand, 0x48); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_wide_left, 0x50); + ASSERT_STRUCT_OFFSET(AnimScriptList, cover_wide_right, 0x58); + ASSERT_STRUCT_OFFSET(AnimScriptList, death, 0x60); + ASSERT_STRUCT_OFFSET(AnimScriptList, grenade_return_throw, 0x68); + ASSERT_STRUCT_OFFSET(AnimScriptList, init, 0x70); + ASSERT_STRUCT_OFFSET(AnimScriptList, pain, 0x78); + ASSERT_STRUCT_OFFSET(AnimScriptList, move, 0x80); + ASSERT_STRUCT_OFFSET(AnimScriptList, scripted, 0x88); + ASSERT_STRUCT_OFFSET(AnimScriptList, stop, 0x90); + ASSERT_STRUCT_OFFSET(AnimScriptList, grenade_cower, 0x98); + ASSERT_STRUCT_OFFSET(AnimScriptList, flashed, 0xA0); + ASSERT_STRUCT_OFFSET(AnimScriptList, weapons, 0xA8); + + struct XAnimTree_s + { + XAnim_s * anims; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 children; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XAnimTree_s, 0x8); + ASSERT_STRUCT_OFFSET(XAnimTree_s, anims, 0x0); + ASSERT_STRUCT_OFFSET(XAnimTree_s, children, 0x4); + + struct actor_prone_info_s + { + bool bCorpseOrientation; //OFS: 0x0 SIZE: 0x1 + bool orientPitch; //OFS: 0x1 SIZE: 0x1 + bool prone; //OFS: 0x2 SIZE: 0x1 + int iProneTime; //OFS: 0x4 SIZE: 0x4 + int iProneTrans; //OFS: 0x8 SIZE: 0x4 + float fBodyHeight; //OFS: 0xC SIZE: 0x4 + float fBodyPitch; //OFS: 0x10 SIZE: 0x4 + float fBodyRoll; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(actor_prone_info_s, 0x18); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, bCorpseOrientation, 0x0); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, orientPitch, 0x1); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, prone, 0x2); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, iProneTime, 0x4); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, iProneTrans, 0x8); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, fBodyHeight, 0xC); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, fBodyPitch, 0x10); + ASSERT_STRUCT_OFFSET(actor_prone_info_s, fBodyRoll, 0x14); + + struct corpseInfo_t + { + XAnimTree_s * tree; //OFS: 0x0 SIZE: 0x4 + int entnum; //OFS: 0x4 SIZE: 0x4 + actor_prone_info_s proneInfo; //OFS: 0x8 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(corpseInfo_t, 0x20); + ASSERT_STRUCT_OFFSET(corpseInfo_t, tree, 0x0); + ASSERT_STRUCT_OFFSET(corpseInfo_t, entnum, 0x4); + ASSERT_STRUCT_OFFSET(corpseInfo_t, proneInfo, 0x8); + + struct ai_orient_t + { + ai_orient_mode_t eMode; //OFS: 0x0 SIZE: 0x4 + float fDesiredLookPitch; //OFS: 0x4 SIZE: 0x4 + float fDesiredLookYaw; //OFS: 0x8 SIZE: 0x4 + float fDesiredBodyYaw; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ai_orient_t, 0x10); + ASSERT_STRUCT_OFFSET(ai_orient_t, eMode, 0x0); + ASSERT_STRUCT_OFFSET(ai_orient_t, fDesiredLookPitch, 0x4); + ASSERT_STRUCT_OFFSET(ai_orient_t, fDesiredLookYaw, 0x8); + ASSERT_STRUCT_OFFSET(ai_orient_t, fDesiredBodyYaw, 0xC); + + struct actorBackup_s + { + ai_animmode_t eAnimMode; //OFS: 0x0 SIZE: 0x4 + ai_animmode_t eDesiredAnimMode; //OFS: 0x4 SIZE: 0x4 + ai_animmode_t eScriptSetAnimMode; //OFS: 0x8 SIZE: 0x4 + bool bUseGoalWeight; //OFS: 0xC SIZE: 0x1 + char gapD[1987]; //OFS: 0xD SIZE: 0x7C3 + ai_orient_t ScriptOrient; //OFS: 0x7D0 SIZE: 0x10 + ai_orient_t CodeOrient; //OFS: 0x7E0 SIZE: 0x10 + float fDesiredBodyYaw; //OFS: 0x7F0 SIZE: 0x4 + float currentOrigin[3]; //OFS: 0x7F4 SIZE: 0xC + float currentAngles[3]; //OFS: 0x800 SIZE: 0xC + float vLookForward[3]; //OFS: 0x80C SIZE: 0xC + float vLookRight[3]; //OFS: 0x818 SIZE: 0xC + float vLookUp[3]; //OFS: 0x824 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(actorBackup_s, 0x830); + ASSERT_STRUCT_OFFSET(actorBackup_s, eAnimMode, 0x0); + ASSERT_STRUCT_OFFSET(actorBackup_s, eDesiredAnimMode, 0x4); + ASSERT_STRUCT_OFFSET(actorBackup_s, eScriptSetAnimMode, 0x8); + ASSERT_STRUCT_OFFSET(actorBackup_s, bUseGoalWeight, 0xC); + ASSERT_STRUCT_OFFSET(actorBackup_s, gapD, 0xD); + ASSERT_STRUCT_OFFSET(actorBackup_s, ScriptOrient, 0x7D0); + ASSERT_STRUCT_OFFSET(actorBackup_s, CodeOrient, 0x7E0); + ASSERT_STRUCT_OFFSET(actorBackup_s, fDesiredBodyYaw, 0x7F0); + ASSERT_STRUCT_OFFSET(actorBackup_s, currentOrigin, 0x7F4); + ASSERT_STRUCT_OFFSET(actorBackup_s, currentAngles, 0x800); + ASSERT_STRUCT_OFFSET(actorBackup_s, vLookForward, 0x80C); + ASSERT_STRUCT_OFFSET(actorBackup_s, vLookRight, 0x818); + ASSERT_STRUCT_OFFSET(actorBackup_s, vLookUp, 0x824); + + struct scr_data_t + { + int levelscript; //OFS: 0x0 SIZE: 0x4 + int animscripts_scripted_init; //OFS: 0x4 SIZE: 0x4 + int CodeCallback_SaveRestored; //OFS: 0x8 SIZE: 0x4 + int CodeCallback_StartGameType; //OFS: 0xC SIZE: 0x4 + int CodeCallback_PlayerConnect; //OFS: 0x10 SIZE: 0x4 + int CodeCallback_PlayerDisconnect; //OFS: 0x14 SIZE: 0x4 + int CodeCallback_PlayerDamage; //OFS: 0x18 SIZE: 0x4 + int CodeCallback_PlayerKilled; //OFS: 0x1C SIZE: 0x4 + int CodeCallback_PlayerRevive; //OFS: 0x20 SIZE: 0x4 + int CodeCallback_PlayerLastStand; //OFS: 0x24 SIZE: 0x4 + XAnim_s * generic_human_animtree; //OFS: 0x28 SIZE: 0x4 + AnimScriptList anim; //OFS: 0x2C SIZE: 0x4A8 + AnimScriptList dogAnim; //OFS: 0x4D4 SIZE: 0x4A8 + int codescripts_delete_main; //OFS: 0x97C SIZE: 0x4 + int codescripts_struct_init; //OFS: 0x980 SIZE: 0x4 + int codescripts_struct_create; //OFS: 0x984 SIZE: 0x4 + int CodeCallback_LevelNotify; //OFS: 0x988 SIZE: 0x4 + XAnimTree_s * actorXAnimTrees[32]; //OFS: 0x98C SIZE: 0x80 + corpseInfo_t actorCorpseInfo[32]; //OFS: 0xA0C SIZE: 0x400 + XAnimTree_s * actorBackupXAnimTree; //OFS: 0xE0C SIZE: 0x4 + actorBackup_s * actorBackup; //OFS: 0xE10 SIZE: 0x4 + int CodeCallback_DisconnectedDuringLoad; //OFS: 0xE14 SIZE: 0x4 + corpseInfo_t playerCorpseInfo[8]; //OFS: 0xE18 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(scr_data_t, 0xF18); + ASSERT_STRUCT_OFFSET(scr_data_t, levelscript, 0x0); + ASSERT_STRUCT_OFFSET(scr_data_t, animscripts_scripted_init, 0x4); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_SaveRestored, 0x8); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_StartGameType, 0xC); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerConnect, 0x10); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerDisconnect, 0x14); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerDamage, 0x18); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerKilled, 0x1C); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerRevive, 0x20); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_PlayerLastStand, 0x24); + ASSERT_STRUCT_OFFSET(scr_data_t, generic_human_animtree, 0x28); + ASSERT_STRUCT_OFFSET(scr_data_t, anim, 0x2C); + ASSERT_STRUCT_OFFSET(scr_data_t, dogAnim, 0x4D4); + ASSERT_STRUCT_OFFSET(scr_data_t, codescripts_delete_main, 0x97C); + ASSERT_STRUCT_OFFSET(scr_data_t, codescripts_struct_init, 0x980); + ASSERT_STRUCT_OFFSET(scr_data_t, codescripts_struct_create, 0x984); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_LevelNotify, 0x988); + ASSERT_STRUCT_OFFSET(scr_data_t, actorXAnimTrees, 0x98C); + ASSERT_STRUCT_OFFSET(scr_data_t, actorCorpseInfo, 0xA0C); + ASSERT_STRUCT_OFFSET(scr_data_t, actorBackupXAnimTree, 0xE0C); + ASSERT_STRUCT_OFFSET(scr_data_t, actorBackup, 0xE10); + ASSERT_STRUCT_OFFSET(scr_data_t, CodeCallback_DisconnectedDuringLoad, 0xE14); + ASSERT_STRUCT_OFFSET(scr_data_t, playerCorpseInfo, 0xE18); + + struct scr_classStruct_t + { + unsigned __int16 id; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 entArrayId; //OFS: 0x2 SIZE: 0x2 + char charId; //OFS: 0x4 SIZE: 0x1 + char * name; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scr_classStruct_t, 0xC); + ASSERT_STRUCT_OFFSET(scr_classStruct_t, id, 0x0); + ASSERT_STRUCT_OFFSET(scr_classStruct_t, entArrayId, 0x2); + ASSERT_STRUCT_OFFSET(scr_classStruct_t, charId, 0x4); + ASSERT_STRUCT_OFFSET(scr_classStruct_t, name, 0x8); + + typedef void(__cdecl* BuiltinMethod)(scr_entref_t); + typedef void(__cdecl* BuiltinFunction)(); + + struct BuiltinFunctionDef + { + const char * actionString; //OFS: 0x0 SIZE: 0x4 + BuiltinFunction actionFunc; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BuiltinFunctionDef, 0xC); + ASSERT_STRUCT_OFFSET(BuiltinFunctionDef, actionString, 0x0); + ASSERT_STRUCT_OFFSET(BuiltinFunctionDef, actionFunc, 0x4); + ASSERT_STRUCT_OFFSET(BuiltinFunctionDef, type, 0x8); + + struct BuiltinMethodDef + { + const char * actionString; //OFS: 0x0 SIZE: 0x4 + BuiltinMethod actionFunc; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BuiltinMethodDef, 0xC); + ASSERT_STRUCT_OFFSET(BuiltinMethodDef, actionString, 0x0); + ASSERT_STRUCT_OFFSET(BuiltinMethodDef, actionFunc, 0x4); + ASSERT_STRUCT_OFFSET(BuiltinMethodDef, type, 0x8); + + struct RefString_u_s + { + unsigned __int32 refCount : 16; + unsigned __int32 user : 8; + unsigned __int32 byteLen : 8; + }; + ASSERT_STRUCT_SIZE(RefString_u_s, 0x4); + + union RefString_u + { + RefString_u_s s; //OFS: 0x0 SIZE: 0x4 + volatile int data; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(RefString_u, 0x4); + + struct RefString + { + RefString_u u; //OFS: 0x0 SIZE: 0x4 + char str[1]; //OFS: 0x4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(RefString, 0x8); + ASSERT_STRUCT_OFFSET(RefString, u, 0x0); + ASSERT_STRUCT_OFFSET(RefString, str, 0x4); + + struct RefVector_u_s + { + unsigned __int32 refCount : 16; + unsigned __int32 user : 8; + unsigned __int32 length : 8; + }; + ASSERT_STRUCT_SIZE(RefVector_u_s, 0x4); + + union RefVector_u + { + RefVector_u_s s; //OFS: 0x0 SIZE: 0x4 + volatile int head; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(RefVector_u, 0x4); + + struct RefVector + { + RefVector_u u; //OFS: 0x0 SIZE: 0x4 + float vec[3]; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(RefVector, 0x10); + ASSERT_STRUCT_OFFSET(RefVector, u, 0x0); + ASSERT_STRUCT_OFFSET(RefVector, vec, 0x4); + +#ifdef __cplusplus +} +#endif diff --git a/src/game/enums.hpp b/src/game/enums.hpp new file mode 100644 index 0000000..d2efa91 --- /dev/null +++ b/src/game/enums.hpp @@ -0,0 +1,4168 @@ +#pragma once + +#ifdef __cplusplus +namespace game +{ +#endif + + enum DvarFlags : unsigned __int16 + { + DVAR_FLAG_NONE = 0x0, + DVAR_FLAG_ARCHIVE = 0x1, + DVAR_FLAG_USERINFO = 0x2, + DVAR_FLAG_SERVERINFO = 0x4, + DVAR_FLAG_SYSTEMINFO = 0x8, + DVAR_FLAG_INIT = 0x10, + DVAR_FLAG_LATCH = 0x20, + DVAR_FLAG_ROM = 0x40, + DVAR_FLAG_CHEAT = 0x80, + DVAR_FLAG_CONFIG = 0x100, + DVAR_FLAG_SAVED = 0x200, + DVAR_FLAG_NORESTART = 0x400, + DVAR_FLAG_UNK3 = 0x800, + DVAR_FLAG_CHANGEABLE_RESET = 0x1000, + DVAR_FLAG_UNK4 = 0x2000, + DVAR_FLAG_EXTERNAL = 0x4000, + DVAR_FLAG_AUTOEXEC = 0x8000, + }; + + enum dvarType_t : __int8 + { + DVAR_TYPE_BOOL = 0x0, + DVAR_TYPE_FLOAT = 0x1, + DVAR_TYPE_FLOAT_2 = 0x2, + DVAR_TYPE_FLOAT_3 = 0x3, + DVAR_TYPE_FLOAT_4 = 0x4, + DVAR_TYPE_INT = 0x5, + DVAR_TYPE_ENUM = 0x6, + DVAR_TYPE_STRING = 0x7, + DVAR_TYPE_COLOR = 0x8, + DVAR_TYPE_COUNT = 0x9, + }; + + enum DvarSetSource : __int32 + { + DVAR_SOURCE_INTERNAL = 0x0, + DVAR_SOURCE_EXTERNAL = 0x1, + DVAR_SOURCE_SCRIPT = 0x2, + }; + + enum netadrtype_t : __int32 + { + NA_BOT = 0x0, + NA_BAD = 0x1, + NA_LOOPBACK = 0x2, + NA_BROADCAST = 0x3, + NA_IP = 0x4, + }; + + enum scriptInstance_t : __int32 + { + SCRIPTINSTANCE_SERVER = 0x0, + SCRIPTINSTANCE_CLIENT = 0x1, + SCRIPT_INSTANCE_MAX = 0x2, + }; + + enum netsrc_t : __int32 + { + NS_CLIENT1 = 0x0, + NS_SERVER = 0x1, + NS_MAXCLIENTS = 0x1, + NS_PACKET = 0x2, + }; + + enum OpcodeVM : __int32 + { + OP_End = 0x0, + OP_Return = 0x1, + OP_GetUndefined = 0x2, + OP_GetZero = 0x3, + OP_GetByte = 0x4, + OP_GetNegByte = 0x5, + OP_GetUnsignedShort = 0x6, + OP_GetNegUnsignedShort = 0x7, + OP_GetInteger = 0x8, + OP_GetFloat = 0x9, + OP_GetString = 0xA, + OP_GetIString = 0xB, + OP_GetVector = 0xC, + OP_GetLevelObject = 0xD, + OP_GetAnimObject = 0xE, + OP_GetSelf = 0xF, + OP_GetLevel = 0x10, + OP_GetGame = 0x11, + OP_GetAnim = 0x12, + OP_GetAnimation = 0x13, + OP_GetGameRef = 0x14, + OP_GetFunction = 0x15, + OP_CreateLocalVariable = 0x16, + OP_RemoveLocalVariables = 0x17, + OP_EvalLocalVariableCached0 = 0x18, + OP_EvalLocalVariableCached1 = 0x19, + OP_EvalLocalVariableCached2 = 0x1A, + OP_EvalLocalVariableCached3 = 0x1B, + OP_EvalLocalVariableCached4 = 0x1C, + OP_EvalLocalVariableCached5 = 0x1D, + OP_EvalLocalVariableCached = 0x1E, + OP_EvalLocalArrayCached = 0x1F, + OP_EvalArray = 0x20, + OP_EvalLocalArrayRefCached0 = 0x21, + OP_EvalLocalArrayRefCached = 0x22, + OP_EvalArrayRef = 0x23, + OP_ClearArray = 0x24, + OP_EmptyArray = 0x25, + OP_GetSelfObject = 0x26, + OP_EvalLevelFieldVariable = 0x27, + OP_EvalAnimFieldVariable = 0x28, + OP_EvalSelfFieldVariable = 0x29, + OP_EvalFieldVariable = 0x2A, + OP_EvalLevelFieldVariableRef = 0x2B, + OP_EvalAnimFieldVariableRef = 0x2C, + OP_EvalSelfFieldVariableRef = 0x2D, + OP_EvalFieldVariableRef = 0x2E, + OP_ClearFieldVariable = 0x2F, + OP_SafeCreateVariableFieldCached = 0x30, + OP_SafeSetVariableFieldCached0 = 0x31, + OP_SafeSetVariableFieldCached = 0x32, + OP_SafeSetWaittillVariableFieldCached = 0x33, + OP_clearparams = 0x34, + OP_checkclearparams = 0x35, + OP_EvalLocalVariableRefCached0 = 0x36, + OP_EvalLocalVariableRefCached = 0x37, + OP_SetLevelFieldVariableField = 0x38, + OP_SetVariableField = 0x39, + OP_SetAnimFieldVariableField = 0x3A, + OP_SetSelfFieldVariableField = 0x3B, + OP_SetLocalVariableFieldCached0 = 0x3C, + OP_SetLocalVariableFieldCached = 0x3D, + OP_CallBuiltin0 = 0x3E, + OP_CallBuiltin1 = 0x3F, + OP_CallBuiltin2 = 0x40, + OP_CallBuiltin3 = 0x41, + OP_CallBuiltin4 = 0x42, + OP_CallBuiltin5 = 0x43, + OP_CallBuiltin = 0x44, + OP_CallBuiltinMethod0 = 0x45, + OP_CallBuiltinMethod1 = 0x46, + OP_CallBuiltinMethod2 = 0x47, + OP_CallBuiltinMethod3 = 0x48, + OP_CallBuiltinMethod4 = 0x49, + OP_CallBuiltinMethod5 = 0x4A, + OP_CallBuiltinMethod = 0x4B, + OP_wait = 0x4C, + OP_waittillFrameEnd = 0x4D, + OP_PreScriptCall = 0x4E, + OP_ScriptFunctionCall2 = 0x4F, + OP_ScriptFunctionCall = 0x50, + OP_ScriptFunctionCallPointer = 0x51, + OP_ScriptMethodCall = 0x52, + OP_ScriptMethodCallPointer = 0x53, + OP_ScriptThreadCall = 0x54, + OP_ScriptThreadCallPointer = 0x55, + OP_ScriptMethodThreadCall = 0x56, + OP_ScriptMethodThreadCallPointer = 0x57, + OP_DecTop = 0x58, + OP_CastFieldObject = 0x59, + OP_EvalLocalVariableObjectCached = 0x5A, + OP_CastBool = 0x5B, + OP_BoolNot = 0x5C, + OP_BoolComplement = 0x5D, + OP_JumpOnFalse = 0x5E, + OP_JumpOnTrue = 0x5F, + OP_JumpOnFalseExpr = 0x60, + OP_JumpOnTrueExpr = 0x61, + OP_jump = 0x62, + OP_jumpback = 0x63, + OP_inc = 0x64, + OP_dec = 0x65, + OP_bit_or = 0x66, + OP_bit_ex_or = 0x67, + OP_bit_and = 0x68, + OP_equality = 0x69, + OP_inequality = 0x6A, + OP_less = 0x6B, + OP_greater = 0x6C, + OP_less_equal = 0x6D, + OP_greater_equal = 0x6E, + OP_shift_left = 0x6F, + OP_shift_right = 0x70, + OP_plus = 0x71, + OP_minus = 0x72, + OP_multiply = 0x73, + OP_divide = 0x74, + OP_mod = 0x75, + OP_size = 0x76, + OP_waittillmatch = 0x77, + OP_waittill = 0x78, + OP_notify = 0x79, + OP_endon = 0x7A, + OP_voidCodepos = 0x7B, + OP_switch = 0x7C, + OP_endswitch = 0x7D, + OP_vector = 0x7E, + OP_NOP = 0x7F, + OP_abort = 0x80, + OP_object = 0x81, + OP_thread_object = 0x82, + OP_EvalLocalVariable = 0x83, + OP_EvalLocalVariableRef = 0x84, + OP_prof_begin = 0x85, + OP_prof_end = 0x86, + OP_breakpoint = 0x87, + OP_assignmentBreakpoint = 0x88, + OP_manualAndAssignmentBreakpoint = 0x89, + OP_count = 0x8A, + }; + + enum meansOfDeath_t : __int32 + { + MOD_UNKNOWN = 0x0, + MOD_PISTOL_BULLET = 0x1, + MOD_RIFLE_BULLET = 0x2, + MOD_GRENADE = 0x3, + MOD_GRENADE_SPLASH = 0x4, + MOD_PROJECTILE = 0x5, + MOD_PROJECTILE_SPLASH = 0x6, + MOD_MELEE = 0x7, + MOD_BAYONET = 0x8, + MOD_HEAD_SHOT = 0x9, + MOD_CRUSH = 0xA, + MOD_TELEFRAG = 0xB, + MOD_FALLING = 0xC, + MOD_SUICIDE = 0xD, + MOD_TRIGGER_HURT = 0xE, + MOD_EXPLOSIVE = 0xF, + MOD_IMPACT = 0x10, + MOD_BURNED = 0x11, + MOD_HIT_BY_OBJECT = 0x12, + MOD_DROWN = 0x13, + MOD_NUM = 0x14, + }; + + enum entityFlag_t + { + FL_GODMODE = 0x1, + FL_DEMI_GODMODE = 0x2, + FL_NOTARGET = 0x4, + FL_NO_KNOCKBACK = 0x8, + FL_DROPPED_ITEM = 0x10, + FL_NO_BOTS = 0x20, + FL_NO_HUMANS = 0x40, + FL_TOGGLE = 0x80, + FL_SOFTACTIVATE = 0x100, + FL_LOW_PRIORITY_USEABLE = 0x200, + FL_NO_TACTICAL_INSERTION = 0x400, + FL_DYNAMICPATH = 0x800, + FL_SUPPORTS_LINKTO = 0x1000, + FL_NO_AUTO_ANIM_UPDATE = 0x2000, + FL_GRENADE_TOUCH_DAMAGE = 0x4000, + FL_GRENADE_MARTYRDOM = 0x8000, + FL_MISSILE_DESTABILIZED = 0x10000, + FL_STABLE_MISSILES = 0x20000, + FL_REPEAT_ANIM_UPDATE = 0x40000, + FL_VEHICLE_TARGET = 0x80000, + FL_GROUND_ENT = 0x100000, + FL_CURSOR_HINT = 0x200000, + FL_USE_TURRET = 0x400000, + FL_MISSILE_ATTRACTOR = 0x800000, + FL_TARGET = 0x1000000, + FL_WEAPON_BEING_GRABBED = 0x2000000, + FL_OBSTACLE = 0x4000000, + FL_DODGE_LEFT = 0x8000000, + FL_DODGE_RIGHT = 0x10000000, + FL_BADPLACE_VOLUME = 0x20000000, + FL_AUTO_BLOCKPATHS = 0x40000000, + FL_MOVER_SLIDE = 0x80000000, + }; + + enum dFlag_t + { + DAMAGE_RADIUS = 0x1, + DAMAGE_NO_ARMOR = 0x2, + DAMAGE_NO_KNOCKBACK = 0x4, + DAMAGE_NO_PROTECTION = 0x8, + }; + + enum svc_ops_e : __int32 + { + svc_nop = 0x0, + svc_gamestate = 0x1, + svc_configstring = 0x2, + svc_baseline = 0x3, + svc_entitycache = 0x4, + svc_dynentstate = 0x5, + svc_destructiblestate = 0x6, + svc_ropestate = 0x7, + svc_serverCommand = 0x8, + svc_download = 0x9, + svc_snapshot = 0xA, + svc_EOF = 0xB, + }; + + enum svscmd_type : __int32 + { + SV_CMD_CAN_IGNORE = 0x0, + SV_CMD_RELIABLE = 0x1, + }; + + enum clientconn_e + { + CS_FREE = 0x0, + CS_ZOMBIE = 0x1, + CS_CONNECTED = 0x2, + CS_PRIMED = 0x3, + CS_ACTIVE = 0x4, + }; + + enum serverState_t : __int32 + { + SS_DEAD = 0x0, + SS_LOADING = 0x1, + SS_GAME = 0x2, + }; + + enum DvarFlags32 : unsigned __int32 + { + DVAR_FLAG32_NONE = 0x0, + DVAR_FLAG32_ARCHIVE = 0x1, + DVAR_FLAG32_USERINFO = 0x2, + DVAR_FLAG32_SERVERINFO = 0x4, + DVAR_FLAG32_SYSTEMINFO = 0x8, + DVAR_FLAG32_INIT = 0x10, + DVAR_FLAG32_LATCH = 0x20, + DVAR_FLAG32_ROM = 0x40, + DVAR_FLAG32_CHEAT = 0x80, + DVAR_FLAG32_CONFIG = 0x100, + DVAR_FLAG32_SAVED = 0x200, + DVAR_FLAG32_NORESTART = 0x400, + DVAR_FLAG32_UNK3 = 0x800, + DVAR_FLAG32_CHANGEABLE_RESET = 0x1000, + DVAR_FLAG32_UNK4 = 0x2000, + DVAR_FLAG32_EXTERNAL = 0x4000, + DVAR_FLAG32_AUTOEXEC = 0x8000, + }; + + enum dvarType32_t : __int32 + { + DVAR_TYPE32_BOOL = 0x0, + DVAR_TYPE32_FLOAT = 0x1, + DVAR_TYPE32_FLOAT_2 = 0x2, + DVAR_TYPE32_FLOAT_3 = 0x3, + DVAR_TYPE32_FLOAT_4 = 0x4, + DVAR_TYPE32_INT = 0x5, + DVAR_TYPE32_ENUM = 0x6, + DVAR_TYPE32_STRING = 0x7, + DVAR_TYPE32_COLOR = 0x8, + DVAR_TYPE32_COUNT = 0x9, + }; + + enum connstate_t : __int32 + { + CA_DISCONNECTED = 0x0, + CA_CINEMATIC = 0x1, + CA_UICINEMATIC = 0x2, + CA_LOGO = 0x3, + CA_CONNECTING = 0x4, + CA_CHALLENGING = 0x5, + CA_CONNECTED = 0x6, + CA_SENDINGSTATS = 0x7, + CA_LOADING = 0x8, + CA_PRIMED = 0x9, + CA_ACTIVE = 0xA, + CA_MAP_RESTART = 0xB, + }; + + enum sessionState_t : __int32 + { + SESS_STATE_PLAYING = 0x0, + SESS_STATE_DEAD = 0x1, + SESS_STATE_SPECTATOR = 0x2, + SESS_STATE_INTERMISSION = 0x3, + }; + + enum entityType_t : __int32 + { + ET_GENERAL = 0x0, + ET_PLAYER = 0x1, + ET_PLAYER_CORPSE = 0x2, + ET_ITEM = 0x3, + ET_MISSILE = 0x4, + ET_INVISIBLE = 0x5, + ET_SCRIPTMOVER = 0x6, + ET_SOUND_BLEND = 0x7, + ET_FX = 0x8, + ET_LOOP_FX = 0x9, + ET_PRIMARY_LIGHT = 0xA, + ET_MG42 = 0xB, + ET_PLANE = 0xC, + ET_VEHICLE = 0xD, + ET_VEHICLE_COLLMAP = 0xE, + ET_VEHICLE_CORPSE = 0xF, + ET_ACTOR = 0x10, + ET_ACTOR_SPAWNER = 0x11, + ET_ACTOR_CORPSE = 0x12, + ET_EVENTS = 0x13, + }; + + enum con_channel_e + { + CON_CHANNEL_DONT_FILTER = 0x0, + CON_CHANNEL_ERROR = 0x1, + CON_CHANNEL_GAMENOTIFY = 0x2, + CON_CHANNEL_BOLDGAME = 0x3, + CON_CHANNEL_SUBTITLE = 0x4, + CON_CHANNEL_OBITUARY = 0x5, + CON_CHANNEL_LOGFILEONLY = 0x6, + CON_CHANNEL_CONSOLEONLY = 0x7, + CON_CHANNEL_GFX = 0x8, + CON_CHANNEL_SOUND = 0x9, + CON_CHANNEL_FILES = 0xA, + CON_CHANNEL_DEVGUI = 0xB, + CON_CHANNEL_PROFILE = 0xC, + CON_CHANNEL_UI = 0xD, + CON_CHANNEL_CLIENT = 0xE, + CON_CHANNEL_SERVER = 0xF, + CON_CHANNEL_SYSTEM = 0x10, + CON_CHANNEL_PLAYERWEAP = 0x11, + CON_CHANNEL_AI = 0x12, + CON_CHANNEL_ANIM = 0x13, + CON_CHANNEL_PHYS = 0x14, + CON_CHANNEL_FX = 0x15, + CON_CHANNEL_LEADERBOARDS = 0x16, + CON_CHANNEL_PARSERSCRIPT = 0x17, + CON_CHANNEL_SCRIPT = 0x18, + CON_CHANNEL_COOPINFO = 0x19, + CON_BUILTIN_CHANNEL_COUNT = 0x1A, + }; + + enum parseSkip_t + { + SKIP_NO = 0x0, + SKIP_YES = 0x1, + SKIP_ALL_ELIFS = 0x2, + }; + + enum UILocalVarType : __int32 + { + UILOCALVAR_INT = 0x0, + UILOCALVAR_FLOAT = 0x1, + UILOCALVAR_STRING = 0x2, + }; + + enum errorParm_t : __int32 + { + ERR_FATAL = 0x0, + ERR_DROP = 0x1, + ERR_SERVERDISCONNECT = 0x2, + ERR_DISCONNECT = 0x3, + ERR_SCRIPT = 0x4, + ERR_SCRIPT_DROP = 0x5, + ERR_LOCALIZATION = 0x6, + ERR_MAPLOADERRORSUMMARY = 0x7, + }; + + enum msgLocErrType_t : __int32 + { + LOCMSG_SAFE = 0x0, + LOCMSG_NOERR = 0x1, + }; + + enum ConfigStringIndices + { + CS_MIN = 0x0, + CS_SOUNDALIASINDICES = 0x78E, + CS_CASE_SENSITIVE = 0x585, + MAX_CONFIGSTRINGS = 0xBF0, + }; + + enum fieldtype_t : __int32 + { + F_INT = 0x0, + F_SHORT = 0x1, + F_BYTE = 0x2, + F_FLOAT = 0x3, + F_LSTRING = 0x4, + F_STRING = 0x5, + F_VECTOR = 0x6, + F_ENTITY = 0x7, + F_ENTHANDLE = 0x8, + F_ACTOR = 0x9, + F_SENTIENT = 0xA, + F_SENTIENTHANDLE = 0xB, + F_CLIENT = 0xC, + F_PATHNODE = 0xD, + F_VECTORHACK = 0xE, + F_MODEL = 0xF, + F_OBJECT = 0x10, + F_ACTORGROUP = 0x11, + F_BITFLAG = 0x12, + }; + + enum deployableCommand_t + { + DEPLOYABLE_CMD_NONE = 0x0, + DEPLOYABLE_CMD_WATER_SHEETING_FX = 0x21, + DEPLOYABLE_CMD_ROPE = 0x23, + DEPLOYABLE_CMD_WATER_PLOP = 0x24, + DEPLOYABLE_CMD_ELECTRIFIED = 0x28, + DEPLOYABLE_CMD_TELEPORTED = 0x29, + DEPLOYABLE_CMD_ENTITY_EVENT = 0x2A, + DEPLOYABLE_CMD_WATER_DROPS = 0x30, + DEPLOYABLE_CMD_BRIEFING_POPUP = 0x31, + DEPLOYABLE_CMD_PHYS_GRAVITY_DIR = 0x32, + DEPLOYABLE_CMD_CLEAR_CONFIGSTRING_RANGE = 0x33, + DEPLOYABLE_CMD_DOUBLE_VISION = 0x34, + DEPLOYABLE_CMD_GENERATE_CLIENT_SAVE = 0x35, + DEPLOYABLE_CMD_CLIENTSYS_STATE_CHANGE = 0x39, + DEPLOYABLE_CMD_COMMIT_CLIENT_SAVE = 0x3A, + DEPLOYABLE_CMD_RESET_CLIENTINFO = 0x3F, + DEPLOYABLE_CMD_EXPLODER = 0x40, + DEPLOYABLE_CMD_UNK1 = 0x41, + DEPLOYABLE_CMD_MAPRESTART_SAVE_PERSIST = 0x42, + DEPLOYABLE_CMD_SWITCH_OFFHAND = 0x43, + DEPLOYABLE_CMD_DEACTIVATE_REVERB = 0x44, + DEPLOYABLE_CMD_SET_CHANNEL_VOLUME = 0x45, + DEPLOYABLE_CMD_DEACTIVATE_CHANNEL_VOLUME = 0x46, + DEPLOYABLE_CMD_MENU_SHOW_NOTIFY = 0x4A, + DEPLOYABLE_CMD_PLAYER_MUTE = 0x4B, + DEPLOYABLE_CMD_CLOSE_INGAME_MENU = 0x4C, + DEPLOYABLE_CMD_SET_STAT_CHANGED = 0x4E, + DEPLOYABLE_CMD_RESET_GUN_PITCH = 0x4F, + DEPLOYABLE_CMD_START_AMPLIFY = 0x51, + DEPLOYABLE_CMD_STOP_AMPLIFY = 0x52, + DEPLOYABLE_CMD_REACHED_CHECKPOINT = 0x53, + DEPLOYABLE_CMD_RETICLE_START_LOCKON = 0x54, + DEPLOYABLE_CMD_FADE = 0x55, + DEPLOYABLE_CMD_OBJECTIVE_STATE = 0x56, + DEPLOYABLE_CMD_BURN = 0x57, + DEPLOYABLE_CMD_SLOW_TIMESCALE_OVER_TIME = 0x58, + DEPLOYABLE_CMD_DEATH_SCREEN = 0x59, + DEPLOYABLE_CMD_COOP_MESSAGE = 0x5E, + DEPLOYABLE_CMD_SWITCH_WEAPON = 0x61, + DEPLOYABLE_CMD_TAKE = 0x61, + DEPLOYABLE_CMD_PARSE_SCORES = 0x62, + DEPLOYABLE_CMD_ANNOUNCMENT = 0x63, + DEPLOYABLE_CMD_CONFIGSTRING_MODIFIED = 0x64, + DEPLOYABLE_CMD_GAMEMESSAGE = 0x65, + DEPLOYABLE_CMD_GAMEMESSAGE2 = 0x66, + DEPLOYABLE_CMD_BOLD_GAMEMESSAGE = 0x67, + DEPLOYABLE_CMD_CHATMESSAGE = 0x68, + DEPLOYABLE_CMD_DYN_ENT_DESTROYED = 0x6A, + DEPLOYABLE_CMD_SYSCMD_EQ = 0x6C, + DEPLOYABLE_CMD_SVSCMD_EQ_DEACTIVATE = 0x6D, + DEPLOYABLE_CMD_STOP_LOCAL_SOUND = 0x6B, + DEPLOYABLE_CMD_MAPRESTART_NO_SAVE_PERSIST = 0x6E, + DEPLOYABLE_CMD_MUSIC_STOP = 0x70, + DEPLOYABLE_CMD_SOUND_FADE = 0x71, + DEPLOYABLE_CMD_ACTIVATE_REVERB = 0x72, + DEPLOYABLE_CMD_PLAY_LOCAL_SOUND = 0x73, + DEPLOYABLE_CMD_OPEN_MENU = 0x74, + DEPLOYABLE_CMD_CLOSE_MENU = 0x75, + DEPLOYABLE_CMD_SET_CLIENT_DVAR = 0x76, + DEPLOYABLE_CMD_CL_DISCONNECT = 0x77, + DEPLOYABLE_CMD_COPY_INTO_BIG_CONFIGSTRING = 0x78, + DEPLOYABLE_CMD_CONCAT_BIG_CONFIGSTRING = 0x79, + DEPLOYABLE_CMD_CONCAT_BIG_CONFIGSTRING2 = 0x7A, + DEPLOYABLE_CMD_SHOW_VIEWMODEL = 0x7B, + DEPLOYABLE_CMD_FADING_BLUR = 0x7C, + DEPLOYABLE_CMD_HIDE_VIEWMODEL = 0x7D, + }; + + enum pmtype_t : __int32 + { + PM_NORMAL = 0x0, + PM_NORMAL_LINKED = 0x1, + PM_NOCLIP = 0x2, + PM_UFO = 0x3, + PM_SPECTATOR = 0x4, + PM_INTERMISSION = 0x5, + PM_LASTSTAND = 0x6, + PM_REVIVEE = 0x7, + PM_LASTSTAND_TRANSITION = 0x8, + PM_DEAD = 0x9, + PM_DEAD_LINKED = 0xA, + }; + + enum entHandler_t : __int32 + { + ENT_HANDLER_NULL = 0x0, + ENT_HANDLER_ACTOR_INIT = 0x1, + ENT_HANDLER_ACTOR = 0x2, + ENT_HANDLER_ACTOR_CORPSE = 0x3, + ENT_HANDLER_TRIGGER_MULTIPLE = 0x4, + ENT_HANDLER_TRIGGER_HURT = 0x5, + ENT_HANDLER_TRIGGER_HURT_TOUCH = 0x6, + ENT_HANDLER_TRIGGER_DAMAGE = 0x7, + ENT_HANDLER_SCRIPT_MOVER = 0x8, + ENT_HANDLER_SCRIPT_MODEL = 0x9, + ENT_HANDLER_GRENADE = 0xA, + ENT_HANDLER_TIMED_OBJECT = 0xB, + ENT_HANDLER_ROCKET = 0xC, + ENT_HANDLER_CLIENT = 0xD, + ENT_HANDLER_CLIENT_SPECTATOR = 0xE, + ENT_HANDLER_CLIENT_DEAD = 0xF, + ENT_HANDLER_PLAYER_CLONE = 0x10, + ENT_HANDLER_TURRET_INIT = 0x11, + ENT_HANDLER_TURRET = 0x12, + ENT_HANDLER_DROPPED_ITEM = 0x13, + ENT_HANDLER_ITEM_INIT = 0x14, + ENT_HANDLER_ITEM = 0x15, + ENT_HANDLER_TRIGGER_USE = 0x16, + ENT_HANDLER_PRIMARY_LIGHT = 0x17, + ENT_HANDLER_PLAYER_BLOCK = 0x18, + ENT_HANDLER_VEHICLE_INIT = 0x19, + ENT_HANDLER_VEHICLE = 0x1A, + ENT_HANDLER_VEHICLE_FREE = 0x1B, + ENT_HANDLER_IK_PLAYERCLIP_TERRAIN = 0x1C, + ENT_HANDLER_IK_DISABLE_TERRAIN_MAPPING = 0x1D, + ENT_HANDLER_COUNT = 0x1E, + }; + + enum actor_think_result_t : __int32 + { + ACTOR_THINK_DONE = 0x0, + ACTOR_THINK_REPEAT = 0x1, + ACTOR_THINK_MOVE_TO_BODY_QUEUE = 0x2, + }; + + enum ai_event_t : __int32 + { + AI_EV_BAD = 0x0, + AI_EV_FIRST_POINT_EVENT = 0x1, + AI_EV_FOOTSTEP = 0x2, + AI_EV_FOOTSTEP_LITE = 0x3, + AI_EV_NEW_ENEMY = 0x4, + AI_EV_PAIN = 0x5, + AI_EV_DEATH = 0x6, + AI_EV_EXPLOSION = 0x7, + AI_EV_GRENADE_PING = 0x8, + AI_EV_PROJECTILE_PING = 0x9, + AI_EV_GUNSHOT = 0xA, + AI_EV_SILENCED_SHOT = 0xB, + AI_EV_LAST_POINT_EVENT = 0xC, + AI_EV_FIRST_LINE_EVENT = 0xD, + AI_EV_BULLET = 0xE, + AI_EV_BLOCK_FRIENDLIES = 0xE, + AI_EV_PROJECTILE_IMPACT = 0xF, + AI_EV_LAST_LINE_EVENT = 0x10, + AI_EV_FIRST_ARC_EVENT = 0x11, + AI_EV_BADPLACE_ARC = 0x12, + AI_EV_BADPLACE_LIMITED_ARC = 0x13, + AI_EV_REALLY_BADPLACE_ARC = 0x14, + AI_EV_LAST_ARC_EVENT = 0x15, + AI_EV_FIRST_VOLUME_EVENT = 0x16, + AI_EV_BADPLACE_VOLUME = 0x17, + AI_EV_LAST_VOLUME_EVENT = 0x18, + AI_EV_NUM_EVENTS = 0x19, + }; + + enum loading_t : __int32 + { + LOADING_DONE = 0x0, + LOADING_LEVEL = 0x1, + LOADING_SAVEGAME = 0x2, + }; + + enum objectiveState_t : __int32 + { + OBJST_EMPTY = 0x0, + OBJST_ACTIVE = 0x1, + OBJST_INVISIBLE = 0x2, + OBJST_DONE = 0x3, + OBJST_CURRENT = 0x4, + OBJST_FAILED = 0x5, + OBJST_NUMSTATES = 0x6, + }; + + enum trType_t : __int32 + { + TR_STATIONARY = 0x0, + TR_INTERPOLATE = 0x1, + TR_LINEAR = 0x2, + TR_LINEAR_STOP = 0x3, + TR_SINE = 0x4, + TR_GRAVITY = 0x5, + TR_ACCELERATE = 0x6, + TR_DECELERATE = 0x7, + TR_PHYSICS = 0x8, + TR_XDOLL = 0x9, + TR_FIRST_RAGDOLL = 0xA, + TR_RAGDOLL = 0xA, + TR_RAGDOLL_GRAVITY = 0xB, + TR_RAGDOLL_INTERPOLATE = 0xC, + TR_LAST_RAGDOLL = 0xC, + TR_COUNT = 0xD, + }; + + enum WheelEffectState : __int32 + { + WHEEL_STATE_ROLLING = 0x0, + WHEEL_STATE_AIRBORN = 0x1, + WHEEL_STATE_PEELINGOUT = 0x2, + WHEEL_STATE_SKIDDING = 0x3, + }; + + enum TractionType : __int32 + { + TRACTION_TYPE_FRONT = 0x0, + TRACTION_TYPE_BACK = 0x1, + TRACTION_TYPE_ALL_WD = 0x2, + NUM_TRACTION_TYPES = 0x3, + }; + + enum OffhandSecondaryClass : __int32 + { + PLAYER_OFFHAND_SECONDARY_SMOKE = 0x0, + PLAYER_OFFHAND_SECONDARY_FLASH = 0x1, + PLAYER_OFFHAND_SECONDARIES_TOTAL = 0x2, + }; + + enum ViewLockTypes : __int32 + { + PLAYERVIEWLOCK_NONE = 0x0, + PLAYERVIEWLOCK_FULL = 0x1, + PLAYERVIEWLOCK_WEAPONJITTER = 0x2, + PLAYERVIEWLOCKCOUNT = 0x3, + }; + + enum ActionSlotType : __int32 + { + ACTIONSLOTTYPE_DONOTHING = 0x0, + ACTIONSLOTTYPE_SPECIFYWEAPON = 0x1, + ACTIONSLOTTYPE_ALTWEAPONTOGGLE = 0x2, + ACTIONSLOTTYPE_NIGHTVISION = 0x3, + ACTIONSLOTTYPECOUNT = 0x4, + }; + + enum he_type_t : __int32 + { + HE_TYPE_FREE = 0x0, + HE_TYPE_TEXT = 0x1, + HE_TYPE_VALUE = 0x2, + HE_TYPE_SCORE = 0x3, + HE_TYPE_MATERIAL = 0x4, + HE_TYPE_TIMER_DOWN = 0x5, + HE_TYPE_TIMER_UP = 0x6, + HE_TYPE_TENTHS_TIMER_DOWN = 0x7, + HE_TYPE_TENTHS_TIMER_UP = 0x8, + HE_TYPE_CLOCK_DOWN = 0x9, + HE_TYPE_CLOCK_UP = 0xA, + HE_TYPE_WAYPOINT = 0xB, + HE_TYPE_COUNT = 0xC, + }; + + enum clientConnected_t : __int32 + { + CON_DISCONNECTED = 0x0, + CON_CONNECTING = 0x1, + CON_CONNECTED = 0x2, + }; + + enum team_t : __int32 + { + TEAM_FREE = 0x0, + TEAM_BAD = 0x0, + TEAM_AXIS = 0x1, + TEAM_ALLIES = 0x2, + TEAM_NEUTRAL = 0x3, + TEAM_DEAD = 0x4, + TEAM_NUM_TEAMS = 0x5, + }; + + enum VehicleAnimState : __int32 + { + VEHICLEANIMSTATE_IDLE = 0x0, + VEHICLEANIMSTATE_ENTRY = 0x1, + VEHICLEANIMSTATE_CHANGEPOS = 0x2, + VEHICLEANIMSTATE_EXIT = 0x3, + VEHICLEANIMSTATECOUNT = 0x4, + }; + + enum AISpecies : __int32 + { + AI_SPECIES_HUMAN = 0x0, + AI_SPECIES_DOG = 0x1, + MAX_AI_SPECIES = 0x2, + AI_SPECIES_ALL = 0x2, + }; + + enum ai_state_t : __int32 + { + AIS_INVALID = 0x0, + AIS_KEEPCURRENT = 0x0, + AIS_EXPOSED = 0x1, + AIS_TURRET = 0x2, + AIS_GRENADE_RESPONSE = 0x3, + AIS_BADPLACE_FLEE = 0x4, + AIS_COVERARRIVAL = 0x5, + AIS_DEATH = 0x6, + AIS_DEFAULT = 0x1, + AIS_SETABLE_FIRST = 0x1, + AIS_SETABLE_LAST = 0x6, + AIS_PAIN = 0x7, + AIS_SCRIPTEDANIM = 0x8, + AIS_CUSTOMANIM = 0x9, + AIS_NEGOTIATION = 0xA, + AIS_PUSHABLE_FIRST = 0x7, + AIS_PUSHABLE_LAST = 0xA, + AIS_COUNT = 0xB, + }; + + enum ai_substate_t : __int32 + { + STATE_EXPOSED_COMBAT = 0x64, + STATE_EXPOSED_NONCOMBAT = 0x65, + STATE_EXPOSED_REACQUIRE_MOVE = 0x66, + STATE_EXPOSED_FLASHBANGED = 0x67, + STATE_DEATH_PRECLEANUP = 0xC8, + STATE_DEATH_POSTCLEANUP = 0xC9, + STATE_GRENADE_FLEE = 0x12C, + STATE_GRENADE_TAKECOVER = 0x12D, + STATE_GRENADE_COWER = 0x12E, + STATE_GRENADE_COMBAT = 0x12F, + STATE_GRENADE_COVERATTACK = 0x130, + STATE_GRENADE_ACQUIRE = 0x131, + STATE_GRENADE_THROWBACK = 0x132, + }; + + enum ai_state_transition_t : unsigned __int32 + { + AIS_TRANSITION_CANONICAL = 0xFFFFFFFF, + AIS_TRANSITION_NONE = 0x0, + AIS_TRANSITION_SET = 0x1, + AIS_TRANSITION_PUSH = 0x2, + AIS_TRANSITION_POP = 0x3, + }; + + enum ai_stance_e : __int32 + { + STANCE_BAD = 0x0, + STANCE_STAND = 0x1, + STANCE_CROUCH = 0x2, + STANCE_PRONE = 0x4, + STANCE_ANY = 0x7, + }; + + enum ai_traverse_mode_t : __int32 + { + AI_TRAVERSE_INVALID = 0x0, + AI_TRAVERSE_GRAVITY = 0x1, + AI_TRAVERSE_NOGRAVITY = 0x2, + AI_TRAVERSE_NOCLIP = 0x3, + AI_TRAVERSE_COUNT = 0x4, + }; + + enum aiphys_t : __int32 + { + AIPHYS_BAD = 0x0, + AIPHYS_NORMAL_ABSOLUTE = 0x1, + AIPHYS_NORMAL_RELATIVE = 0x2, + AIPHYS_NOCLIP = 0x3, + AIPHYS_NOGRAVITY = 0x4, + AIPHYS_ZONLY_PHYSICS_RELATIVE = 0x5, + }; + + enum aiGoalSources : __int32 + { + AI_GOAL_SRC_SCRIPT_GOAL = 0x0, + AI_GOAL_SRC_SCRIPT_ENTITY_GOAL = 0x1, + AI_GOAL_SRC_FRIENDLY_CHAIN = 0x2, + AI_GOAL_SRC_ENEMY = 0x3, + }; + + enum ai_badplace_t : __int32 + { + AI_BADPLACE_NONE = 0x0, + AI_BADPLACE_NORMAL = 0x1, + AI_BADPLACE_REALLYBAD = 0x2, + }; + + enum VehicleMoveState : __int32 + { + VEH_MOVESTATE_STOP = 0x0, + VEH_MOVESTATE_MOVE = 0x1, + VEH_MOVESTATE_HOVER = 0x2, + VEH_MOVESTATE_PLANE_ONCURVE = 0x3, + VEH_MOVESTATE_PLANE_FREE = 0x4, + }; + + enum VehicleTurretState : __int32 + { + VEH_TURRET_STOPPED = 0x0, + VEH_TURRET_STOPPING = 0x1, + VEH_TURRET_MOVING = 0x2, + }; + + enum MissileStage : __int32 + { + MISSILESTAGE_SOFTLAUNCH = 0x0, + MISSILESTAGE_ASCENT = 0x1, + MISSILESTAGE_DESCENT = 0x2, + }; + + enum MissileFlightMode : __int32 + { + MISSILEFLIGHTMODE_TOP = 0x0, + MISSILEFLIGHTMODE_DIRECT = 0x1, + }; + + enum weapClipType_t : __int32 + { + WEAPON_CLIPTYPE_BOTTOM = 0x0, + WEAPON_CLIPTYPE_TOP = 0x1, + WEAPON_CLIPTYPE_LEFT = 0x2, + WEAPON_CLIPTYPE_DP28 = 0x3, + WEAPON_CLIPTYPE_PTRS = 0x4, + WEAPON_CLIPTYPE_LMG = 0x5, + WEAPON_CLIPTYPECOUNT = 0x6, + }; + + enum DemoType : __int32 + { + DEMO_TYPE_NONE = 0x0, + DEMO_TYPE_CLIENT = 0x1, + DEMO_TYPE_SERVER = 0x2, + }; + + enum CubemapShot : __int32 + { + CUBEMAPSHOT_NONE = 0x0, + CUBEMAPSHOT_RIGHT = 0x1, + CUBEMAPSHOT_LEFT = 0x2, + CUBEMAPSHOT_BACK = 0x3, + CUBEMAPSHOT_FRONT = 0x4, + CUBEMAPSHOT_UP = 0x5, + CUBEMAPSHOT_DOWN = 0x6, + CUBEMAPSHOT_COUNT = 0x7, + }; + + enum CameraMode : __int32 + { + CAM_NORMAL = 0x0, + CAM_LINKED = 0x1, + CAM_VEHICLE = 0x2, + CAM_VEHICLE_GUNNER = 0x3, + CAM_TURRET = 0x4, + }; + + enum InvalidCmdHintType : __int32 + { + INVALID_CMD_NONE = 0x0, + INVALID_CMD_NO_AMMO_BULLETS = 0x1, + INVALID_CMD_NO_AMMO_FRAG_GRENADE = 0x2, + INVALID_CMD_NO_AMMO_SPECIAL_GRENADE = 0x3, + INVALID_CMD_NO_AMMO_FLASH_GRENADE = 0x4, + INVALID_CMD_STAND_BLOCKED = 0x5, + INVALID_CMD_CROUCH_BLOCKED = 0x6, + INVALID_CMD_TARGET_TOO_CLOSE = 0x7, + INVALID_CMD_LOCKON_REQUIRED = 0x8, + INVALID_CMD_NOT_ENOUGH_CLEARANCE = 0x9, + }; + + enum SuccessfulCmdHintType : __int32 + { + SUCCESSFUL_CMD_NONE = 0x0, + SUCCESSFUL_CMD_GOD_MODE_ON = 0x1, + SUCCESSFUL_CMD_GOD_MODE_OFF = 0x2, + SUCCESSFUL_CMD_DEMIGOD_MODE_ON = 0x3, + SUCCESSFUL_CMD_DEMIGOD_MODE_OFF = 0x4, + SUCCESSFUL_CMD_UFO_ON = 0x5, + SUCCESSFUL_CMD_UFO_OFF = 0x6, + SUCCESSFUL_CMD_WEAPNEXT = 0x7, + SUCCESSFUL_CMD_WEAPPREV = 0x8, + SUCCESSFUL_CMD_GIVE_ALL = 0x9, + SUCCESSFUL_CMD_CAMLOCK_ON = 0xA, + SUCCESSFUL_CMD_CAMLOCK_OFF = 0xB, + SUCCESSFUL_CMD_LOOKSPRING_ON = 0xC, + SUCCESSFUL_CMD_LOOKSPRING_OFF = 0xD, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_HORZ = 0xE, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_RIGHT = 0xF, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_LEFT = 0x10, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_VERT = 0x11, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_UP = 0x12, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SHAKE_DOWN = 0x13, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_PUSH_PULL = 0x14, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_PUSH = 0x15, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_PULL = 0x16, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_TWIST_CW = 0x17, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_TWIST_CCW = 0x18, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_SWIPE = 0x19, + SUCCESSFUL_CMD_GESTURE_WIIMOTE_TOSS = 0x1A, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_HORZ = 0x1B, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_RIGHT = 0x1C, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_LEFT = 0x1D, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_VERT = 0x1E, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_UP = 0x1F, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SHAKE_DOWN = 0x20, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_PUSH_PULL = 0x21, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_PUSH = 0x22, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_PULL = 0x23, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_TWIST_CW = 0x24, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_TWIST_CCW = 0x25, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_SWIPE = 0x26, + SUCCESSFUL_CMD_GESTURE_NUNCHUK_TOSS = 0x27, + }; + + enum ShockViewTypes : __int32 + { + SHELLSHOCK_VIEWTYPE_BLURRED = 0x0, + SHELLSHOCK_VIEWTYPE_FLASHED = 0x1, + SHELLSHOCK_VIEWTYPE_NONE = 0x2, + }; + + enum visionSetLerpStyle_t : __int32 + { + VISIONSETLERP_UNDEFINED = 0x0, + VISIONSETLERP_NONE = 0x1, + VISIONSETLERP_TO_LINEAR = 0x2, + VISIONSETLERP_TO_SMOOTH = 0x3, + VISIONSETLERP_BACKFORTH_LINEAR = 0x4, + VISIONSETLERP_BACKFORTH_SMOOTH = 0x5, + }; + + enum markerState_t : __int32 + { + MRKST_EMPTY = 0x0, + MRKST_ACTIVE_ENTITY = 0x1, + MRKST_ACTIVE_VECTOR = 0x2, + }; + + enum StanceState : __int32 + { + CL_STANCE_STAND = 0x0, + CL_STANCE_CROUCH = 0x1, + CL_STANCE_PRONE = 0x2, + }; + + enum TraceHitType : __int32 + { + TRACE_HITTYPE_NONE = 0x0, + TRACE_HITTYPE_ENTITY = 0x1, + TRACE_HITTYPE_DYNENT_MODEL = 0x2, + TRACE_HITTYPE_DYNENT_BRUSH = 0x3, + }; + + enum hitLocation_t : __int32 + { + HITLOC_NONE = 0x0, + HITLOC_HELMET = 0x1, + HITLOC_HEAD = 0x2, + HITLOC_NECK = 0x3, + HITLOC_TORSO_UPR = 0x4, + HITLOC_TORSO_LWR = 0x5, + HITLOC_R_ARM_UPR = 0x6, + HITLOC_L_ARM_UPR = 0x7, + HITLOC_R_ARM_LWR = 0x8, + HITLOC_L_ARM_LWR = 0x9, + HITLOC_R_HAND = 0xA, + HITLOC_L_HAND = 0xB, + HITLOC_R_LEG_UPR = 0xC, + HITLOC_L_LEG_UPR = 0xD, + HITLOC_R_LEG_LWR = 0xE, + HITLOC_L_LEG_LWR = 0xF, + HITLOC_R_FOOT = 0x10, + HITLOC_L_FOOT = 0x11, + HITLOC_GUN = 0x12, + HITLOC_NUM = 0x13, + }; + + enum scriptAnimMoveTypes_t : __int32 + { + ANIM_MT_UNUSED = 0x0, + ANIM_MT_IDLE = 0x1, + ANIM_MT_IDLECR = 0x2, + ANIM_MT_IDLEPRONE = 0x3, + ANIM_MT_WALK = 0x4, + ANIM_MT_WALKBK = 0x5, + ANIM_MT_WALKCR = 0x6, + ANIM_MT_WALKCRBK = 0x7, + ANIM_MT_WALKPRONE = 0x8, + ANIM_MT_WALKPRONEBK = 0x9, + ANIM_MT_RUN = 0xA, + ANIM_MT_RUNBK = 0xB, + ANIM_MT_RUNCR = 0xC, + ANIM_MT_RUNCRBK = 0xD, + ANIM_MT_TURNRIGHT = 0xE, + ANIM_MT_TURNLEFT = 0xF, + ANIM_MT_TURNRIGHTCR = 0x10, + ANIM_MT_TURNLEFTCR = 0x11, + ANIM_MT_CLIMBUP = 0x12, + ANIM_MT_CLIMBDOWN = 0x13, + ANIM_MT_SPRINT = 0x14, + ANIM_MT_MANTLE_ROOT = 0x15, + ANIM_MT_MANTLE_UP_57 = 0x16, + ANIM_MT_MANTLE_UP_51 = 0x17, + ANIM_MT_MANTLE_UP_45 = 0x18, + ANIM_MT_MANTLE_UP_39 = 0x19, + ANIM_MT_MANTLE_UP_33 = 0x1A, + ANIM_MT_MANTLE_UP_27 = 0x1B, + ANIM_MT_MANTLE_UP_21 = 0x1C, + ANIM_MT_MANTLE_OVER_HIGH = 0x1D, + ANIM_MT_MANTLE_OVER_MID = 0x1E, + ANIM_MT_MANTLE_OVER_LOW = 0x1F, + ANIM_MT_FLINCH_FORWARD = 0x20, + ANIM_MT_FLINCH_BACKWARD = 0x21, + ANIM_MT_FLINCH_LEFT = 0x22, + ANIM_MT_FLINCH_RIGHT = 0x23, + ANIM_MT_STUMBLE_FORWARD = 0x24, + ANIM_MT_STUMBLE_BACKWARD = 0x25, + ANIM_MT_STUMBLE_WALK_FORWARD = 0x26, + ANIM_MT_STUMBLE_WALK_BACKWARD = 0x27, + ANIM_MT_STUMBLE_CROUCH_FORWARD = 0x28, + ANIM_MT_STUMBLE_CROUCH_BACKWARD = 0x29, + ANIM_MT_STUMBLE_SPRINT_FORWARD = 0x2A, + ANIM_MT_SWIM = 0x2B, + ANIM_MT_SWIMBK = 0x2C, + NUM_ANIM_MOVETYPES = 0x2D, + }; + + enum animScriptConditionTypes_t : __int32 + { + ANIM_CONDTYPE_BITFLAGS = 0x0, + ANIM_CONDTYPE_VALUE = 0x1, + ANIM_CONDTYPE_ENABLED = 0x2, + ANIM_CONDTYPE_STRINGHASH = 0x3, + NUM_ANIM_CONDTYPES = 0x4, + }; + + enum animScriptParseMode_t : __int32 + { + PARSEMODE_DEFINES = 0x0, + PARSEMODE_ANIMATION = 0x1, + PARSEMODE_CANNED_ANIMATIONS = 0x2, + PARSEMODE_STATECHANGES = 0x3, + PARSEMODE_EVENTS = 0x4, + NUM_PARSEMODES = 0x5, + }; + + enum aistateEnum_t : __int32 + { + AISTATE_COMBAT = 0x0, + MAX_AISTATES = 0x1, + }; + + enum pmoveVehAnimState_t : __int32 + { + PMOVE_VEH_ANIM_STATE_PLAYING = 0x0, + PMOVE_VEH_ANIM_STATE_END_STAGE = 0x1, + PMOVE_VEH_ANIM_STATE_COMPLETE = 0x2, + }; + + enum itemType_t : __int32 + { + IT_BAD = 0x0, + IT_WEAPON = 0x1, + }; + + enum proneCheckType_t : __int32 + { + PCT_CLIENT = 0x0, + PCT_ACTOR = 0x1, + }; + + enum PmStanceFrontBack : __int32 + { + PM_STANCE_STAND = 0x0, + PM_STANCE_PRONE = 0x1, + PM_STANCE_CROUCH = 0x2, + PM_STANCE_BACKWARD_FIRST = 0x3, + PM_STANCE_BACKWARD_RUN = 0x3, + PM_STANCE_BACKWARD_PRONE = 0x4, + PM_STANCE_BACKWARD_CROUCH = 0x5, + NUM_PM_STANCE_FRONTBACK = 0x6, + }; + + enum scriptAnimStrafeStates_t : __int32 + { + ANIM_STRAFE_NOT = 0x0, + ANIM_STRAFE_LEFT = 0x1, + ANIM_STRAFE_RIGHT = 0x2, + NUM_ANIM_STRAFESTATES = 0x3, + }; + + enum VehicleSeatPositions : unsigned __int32 + { + VEH_POS_NONE = 0xFFFFFFFF, + VEH_POS_DRIVER = 0x0, + VEH_POS_MIN_GUNNER = 0x1, + VEH_POS_GUNNER_1 = 0x1, + VEH_POS_GUNNER_2 = 0x2, + VEH_POS_GUNNER_3 = 0x3, + VEH_POS_GUNNER_4 = 0x4, + VEH_POS_MAX_GUNNER = 0x4, + VEH_POS_MIN_PASSENGER = 0x5, + VEH_POS_PASSENGER_1 = 0x5, + VEH_POS_PASSENGER_2 = 0x6, + VEH_POS_PASSENGER_3 = 0x7, + VEH_POS_PASSENGER_4 = 0x8, + VEH_POS_MAX_PASSENGER = 0x8, + VEH_POS_MANTLE = 0x9, + NUM_VEHICLE_POSITIONS = 0xA, + }; + + enum CompassType : __int32 + { + COMPASS_TYPE_PARTIAL = 0x0, + COMPASS_TYPE_FULL = 0x1, + }; + + enum BlurPriority : __int32 + { + BLUR_PRIORITY_NONE = 0x0, + BLUR_PRIORITY_SCRIPT = 0x1, + BLUR_PRIORITY_CODE = 0x2, + }; + + enum BlurTime : __int32 + { + BLUR_TIME_RELATIVE = 0x0, + BLUR_TIME_ABSOLUTE = 0x1, + }; + + enum operationEnum : __int32 + { + OP_NOOP = 0x0, + OP_RIGHTPAREN = 0x1, + OP_MULTIPLY = 0x2, + OP_DIVIDE = 0x3, + OP_MODULUS = 0x4, + OP_ADD = 0x5, + OP_SUBTRACT = 0x6, + OP_NOT = 0x7, + OP_LESSTHAN = 0x8, + OP_LESSTHANEQUALTO = 0x9, + OP_GREATERTHAN = 0xA, + OP_GREATERTHANEQUALTO = 0xB, + OP_EQUALS = 0xC, + OP_NOTEQUAL = 0xD, + OP_AND = 0xE, + OP_OR = 0xF, + OP_LEFTPAREN = 0x10, + OP_COMMA = 0x11, + OP_BITWISEAND = 0x12, + OP_BITWISEOR = 0x13, + OP_BITWISENOT = 0x14, + OP_BITSHIFTLEFT = 0x15, + OP_BITSHIFTRIGHT = 0x16, + OP_SIN = 0x17, + OP_FIRSTFUNCTIONCALL = 0x17, + OP_COS = 0x18, + OP_MIN = 0x19, + OP_MAX = 0x1A, + OP_MILLISECONDS = 0x1B, + OP_DVARINT = 0x1C, + OP_DVARBOOL = 0x1D, + OP_DVARFLOAT = 0x1E, + OP_DVARSTRING = 0x1F, + OP_STAT = 0x20, + OP_UIACTIVE = 0x21, + OP_FLASHBANGED = 0x22, + OP_SCOPED = 0x23, + OP_SCOREBOARDVISIBLE = 0x24, + OP_INKILLCAM = 0x25, + OP_PLAYERFIELD = 0x26, + OP_SELECTINGLOCATION = 0x27, + OP_TEAMFIELD = 0x28, + OP_OTHERTEAMFIELD = 0x29, + OP_MARINESFIELD = 0x2A, + OP_OPFORFIELD = 0x2B, + OP_MENUISOPEN = 0x2C, + OP_WRITINGDATA = 0x2D, + OP_INLOBBY = 0x2E, + OP_INPRIVATEPARTY = 0x2F, + OP_PRIVATEPARTYHOST = 0x30, + OP_PRIVATEPARTYHOSTINLOBBY = 0x31, + OP_ALONEINPARTY = 0x32, + OP_ADSJAVELIN = 0x33, + OP_WEAPLOCKBLINK = 0x34, + OP_WEAPATTACKTOP = 0x35, + OP_WEAPATTACKDIRECT = 0x36, + OP_SECONDSASTIME = 0x37, + OP_TABLELOOKUP = 0x38, + OP_LOCALIZESTRING = 0x39, + OP_LOCALVARINT = 0x3A, + OP_LOCALVARBOOL = 0x3B, + OP_LOCALVARFLOAT = 0x3C, + OP_LOCALVARSTRING = 0x3D, + OP_TIMELEFT = 0x3E, + OP_SECONDSASCOUNTDOWN = 0x3F, + OP_GAMEMSGWNDACTIVE = 0x40, + OP_TOINT = 0x41, + OP_TOSTRING = 0x42, + OP_TOFLOAT = 0x43, + OP_GAMETYPENAME = 0x44, + OP_GAMETYPE = 0x45, + OP_GAMETYPEDESCRIPTION = 0x46, + OP_SCORE = 0x47, + OP_FRIENDSONLINE = 0x48, + OP_FOLLOWING = 0x49, + OP_STATRANGEBITSSET = 0x4A, + OP_KEYBINDING = 0x4B, + OP_ACTIONSLOTUSABLE = 0x4C, + OP_HUDFADE = 0x4D, + OP_MAXPLAYERS = 0x4E, + OP_ACCEPTINGINVITE = 0x4F, + OP_GAMEHOST = 0x50, + OP_ISSPLITSCREEN = 0x51, + OP_ISSPLITSCREENHOST = 0x52, + OP_SPLITSCREENNUM = 0x53, + OP_ISCINEMATICFINISHED = 0x54, + OP_ISSQUADLEADER = 0x55, + OP_GETSQUADID = 0x56, + OP_ISARTILLERY = 0x57, + OP_GETPLAYERSQUADID = 0x58, + OP_HASFRIENDS = 0x59, + OP_HASPENDINGFRIENDS = 0x5A, + OP_HASINVITES = 0x5B, + OP_SQUADINVITESENT = 0x5C, + OP_IFTHENELSE = 0x5D, + OP_PLAYERPROFILENAME = 0x5E, + OP_PLAYERPROFILEDEFINED = 0x5F, + NUM_OPERATORS = 0x60, + }; + + enum snd_overlay_type_t : __int32 + { + SND_OVERLAY_NONE = 0x0, + SND_OVERLAY_3D = 0x1, + SND_OVERLAY_STREAM = 0x2, + SND_OVERLAY_2D = 0x3, + }; + + enum uiMenuCommand_t : __int32 + { + UIMENU_NONE = 0x0, + UIMENU_MAIN = 0x1, + UIMENU_INGAME = 0x2, + UIMENU_PREGAME = 0x3, + UIMENU_POSTGAME = 0x4, + UIMENU_WM_QUICKMESSAGE = 0x5, + UIMENU_CLIPBOARD = 0x6, + UIMENU_BRIEFING = 0x7, + UIMENU_VICTORYSCREEN = 0x8, + UIMENU_SAVEERROR = 0x9, + UIMENU_SAVE_LOADING = 0xA, + UIMENU_SAVE_SAVING = 0xB, + UIMENU_SCRIPT_POPUP = 0xC, + UIMENU_SPLITSCREENGAMESETUP = 0xD, + UIMENU_SYSTEMLINKJOINGAME = 0xE, + UIMENU_PARTY = 0xF, + UIMENU_GAMELOBBY = 0x10, + UIMENU_PRIVATELOBBY = 0x11, + UIMENU_CONTROLLERREMOVED = 0x12, + UIMENU_NUNCHUKREMOVED = 0x13, + UIMENU_UNKNOWNCONTROLLER = 0x14, + }; + + enum SaveBufferState : __int32 + { + MEMCLEAR = 0x0, + MEMALLOCATING = 0x1, + MEMALLOCATED = 0x2, + SAVING = 0x3, + AWAITING_COMMIT = 0x4, + COMMITTED = 0x5, + LOADING = 0x6, + }; + + enum LaserOwnerEnum : __int32 + { + LASER_OWNER_NON_PLAYER = 0x0, + LASER_OWNER_PLAYER = 0x1, + }; + + enum leType_t : __int32 + { + LE_MOVING_TRACER = 0x0, + }; + + enum ZapperMenuSelectionMethod : __int32 + { + ZAPPER_MENU_SELECT_NONE = 0x0, + ZAPPER_MENU_SELECT_POINT = 0x1, + ZAPPER_MENU_SELECT_POINT_AND_HOLD = 0x2, + ZAPPER_MENU_SELECT_POINT_AND_SHOOT = 0x3, + ZAPPER_MENU_SELECT_POINT_AND_SHAKE = 0x4, + ZAPPER_MENU_SELECT_POINT_OR_TILT = 0x5, + ZAPPER_MENU_SELECT_POINT_OR_TAP = 0x6, + ZAPPER_MENU_SELECT_EXCLUSIVE_TAP = 0x7, + ZAPPER_MENU_SELECT_TWIST_OR_TAP = 0x8, + ZAPPER_MENU_SELECT_NUM = 0x9, + }; + + enum RumbleSourceType : __int32 + { + RUMBLESOURCE_INVALID = 0x0, + RUMBLESOURCE_ENTITY = 0x1, + RUMBLESOURCE_POS = 0x2, + }; + + enum Clip_t : __int32 + { + CLIP_NONE = 0x0, + CLIP_TOP = 0x1, + CLIP_BOTTOM = 0x2, + CLIP_RIGHT = 0x3, + CLIP_LEFT = 0x4, + }; + + enum print_msg_dest_t : __int32 + { + CON_DEST_CONSOLE = 0x0, + CON_DEST_MINICON = 0x1, + CON_DEST_ERROR = 0x2, + CON_DEST_GAME_FIRST = 0x3, + CON_DEST_GAME1 = 0x3, + CON_DEST_GAME2 = 0x4, + CON_DEST_GAME3 = 0x5, + CON_DEST_GAME4 = 0x6, + CON_DEST_GAME_LAST = 0x6, + CON_DEST_COUNT = 0x7, + }; + + enum msgwnd_mode_t : __int32 + { + MWM_BOTTOMUP_ALIGN_TOP = 0x0, + MWM_BOTTOMUP_ALIGN_BOTTOM = 0x1, + MWM_TOPDOWN_ALIGN_TOP = 0x2, + MWM_TOPDOWN_ALIGN_BOTTOM = 0x3, + }; + + enum LocSelInputState : __int32 + { + LOC_SEL_INPUT_NONE = 0x0, + LOC_SEL_INPUT_CONFIRM = 0x1, + LOC_SEL_INPUT_REGROUP = 0x2, + LOC_SEL_INPUT_DEFEND = 0x3, + LOC_SEL_INPUT_SQUAD_CANCEL = 0x4, + LOC_SEL_INPUT_CANCEL = 0x5, + }; + + enum GamepadPhysicalAxis + { + GPAD_PHYSAXIS_RSTICK_X = 0x0, + GPAD_PHYSAXIS_RSTICK_Y = 0x1, + GPAD_PHYSAXIS_LSTICK_X = 0x2, + GPAD_PHYSAXIS_LSTICK_Y = 0x3, + GPAD_PHYSAXIS_RTRIGGER = 0x4, + GPAD_PHYSAXIS_LTRIGGER = 0x5, + GPAD_PHYSAXIS_COUNT = 0x6, + GPAD_PHYSAXIS_NONE = 0xFFFFFFFF, + }; + + enum GamepadMapping + { + GPAD_MAP_LINEAR = 0x0, + GPAD_MAP_SQUARED = 0x1, + GPAD_MAP_COUNT = 0x2, + GPAD_MAP_NONE = 0xFFFFFFFF, + }; + + enum keyNum_t : __int32 + { + K_NONE = 0x0, + K_FIRSTGAMEPADBUTTON_RANGE_1 = 0x1, + K_BUTTON_A = 0x1, + K_BUTTON_B = 0x2, + K_BUTTON_X = 0x3, + K_BUTTON_Y = 0x4, + K_BUTTON_LSHLDR = 0x5, + K_BUTTON_RSHLDR = 0x6, + K_LASTGAMEPADBUTTON_RANGE_1 = 0x6, + K_TAB = 0x9, + K_ENTER = 0xD, + K_FIRSTGAMEPADBUTTON_RANGE_2 = 0xE, + K_BUTTON_START = 0xE, + K_BUTTON_BACK = 0xF, + K_BUTTON_LSTICK = 0x10, + K_BUTTON_RSTICK = 0x11, + K_BUTTON_LTRIG = 0x12, + K_BUTTON_RTRIG = 0x13, + K_DPAD_UP = 0x14, + K_FIRSTDPAD = 0x14, + K_DPAD_DOWN = 0x15, + K_DPAD_LEFT = 0x16, + K_DPAD_RIGHT = 0x17, + K_BUTTON_LSTICK_ALTIMAGE = 0xBC, + K_BUTTON_RSTICK_ALTIMAGE = 0xBD, + K_LASTDPAD = 0x17, + K_LASTGAMEPADBUTTON_RANGE_2 = 0x17, + K_ESCAPE = 0x1B, + K_FIRSTGAMEPADBUTTON_RANGE_3 = 0x1C, + K_APAD_UP = 0x1C, + K_FIRSTAPAD = 0x1C, + K_APAD_DOWN = 0x1D, + K_APAD_LEFT = 0x1E, + K_APAD_RIGHT = 0x1F, + K_LASTAPAD = 0x1F, + K_LASTGAMEPADBUTTON_RANGE_3 = 0x1F, + K_SPACE = 0x20, + K_FIRSTBUDDYBUTTON_RANGE = 0x21, + K_BUTTON_A_ALT = 0x21, + K_BUTTON_B_ALT = 0x22, + K_BUTTON_C_ALT = 0x23, + K_BUTTON_Z_ALT = 0x24, + K_BUTTON_X_ALT = 0x25, + K_BUTTON_Y_ALT = 0x26, + K_BUTTON_PLUS_ALT = 0x27, + K_BUTTON_MINUS_ALT = 0x28, + K_DPAD_LEFT_ALT = 0x29, + K_DPAD_RIGHT_ALT = 0x2A, + K_LASTBUDDYBUTTON_RANGE = 0x2A, + K_BACKSPACE = 0x7F, + K_ASCII_FIRST = 0x80, + K_ASCII_181 = 0x80, + K_ASCII_191 = 0x81, + K_ASCII_223 = 0x82, + K_ASCII_224 = 0x83, + K_ASCII_225 = 0x84, + K_ASCII_228 = 0x85, + K_ASCII_229 = 0x86, + K_ASCII_230 = 0x87, + K_ASCII_231 = 0x88, + K_ASCII_232 = 0x89, + K_ASCII_233 = 0x8A, + K_ASCII_236 = 0x8B, + K_ASCII_241 = 0x8C, + K_ASCII_242 = 0x8D, + K_ASCII_243 = 0x8E, + K_ASCII_246 = 0x8F, + K_ASCII_248 = 0x90, + K_ASCII_249 = 0x91, + K_ASCII_250 = 0x92, + K_ASCII_252 = 0x93, + K_END_ASCII_CHARS = 0x94, + K_COMMAND = 0x96, + K_CAPSLOCK = 0x97, + K_POWER = 0x98, + K_PAUSE = 0x99, + K_UPARROW = 0x9A, + K_DOWNARROW = 0x9B, + K_LEFTARROW = 0x9C, + K_RIGHTARROW = 0x9D, + K_ALT = 0x9E, + K_CTRL = 0x9F, + K_SHIFT = 0xA0, + K_INS = 0xA1, + K_DEL = 0xA2, + K_PGDN = 0xA3, + K_PGUP = 0xA4, + K_HOME = 0xA5, + K_END = 0xA6, + K_F1 = 0xA7, + K_F2 = 0xA8, + K_F3 = 0xA9, + K_F4 = 0xAA, + K_F5 = 0xAB, + K_F6 = 0xAC, + K_F7 = 0xAD, + K_F8 = 0xAE, + K_F9 = 0xAF, + K_F10 = 0xB0, + K_F11 = 0xB1, + K_F12 = 0xB2, + K_F13 = 0xB3, + K_F14 = 0xB4, + K_F15 = 0xB5, + K_KP_HOME = 0xB6, + K_KP_UPARROW = 0xB7, + K_KP_PGUP = 0xB8, + K_KP_LEFTARROW = 0xB9, + K_KP_5 = 0xBA, + K_KP_RIGHTARROW = 0xBB, + K_KP_END = 0xBC, + K_KP_DOWNARROW = 0xBD, + K_KP_PGDN = 0xBE, + K_KP_ENTER = 0xBF, + K_KP_INS = 0xC0, + K_KP_DEL = 0xC1, + K_KP_SLASH = 0xC2, + K_KP_MINUS = 0xC3, + K_KP_PLUS = 0xC4, + K_KP_NUMLOCK = 0xC5, + K_KP_STAR = 0xC6, + K_KP_EQUALS = 0xC7, + K_MOUSE1 = 0xC8, + K_MOUSE2 = 0xC9, + K_MOUSE3 = 0xCA, + K_MOUSE4 = 0xCB, + K_MOUSE5 = 0xCC, + K_MWHEELDOWN = 0xCD, + K_MWHEELUP = 0xCE, + K_AUX1 = 0xCF, + K_AUX2 = 0xD0, + K_AUX3 = 0xD1, + K_AUX4 = 0xD2, + K_AUX5 = 0xD3, + K_AUX6 = 0xD4, + K_AUX7 = 0xD5, + K_AUX8 = 0xD6, + K_AUX9 = 0xD7, + K_AUX10 = 0xD8, + K_AUX11 = 0xD9, + K_AUX12 = 0xDA, + K_AUX13 = 0xDB, + K_AUX14 = 0xDC, + K_AUX15 = 0xDD, + K_AUX16 = 0xDE, + K_LAST_KEY = 0xDF, + }; + + enum GamepadVirtualAxis : unsigned __int32 + { + GPAD_VIRTAXIS_SIDE = 0x0, + GPAD_VIRTAXIS_FORWARD = 0x1, + GPAD_VIRTAXIS_UP = 0x2, + GPAD_VIRTAXIS_YAW = 0x3, + GPAD_VIRTAXIS_PITCH = 0x4, + GPAD_VIRTAXIS_ATTACK = 0x5, + GPAD_VIRTAXIS_ROLL = 0x6, + GPAD_VIRTAXIS_PITCH_BUDDY = 0x7, + GPAD_VIRTAXIS_YAW_BUDDY = 0x8, + GPAD_VIRTAXIS_COUNT = 0x9, + GPAD_VIRTAXIS_NONE = 0xFFFFFFFF, + }; + + enum GamePadStick : __int32 + { + GPAD_INVALID = 0x0, + GPAD_LX = 0x40000000, + GPAD_LY = 0x40000001, + GPAD_RX = 0x40000002, + GPAD_RY = 0x40000003, + GPAD_HORIZON = 0x40000004, + }; + + enum INITIAL_SAVE_STATE : __int32 + { + INITIAL_SAVE_STATE_START = 0x0, + INITIAL_SAVE_STATE_WAITINGONUI1 = 0x1, + INITIAL_SAVE_STATE_WAITINGONUI2 = 0x2, + INITIAL_SAVE_STATE_SAVE = 0x3, + INITIAL_SAVE_STATE_DONE = 0x4, + }; + + enum snd_alias_type_t : __int32 + { + SAT_UNKNOWN = 0x0, + SAT_LOADED = 0x1, + SAT_STREAMED = 0x2, + SAT_PRIMED = 0x3, + SAT_COUNT = 0x4, + }; + + enum gpuTextureFormat : __int32 + { + GPU_TEXTURE_DXT1 = 0xE, + GPU_TEXTURE_L8 = 0x1, + GPU_TEXTURE_U8 = 0x1, + GPU_TEXTURE_V8 = 0x1, + GPU_TEXTURE_Y8 = 0x1, + GPU_TEXTURE_R5G6B5 = 0x4, + GPU_TEXTURE_R5G5B5A3 = 0x5, + GPU_TEXTURE_A8R8G8B8 = 0x6, + GPU_TEXTURE_A8L8 = 0x3, + GPU_TEXTURE_L4 = 0x0, + GPU_TEXTURE_A4L4 = 0x2, + GPU_TEXTURE_C4 = 0x8, + GPU_TEXTURE_C8 = 0x9, + GPU_TEXTURE_R8G8B8_EFB = 0xA, + GPU_TEXTURE_R5G6B5_EFB = 0xB, + GPU_TEXTURE_Z8 = 0xC, + GPU_TEXTURE_Z16 = 0xD, + GPU_TEXTURE_Z24 = 0xE, + GPU_TEXTURE_A6R6G6B6_EFB = 0xF, + }; + + enum MaterialWorldVertexFormat : __int32 + { + MTL_WORLDVERT_TEX_1_NRM_1 = 0x0, + MTL_WORLDVERT_TEX_2_NRM_1 = 0x1, + MTL_WORLDVERT_TEX_2_NRM_2 = 0x2, + MTL_WORLDVERT_TEX_3_NRM_1 = 0x3, + MTL_WORLDVERT_TEX_3_NRM_2 = 0x4, + MTL_WORLDVERT_TEX_3_NRM_3 = 0x5, + MTL_WORLDVERT_TEX_4_NRM_1 = 0x6, + MTL_WORLDVERT_TEX_4_NRM_2 = 0x7, + MTL_WORLDVERT_TEX_4_NRM_3 = 0x8, + MTL_WORLDVERT_TEX_5_NRM_1 = 0x9, + MTL_WORLDVERT_TEX_5_NRM_2 = 0xA, + MTL_WORLDVERT_TEX_5_NRM_3 = 0xB, + }; + + enum GfxLightType : __int32 + { + GFX_LIGHT_TYPE_NONE = 0x0, + GFX_LIGHT_TYPE_DIR = 0x1, + GFX_LIGHT_TYPE_SPOT = 0x2, + GFX_LIGHT_TYPE_OMNI = 0x3, + GFX_LIGHT_TYPE_COUNT = 0x4, + GFX_LIGHT_TYPE_DIR_SHADOWMAP = 0x4, + GFX_LIGHT_TYPE_SPOT_SHADOWMAP = 0x5, + GFX_LIGHT_TYPE_OMNI_SHADOWMAP = 0x6, + GFX_LIGHT_TYPE_COUNT_WITH_SHADOWMAP_VERSIONS = 0x7, + }; + + enum weapAnimFiles_t : __int32 + { + WEAP_ANIM_ROOT = 0x0, + WEAP_ANIM_IDLE = 0x1, + WEAP_ANIM_EMPTY_IDLE = 0x2, + WEAP_ANIM_FIRE = 0x3, + WEAP_ANIM_HOLD_FIRE = 0x4, + WEAP_ANIM_LASTSHOT = 0x5, + WEAP_ANIM_RECHAMBER = 0x6, + WEAP_ANIM_MELEE = 0x7, + WEAP_ANIM_MELEE_CHARGE = 0x8, + WEAP_ANIM_RELOAD = 0x9, + WEAP_ANIM_RELOAD_EMPTY = 0xA, + WEAP_ANIM_RELOAD_START = 0xB, + WEAP_ANIM_RELOAD_END = 0xC, + WEAP_ANIM_RAISE = 0xD, + WEAP_ANIM_FIRST_RAISE = 0xE, + WEAP_ANIM_DROP = 0xF, + WEAP_ANIM_ALT_RAISE = 0x10, + WEAP_ANIM_ALT_DROP = 0x11, + WEAP_ANIM_QUICK_RAISE = 0x12, + WEAP_ANIM_QUICK_DROP = 0x13, + WEAP_ANIM_EMPTY_RAISE = 0x14, + WEAP_ANIM_EMPTY_DROP = 0x15, + WEAP_ANIM_SPRINT_IN = 0x16, + WEAP_ANIM_SPRINT_LOOP = 0x17, + WEAP_ANIM_SPRINT_OUT = 0x18, + WEAP_ANIM_DEPLOY = 0x19, + WEAP_ANIM_BREAKDOWN = 0x1A, + WEAP_ANIM_DETONATE = 0x1B, + WEAP_ANIM_NIGHTVISION_WEAR = 0x1C, + WEAP_ANIM_NIGHTVISION_REMOVE = 0x1D, + WEAP_ANIM_ADS_FIRE = 0x1E, + WEAP_ANIM_ADS_LASTSHOT = 0x1F, + WEAP_ANIM_ADS_RECHAMBER = 0x20, + WEAP_ANIM_ADS_UP = 0x21, + WEAP_ANIM_ADS_DOWN = 0x22, + NUM_WEAP_ANIMS = 0x23, + }; + + enum weapPositionAnimNum_t : __int32 + { + WEAPPOS_HIP_TO_ADS = 0x0, + WEAPPOS_ADS_TO_HIP = 0x1, + NUM_WEAPPOS_ANIMS = 0x2, + }; + + enum WeapAccuracyType : __int32 + { + WEAP_ACCURACY_AI_VS_AI = 0x0, + WEAP_ACCURACY_AI_VS_PLAYER = 0x1, + WEAP_ACCURACY_COUNT = 0x2, + }; + + enum weaponAltModel_t : __int32 + { + WEAP_ALT_MODEL0 = 0x0, + WEAP_ALT_MODEL1 = 0x1, + WEAP_ALT_MODEL2 = 0x2, + WEAP_ALT_MODEL3 = 0x3, + WEAP_ALT_MODEL4 = 0x4, + WEAP_ALT_MODEL5 = 0x5, + WEAP_ALT_MODEL6 = 0x6, + WEAP_ALT_MODEL7 = 0x7, + WEAP_ALT_MODEL8 = 0x8, + WEAP_ALT_MODEL9 = 0x9, + WEAP_ALT_MODEL10 = 0xA, + WEAP_ALT_MODEL11 = 0xB, + WEAP_ALT_MODEL12 = 0xC, + WEAP_ALT_MODEL13 = 0xD, + WEAP_ALT_MODEL14 = 0xE, + WEAP_ALT_MODEL15 = 0xF, + NUM_WEAP_ALTMODELS = 0x10, + }; + + enum nglCullType : __int32 + { + NGL_CULL_NONE = 0x0, + NGL_CULL_FRONT = 0x1, + NGL_CULL_BACK = 0x2, + NGL_CULL_ALL = 0x3, + }; + + enum _GXCompare : __int32 + { + GX_NEVER = 0x0, + GX_LESS = 0x1, + GX_EQUAL = 0x2, + GX_LEQUAL = 0x3, + GX_GREATER = 0x4, + GX_NEQUAL = 0x5, + GX_GEQUAL = 0x6, + GX_ALWAYS = 0x7, + }; + + enum nflMediaID : unsigned __int32 + { + NFL_MEDIA_ID_DISC = 0x1, + NFL_MEDIA_ID_HOST = 0x2, + NFL_MEDIA_ID_LINK = 0x4, + NFL_MEDIA_ID_DEFAULT = 0x3, + NFL_MEDIA_ID_ALL = 0x7FFFFFFF, + NFL_MEDIA_ID_INVALID = 0xFFFFFFFF, + }; + + enum DynEntityDrawType : __int32 + { + DYNENT_DRAW_MODEL = 0x0, + DYNENT_DRAW_BRUSH = 0x1, + DYNENT_DRAW_COUNT = 0x2, + }; + + enum DynEntityCollType : __int32 + { + DYNENT_COLL_CLIENT_FIRST = 0x0, + DYNENT_COLL_CLIENT_MODEL = 0x0, + DYNENT_COLL_CLIENT_BRUSH = 0x1, + DYNENT_COLL_SERVER_FIRST = 0x2, + DYNENT_COLL_SERVER_MODEL = 0x2, + DYNENT_COLL_SERVER_BRUSH = 0x3, + DYNENT_COLL_COUNT = 0x4, + }; + + enum FxUpdateResult : __int32 + { + FX_UPDATE_REMOVE = 0x0, + FX_UPDATE_KEEP = 0x1, + }; + + enum enumLastShot : __int32 + { + LAST_SHOT_IN_CLIP = 0x0, + NOT_LAST_SHOT_IN_CLIP = 0x1, + }; + + enum PARM_SUPPRESSION : __int32 + { + DO_SUPPRESSION = 0x0, + DONT_SUPPRESS = 0x1, + }; + + enum PredictionTraceResult : __int32 + { + PTR_SUCCESS = 0x0, + PTR_HIT_WORLD = 0x1, + PTR_HIT_ENTITY = 0x2, + }; + + enum SlideMoveResult : __int32 + { + SLIDEMOVE_COMPLETE = 0x0, + SLIDEMOVE_CLIPPED = 0x1, + SLIDEMOVE_FAIL = 0x2, + }; + + enum ai_teammove_t : __int32 + { + AI_TEAMMOVE_TRAVEL = 0x0, + AI_TEAMMOVE_WAIT = 0x1, + AI_TEAMMOVE_SLOW_DOWN = 0x2, + }; + + enum weaponstate_t : __int32 + { + WEAPON_READY = 0x0, + WEAPON_RAISING = 0x1, + WEAPON_RAISING_ALTSWITCH = 0x2, + WEAPON_DROPPING = 0x3, + WEAPON_DROPPING_QUICK = 0x4, + WEAPON_FIRING = 0x5, + WEAPON_RECHAMBERING = 0x6, + WEAPON_RELOADING = 0x7, + WEAPON_RELOADING_INTERUPT = 0x8, + WEAPON_RELOAD_START = 0x9, + WEAPON_RELOAD_START_INTERUPT = 0xA, + WEAPON_RELOAD_END = 0xB, + WEAPON_MELEE_CHARGE = 0xC, + WEAPON_MELEE_INIT = 0xD, + WEAPON_MELEE_FIRE = 0xE, + WEAPON_MELEE_END = 0xF, + WEAPON_OFFHAND_INIT = 0x10, + WEAPON_OFFHAND_PREPARE = 0x11, + WEAPON_OFFHAND_HOLD = 0x12, + WEAPON_OFFHAND_START = 0x13, + WEAPON_OFFHAND = 0x14, + WEAPON_OFFHAND_END = 0x15, + WEAPON_DETONATING = 0x16, + WEAPON_SPRINT_RAISE = 0x17, + WEAPON_SPRINT_LOOP = 0x18, + WEAPON_SPRINT_DROP = 0x19, + WEAPON_DEPLOYING = 0x1A, + WEAPON_DEPLOYED = 0x1B, + WEAPON_BREAKING_DOWN = 0x1C, + WEAPON_SWIM_IN = 0x1D, + WEAPON_SWIM_OUT = 0x1E, + WEAPONSTATES_NUM = 0x1F, + }; + + enum saveFieldtype_t : __int32 + { + SF_NONE = 0x0, + SF_STRING = 0x1, + SF_ENTITY = 0x2, + SF_ENTHANDLE = 0x3, + SF_CLIENT = 0x4, + SF_ACTOR = 0x5, + SF_SENTIENT = 0x6, + SF_SENTIENTHANDLE = 0x7, + SF_VEHICLE = 0x8, + SF_TURRETINFO = 0x9, + SF_DESTRUCTIBLE = 0xA, + SF_THREAD = 0xB, + SF_ANIMSCRIPT = 0xC, + SF_PATHNODE = 0xD, + SF_ANIMTREE = 0xE, + SF_TYPE_TAG_INFO = 0xF, + SF_TYPE_SCRIPTED = 0x10, + SF_MODELUSHORT = 0x11, + SF_MODELINT = 0x12, + }; + + enum SaveErrorType : __int32 + { + SAVE_ERROR_MISSING_DEVICE = 0x0, + SAVE_ERROR_CORRUPT_SAVE = 0x1, + }; + + enum SaveType : __int32 + { + SAVE_TYPE_INTERNAL = 0x0, + SAVE_TYPE_AUTOSAVE = 0x1, + SAVE_TYPE_CONSOLE = 0x2, + }; + + enum VehicleMantlePoints : __int32 + { + MANTLE_ANGLE_FRONT = 0x0, + MANTLE_ANGLE_BACK = 0x1, + MANTLE_ANGLE_LEFT = 0x2, + MANTLE_ANGLE_RIGHT = 0x3, + MANTLE_ANGLE_MAX = 0x4, + }; + + enum nearestNodeHeightCheck : __int32 + { + NEAREST_NODE_DO_HEIGHT_CHECK = 0x0, + NEAREST_NODE_DONT_DO_HEIGHT_CHECK = 0x1, + }; + + enum phys_proftimer_e : __int32 + { + phys_proftimer_buoyancy = 0x0, + phys_proftimer_terrain_query = 0x1, + phys_proftimer_dent_query = 0x2, + phys_proftimer_phys_collision_total = 0x3, + phys_proftimer_phys_collision_prolog = 0x4, + phys_proftimer_collision_broad_phase = 0x5, + phys_proftimer_collision_object_environment = 0x6, + phys_proftimer_collision_terrain_query = 0x7, + phys_proftimer_generate_clusters0 = 0x8, + phys_proftimer_generate_clusters1 = 0x9, + phys_proftimer_generate_clusters2 = 0xA, + phys_proftimer_generate_clusters3 = 0xB, + phys_proftimer_collision_self = 0xC, + phys_proftimer_collision_object_object = 0xD, + phys_proftimer_aasap_sort0 = 0xE, + phys_proftimer_aasap_sort1 = 0xF, + phys_proftimer_aasap_sort2 = 0x10, + phys_proftimer_aasap_sort = 0x11, + phys_proftimer_aasap_process = 0x12, + phys_proftimer_collision_narrow_phase = 0x13, + phys_proftimer_collision_narrow_phase_finish = 0x14, + phys_proftimer_collision_rbc_update = 0x15, + phys_proftimer_gjk = 0x16, + phys_proftimer_gjk_query = 0x17, + phys_proftimer_contact_manifold = 0x18, + phys_proftimer_gjk_support = 0x19, + phys_proftimer_phys_misc = 0x1A, + phys_proftimer_phys_generate_partitions = 0x1B, + phys_proftimer_phys_priority_sort = 0x1C, + phys_proftimer_phys_rbc_contact_purge = 0x1D, + phys_proftimer_phys_solver = 0x1E, + phys_proftimer_phys_ppu_solver = 0x1F, + phys_proftimer_phys_solver_setup = 0x20, + phys_proftimer_phys_solver_iterative = 0x21, + phys_proftimer_phys_solver_epilog = 0x22, + num_phys_proftimers = 0x23, + }; + + enum phys_profcounter_e : __int32 + { + phys_profcounter_angular_ke_dif = 0x0, + phys_profcounter_total_possible_clusters = 0x1, + phys_profcounter_total_clusters = 0x2, + phys_profcounter_cluster_compare = 0x3, + phys_profcounter_total_rigid_bodies = 0x4, + phys_profcounter_total_pcps = 0x5, + phys_profcounter_total_solver_islands = 0x6, + phys_profcounter_total_ppu_solver_islands = 0x7, + phys_profcounter_total_contact_cache_hit = 0x8, + phys_profcounter_total_contact_cache_miss = 0x9, + num_phys_profcounters = 0xA, + }; + + enum Phys_SurfaceType : __int32 + { + EFFECT_SURF_TYPE_HARD = 0x0, + EFFECT_SURF_TYPE_SOFT = 0x1, + EFFECT_SURF_TYPE_METAL = 0x2, + EFFECT_SURF_TYPE_GLASS = 0x3, + EFFECT_SURF_TYPE_WATER = 0x4, + EFFECT_SURF_TYPE_WOOD = 0x5, + EFFECT_SURF_TYPE_FOLIAGE = 0x6, + EFFECT_SURF_TYPE_FLESH = 0x7, + EFFECT_SURF_TYPE_COUNT = 0x8, + }; + + enum SphereEdgeTraceResult : __int32 + { + SPHERE_HITS_EDGE = 0x0, + SPHERE_MISSES_EDGE = 0x1, + SPHERE_MAY_HIT_V0 = 0x2, + SPHERE_MAY_HIT_V1 = 0x3, + }; + + enum GamePadButton : __int32 + { + GPAD_NONE = 0x0, + GPAD_UP = 0x10000008, + GPAD_DOWN = 0x10000004, + GPAD_LEFT = 0x10000001, + GPAD_RIGHT = 0x10000002, + GPAD_START = 0x10000010, + GPAD_BACK = 0x10004800, + GPAD_L3 = 0x10005000, + GPAD_R3 = 0x10004000, + GPAD_A = 0x10000800, + GPAD_B = 0x10001000, + GPAD_X = 0x10000100, + GPAD_Y = 0x10000200, + GPAD_L_SHLDR = 0x10006000, + GPAD_R_SHLDR = 0x10004400, + GPAD_L_TRIG = 0x10002000, + GPAD_R_TRIG = 0x10000400, + GPAD_HOME = 0x10008000, + }; + + enum sysEventType_t + { + SE_NONE = 0x0, + SE_KEY = 0x1, + SE_CHAR = 0x2, + SE_CONSOLE = 0x3, + }; + + enum ThreadOwner : __int32 + { + THREAD_OWNER_NONE = 0x0, + THREAD_OWNER_DATABASE = 0x1, + THREAD_OWNER_CINEMATICS = 0x2, + }; + + enum PhysicsGeomType : __int32 + { + PHYS_GEOM_NONE = 0x0, + PHYS_GEOM_BOX = 0x1, + PHYS_GEOM_BRUSHMODEL = 0x2, + PHYS_GEOM_BRUSH = 0x3, + PHYS_GEOM_CYLINDER = 0x4, + PHYS_GEOM_CAPSULE = 0x5, + PHYS_GEOM_COUNT = 0x6, + }; + + enum JointType : __int32 + { + RAGDOLL_JOINT_NONE = 0x0, + RAGDOLL_JOINT_HINGE = 0x1, + RAGDOLL_JOINT_SWIVEL = 0x2, + }; + + enum RagdollBodyState : __int32 + { + BS_DEAD = 0x0, + BS_DOBJ_WAIT = 0x1, + BS_VELOCITY_CAPTURE = 0x2, + BS_TUNNEL_TEST = 0x3, + BS_RUNNING = 0x4, + BS_IDLE = 0x5, + RAGDOLL_NUM_STATES = 0x6, + }; + + enum nglFrameLockType : __int32 + { + NGLFL_NONE = 0x0, + NGLFL_ONE = 0x1, + NGLFL_TWO = 0x2, + NGLFL_ONE_OR_IMMEDIATE = 0x3, + NGLFL_TWO_OR_IMMEDIATE = 0x4, + }; + + enum eCurveType : __int32 + { + CURVE_RNS = 0x0, + CURVE_SNS = 0x1, + CURVE_TNS = 0x2, + CURVE_BSPLINE = 0x3, + }; + + enum EMemTrack : __int32 + { + TRACK_DEBUG = 0x0, + TRACK_DEBUG_MEM = 0x1, + TRACK_HUNK = 0x2, + TRACK_BINARIES = 0x3, + TRACK_MISC_SWAP = 0x4, + TRACK_DELIMITER1 = 0x5, + TRACK_AI = 0x6, + TRACK_AI_NODES = 0x7, + TRACK_SCRIPT = 0x8, + TRACK_FX = 0x9, + TRACK_NETWORK_ENTITY = 0xA, + TRACK_MISC = 0xB, + TRACK_FASTFILE = 0xC, + TRACK_ANIMATION = 0xD, + TRACK_WORLD_GLOBALS = 0xE, + TRACK_SOUND_GLOBALS = 0xF, + TRACK_DB_REGISTRY = 0x10, + TRACK_WII_SOUND_GLOBALS = 0x11, + TRACK_SOUND = 0x12, + TRACK_WII_SOUND = 0x13, + TRACK_DELIMITER2 = 0x14, + TRACK_RENDERER_GLOBALS = 0x15, + TRACK_RENDERER_IMAGES = 0x16, + TRACK_RENDERER_WORLD = 0x17, + TRACK_RENDERER_MODELS = 0x18, + TRACK_RENDERER_MISC = 0x19, + TRACK_RENDERER_TOTAL = 0x1A, + TRACK_CINEMATICS = 0x1B, + TRACK_DELIMITER3 = 0x1C, + TRACK_COLLISION_MISC = 0x1D, + TRACK_COLLISION_BRUSH = 0x1E, + TRACK_COLLISION_MODEL_TRI = 0x1F, + TRACK_COLLISION_TERRAIN = 0x20, + TRACK_COLLISION_TOTAL = 0x21, + TRACK_PHYSICS = 0x22, + TRACK_MAP_ENTS = 0x23, + TRACK_TEMP = 0x24, + TRACK_DELIMITER4 = 0x25, + TRACK_LOCALIZATION = 0x26, + TRACK_FLAME = 0x27, + TRACK_UI = 0x28, + TRACK_TL = 0x29, + TRACK_ZMEM = 0x2A, + TRACK_SCALEFORM = 0x2B, + TRACK_FIREMANAGER = 0x2C, + TRACK_PROFILE = 0x2D, + TRACK_WATERSIM = 0x2E, + TRACK_CLIENT = 0x2F, + TRACK_CONSOLE_IMAGES = 0x30, + TRACK_DELIMITER5 = 0x31, + TRACK_NONE = 0x32, + TRACK_COUNT = 0x33, + }; + + enum IKBoneNames : unsigned __int32 + { + IKBONE_NONE = 0xFFFFFFFF, + IKBONE_FIRST = 0x0, + IKBONE_ORIGIN = 0x0, + IKBONE_TORSO = 0x1, + IKBONE_LUPPERARM = 0x2, + IKBONE_LFOREARM = 0x3, + IKBONE_LHAND = 0x4, + IKBONE_RUPPERARM = 0x5, + IKBONE_RFOREARM = 0x6, + IKBONE_RHAND = 0x7, + IKBONE_RWEAPON = 0x8, + IKBONE_COUNT = 0x9, + }; + + enum IKLayerNames : __int32 + { + IKLAYER_PELVIS_TEST = 0x0, + IKLAYER_TERRAIN_MAPPING = 0x1, + IKLAYER_HAND_TEST = 0x2, + IKLAYER_LEFT_HAND_ON_GUN = 0x3, + IKLAYER_RIGHT_HAND_ON_GUN = 0x4, + IKLAYER_PLAYER_PITCH = 0x5, + IKLAYER_WII_HANDS = 0x6, + IKLAYER_VEHICLE_GUNNER_OFFSET = 0x7, + IKLAYER_TURRET_FIRING = 0x8, + IKLAYER_CROUCH_ACTIVE = 0x9, + IKLAYER_PLAYER_CONTROLLERS = 0xA, + IKLAYER_COUNT = 0xB, + }; + + enum XModelLodRampType : __int32 + { + XMODEL_LOD_RAMP_RIGID = 0x0, + XMODEL_LOD_RAMP_SKINNED = 0x1, + XMODEL_LOD_RAMP_COUNT = 0x2, + }; + + enum inflate_block_mode : __int32 + { + TYPE = 0x0, + LENS = 0x1, + STORED = 0x2, + TABLE = 0x3, + BTREE = 0x4, + DTREE = 0x5, + CODES = 0x6, + DRY = 0x7, + DONE = 0x8, + BAD = 0x9, + }; + + enum nflBufferMode : __int32 + { + NFL_BUFFER_MODE_DEFAULT = 0x0, + NFL_BUFFER_MODE_NOBUFFER = 0x1, + NFL_BUFFER_MODE_UNALIGNED = 0x2, + NFL_BUFFER_MODE_ALL = 0x3, + NFL_BUFFER_MODE_VM = 0x4, + }; + + enum nflThreadMode : __int32 + { + NFL_THREAD_MODE_SINGLE = 0x0, + NFL_THREAD_MODE_MULTI = 0x1, + }; + + enum nflFileID : unsigned __int32 + { + NFL_FILE_ID_INVALID = 0xFFFFFFFF, + NFL_FILE_ID_FORCE32 = 0x7FFFFFFF, + }; + + enum VoiceState : __int32 + { + VOICE_STATE_STOPPED = 0x0, + VOICE_STATE_START = 0x1, + VOICE_STATE_STARTED = 0x2, + VOICE_STATE_PLAYING = 0x3, + VOICE_STATE_STOP = 0x4, + VOICE_STATE_RELEASE = 0x5, + VOICE_STATE_FREE = 0x6, + VOICE_STATE_DROPPED = 0x7, + }; + + enum SndFileLoadingState : __int32 + { + SFLS_UNLOADED = 0x0, + SFLS_LOADING = 0x1, + SFLS_LOADED = 0x2, + }; + + enum snd_entity_update : __int32 + { + SND_ENTITY_ALWAYS = 0x0, + SND_ENTITY_ONCE = 0x1, + SND_ENTITY_NEVER = 0x2, + }; + + enum SndLengthId : __int32 + { + SndLengthNotify_Script = 0x0, + SndLengthNotify_Subtitle = 0x1, + SndLengthNotifyCount = 0x2, + }; + + enum snd_alias_system_t : __int32 + { + SASYS_UI = 0x0, + SASYS_CGAME = 0x1, + SASYS_GAME = 0x2, + SASYS_COUNT = 0x3, + }; + + enum WiiFilterPresetIndex : __int32 + { + FILTER_NONE = 0x0, + FILTER_DEFAULT = 0x1, + FILTER_MENU = 0x2, + FILTER_ADS = 0x3, + FILTER_PRECISION = 0x4, + FILTER_SCOPE = 0x5, + FILTER_HIGH_SENS = 0x6, + FILTER_MED_SENS = 0x7, + FILTER_LOW_SENS = 0x8, + FILTER_60_FPS = 0x9, + FILTER_30_FPS = 0xA, + FILTER_20_FPS = 0xB, + FILTER_ZAPPER = 0xC, + FILTER_DYN_RES_HIP = 0xD, + FILTER_DYN_RES_ADS = 0xE, + NUM_FILTER_PRESETS = 0xF, + }; + + enum profileWriteState_t : __int32 + { + PROFILE_NO_WRITE = 0x0, + PROFILE_WRITE_IF_CHANGED = 0x1, + }; + + enum VITVMode : __int32 + { + VI_TVMODE_NTSC_INT = 0x0, + VI_TVMODE_NTSC_DS = 0x1, + VI_TVMODE_NTSC_PROG = 0x2, + VI_TVMODE_PAL_INT = 0x4, + VI_TVMODE_PAL_DS = 0x5, + VI_TVMODE_EURGB60_INT = 0x14, + VI_TVMODE_EURGB60_DS = 0x15, + VI_TVMODE_EURGB60_PROG = 0x16, + VI_TVMODE_MPAL_INT = 0x8, + VI_TVMODE_MPAL_DS = 0x9, + VI_TVMODE_MPAL_PROG = 0xA, + VI_TVMODE_DEBUG_INT = 0xC, + VI_TVMODE_DEBUG_PAL_INT = 0x10, + VI_TVMODE_DEBUG_PAL_DS = 0x11, + }; + + enum VIXFBMode : __int32 + { + VI_XFBMODE_SF = 0x0, + VI_XFBMODE_DF = 0x1, + }; + + enum WiiError : __int32 + { + WII_NO_ERROR = 0x0, + WII_NO_DISC = 0x1, + WII_WRONG_DISC = 0x2, + WII_DISC_RETRY = 0x3, + WII_DISC_FATAL = 0x4, + WII_NAND_CORRUPT = 0x5, + WII_NAND_NOSPACE = 0x6, + WII_NAND_FAILED = 0x7, + WII_NAND_UNKNOWN = 0x8, + WII_RESET = 0x9, + }; + + enum HBMSelectBtnNum : unsigned __int32 + { + HBM_SELECT_NULL = 0xFFFFFFFF, + HBM_SELECT_HOMEBTN = 0x0, + HBM_SELECT_BTN1 = 0x1, + HBM_SELECT_BTN2 = 0x2, + HBM_SELECT_BTN3 = 0x3, + HBM_SELECT_BTN4 = 0x4, + HBM_SELECT_MAX = 0x5, + }; + + enum MemcardOperation : __int32 + { + MEMCARD_READ = 0x0, + MEMCARD_WRITE = 0x1, + }; + + enum DeleteOp : __int32 + { + DELETE_BANNER = 0x0, + DELETE_PROFILES = 0x1, + DELETE_CHECK_SPACE = 0x2, + DELETE_CHECK_SPACE_END = 0x3, + DELETE_END = 0x4, + }; + + enum CreateOp : __int32 + { + CREATE_DELETE_BANNER = 0x0, + CREATE_DELETE_PROFILES = 0x1, + CREATE_CHECK_SPACE = 0x2, + CREATE_CHECK_SPACE_END = 0x3, + CREATE_CREATE_DIR = 0x4, + CREATE_CREATE_FILE = 0x5, + CREATE_OPEN_FILE = 0x6, + CREATE_WRITE0_FILE = 0x7, + CREATE_WRITE_FILE = 0x8, + CREATE_CLOSE_FILE = 0x9, + CREATE_CREATE_BANNER = 0xA, + CREATE_OPEN_BANNER = 0xB, + CREATE_WRITE_BANNER = 0xC, + CREATE_CLOSE_BANNER = 0xD, + CREATE_END = 0xE, + }; + + enum ZapperMenuRegion : __int32 + { + ZAPPER_MENU_NONE = 0x0, + ZAPPER_MENU_TOP = 0x1, + ZAPPER_MENU_TOP_TOP = 0x2, + ZAPPER_MENU_LEFT = 0x3, + ZAPPER_MENU_RIGHT = 0x4, + ZAPPER_MENU_BOTTOM = 0x5, + ZAPPER_MENU_BOTTOM_BOTTOM = 0x6, + ZAPPER_MENU_NUM = 0x7, + }; + + enum AsyncSOStartupState : __int32 + { + ASYNC_SOSTARTUP_STATE_IDLE = 0x0, + ASYNC_SOSTARTUP_STATE_REQUESTED = 0x1, + ASYNC_SOSTARTUP_STATE_PROCESSING = 0x2, + ASYNC_SOSTARTUP_STATE_DONE_SUCCESSFUL = 0x3, + ASYNC_SOSTARTUP_STATE_DONE_FAIL = 0x4, + }; + + enum BaseLineState : __int32 + { + BASELINE_NOT_FROM_BASELINE = 0x0, + BASELINE_USED = 0x1, + BASELINE_NULL = 0x2, + }; + + enum MovieToPlayScriptOp : __int32 + { + MTPSOP_PLUS = 0x0, + MTPSOP_MINUS = 0x1, + MTPSOP_MUL = 0x2, + MTPSOP_GT = 0x3, + MTPSOP_LT = 0x4, + MTPSOP_EQ = 0x5, + MTPSOP_STRCMP = 0x6, + MTPSOP_STRCAT = 0x7, + MTPSOP_NOT = 0x8, + MTPSOP_DUP = 0x9, + MTPSOP_DROP = 0xA, + MTPSOP_SWAP = 0xB, + MTPSOP_GETDVAR = 0xC, + MTPSOP_GETMAPNAME = 0xD, + MTPSOP_IF = 0xE, + MTPSOP_THEN = 0xF, + MTPSOP_PLAY = 0x10, + MTPSOP_LITERAL = 0x11, + MTPSOP_COUNT = 0x12, + }; + + enum rankTableColumns_t : __int32 + { + MP_RANKTABLE_RANKID = 0x0, + MP_RANKTABLE_RANK = 0x1, + MP_RANKTABLE_MINXP = 0x2, + MP_RANKTABLE_XPTONEXT = 0x3, + MP_RANKTABLE_SHORTRANK = 0x4, + MP_RANKTABLE_FULLRANK = 0x5, + MP_RANKTABLE_ICON = 0x6, + MP_RANKTABLE_MAXXP = 0x7, + MP_RANKTABLE_WEAPUNLOCK = 0x8, + MP_RANKTABLE_PERKUNLOCK = 0x9, + MP_RANKTABLE_CHALLENGE = 0xA, + MP_RANKTABLE_CAMO = 0xB, + MP_RANKTABLE_ATTACHMENT = 0xC, + MP_RANKTABLE_LEVEL = 0xD, + MP_RANKTABLE_DISPLAYLEVEL = 0xE, + MP_RANKTABLE_COUNT = 0xF, + }; + + enum snd_stopsounds_arg_t : __int32 + { + SND_STOP_ALL = 0x0, + SND_KEEP_REVERB = 0x1, + SND_KEEP_MUSIC = 0x2, + SND_KEEP_AMBIENT = 0x4, + SND_KEEP_MUSIC_AND_AMBIENT = 0x6, + SND_STOP_STREAMED = 0x8, + SND_KEEP_BUS_VOLUMES = 0x10, + }; + + enum snd_attenuation_factor_t : __int32 + { + SND_ATTENUATION_ALIAS = 0x1, + SND_ATTENUATION_START = 0x2, + SND_ATTENUATION_BUS = 0x4, + SND_ATTENUATION_DISTANCE = 0x8, + SND_ATTENUATION_CYLINDER = 0x10, + SND_ATTENUATION_FADE = 0x20, + SND_ATTENUATION_GLOBAL = 0x40, + SND_ATTENUATION_SLAVE = 0x80, + SND_ATTENUATION_SCRIPT = 0x100, + SND_ATTENUATION_LOS = 0x200, + SND_ATTENUATION_TEAM = 0x400, + SND_ATTENUATION_WETDRY = 0x800, + SND_ATTENUATION_MENU = 0x1000, + SND_ATTENUATION_PAD = 0x2000, + SND_ATTENUATION_ALL = 0xFFFF, + }; + + enum snd_csv_entry_type : __int32 + { + SND_CSV_STRING = 0x0, + SND_CSV_FLOAT = 0x1, + SND_CSV_INT = 0x2, + SND_CSV_ENUM = 0x3, + }; + + enum snd_speaker_flag : __int32 + { + SND_SPEAKER_FLAG_LEFT = 0x1, + SND_SPEAKER_FLAG_RIGHT = 0x2, + SND_SPEAKER_FLAG_CENTER = 0x4, + SND_SPEAKER_FLAG_LFE = 0x8, + SND_SPEAKER_FLAG_LEFT_SURROUND = 0x10, + SND_SPEAKER_FLAG_RIGHT_SURROUND = 0x20, + SND_SPEAKER_FLAG_LEFT_REAR_SURROUND = 0x40, + SND_SPEAKER_FLAG_RIGHT_REAR_SURROUND = 0x80, + }; + + enum ShadowType : __int32 + { + SHADOW_NONE = 0x0, + SHADOW_COOKIE = 0x1, + SHADOW_MAP = 0x2, + }; + + enum MaterialTechniqueType : __int32 + { + TECHNIQUE_DEPTH_PREPASS = 0x0, + TECHNIQUE_BUILD_FLOAT_Z = 0x1, + TECHNIQUE_BUILD_SHADOWMAP_DEPTH = 0x2, + TECHNIQUE_BUILD_SHADOWMAP_COLOR = 0x3, + TECHNIQUE_UNLIT = 0x4, + TECHNIQUE_EMISSIVE = 0x5, + TECHNIQUE_EMISSIVE_SHADOW = 0x6, + TECHNIQUE_EMISSIVE_REFLECTED = 0x7, + TECHNIQUE_LIT_BEGIN = 0x8, + TECHNIQUE_LIT = 0x8, + TECHNIQUE_LIT_FADE = 0x9, + TECHNIQUE_LIT_SUN = 0xA, + TECHNIQUE_LIT_SUN_FADE = 0xB, + TECHNIQUE_LIT_SUN_SHADOW = 0xC, + TECHNIQUE_LIT_SUN_SHADOW_FADE = 0xD, + TECHNIQUE_LIT_SPOT = 0xE, + TECHNIQUE_LIT_SPOT_FADE = 0xF, + TECHNIQUE_LIT_SPOT_SHADOW = 0x10, + TECHNIQUE_LIT_SPOT_SHADOW_FADE = 0x11, + TECHNIQUE_LIT_OMNI = 0x12, + TECHNIQUE_LIT_OMNI_FADE = 0x13, + TECHNIQUE_LIT_OMNI_SHADOW = 0x14, + TECHNIQUE_LIT_OMNI_SHADOW_FADE = 0x15, + TECHNIQUE_LIT_CHARRED = 0x16, + TECHNIQUE_LIT_FADE_CHARRED = 0x17, + TECHNIQUE_LIT_SUN_CHARRED = 0x18, + TECHNIQUE_LIT_SUN_FADE_CHARRED = 0x19, + TECHNIQUE_LIT_SUN_SHADOW_CHARRED = 0x1A, + TECHNIQUE_LIT_SUN_SHADOW_FADE_CHARRED = 0x1B, + TECHNIQUE_LIT_SPOT_CHARRED = 0x1C, + TECHNIQUE_LIT_SPOT_FADE_CHARRED = 0x1D, + TECHNIQUE_LIT_SPOT_SHADOW_CHARRED = 0x1E, + TECHNIQUE_LIT_SPOT_SHADOW_FADE_CHARRED = 0x1F, + TECHNIQUE_LIT_OMNI_CHARRED = 0x20, + TECHNIQUE_LIT_OMNI_FADE_CHARRED = 0x21, + TECHNIQUE_LIT_OMNI_SHADOW_CHARRED = 0x22, + TECHNIQUE_LIT_OMNI_SHADOW_FADE_CHARRED = 0x23, + TECHNIQUE_LIT_END = 0x24, + TECHNIQUE_LIGHT_SPOT = 0x24, + TECHNIQUE_LIGHT_OMNI = 0x25, + TECHNIQUE_LIGHT_SPOT_SHADOW = 0x26, + TECHNIQUE_LIGHT_SPOT_CHARRED = 0x27, + TECHNIQUE_LIGHT_OMNI_CHARRED = 0x28, + TECHNIQUE_LIGHT_SPOT_SHADOW_CHARRED = 0x29, + TECHNIQUE_FAKELIGHT_NORMAL = 0x2A, + TECHNIQUE_FAKELIGHT_VIEW = 0x2B, + TECHNIQUE_SUNLIGHT_PREVIEW = 0x2C, + TECHNIQUE_CASE_TEXTURE = 0x2D, + TECHNIQUE_WIREFRAME_SOLID = 0x2E, + TECHNIQUE_WIREFRAME_SHADED = 0x2F, + TECHNIQUE_SHADOWCOOKIE_CASTER = 0x30, + TECHNIQUE_SHADOWCOOKIE_RECEIVER = 0x31, + TECHNIQUE_DEBUG_BUMPMAP = 0x32, + TECHNIQUE_COUNT = 0x33, + TECHNIQUE_TOTAL_COUNT = 0x34, + TECHNIQUE_NONE = 0x35, + }; + + enum GfxRenderTargetId : __int32 + { + R_RENDERTARGET_SAVED_SCREEN = 0x0, + R_RENDERTARGET_FRAME_BUFFER = 0x1, + R_RENDERTARGET_SCENE = 0x2, + R_RENDERTARGET_RESOLVED_POST_SUN = 0x3, + R_RENDERTARGET_RESOLVED_SCENE = 0x4, + R_RENDERTARGET_FLOAT_Z = 0x5, + R_RENDERTARGET_DYNAMICSHADOWS = 0x6, + R_RENDERTARGET_SHADOWCOOKIE = 0x7, + R_RENDERTARGET_SHADOWCOOKIE_BLUR = 0x8, + R_RENDERTARGET_POST_EFFECT_SRC = 0x9, + R_RENDERTARGET_POST_EFFECT_GODRAYS = 0xA, + R_RENDERTARGET_POST_EFFECT_0 = 0xB, + R_RENDERTARGET_POST_EFFECT_1 = 0xC, + R_RENDERTARGET_SHADOWMAP_SUN = 0xD, + R_RENDERTARGET_SHADOWMAP_SPOT = 0xE, + R_RENDERTARGET_COUNT = 0xF, + R_RENDERTARGET_NONE = 0x10, + }; + + enum GeomStreamLoadedGroupState : __int32 + { + GEOMSTREAM_ACTIVE = 0x0, + GEOMSTREAM_LOADING = 0x1, + GEOMSTREAM_UNLOADING_WAIT = 0x2, + GEOMSTREAM_UNLOADING = 0x3, + GEOMSTREAM_DEFRAG_WAIT1 = 0x4, + GEOMSTREAM_DEFRAG_WAIT2 = 0x5, + GEOMSTREAM_DEFRAG = 0x6, + GEOMSTREAM_EXTERNAL_ALLOC = 0x7, + GEOMSTREAM_SENTINEL = 0x8, + }; + + enum GeomSetType : __int32 + { + GEOMSET_BSP = 0x0, + GEOMSET_XMODEL = 0x1, + GEOMSET_COUNT = 0x2, + }; + + enum CinematicEnum : __int32 + { + CINEMATIC_NOT_PAUSED = 0x0, + CINEMATIC_PAUSED = 0x1, + }; + + enum CinematicThreadState : __int32 + { + CINEMATIC_THREAD_STATE_FROM_HOST_GO = 0x0, + CINEMATIC_THREAD_STATE_FROM_HOST_GO_BINK = 0x1, + CINEMATIC_THREAD_STATE_TO_HOST_BETWEEN_UPDATES = 0x2, + CINEMATIC_THREAD_STATE_TO_HOST_ENTERING_BINK = 0x3, + CINEMATIC_THREAD_STATE_TO_HOST_EXITED_BINK = 0x4, + }; + + enum _GXTexFmt : __int32 + { + GX_TF_I4 = 0x0, + GX_TF_I8 = 0x1, + GX_TF_IA4 = 0x2, + GX_TF_IA8 = 0x3, + GX_TF_RGB565 = 0x4, + GX_TF_RGB5A3 = 0x5, + GX_TF_RGBA8 = 0x6, + GX_TF_CMPR = 0xE, + GX_CTF_R4 = 0x20, + GX_CTF_RA4 = 0x22, + GX_CTF_RA8 = 0x23, + GX_CTF_YUVA8 = 0x26, + GX_CTF_A8 = 0x27, + GX_CTF_R8 = 0x28, + GX_CTF_G8 = 0x29, + GX_CTF_B8 = 0x2A, + GX_CTF_RG8 = 0x2B, + GX_CTF_GB8 = 0x2C, + GX_TF_Z8 = 0x11, + GX_TF_Z16 = 0x13, + GX_TF_Z24X8 = 0x16, + GX_CTF_Z4 = 0x30, + GX_CTF_Z8M = 0x39, + GX_CTF_Z8L = 0x3A, + GX_CTF_Z16L = 0x3C, + GX_TF_A8 = 0x27, + }; + + enum _GXTexWrapMode : __int32 + { + GX_CLAMP = 0x0, + GX_REPEAT = 0x1, + GX_MIRROR = 0x2, + GX_MAX_TEXWRAPMODE = 0x3, + }; + + enum GfxViewMode : __int32 + { + VIEW_MODE_NONE = 0x0, + VIEW_MODE_3D = 0x1, + VIEW_MODE_2D = 0x2, + VIEW_MODE_IDENTITY = 0x3, + }; + + enum GfxViewportBehavior : __int32 + { + GFX_USE_VIEWPORT_FOR_VIEW = 0x0, + GFX_USE_VIEWPORT_FULL = 0x1, + }; + + enum MaterialVertexDeclType : __int32 + { + VERTDECL_GENERIC = 0x0, + VERTDECL_PACKED = 0x1, + VERTDECL_WORLD = 0x2, + VERTDECL_WORLD_T1N0 = 0x3, + VERTDECL_WORLD_T1N1 = 0x4, + VERTDECL_WORLD_T2N0 = 0x5, + VERTDECL_WORLD_T2N1 = 0x6, + VERTDECL_WORLD_T2N2 = 0x7, + VERTDECL_WORLD_T3N0 = 0x8, + VERTDECL_WORLD_T3N1 = 0x9, + VERTDECL_WORLD_T3N2 = 0xA, + VERTDECL_WORLD_T4N0 = 0xB, + VERTDECL_WORLD_T4N1 = 0xC, + VERTDECL_WORLD_T4N2 = 0xD, + VERTDECL_POS_TEX = 0xE, + VERTDECL_WATER = 0xF, + VERTDECL_COUNT = 0x10, + }; + + enum GfxDepthRangeType : unsigned __int32 + { + GFX_DEPTH_RANGE_SCENE = 0x0, + GFX_DEPTH_RANGE_VIEWMODEL = 0x2, + GFX_DEPTH_RANGE_FULL = 0xFFFFFFFF, + }; + + enum DpvsForceBevels : __int32 + { + DPVS_DONT_FORCE_BEVELS = 0x0, + DPVS_FORCE_BEVELS = 0x1, + }; + + enum DpvsClipChildren : __int32 + { + DPVS_DONT_CLIP_CHILDREN = 0x0, + DPVS_CLIP_CHILDREN = 0x1, + }; + + enum GfxDrawSceneMethod : __int32 + { + GFX_DRAW_SCENE_NONE = 0x0, + GFX_DRAW_SCENE_FULLBRIGHT = 0x1, + GFX_DRAW_SCENE_DEBUGSHADER = 0x2, + GFX_DRAW_SCENE_STANDARD = 0x3, + }; + + enum GfxTechCharredType : __int32 + { + GFX_TECHNIQUE_NOT_CHARRED = 0x0, + GFX_TECHNIQUE_CHARRED = 0x1, + GFX_TECHNIQUE_CHARRED_TYPES = 0x2, + }; + + enum GfxFadeType : __int32 + { + GFX_TECHNIQUE_NO_FADE = 0x0, + GFX_TECHNIQUE_FADE = 0x1, + GFX_TECHNIQUE_FADE_TYPES = 0x2, + }; + + enum LightHasShadowMap : __int32 + { + LIGHT_HAS_SHADOWMAP = 0x0, + LIGHT_HAS_NO_SHADOWMAP = 0x1, + }; + + enum ForceType : __int32 + { + GRENADE_EXPLOSION = 0x0, + NEAR_MUZZLE_SHAKE = 0x1, + }; + + enum ShakeForceState : __int32 + { + GAINING = 0x0, + MAINTAINING = 0x1, + DECAYING = 0x2, + }; + + enum _GXAttrType : __int32 + { + GX_NONE = 0x0, + GX_DIRECT = 0x1, + GX_INDEX8 = 0x2, + GX_INDEX16 = 0x3, + }; + + enum _GXAttr : __int32 + { + GX_VA_PNMTXIDX = 0x0, + GX_VA_TEX0MTXIDX = 0x1, + GX_VA_TEX1MTXIDX = 0x2, + GX_VA_TEX2MTXIDX = 0x3, + GX_VA_TEX3MTXIDX = 0x4, + GX_VA_TEX4MTXIDX = 0x5, + GX_VA_TEX5MTXIDX = 0x6, + GX_VA_TEX6MTXIDX = 0x7, + GX_VA_TEX7MTXIDX = 0x8, + GX_VA_POS = 0x9, + GX_VA_NRM = 0xA, + GX_VA_CLR0 = 0xB, + GX_VA_CLR1 = 0xC, + GX_VA_TEX0 = 0xD, + GX_VA_TEX1 = 0xE, + GX_VA_TEX2 = 0xF, + GX_VA_TEX3 = 0x10, + GX_VA_TEX4 = 0x11, + GX_VA_TEX5 = 0x12, + GX_VA_TEX6 = 0x13, + GX_VA_TEX7 = 0x14, + GX_POS_MTX_ARRAY = 0x15, + GX_NRM_MTX_ARRAY = 0x16, + GX_TEX_MTX_ARRAY = 0x17, + GX_LIGHT_ARRAY = 0x18, + GX_VA_NBT = 0x19, + GX_VA_MAX_ATTR = 0x1A, + GX_VA_NULL = 0xFF, + }; + + enum MaterialUpdateFrequency : __int32 + { + MTL_UPDATE_PER_PRIM = 0x0, + MTL_UPDATE_PER_OBJECT = 0x1, + MTL_UPDATE_RARELY = 0x2, + MTL_UPDATE_CUSTOM = 0x3, + }; + + enum GfxProjectionTypes : __int32 + { + GFX_PROJECTION_2D = 0x0, + GFX_PROJECTION_3D = 0x1, + }; + + enum surfaceType_t : unsigned __int32 + { + SF_TRIANGLES = 0x0, + SF_BEGIN_STATICMODEL = 0x1, + SF_STATICMODEL_RIGID = 0x1, + SF_END_STATICMODEL = 0x2, + SF_SIMPLE_FLAG = 0x2, + SF_BMODEL = 0x3, + SF_BEGIN_XMODEL = 0x4, + SF_XMODEL_RIGID = 0x4, + SF_XMODEL_SKINNED = 0x5, + SF_XMODEL_WATER = 0x6, + SF_END_XMODEL = 0x7, + SF_SIMPLE_WATER = 0x7, + SF_BEGIN_FX = 0x8, + SF_CODE_MESH = 0x8, + SF_MARK_MESH = 0x9, + SF_PARTICLE_CLOUD = 0xA, + SF_ROPE_MESH = 0xB, + SF_END_FX = 0xC, + SF_NUM_SURFACE_TYPES = 0xC, + SF_FORCE_32_BITS = 0xFFFFFFFF, + }; + + enum AnimLodLevel : __int32 + { + ANIMLOD_ANIMATED = 0x0, + ANIMLOD_TRANSITION = 0x1, + ANIMLOD_NONE = 0x2, + }; + + enum EStreamPriority : __int32 + { + STREAM_PRIORITY_ZERO = 0x0, + STREAM_PRIORITY_LOW = 0x1, + STREAM_PRIORITY_MEDIUM = 0x2, + STREAM_PRIORITY_HIGH = 0x3, + STREAM_PRIORITY_FALLING_FROM_USE = 0x4, + STREAM_PRIORITY_IN_USE = 0x5, + STREAM_PRIORITY_COUNT = 0x6, + STREAM_PRIORITY_INVALID = 0xFF, + }; + + enum GfxTevDstArg : __int32 + { + GFX_TEV_DEST_PREV = 0x0, + GFX_TEV_DEST_REG0 = 0x1, + GFX_TEV_DEST_REG1 = 0x2, + GFX_TEV_DEST_REG2 = 0x3, + }; + + enum _GXCompType : __int32 + { + GX_U8 = 0x0, + GX_S8 = 0x1, + GX_U16 = 0x2, + GX_S16 = 0x3, + GX_F32 = 0x4, + GX_RGB565 = 0x0, + GX_RGB8 = 0x1, + GX_RGBX8 = 0x2, + GX_RGBA4 = 0x3, + GX_RGBA6 = 0x4, + GX_RGBA8 = 0x5, + }; + + enum gjk_retval_e : __int32 + { + GJK_SEPARATED = 0x0, + GJK_VALID = 0x1, + GJK_PENETRATING = 0x2, + GJK_INVALID = 0x3, + }; + + enum gpuPrimType : __int32 + { + GPU_PRIM_POINTLIST = 0xB8, + GPU_PRIM_LINELIST = 0xA8, + GPU_PRIM_LINESTRIP = 0xB0, + GPU_PRIM_TRIANGLELIST = 0x90, + GPU_PRIM_TRIANGLESTRIP = 0x98, + GPU_PRIM_TRIANGLEFAN = 0xA0, + GPU_PRIM_QUADLIST = 0x80, + }; + + enum _GXPixelFmt : __int32 + { + GX_PF_RGB8_Z24 = 0x0, + GX_PF_RGBA6_Z24 = 0x1, + GX_PF_RGB565_Z16 = 0x2, + GX_PF_Z24 = 0x3, + GX_PF_Y8 = 0x4, + GX_PF_U8 = 0x5, + GX_PF_V8 = 0x6, + GX_PF_YUV420 = 0x7, + }; + + enum nglProjType : __int32 + { + NGLPROJ_ORTHOGRAPHIC = 0x0, + NGLPROJ_PERSPECTIVE = 0x1, + }; + + enum nglLightType : __int32 + { + NGLLIGHT_POINT = 0x0, + NGLLIGHT_DIRECTIONAL = 0x1, + NGLLIGHT_PROJECTED_DIRECTIONAL = 0x2, + NGLLIGHT_PROJECTED_SPOT = 0x3, + NGLLIGHT_PROJECTED_PARALLEL = 0x4, + NGLLIGHT_USER_FIRST = 0x5, + }; + + enum gpuAddressMode : __int32 + { + GPU_ADDRESS_CLAMP = 0x0, + GPU_ADDRESS_WRAP = 0x1, + GPU_ADDRESS_MIRROR = 0x2, + }; + + enum gpuFilterMode : __int32 + { + GPU_FILTER_POINT = 0x0, + GPU_FILTER_LINEAR = 0x1, + GPU_FILTER_ANISOTROPIC = 0x2, + }; + + enum _GXFogType : __int32 + { + GX_FOG_NONE = 0x0, + GX_FOG_PERSP_LIN = 0x2, + GX_FOG_PERSP_EXP = 0x4, + GX_FOG_PERSP_EXP2 = 0x5, + GX_FOG_PERSP_REVEXP = 0x6, + GX_FOG_PERSP_REVEXP2 = 0x7, + GX_FOG_ORTHO_LIN = 0xA, + GX_FOG_ORTHO_EXP = 0xC, + GX_FOG_ORTHO_EXP2 = 0xD, + GX_FOG_ORTHO_REVEXP = 0xE, + GX_FOG_ORTHO_REVEXP2 = 0xF, + GX_FOG_LIN = 0x2, + GX_FOG_EXP = 0x4, + GX_FOG_EXP2 = 0x5, + GX_FOG_REVEXP = 0x6, + GX_FOG_REVEXP2 = 0x7, + }; + + enum _GXTexMapID : __int32 + { + GX_TEXMAP0 = 0x0, + GX_TEXMAP1 = 0x1, + GX_TEXMAP2 = 0x2, + GX_TEXMAP3 = 0x3, + GX_TEXMAP4 = 0x4, + GX_TEXMAP5 = 0x5, + GX_TEXMAP6 = 0x6, + GX_TEXMAP7 = 0x7, + GX_MAX_TEXMAP = 0x8, + GX_TEXMAP_NULL = 0xFF, + GX_TEX_DISABLE = 0x100, + }; + + enum nglSortType : __int32 + { + NGLSORT_OPAQUE = 0x0, + NGLSORT_TRANSLUCENT = 0x1, + }; + + enum nglNodeType : __int32 + { + NGLNODE_SCENE = 0x0, + NGLNODE_CUSTOM = 0x1, + }; + + enum _GXCullMode : __int32 + { + GX_CULL_NONE = 0x0, + GX_CULL_FRONT = 0x1, + GX_CULL_BACK = 0x2, + GX_CULL_ALL = 0x3, + }; + + enum _GXTevRegID : __int32 + { + GX_TEVPREV = 0x0, + GX_TEVREG0 = 0x1, + GX_TEVREG1 = 0x2, + GX_TEVREG2 = 0x3, + GX_MAX_TEVREG = 0x4, + }; + + enum _GXTevSwapSel : __int32 + { + GX_TEV_SWAP0 = 0x0, + GX_TEV_SWAP1 = 0x1, + GX_TEV_SWAP2 = 0x2, + GX_TEV_SWAP3 = 0x3, + GX_MAX_TEVSWAP = 0x4, + }; + + enum _GXTevScale : __int32 + { + GX_CS_SCALE_1 = 0x0, + GX_CS_SCALE_2 = 0x1, + GX_CS_SCALE_4 = 0x2, + GX_CS_DIVIDE_2 = 0x3, + GX_MAX_TEVSCALE = 0x4, + }; + + enum _GXTevBias : __int32 + { + GX_TB_ZERO = 0x0, + GX_TB_ADDHALF = 0x1, + GX_TB_SUBHALF = 0x2, + GX_MAX_TEVBIAS = 0x3, + }; + + enum _GXTevOp : __int32 + { + GX_TEV_ADD = 0x0, + GX_TEV_SUB = 0x1, + GX_TEV_COMP_R8_GT = 0x8, + GX_TEV_COMP_R8_EQ = 0x9, + GX_TEV_COMP_GR16_GT = 0xA, + GX_TEV_COMP_GR16_EQ = 0xB, + GX_TEV_COMP_BGR24_GT = 0xC, + GX_TEV_COMP_BGR24_EQ = 0xD, + GX_TEV_COMP_RGB8_GT = 0xE, + GX_TEV_COMP_RGB8_EQ = 0xF, + GX_TEV_COMP_A8_GT = 0xE, + GX_TEV_COMP_A8_EQ = 0xF, + }; + + enum _GXTevAlphaArg : __int32 + { + GX_CA_APREV = 0x0, + GX_CA_A0 = 0x1, + GX_CA_A1 = 0x2, + GX_CA_A2 = 0x3, + GX_CA_TEXA = 0x4, + GX_CA_RASA = 0x5, + GX_CA_KONST = 0x6, + GX_CA_ZERO = 0x7, + GX_CA_ONE = 0x6, + }; + + enum _GXTevColorArg : __int32 + { + GX_CC_CPREV = 0x0, + GX_CC_APREV = 0x1, + GX_CC_C0 = 0x2, + GX_CC_A0 = 0x3, + GX_CC_C1 = 0x4, + GX_CC_A1 = 0x5, + GX_CC_C2 = 0x6, + GX_CC_A2 = 0x7, + GX_CC_TEXC = 0x8, + GX_CC_TEXA = 0x9, + GX_CC_RASC = 0xA, + GX_CC_RASA = 0xB, + GX_CC_ONE = 0xC, + GX_CC_HALF = 0xD, + GX_CC_KONST = 0xE, + GX_CC_ZERO = 0xF, + GX_CC_TEXRRR = 0x10, + GX_CC_TEXGGG = 0x11, + GX_CC_TEXBBB = 0x12, + GX_CC_QUARTER = 0xE, + }; + + enum _GXTevKAlphaSel : __int32 + { + GX_TEV_KASEL_8_8 = 0x0, + GX_TEV_KASEL_7_8 = 0x1, + GX_TEV_KASEL_6_8 = 0x2, + GX_TEV_KASEL_5_8 = 0x3, + GX_TEV_KASEL_4_8 = 0x4, + GX_TEV_KASEL_3_8 = 0x5, + GX_TEV_KASEL_2_8 = 0x6, + GX_TEV_KASEL_1_8 = 0x7, + GX_TEV_KASEL_1 = 0x0, + GX_TEV_KASEL_3_4 = 0x2, + GX_TEV_KASEL_1_2 = 0x4, + GX_TEV_KASEL_1_4 = 0x6, + GX_TEV_KASEL_K0_R = 0x10, + GX_TEV_KASEL_K1_R = 0x11, + GX_TEV_KASEL_K2_R = 0x12, + GX_TEV_KASEL_K3_R = 0x13, + GX_TEV_KASEL_K0_G = 0x14, + GX_TEV_KASEL_K1_G = 0x15, + GX_TEV_KASEL_K2_G = 0x16, + GX_TEV_KASEL_K3_G = 0x17, + GX_TEV_KASEL_K0_B = 0x18, + GX_TEV_KASEL_K1_B = 0x19, + GX_TEV_KASEL_K2_B = 0x1A, + GX_TEV_KASEL_K3_B = 0x1B, + GX_TEV_KASEL_K0_A = 0x1C, + GX_TEV_KASEL_K1_A = 0x1D, + GX_TEV_KASEL_K2_A = 0x1E, + GX_TEV_KASEL_K3_A = 0x1F, + }; + + enum _GXTevKColorSel : __int32 + { + GX_TEV_KCSEL_8_8 = 0x0, + GX_TEV_KCSEL_7_8 = 0x1, + GX_TEV_KCSEL_6_8 = 0x2, + GX_TEV_KCSEL_5_8 = 0x3, + GX_TEV_KCSEL_4_8 = 0x4, + GX_TEV_KCSEL_3_8 = 0x5, + GX_TEV_KCSEL_2_8 = 0x6, + GX_TEV_KCSEL_1_8 = 0x7, + GX_TEV_KCSEL_1 = 0x0, + GX_TEV_KCSEL_3_4 = 0x2, + GX_TEV_KCSEL_1_2 = 0x4, + GX_TEV_KCSEL_1_4 = 0x6, + GX_TEV_KCSEL_K0 = 0xC, + GX_TEV_KCSEL_K1 = 0xD, + GX_TEV_KCSEL_K2 = 0xE, + GX_TEV_KCSEL_K3 = 0xF, + GX_TEV_KCSEL_K0_R = 0x10, + GX_TEV_KCSEL_K1_R = 0x11, + GX_TEV_KCSEL_K2_R = 0x12, + GX_TEV_KCSEL_K3_R = 0x13, + GX_TEV_KCSEL_K0_G = 0x14, + GX_TEV_KCSEL_K1_G = 0x15, + GX_TEV_KCSEL_K2_G = 0x16, + GX_TEV_KCSEL_K3_G = 0x17, + GX_TEV_KCSEL_K0_B = 0x18, + GX_TEV_KCSEL_K1_B = 0x19, + GX_TEV_KCSEL_K2_B = 0x1A, + GX_TEV_KCSEL_K3_B = 0x1B, + GX_TEV_KCSEL_K0_A = 0x1C, + GX_TEV_KCSEL_K1_A = 0x1D, + GX_TEV_KCSEL_K2_A = 0x1E, + GX_TEV_KCSEL_K3_A = 0x1F, + }; + + enum _GXChannelID : __int32 + { + GX_COLOR0 = 0x0, + GX_COLOR1 = 0x1, + GX_ALPHA0 = 0x2, + GX_ALPHA1 = 0x3, + GX_COLOR0A0 = 0x4, + GX_COLOR1A1 = 0x5, + GX_COLOR_ZERO = 0x6, + GX_ALPHA_BUMP = 0x7, + GX_ALPHA_BUMPN = 0x8, + GX_COLOR_NULL = 0xFF, + }; + + enum _GXTexCoordID : __int32 + { + GX_TEXCOORD0 = 0x0, + GX_TEXCOORD1 = 0x1, + GX_TEXCOORD2 = 0x2, + GX_TEXCOORD3 = 0x3, + GX_TEXCOORD4 = 0x4, + GX_TEXCOORD5 = 0x5, + GX_TEXCOORD6 = 0x6, + GX_TEXCOORD7 = 0x7, + GX_MAX_TEXCOORD = 0x8, + GX_TEXCOORD_NULL = 0xFF, + }; + + enum _GXTexGenSrc : __int32 + { + GX_TG_POS = 0x0, + GX_TG_NRM = 0x1, + GX_TG_BINRM = 0x2, + GX_TG_TANGENT = 0x3, + GX_TG_TEX0 = 0x4, + GX_TG_TEX1 = 0x5, + GX_TG_TEX2 = 0x6, + GX_TG_TEX3 = 0x7, + GX_TG_TEX4 = 0x8, + GX_TG_TEX5 = 0x9, + GX_TG_TEX6 = 0xA, + GX_TG_TEX7 = 0xB, + GX_TG_TEXCOORD0 = 0xC, + GX_TG_TEXCOORD1 = 0xD, + GX_TG_TEXCOORD2 = 0xE, + GX_TG_TEXCOORD3 = 0xF, + GX_TG_TEXCOORD4 = 0x10, + GX_TG_TEXCOORD5 = 0x11, + GX_TG_TEXCOORD6 = 0x12, + GX_TG_COLOR0 = 0x13, + GX_TG_COLOR1 = 0x14, + }; + + enum _GXTexGenType : __int32 + { + GX_TG_MTX3x4 = 0x0, + GX_TG_MTX2x4 = 0x1, + GX_TG_BUMP0 = 0x2, + GX_TG_BUMP1 = 0x3, + GX_TG_BUMP2 = 0x4, + GX_TG_BUMP3 = 0x5, + GX_TG_BUMP4 = 0x6, + GX_TG_BUMP5 = 0x7, + GX_TG_BUMP6 = 0x8, + GX_TG_BUMP7 = 0x9, + GX_TG_SRTG = 0xA, + }; + + enum _GXAttnFn : __int32 + { + GX_AF_SPEC = 0x0, + GX_AF_SPOT = 0x1, + GX_AF_NONE = 0x2, + }; + + enum _GXDiffuseFn : __int32 + { + GX_DF_NONE = 0x0, + GX_DF_SIGN = 0x1, + GX_DF_CLAMP = 0x2, + }; + + enum _GXColorSrc : __int32 + { + GX_SRC_REG = 0x0, + GX_SRC_VTX = 0x1, + }; + + enum _GXCompCnt : __int32 + { + GX_POS_XY = 0x0, + GX_POS_XYZ = 0x1, + GX_NRM_XYZ = 0x0, + GX_NRM_NBT = 0x1, + GX_NRM_NBT3 = 0x2, + GX_CLR_RGB = 0x0, + GX_CLR_RGBA = 0x1, + GX_TEX_S = 0x0, + GX_TEX_ST = 0x1, + }; + + enum _GXZFmt16 : __int32 + { + GX_ZC_LINEAR = 0x0, + GX_ZC_NEAR = 0x1, + GX_ZC_MID = 0x2, + GX_ZC_FAR = 0x3, + }; + + enum _GXFBClamp : __int32 + { + GX_CLAMP_NONE = 0x0, + GX_CLAMP_TOP = 0x1, + GX_CLAMP_BOTTOM = 0x2, + }; + + enum nglPaletteFormat : __int32 + { + NGLPAL_L8A8 = 0x0, + NGLPAL_R5G6B5 = 0x1, + NGLPAL_RGB5A3 = 0x2, + }; + + enum _GXIndTexScale : __int32 + { + GX_ITS_1 = 0x0, + GX_ITS_2 = 0x1, + GX_ITS_4 = 0x2, + GX_ITS_8 = 0x3, + GX_ITS_16 = 0x4, + GX_ITS_32 = 0x5, + GX_ITS_64 = 0x6, + GX_ITS_128 = 0x7, + GX_ITS_256 = 0x8, + GX_MAX_ITSCALE = 0x9, + }; + + enum _GXTexMtx : __int32 + { + GX_TEXMTX0 = 0x1E, + GX_TEXMTX1 = 0x21, + GX_TEXMTX2 = 0x24, + GX_TEXMTX3 = 0x27, + GX_TEXMTX4 = 0x2A, + GX_TEXMTX5 = 0x2D, + GX_TEXMTX6 = 0x30, + GX_TEXMTX7 = 0x33, + GX_TEXMTX8 = 0x36, + GX_TEXMTX9 = 0x39, + GX_IDENTITY = 0x3C, + }; + + enum nglColorChannel : __int32 + { + NGL_COLOR0A0 = 0x0, + NGL_COLOR1A1 = 0x1, + NGL_COLOR0 = 0x0, + NGL_COLOR1 = 0x1, + NGL_ALPHA0 = 0x0, + NGL_ALPHA1 = 0x1, + NGL_COLOR_ZERO = 0x7, + NGL_ALPHA_BUMP = 0x5, + NGL_ALPHA_BUMPN = 0x6, + NGL_COLOR_NULL = 0x7, + }; + + enum _GXIndTexAlphaSel : __int32 + { + GX_ITBA_OFF = 0x0, + GX_ITBA_S = 0x1, + GX_ITBA_T = 0x2, + GX_ITBA_U = 0x3, + GX_MAX_ITBALPHA = 0x4, + }; + + enum nflRequestID : unsigned __int32 + { + NFL_REQUEST_ID_INVALID = 0xFFFFFFFF, + NFL_REQUEST_ID_FORCE32 = 0x7FFFFFFF, + }; + + enum nflStreamID : unsigned __int32 + { + NFL_STREAM_ID_INVALID = 0xFFFFFFFF, + NFL_STREAM_ID_DEFAULT = 0x0, + NFL_STREAM_ID_FORCE32 = 0x7FFFFFFF, + }; + + enum nflRequestState : unsigned __int32 + { + NFL_REQUEST_STATE_INVALID = 0xFFFFFFFF, + NFL_REQUEST_STATE_COMPLETED = 0x0, + NFL_REQUEST_STATE_CANCELED = 0x1, + NFL_REQUEST_STATE_TIMEOUT = 0x2, + NFL_REQUEST_STATE_ERROR = 0x3, + NFL_REQUEST_STATE_ACTIVE = 0x4, + }; + + enum nflRequestType : unsigned __int32 + { + NFL_REQUEST_TYPE_INVALID = 0xFFFFFFFF, + NFL_REQUEST_TYPE_READ = 0x0, + NFL_REQUEST_TYPE_WRITE = 0x1, + }; + + enum nflPriority : unsigned __int32 + { + NFL_PRIORITY_INVALID = 0xFFFFFFFF, + NFL_PRIORITY_LOWEST = 0x0, + NFL_PRIORITY_LOW = 0x1, + NFL_PRIORITY_NORMAL = 0x2, + NFL_PRIORITY_HIGH = 0x3, + NFL_PRIORITY_HIGHEST = 0x4, + }; + + enum nfdError : unsigned __int32 + { + NFD_ERROR_FORCE32 = 0x7FFFFFFF, + NFD_ERROR_INVALID = 0xFFFFFFFF, + NFD_ERROR_NOERROR = 0x0, + NFD_ERROR_FAILURE = 0x1, + NFD_ERROR_EOF = 0x2, + NFD_ERROR_UNALIGNED_ACCESS = 0x3, + NFD_ERROR_INVALID_MEDIA = 0x4, + NFD_ERROR_INVALID_STATE = 0x5, + NFD_ERROR_INVALID_FLAGS = 0x6, + NFD_ERROR_INVALID_FILENAME = 0x7, + NFD_ERROR_INVALID_ARGUMENTS = 0x8, + }; + + enum nfdMediaState : unsigned __int32 + { + NFD_MEDIA_STATE_FORCE32 = 0x7FFFFFFF, + NFD_MEDIA_STATE_INVALID = 0xFFFFFFFF, + NFD_MEDIA_STATE_LOADING = 0x0, + NFD_MEDIA_STATE_LOADED = 0x1, + NFD_MEDIA_STATE_LOADFAILED = 0x2, + NFD_MEDIA_STATE_UNLOADING = 0x3, + NFD_MEDIA_STATE_UNLOADED = 0x4, + }; + + enum nfdFileFlags : unsigned __int32 + { + NFD_FILE_FLAGS_FORCE32 = 0x7FFFFFFF, + NFD_FILE_FLAGS_INVALID = 0xFFFFFFFF, + NFD_FILE_FLAGS_READ = 0x1, + NFD_FILE_FLAGS_WRITE = 0x2, + NFD_FILE_FLAGS_CREATE = 0x4, + NFD_FILE_FLAGS_ASYNC_OPEN = 0x8, + }; + + enum nfdIoState : unsigned __int32 + { + NFD_IO_STATE_FORCE32 = 0x7FFFFFFF, + NFD_IO_STATE_INVALID = 0xFFFFFFFF, + NFD_IO_STATE_IDLE = 0x0, + NFD_IO_STATE_WORKING = 0x1, + NFD_IO_STATE_WORKDONE = 0x2, + NFD_IO_STATE_CANCELING = 0x3, + NFD_IO_STATE_CANCELED = 0x4, + NFD_IO_STATE_ERROR = 0x5, + }; + + enum txSlot : unsigned __int32 + { + TX_SLOT_INVALID = 0xFFFFFFFF, + TX_SLOT_FORCE32 = 0x7FFFFFFF, + }; + + enum nfsRequestState : __int32 + { + NFS_REQUEST_STATE_WAITING = 0x0, + NFS_REQUEST_STATE_WORKING = 0x1, + NFS_REQUEST_STATE_WORKDONE = 0x2, + NFS_REQUEST_STATE_CANCELING = 0x3, + NFS_REQUEST_STATE_CANCELED = 0x4, + NFS_REQUEST_STATE_TIMEOUT = 0x5, + NFS_REQUEST_STATE_IO_ERROR = 0x6, + NFS_REQUEST_STATE_IO_ERROR_WAITING = 0x7, + }; + + enum nfsFileType : __int32 + { + NFS_FILE_TYPE_NATIVE = 0x0, + NFS_FILE_TYPE_SUBFILE = 0x1, + }; + + enum _enum : unsigned __int32 + { + TX_SLOT_INVALID_0 = 0xFFFFFFFF, + TX_SLOT_FORCE32_0 = 0x7FFFFFFF, + }; + + enum kbutton_buttons + { + KB_LEFT = 0x0, + KB_RIGHT = 0x1, + KB_FORWARD = 0x2, + KB_BACKWARD = 0x3, + KB_LOOKUP = 0x4, + KB_LOOKDOWN = 0x5, + KB_MOVELEFT = 0x6, + KB_MOVERIGHT = 0x7, + KB_STRAFE = 0x8, + KB_SPEED = 0x9, + KB_STAND = 0xA, + KB_CROUCH = 0xB, + KB_GOSTAND = 0xC, + KB_MLOOK = 0xD, + KB_ATTACK = 0xE, + KB_BREATH = 0xF, + KB_FRAG = 0x10, + KB_SMOKE = 0x11, + KB_MELEE = 0x12, + KB_ACTIVATE = 0x13, + KB_RELOAD = 0x14, + KB_USERELOAD = 0x15, + KB_LEANLEFT = 0x16, + KB_LEANRIGHT = 0x17, + KB_PRONE = 0x18, + KB_THROW = 0x1A, + KB_SPRINT = 0x1B, + KB_TALK = 0x1D, + }; + + enum eAutoMeleeState + { + AMS_NOT_ACTIVE = 0x0, + AMS_TARGET_AQUIRED = 0x1, + AMS_TARGETING = 0x2, + }; + + enum ClientEvents_e + { + EV_NONE = 0x0, + EV_FOLIAGE_SOUND = 0x1, + EV_STOP_WEAPON_SOUND = 0x2, + EV_STOP_SOUND_ALIAS = 0x3, + EV_SOUND_ALIAS = 0x4, + EV_SOUND_ALIAS_AS_MASTER = 0x5, + EV_SOUND_BATTLECHAT_ALIAS = 0x6, + EV_STOPSOUNDS = 0x7, + EV_STANCE_FORCE_STAND = 0x8, + EV_STANCE_FORCE_CROUCH = 0x9, + EV_STANCE_FORCE_PRONE = 0xA, + EV_ITEM_PICKUP = 0xB, + EV_AMMO_PICKUP = 0xC, + EV_NOAMMO = 0xD, + EV_EMPTYCLIP = 0xE, + EV_EMPTY_OFFHAND = 0xF, + EV_RESET_ADS = 0x10, + EV_RELOAD = 0x11, + EV_RELOAD_FROM_EMPTY = 0x12, + EV_RELOAD_START = 0x13, + EV_RELOAD_END = 0x14, + EV_RELOAD_START_NOTIFY = 0x15, + EV_RELOAD_ADDAMMO = 0x16, + EV_RAISE_WEAPON = 0x17, + EV_FIRST_RAISE_WEAPON = 0x18, + EV_PUTAWAY_WEAPON = 0x19, + EV_WEAPON_ALT = 0x1A, + EV_PULLBACK_WEAPON = 0x1B, + EV_FIRE_WEAPON = 0x1C, + EV_FIRE_WEAPON_LASTSHOT = 0x1D, + EV_RECHAMBER_WEAPON = 0x1E, + EV_EJECT_BRASS = 0x1F, + EV_MELEE_SWIPE = 0x20, + EV_FIRE_MELEE = 0x21, + EV_WEAPON_DEPLOYING = 0x22, + EV_WEAPON_FINISH_DEPLOYING = 0x23, + EV_WEAPON_BREAKING_DOWN = 0x24, + EV_WEAPON_FINISH_BREAKING_DOWN = 0x25, + EV_PREP_OFFHAND = 0x26, + EV_USE_OFFHAND = 0x27, + EV_SWITCH_OFFHAND = 0x28, + EV_MELEE_HIT = 0x29, + EV_MELEE_MISS = 0x2A, + EV_MELEE_BLOOD = 0x2B, + EV_FIRE_WEAPON_MG42 = 0x2C, + EV_FIRE_QUADBARREL_1 = 0x2D, + EV_FIRE_QUADBARREL_2 = 0x2E, + EV_BULLET_TRACER = 0x2F, + EV_SOUND_ALIAS_NOTIFY = 0x30, + EV_SOUND_ALIAS_NOTIFY_AS_MASTER = 0x31, + EV_SOUND_ALIAS_ADD_NOTIFY = 0x32, + EV_BULLET_HIT = 0x33, + EV_BULLET_HIT_CLIENT_SMALL = 0x34, + EV_BULLET_HIT_CLIENT_LARGE = 0x35, + EV_DESTRUCTIBLE_BULLET_HIT = 0x36, + EV_DESTRUCTIBLE_EXPLOSION_HIT = 0x37, + EV_GRENADE_BOUNCE = 0x38, + EV_GRENADE_EXPLODE = 0x39, + EV_ROCKET_EXPLODE = 0x3A, + EV_ROCKET_EXPLODE_NOMARKS = 0x3B, + EV_FLASHBANG_EXPLODE = 0x3C, + EV_CUSTOM_EXPLODE = 0x3D, + EV_CUSTOM_EXPLODE_NOMARKS = 0x3E, + EV_CHANGE_TO_DUD = 0x3F, + EV_DUD_EXPLODE = 0x40, + EV_DUD_IMPACT = 0x41, + EV_FIRE_EXPLODE = 0x42, + EV_MOLOTOV_FLOAT = 0x43, + EV_BULLET = 0x44, + EV_PLAY_FX = 0x45, + EV_PLAY_FX_ON_TAG = 0x46, + EV_PHYS_EXPLOSION_SPHERE = 0x47, + EV_PHYS_EXPLOSION_CYLINDER = 0x48, + EV_PHYS_EXPLOSION_JOLT = 0x49, + EV_PHYS_LAUNCH = 0x4A, + EV_CREATE_DYNENT = 0x4B, + EV_CREATE_ROPE = 0x4C, + EV_BLOOD_IMPACTS = 0x4D, + EV_DETACH_ENTITY = 0x4E, + EV_BREAK_ROPE = 0x4F, + EV_DELETE_ROPE = 0x50, + EV_TANNING = 0x51, + EV_SETWETNESS = 0x52, + EV_STOP_BURNING = 0x53, + EV_EARTHQUAKE = 0x54, + EV_GRENADE_DROP = 0x55, + EV_GRENADE_SUICIDE = 0x56, + EV_DETONATE = 0x57, + EV_NIGHTVISION_WEAR = 0x58, + EV_NIGHTVISION_REMOVE = 0x59, + EV_NO_FRAG_GRENADE_HINT = 0x5A, + EV_NO_SPECIAL_GRENADE_HINT = 0x5B, + EV_TARGET_TOO_CLOSE_HINT = 0x5C, + EV_TARGET_NOT_ENOUGH_CLEARANCE = 0x5D, + EV_LOCKON_REQUIRED_HINT = 0x5E, + EV_FOOTSTEP_SPRINT = 0x5F, + EV_FOOTSTEP_RUN = 0x60, + EV_FOOTSTEP_WALK = 0x61, + EV_FOOTSTEP_PRONE = 0x62, + EV_JUMP = 0x63, + EV_LANDING_DEFAULT = 0x64, + EV_LANDING_BARK = 0x65, + EV_LANDING_BRICK = 0x66, + EV_LANDING_CARPET = 0x67, + EV_LANDING_CLOTH = 0x68, + EV_LANDING_CONCRETE = 0x69, + EV_LANDING_DIRT = 0x6A, + EV_LANDING_FLESH = 0x6B, + EV_LANDING_FOLIAGE = 0x6C, + EV_LANDING_GLASS = 0x6D, + EV_LANDING_GRASS = 0x6E, + EV_LANDING_GRAVEL = 0x6F, + EV_LANDING_ICE = 0x70, + EV_LANDING_METAL = 0x71, + EV_LANDING_MUD = 0x72, + EV_LANDING_PAPER = 0x73, + EV_LANDING_PLASTER = 0x74, + EV_LANDING_ROCK = 0x75, + EV_LANDING_SAND = 0x76, + EV_LANDING_SNOW = 0x77, + EV_LANDING_WATER = 0x78, + EV_LANDING_WOOD = 0x79, + EV_LANDING_ASPHALT = 0x7A, + EV_LANDING_CERAMIC = 0x7B, + EV_LANDING_PLASTIC = 0x7C, + EV_LANDING_RUBBER = 0x7D, + EV_LANDING_CUSHION = 0x7E, + EV_LANDING_FRUIT = 0x7F, + EV_LANDING_PAINTEDMETAL = 0x80, + EV_LANDING_PLAYER = 0x81, + EV_LANDING_TALLGRASS = 0x82, + EV_LANDING_PAIN_DEFAULT = 0x83, + EV_LANDING_PAIN_BARK = 0x84, + EV_LANDING_PAIN_BRICK = 0x85, + EV_LANDING_PAIN_CARPET = 0x86, + EV_LANDING_PAIN_CLOTH = 0x87, + EV_LANDING_PAIN_CONCRETE = 0x88, + EV_LANDING_PAIN_DIRT = 0x89, + EV_LANDING_PAIN_FLESH = 0x8A, + EV_LANDING_PAIN_FOLIAGE = 0x8B, + EV_LANDING_PAIN_GLASS = 0x8C, + EV_LANDING_PAIN_GRASS = 0x8D, + EV_LANDING_PAIN_GRAVEL = 0x8E, + EV_LANDING_PAIN_ICE = 0x8F, + EV_LANDING_PAIN_METAL = 0x90, + EV_LANDING_PAIN_MUD = 0x91, + EV_LANDING_PAIN_PAPER = 0x92, + EV_LANDING_PAIN_PLASTER = 0x93, + EV_LANDING_PAIN_ROCK = 0x94, + EV_LANDING_PAIN_SAND = 0x95, + EV_LANDING_PAIN_SNOW = 0x96, + EV_LANDING_PAIN_WATER = 0x97, + EV_LANDING_PAIN_WOOD = 0x98, + EV_LANDING_PAIN_ASPHALT = 0x99, + EV_LANDING_PAIN_CERAMIC = 0x9A, + EV_LANDING_PAIN_PLASTIC = 0x9B, + EV_LANDING_PAIN_RUBBER = 0x9C, + EV_LANDING_PAIN_CUSHION = 0x9D, + EV_LANDING_PAIN_FRUIT = 0x9E, + EV_LANDING_PAIN_PAINTEDMETAL = 0x9F, + EV_LANDING_PAIN_PLAYER = 0xA0, + EV_LANDING_PAIN_TALLGRASS = 0xA1, + EV_FIRE_VEHICLE_TURRET = 0xA2, + EV_FIRE_GUNNER_1 = 0xA3, + EV_FIRE_GUNNER_2 = 0xA4, + EV_FIRE_GUNNER_3 = 0xA5, + EV_FIRE_GUNNER_4 = 0xA6, + EV_FIRE_GUNNER_1A = 0xA7, + EV_FIRE_GUNNER_2A = 0xA8, + EV_FIRE_GUNNER_3A = 0xA9, + EV_FIRE_GUNNER_4A = 0xAA, + EV_START_CAMERA_TWEEN = 0xAB, + EV_DESTRUCTIBLE_DISABLE_PIECES = 0xAC, + EV_FOOTPRINT = 0xAD, + EV_MANTLE = 0xAE, + EV_CANNOTPLANT = 0xAF, + }; + + enum contents_e + { + CONTENTS_SOLID = 0x1, + CONTENTS_FOLIAGE = 0x2, + CONTENTS_NONCOLLIDING = 0x4, + CONTENTS_GLASS = 0x10, + CONTENTS_WATER = 0x20, + CONTENTS_CANSHOOTCLIP = 0x40, + CONTENTS_MISSILECLIP = 0x80, + CONTENTS_ITEM = 0x100, + CONTENTS_VEHICLECLIP = 0x200, + CONTENTS_ITEMCLIP = 0x400, + CONTENTS_SKY = 0x800, + CONTENTS_AI_NOSIGHT = 0x1000, + CONTENTS_CLIPSHOT = 0x2000, + CONTENTS_CORPSE_CLIPSHOT = 0x4000, + CONTENTS_ACTOR = 0x8000, + CONTENTS_FAKE_ACTOR = 0x8000, + CONTENTS_PLAYERCLIP = 0x10000, + CONTENTS_MONSTERCLIP = 0x20000, + CONTENTS_PLAYERVEHICLECLIP = 0x40000, + CONTENTS_USE = 0x200000, + CONTENTS_UTILITYCLIP = 0x400000, + CONTENTS_VEHICLE = 0x800000, + CONTENTS_MANTLE = 0x1000000, + CONTENTS_PLAYER = 0x2000000, + CONTENTS_CORPSE = 0x4000000, + CONTENTS_DETAIL = 0x8000000, + CONTENTS_STRUCTURAL = 0x10000000, + CONTENTS_LOOKAT = 0x10000000, + CONTENTS_TRIGGER = 0x40000000, + CONTENTS_NODROP = 0x80000000, + }; + + enum pmflags_t + { + PMF_PRONE = 0x1, + PMF_MANTLE = 0x4, + PMF_LADDER = 0x8, + PMF_BACKWARDS_RUN = 0x20, + PMF_RESPAWNED = 0x400, + PMF_JUMPING = 0x4000, + PMF_SPRINTING = 0x8000, + PMF_VEHICLE_ATTACHED = 0x100000, + }; + + enum LumpType : __int32 + { + LUMP_MATERIALS = 0x0, + LUMP_LIGHTBYTES_COMPRESSED = 0x1, + LUMP_LIGHTGRIDENTRIES = 0x2, + LUMP_LIGHTGRIDCOLORS = 0x3, + LUMP_PLANES = 0x4, + LUMP_BRUSHSIDES = 0x5, + LUMP_BRUSHSIDEEDGECOUNTS = 0x6, + LUMP_BRUSHEDGES = 0x7, + LUMP_BRUSHES = 0x8, + LUMP_TRIANGLES = 0x9, + LUMP_DRAWVERTS = 0xA, + LUMP_DRAWINDICES = 0xB, + LUMP_CULLGROUPS = 0xC, + LUMP_CULLGROUPINDICES = 0xD, + LUMP_LIGHTBYTES_UNCOMPRESSED = 0xE, + LUMP_OBSOLETE_2 = 0xF, + LUMP_OBSOLETE_3 = 0x10, + LUMP_OBSOLETE_4 = 0x11, + LUMP_OBSOLETE_5 = 0x12, + LUMP_PORTALVERTS = 0x13, + LUMP_OBSOLETE_6 = 0x14, + LUMP_UINDS = 0x15, + LUMP_BRUSHVERTSCOUNTS = 0x16, + LUMP_BRUSHVERTS = 0x17, + LUMP_AABBTREES = 0x18, + LUMP_CELLS = 0x19, + LUMP_PORTALS = 0x1A, + LUMP_NODES = 0x1B, + LUMP_LEAFS = 0x1C, + LUMP_LEAFBRUSHES = 0x1D, + LUMP_LEAFSURFACES = 0x1E, + LUMP_COLLISIONVERTS = 0x1F, + LUMP_COLLISIONTRIS = 0x20, + LUMP_COLLISIONEDGEWALKABLE = 0x21, + LUMP_COLLISIONBORDERS = 0x22, + LUMP_COLLISIONPARTITIONS = 0x23, + LUMP_COLLISIONAABBS = 0x24, + LUMP_MODELS = 0x25, + LUMP_VISIBILITY = 0x26, + LUMP_ENTITIES = 0x27, + LUMP_PATHCONNECTIONS = 0x28, + LUMP_REFLECTION_PROBES = 0x29, + LUMP_VERTEX_LAYER_DATA = 0x2A, + LUMP_PRIMARY_LIGHTS = 0x2B, + LUMP_LIGHTGRIDHEADER = 0x2C, + LUMP_LIGHTGRIDROWS = 0x2D, + LUMP_OBSOLETE_10 = 0x2E, + LUMP_OBSOLETE_11 = 0x2F, + LUMP_OBSOLETE_12 = 0x30, + LUMP_OBSOLETE_13 = 0x31, + LUMP_OBSOLETE_14 = 0x32, + LUMP_OBSOLETE_15 = 0x33, + LUMP_UNUSED1 = 0x34, + LUMP_UNUSED2 = 0x35, + LUMP_UNUSED3 = 0x36, + LUMP_UNUSED4 = 0x37, + LUMP_UNUSED5 = 0x38, + LUMP_UNUSED6 = 0x39, + LUMP_SIMPLELIGHTMAPBYTES = 0x3A, + LUMP_UNUSED7 = 0x3B, + LUMP_UNUSED8 = 0x3C, + LUMP_UNUSED9 = 0x3D, + LUMP_LIGHTREGIONS = 0x3E, + LUMP_LIGHTREGION_HULLS = 0x3F, + LUMP_LIGHTREGION_AXES = 0x40, + LUMP_UNUSED10 = 0x41, + LUMP_LIGHTGRID2D_LIGHTS = 0x42, + LUMP_LIGHTGRID2D_INDICES = 0x43, + LUMP_LIGHTGRID2D_POINTS = 0x44, + LUMP_LIGHTGRID2D_CELLS = 0x45, + LUMP_LIGHT_CORONAS = 0x46, + LUMP_SHADOWMAP_VOLUMES = 0x47, + LUMP_SHADOWMAP_VOLUME_PLANES = 0x48, + LUMP_EXPOSURE_VOLUMES = 0x49, + LUMP_EXPOSURE_VOLUME_PLANES = 0x4A, + LUMP_WORLDFOG_VOLUMES = 0x4B, + LUMP_WORLDFOG_VOLUME_PLANES = 0x4C, + LUMP_VISION_VOLUMES = 0x4D, + LUMP_VISION_VOLUME_PLANES = 0x4E, + LUMP_OCCLUDERS = 0x4F, + LUMP_OUTDOORBOUNDS = 0x50, + LUMP_HERO_ONLY_LIGHTS = 0x51, + LUMP_STATIC_MODEL_DATA = 0x52, + LUMP_SKY_GRID_VOLUMES = 0x53, + LUMP_LIGHTING_INFO = 0x54, + LUMP_SMODEL_LIGHTMAP_VCOLORS = 0x55, + LUMP_SMODEL_LIGHTMAP_VC_INSTS = 0x56, + LUMP_SIEGE_SKIN_MODEL_INSTS = 0x57, + LUMP_LIGHTGRIDCOEFFS = 0x58, + LUMP_LUT_VOLUMES = 0x59, + LUMP_LUT_VOLUME_PLANES = 0x5A, + LUMP_WORLDFOG_MODIFIER_VOLUMES = 0x5B, + LUMP_WORLDFOG_MODIFIER_VOLUME_PLANES = 0x5C, + LUMP_COUNT = 0x5D, + }; + + enum classNum_e + { + CLASS_NUM_ENTITY = 0x0, + CLASS_NUM_HUDELEM = 0x1, + CLASS_NUM_PATHNODE = 0x2, + CLASS_NUM_VEHICLENODE = 0x3, + CLASS_NUM_COUNT = 0x4, + }; + + enum fsMode_t : __int32 + { + FS_READ = 0x0, + FS_WRITE = 0x1, + FS_APPEND = 0x2, + FS_APPEND_SYNC = 0x3, + }; + + enum button_mask : __int32 + { + KEY_FIRE = 0x1, + KEY_SPRINT = 0x2, + KEY_MELEE = 0x4, + KEY_USE = 0x8, + KEY_RELOAD = 0x10, + KEY_USERELOAD = 0x20, + KEY_LEANLEFT = 0x40, + KEY_LEANRIGHT = 0x80, + KEY_PRONE = 0x100, + KEY_CROUCH = 0x200, + KEY_GOSTAND = 0x400, + KEY_ADSMODE = 0x800, + KEY_TEMP = 0x1000, + KEY_HOLDBREATH = 0x2000, + KEY_FRAG = 0x4000, + KEY_SMOKE = 0x8000, + KEY_SELECTING_LOCATION = 0x10000, + KEY_CANCEL_LOCATION = 0x20000, + KEY_NIGHTVISION = 0x40000, + KEY_ADS = 0x80000, + KEY_REVERSE = 0x100000, + KEY_HANDBRAKE = 0x200000, + KEY_THROW = 0x400000, + KEY_INMENU = 0x800000, + KEY_UNK6 = 0x1000000, + KEY_UNK7 = 0x2000000, + KEY_UNK8 = 0x2000000, + KEY_UNK9 = 0x4000000, + KEY_UNK10 = 0x8000000, + }; + + enum scr_enum_t + { + ENUM_NOP = 0x0, + ENUM_program = 0x1, + ENUM_assignment = 0x2, + ENUM_unknown_variable = 0x3, + ENUM_duplicate_variable = 0x4, + ENUM_local_variable = 0x5, + ENUM_local_variable_frozen = 0x6, + ENUM_duplicate_expression = 0x7, + ENUM_primitive_expression = 0x8, + ENUM_integer = 0x9, + ENUM_float = 0xA, + ENUM_minus_integer = 0xB, + ENUM_minus_float = 0xC, + ENUM_string = 0xD, + ENUM_istring = 0xE, + ENUM_array_variable = 0xF, + ENUM_unknown_field = 0x10, + ENUM_field_variable = 0x11, + ENUM_field_variable_frozen = 0x12, + ENUM_variable = 0x13, + ENUM_function = 0x14, + ENUM_call_expression = 0x15, + ENUM_local_function = 0x16, + ENUM_far_function = 0x17, + ENUM_function_pointer = 0x18, + ENUM_call = 0x19, + ENUM_method = 0x1A, + ENUM_call_expression_statement = 0x1B, + ENUM_script_call = 0x1C, + ENUM_return = 0x1D, + ENUM_return2 = 0x1E, + ENUM_wait = 0x1F, + ENUM_script_thread_call = 0x20, + ENUM_undefined = 0x21, + ENUM_self = 0x22, + ENUM_self_frozen = 0x23, + ENUM_level = 0x24, + ENUM_game = 0x25, + ENUM_anim = 0x26, + ENUM_if = 0x27, + ENUM_if_else = 0x28, + ENUM_while = 0x29, + ENUM_for = 0x2A, + ENUM_inc = 0x2B, + ENUM_dec = 0x2C, + ENUM_binary_equals = 0x2D, + ENUM_statement_list = 0x2E, + ENUM_developer_statement_list = 0x2F, + ENUM_expression_list = 0x30, + ENUM_bool_or = 0x31, + ENUM_bool_and = 0x32, + ENUM_binary = 0x33, + ENUM_bool_not = 0x34, + ENUM_bool_complement = 0x35, + ENUM_size_field = 0x36, + ENUM_self_field = 0x37, + ENUM_precachetree = 0x38, + ENUM_waittill = 0x39, + ENUM_waittillmatch = 0x3A, + ENUM_waittillFrameEnd = 0x3B, + ENUM_notify = 0x3C, + ENUM_endon = 0x3D, + ENUM_switch = 0x3E, + ENUM_case = 0x3F, + ENUM_default = 0x40, + ENUM_break = 0x41, + ENUM_continue = 0x42, + ENUM_expression = 0x43, + ENUM_empty_array = 0x44, + ENUM_animation = 0x45, + ENUM_thread = 0x46, + ENUM_begin_developer_thread = 0x47, + ENUM_end_developer_thread = 0x48, + ENUM_usingtree = 0x49, + ENUM_false = 0x4A, + ENUM_true = 0x4B, + ENUM_animtree = 0x4C, + ENUM_breakon = 0x4D, + ENUM_breakpoint = 0x4E, + ENUM_prof_begin = 0x4F, + ENUM_prof_end = 0x50, + ENUM_vector = 0x51, + ENUM_object = 0x52, + ENUM_thread_object = 0x53, + ENUM_local = 0x54, + ENUM_statement = 0x55, + ENUM_bad_expression = 0x56, + ENUM_bad_statement = 0x57, + ENUM_include = 0x58, + ENUM_argument = 0x59, + }; + + enum LocalClientNum_t : unsigned __int32 + { + INVALID_LOCAL_CLIENT = 0xFFFFFFFF, + LOCAL_CLIENT_FIRST = 0x0, + LOCAL_CLIENT_0 = 0x0, + ONLY_LOCAL_CLIENT = 0x0, + LOCAL_CLIENT_COUNT = 0x1, + }; + + enum FsListBehavior_e + { + FS_LIST_PURE_ONLY = 0x0, + FS_LIST_ALL = 0x1, + }; + + enum CriticalSection : __int32 + { + CRITSECT_CONSOLE = 0x2, + CRITSECT_DEBUG_SOCKET = 0x3, + CRITSECT_COM_ERROR = 0x4, + CRITSECT_SCRIPT_STRING = 0xB, + CRITSECT_MEMORY_TREE = 0xC, + CRITSECT_SYS_EVENT_QUEUE = 0xE, + CRITSECT_PHYSICS_UPDATE = 0x15, + CRITSECT_CINEMATIC = 0x19, + CRITSECT_CINEMATIC_TARGET_CHANGE = 0x1A, + CRITSECT_CBUF = 0x2A, + CRITSECT_COUNT = 0x2F, + }; + + enum HASH_e + { + HASH_STAT_MASK = 0x30000, + HASH_STAT_HEAD = 0x20000, + HASH_STAT_MOVABLE = 0x10000, + HASH_STAT_FREE = 0x0, + }; + + enum VAR_e + { + VAR_STAT_FREE = 0x0, + VAR_BEGIN_REF = 0x1, + VAR_END_REF = 0x5, + VAR_STAT_MASK = 0x60, + VAR_STAT_MOVABLE = 0x20, + VAR_STAT_HEAD = 0x40, + VAR_STAT_EXTERNAL = 0x60, + VAR_MASK = 0x1F, + VAR_NAME_LOW_MASK = 0xFF000000, + VAR_NAME_HIGH_MASK = 0xFFFFFF00, + VAR_NAME_BITS = 0x8, + VARIABLELIST_CHILD_SIZE = 0x10000, + VARIABLELIST_CHILD_BEGIN = 0x6000, + SL_MAX_STRING_INDEX = 0x10000, + OBJECT_STACK = 0x15FFE, + FIRST_OBJECT = 0x14, + }; + + enum weapFieldType_t + { + WFT_WEAPONTYPE = 0xC, + WFT_WEAPONCLASS = 0xD, + WFT_OVERLAYRETICLE = 0xE, + WFT_PENETRATE_TYPE = 0xF, + WFT_IMPACT_TYPE = 0x10, + WFT_STANCE = 0x11, + WFT_PROJ_EXPLOSION = 0x12, + WFT_OFFHAND_CLASS = 0x13, + WFT_OFFHAND_SLOT = 0x14, + WFT_ACTIVE_RETICLE_TYPE = 0x15, + WFT_GUIDED_MISSILE_TYPE = 0x16, + WFT_BOUNCE_SOUND = 0x17, + WFT_STICKINESS = 0x18, + WFT_OVERLAYINTERFACE = 0x19, + WFT_INVENTORYTYPE = 0x1A, + WFT_FIRETYPE = 0x1B, + WFT_CLIPTYPE = 0x1C, + WFT_AMMOCOUNTER_CLIPTYPE = 0x1D, + WFT_ICONRATIO_HUD = 0x1E, + WFT_ICONRATIO_AMMOCOUNTER = 0x1F, + WFT_ICONRATIO_KILL = 0x20, + WFT_ICONRATIO_DPAD = 0x21, + WFT_HIDETAGS = 0x22, + WFT_NOTETRACKSOUNDMAP = 0x23, + WFT_NUM_FIELD_TYPES = 0x24, + }; + + enum csParseFieldType_t + { + CSPFT_STRING = 0x0, + CSPFT_STRING_MAX_STRING_CHARS = 0x1, + CSPFT_STRING_MAX_QPATH = 0x2, + CSPFT_STRING_MAX_OSPATH = 0x3, + CSPFT_INT = 0x4, + CSPFT_BOOL = 0x5, + CSPFT_FLOAT = 0x6, + CSPFT_MILLISECONDS = 0x7, + CSPFT_FX = 0x8, + CSPFT_XMODEL = 0x9, + CSPFT_MATERIAL = 0xA, + CSPFT_MATERIAL_STREAM = 0xB, + CSPFT_PHYS_PRESET = 0xC, + CSPFT_SCRIPT_STRING = 0xD, + CSPFT_NUM_BASE_FIELD_TYPES = 0xE, + }; + + enum GfxRenderCommand : __int16 + { + RC_END_OF_LIST = 0x0, + RC_SET_CUSTOM_CONSTANT = 0x1, + RC_SET_MATERIAL_COLOR = 0x2, + RC_SAVE_SCREEN = 0x3, + RC_SAVE_SCREEN_SECTION = 0x4, + RC_CLEAR_SCREEN = 0x5, + RC_SET_VIEWPORT = 0x6, + RC_SET_SCISSOR = 0x7, + RC_RESOLVE_COMPOSITE = 0x8, + RC_PC_COPY_IMAGE_GEN_MIP = 0x9, + RC_FIRST_NONCRITICAL = 0xA, + RC_STRETCH_PIC = 0xA, + RC_STRETCH_PIC_FLIP_ST = 0xB, + RC_STRETCH_PIC_ROTATE_XY = 0xC, + RC_STRETCH_PIC_ROTATE_ST = 0xD, + RC_STRETCH_RAW = 0xE, + RC_DRAW_QUAD_PIC = 0xF, + RC_DRAW_FULL_SCREEN_COLORED_QUAD = 0x10, + RC_DRAW_TEXT_2D = 0x11, + RC_DRAW_TEXT_3D = 0x12, + RC_BLEND_SAVED_SCREEN_BLURRED = 0x13, + RC_BLEND_SAVED_SCREEN_FLASHED = 0x14, + RC_DRAW_POINTS = 0x15, + RC_DRAW_LINES = 0x16, + RC_DRAW_TRIANGLES = 0x17, + RC_DRAW_QUADLIST_2D = 0x18, + RC_DRAW_EMBLEM_LAYER = 0x19, + RC_STRETCH_COMPOSITE = 0x1A, + RC_PROJECTION_SET = 0x1B, + RC_DRAW_FRAMED = 0x1C, + RC_COUNT = 0x1D, + }; + + enum HudelemFontTypes + { + HE_FONT_DEFAULT = 0x0, + HE_FONT_BIGFIXED = 0x1, + HE_FONT_SMALLFIXED = 0x2, + HE_FONT_OBJECTIVE = 0x3, + HE_FONT_BIG = 0x4, + HE_FONT_SMALL = 0x5, + HE_FONT_COUNT = 0x6, + }; + + enum hudelem_flags_t : __int32 + { + HE_FLAG_NONE = 0x0, + HE_FLAG_FOREGROUND = 0x1, + HE_FLAG_HIDEWHENDEAD = 0x2, + HE_FLAG_HIDEWHENINMENU = 0x4, + HE_FLAG_SHADOWED = 0x8, + HE_FLAG_SHADOWEDMORE = 0x10, + HE_FLAG_SET3DFONTUSEGLOWCOLOR = 0x20, + }; + + enum FF_DIR + { + FFD_DEFAULT = 0x0, + FFD_MOD_DIR = 0x1, + FFD_USER_MAP = 0x2, + }; + + enum block_state : __int32 + { + need_more = 0x0, + block_done = 0x1, + finish_started = 0x2, + finish_done = 0x3, + }; + + enum hudelem_update_t + { + HUDELEM_UPDATE_ARCHIVAL = 0x1, + HUDELEM_UPDATE_CURRENT = 0x2, + HUDELEM_UPDATE_ARCHIVAL_AND_CURRENT = 0x3, + }; + + enum sourceType_e + { + SOURCE_TYPE_BREAKPOINT = 0x1, + SOURCE_TYPE_CALL = 0x2, + SOURCE_TYPE_THREAD_START = 0x4, + SOURCE_TYPE_BUILTIN_CALL = 0x8, + SOURCE_TYPE_NOTIFY = 0x10, + }; + + enum animBodyPart_t + { + ANIM_BP_UNUSED = 0x0, + ANIM_BP_LEGS = 0x1, + ANIM_BP_TORSO = 0x2, + ANIM_BP_BOTH = 0x3, + NUM_ANIM_BODYPARTS = 0x4, + }; + +#ifdef __cplusplus +} +#endif diff --git a/src/game/game.cpp b/src/game/game.cpp index 98e1d9e..a9b73b6 100644 --- a/src/game/game.cpp +++ b/src/game/game.cpp @@ -1,5 +1,4 @@ #include -#include "game.hpp" #include #include diff --git a/src/game/game.hpp b/src/game/game.hpp index 5003597..892a348 100644 --- a/src/game/game.hpp +++ b/src/game/game.hpp @@ -1,7 +1,5 @@ #pragma once -#include "structs.hpp" - #define SELECT(mp, sp) (game::environment::t4mp() ? mp : sp) #define ASSIGN(type, mp, sp) reinterpret_cast(SELECT(mp, sp)) #define CALL_ADDR(mp, sp) ASSIGN(void*, mp, sp) @@ -67,5 +65,3 @@ namespace game T* t4sp_; }; } - -#include "symbols.hpp" \ No newline at end of file diff --git a/src/game/structs.hpp b/src/game/structs.hpp index 0bcfc70..9729359 100644 --- a/src/game/structs.hpp +++ b/src/game/structs.hpp @@ -1,8 +1,6 @@ #pragma once #ifdef __cplusplus -#include - #define ASSERT_STRUCT_SIZE(structure, size) static_assert(sizeof(structure) == size, "sizeof(" #structure ") != " #size); #define ASSERT_STRUCT_OFFSET(structure, member, offset) static_assert(offsetof(structure, member) == offset, "offsetof(" #structure ", " #member ") != " #offset); #else @@ -18,54 +16,13253 @@ ASSERT_STRUCT_SIZE(double, 8); ASSERT_STRUCT_SIZE(long, 4); ASSERT_STRUCT_SIZE(long long, 8); ASSERT_STRUCT_SIZE(void*, 4); -ASSERT_STRUCT_SIZE(jmp_buf, 4 * 16) -ASSERT_STRUCT_SIZE(CRITICAL_SECTION, 0x18) +ASSERT_STRUCT_SIZE(jmp_buf, 4 * 16); +ASSERT_STRUCT_SIZE(CRITICAL_SECTION, 0x18); + +#include "xasset.hpp" +#include "clientscript_public.hpp" #ifdef __cplusplus namespace game { #endif - enum con_channel_e - { - CON_CHANNEL_DONT_FILTER = 0x0, - CON_CHANNEL_ERROR = 0x1, - CON_CHANNEL_GAMENOTIFY = 0x2, - CON_CHANNEL_BOLDGAME = 0x3, - CON_CHANNEL_SUBTITLE = 0x4, - CON_CHANNEL_OBITUARY = 0x5, - CON_CHANNEL_LOGFILEONLY = 0x6, - CON_CHANNEL_CONSOLEONLY = 0x7, - CON_CHANNEL_GFX = 0x8, - CON_CHANNEL_SOUND = 0x9, - CON_CHANNEL_FILES = 0xA, - CON_CHANNEL_DEVGUI = 0xB, - CON_CHANNEL_PROFILE = 0xC, - CON_CHANNEL_UI = 0xD, - CON_CHANNEL_CLIENT = 0xE, - CON_CHANNEL_SERVER = 0xF, - CON_CHANNEL_SYSTEM = 0x10, - CON_CHANNEL_PLAYERWEAP = 0x11, - CON_CHANNEL_AI = 0x12, - CON_CHANNEL_ANIM = 0x13, - CON_CHANNEL_PHYS = 0x14, - CON_CHANNEL_FX = 0x15, - CON_CHANNEL_LEADERBOARDS = 0x16, - CON_CHANNEL_PARSERSCRIPT = 0x17, - CON_CHANNEL_SCRIPT = 0x18, - CON_CHANNEL_COOPINFO = 0x19, - CON_BUILTIN_CHANNEL_COUNT = 0x1A, - }; + struct client_s; + struct gclient_s; + struct gentity_s; + struct actor_s; + struct NitrousVehicle; + struct DObjModel_s; + struct game_hudelem_s; + struct z_stream_s; + struct flameGeneric_s; + struct flameStream_s; + struct phys_free_list_NitrousVehicle_T_internal; - struct scr_entref_t + struct __declspec(align(1)) struc_74 { - unsigned __int16 entnum; - unsigned __int16 classnum; - unsigned __int16 client; + _BYTE gap0[1567]; //OFS: 0x0 SIZE: 0x61F + char field_61F; //OFS: 0x61F SIZE: 0x1 }; + ASSERT_STRUCT_SIZE(struc_74, 0x620); + ASSERT_STRUCT_OFFSET(struc_74, gap0, 0x0); + ASSERT_STRUCT_OFFSET(struc_74, field_61F, 0x61F); + + struct ucmd_t + { + char * name; //OFS: 0x0 SIZE: 0x4 + void (__cdecl *func)(client_s *); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ucmd_t, 0x8); + ASSERT_STRUCT_OFFSET(ucmd_t, name, 0x0); + ASSERT_STRUCT_OFFSET(ucmd_t, func, 0x4); + + struct path_node_field_t + { + char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *getter)(void *, int); //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(path_node_field_t, 0x10); + ASSERT_STRUCT_OFFSET(path_node_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(path_node_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(path_node_field_t, type, 0x8); + ASSERT_STRUCT_OFFSET(path_node_field_t, getter, 0xC); + + struct GamerSettingState + { + char isProfileLoggedIn; //OFS: 0x0 SIZE: 0x1 + char errorOnRead; //OFS: 0x1 SIZE: 0x1 + _BYTE gap2[7]; //OFS: 0x2 SIZE: 0x7 + char subtitlesEnabled; //OFS: 0x9 SIZE: 0x1 + _BYTE gapA[258]; //OFS: 0xA SIZE: 0x102 + int gameSkill; //OFS: 0x10C SIZE: 0x4 + _BYTE gap110[260]; //OFS: 0x110 SIZE: 0x104 + int takeCoverWarnings; //OFS: 0x214 SIZE: 0x4 + int cheatPoints; //OFS: 0x218 SIZE: 0x4 + int cheatItemsSet1; //OFS: 0x21C SIZE: 0x4 + int cheatItemsSet2; //OFS: 0x220 SIZE: 0x4 + int arcadeScores[19]; //OFS: 0x224 SIZE: 0x4C + int missionGlobals[30]; //OFS: 0x270 SIZE: 0x78 + _BYTE gap2E8[520]; //OFS: 0x2E8 SIZE: 0x208 + float gamma; //OFS: 0x4F0 SIZE: 0x4 + _BYTE gap_4F4[4]; //OFS: 0x4F4 SIZE: 0x4 + char exeSettingsBuffer[1000]; //OFS: 0x4F8 SIZE: 0x3E8 + char commonSettingsBuffer[1000]; //OFS: 0x8E0 SIZE: 0x3E8 + char motd[256]; //OFS: 0xCC8 SIZE: 0x100 + _BYTE gap_DC8[4]; //OFS: 0xDC8 SIZE: 0x4 + int field_DCC; //OFS: 0xDCC SIZE: 0x4 + char clanAbbrev[172]; //OFS: 0xDD0 SIZE: 0xAC + }; + ASSERT_STRUCT_SIZE(GamerSettingState, 0xE7C); + ASSERT_STRUCT_OFFSET(GamerSettingState, isProfileLoggedIn, 0x0); + ASSERT_STRUCT_OFFSET(GamerSettingState, errorOnRead, 0x1); + ASSERT_STRUCT_OFFSET(GamerSettingState, gap2, 0x2); + ASSERT_STRUCT_OFFSET(GamerSettingState, subtitlesEnabled, 0x9); + ASSERT_STRUCT_OFFSET(GamerSettingState, gapA, 0xA); + ASSERT_STRUCT_OFFSET(GamerSettingState, gameSkill, 0x10C); + ASSERT_STRUCT_OFFSET(GamerSettingState, gap110, 0x110); + ASSERT_STRUCT_OFFSET(GamerSettingState, takeCoverWarnings, 0x214); + ASSERT_STRUCT_OFFSET(GamerSettingState, cheatPoints, 0x218); + ASSERT_STRUCT_OFFSET(GamerSettingState, cheatItemsSet1, 0x21C); + ASSERT_STRUCT_OFFSET(GamerSettingState, cheatItemsSet2, 0x220); + ASSERT_STRUCT_OFFSET(GamerSettingState, arcadeScores, 0x224); + ASSERT_STRUCT_OFFSET(GamerSettingState, missionGlobals, 0x270); + ASSERT_STRUCT_OFFSET(GamerSettingState, gap2E8, 0x2E8); + ASSERT_STRUCT_OFFSET(GamerSettingState, gamma, 0x4F0); + ASSERT_STRUCT_OFFSET(GamerSettingState, gap_4F4, 0x4F4); + ASSERT_STRUCT_OFFSET(GamerSettingState, exeSettingsBuffer, 0x4F8); + ASSERT_STRUCT_OFFSET(GamerSettingState, commonSettingsBuffer, 0x8E0); + ASSERT_STRUCT_OFFSET(GamerSettingState, motd, 0xCC8); + ASSERT_STRUCT_OFFSET(GamerSettingState, gap_DC8, 0xDC8); + ASSERT_STRUCT_OFFSET(GamerSettingState, field_DCC, 0xDCC); + ASSERT_STRUCT_OFFSET(GamerSettingState, clanAbbrev, 0xDD0); + + struct __declspec(align(1)) colorunpacked + { + char r; //OFS: 0x0 SIZE: 0x1 + char g; //OFS: 0x1 SIZE: 0x1 + char b; //OFS: 0x2 SIZE: 0x1 + char a; //OFS: 0x3 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(colorunpacked, 0x4); + ASSERT_STRUCT_OFFSET(colorunpacked, r, 0x0); + ASSERT_STRUCT_OFFSET(colorunpacked, g, 0x1); + ASSERT_STRUCT_OFFSET(colorunpacked, b, 0x2); + ASSERT_STRUCT_OFFSET(colorunpacked, a, 0x3); + + union hudelem_color_t + { + colorunpacked color; //OFS: 0x0 SIZE: 0x4 + int rgba; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(hudelem_color_t, 0x4); + + struct hudelem_s + { + he_type_t type; //OFS: 0x0 SIZE: 0x4 + float x; //OFS: 0x4 SIZE: 0x4 + float y; //OFS: 0x8 SIZE: 0x4 + float z; //OFS: 0xC SIZE: 0x4 + int targetEntNum; //OFS: 0x10 SIZE: 0x4 + float fontScale; //OFS: 0x14 SIZE: 0x4 + float fromFontScale; //OFS: 0x18 SIZE: 0x4 + int fontScaleStartTime; //OFS: 0x1C SIZE: 0x4 + int fontScaleTime; //OFS: 0x20 SIZE: 0x4 + HudelemFontTypes font; //OFS: 0x24 SIZE: 0x4 + int alignOrg; //OFS: 0x28 SIZE: 0x4 + int alignScreen; //OFS: 0x2C SIZE: 0x4 + hudelem_color_t color; //OFS: 0x30 SIZE: 0x4 + hudelem_color_t fromColor; //OFS: 0x34 SIZE: 0x4 + int fadeStartTime; //OFS: 0x38 SIZE: 0x4 + int fadeTime; //OFS: 0x3C SIZE: 0x4 + int label; //OFS: 0x40 SIZE: 0x4 + int width; //OFS: 0x44 SIZE: 0x4 + int height; //OFS: 0x48 SIZE: 0x4 + int materialIndex; //OFS: 0x4C SIZE: 0x4 + int offscreenMaterialIdx; //OFS: 0x50 SIZE: 0x4 + int fromWidth; //OFS: 0x54 SIZE: 0x4 + int fromHeight; //OFS: 0x58 SIZE: 0x4 + int scaleStartTime; //OFS: 0x5C SIZE: 0x4 + int scaleTime; //OFS: 0x60 SIZE: 0x4 + float fromX; //OFS: 0x64 SIZE: 0x4 + float fromY; //OFS: 0x68 SIZE: 0x4 + int fromAlignOrg; //OFS: 0x6C SIZE: 0x4 + int fromAlignScreen; //OFS: 0x70 SIZE: 0x4 + int moveStartTime; //OFS: 0x74 SIZE: 0x4 + int moveTime; //OFS: 0x78 SIZE: 0x4 + int time; //OFS: 0x7C SIZE: 0x4 + int duration; //OFS: 0x80 SIZE: 0x4 + float value; //OFS: 0x84 SIZE: 0x4 + int text; //OFS: 0x88 SIZE: 0x4 + float sort; //OFS: 0x8C SIZE: 0x4 + hudelem_color_t glowColor; //OFS: 0x90 SIZE: 0x4 + int fxBirthTime; //OFS: 0x94 SIZE: 0x4 + int fxLetterTime; //OFS: 0x98 SIZE: 0x4 + int fxDecayStartTime; //OFS: 0x9C SIZE: 0x4 + int fxDecayDuration; //OFS: 0xA0 SIZE: 0x4 + int soundID; //OFS: 0xA4 SIZE: 0x4 + hudelem_flags_t flags; //OFS: 0xA8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(hudelem_s, 0xAC); + ASSERT_STRUCT_OFFSET(hudelem_s, type, 0x0); + ASSERT_STRUCT_OFFSET(hudelem_s, x, 0x4); + ASSERT_STRUCT_OFFSET(hudelem_s, y, 0x8); + ASSERT_STRUCT_OFFSET(hudelem_s, z, 0xC); + ASSERT_STRUCT_OFFSET(hudelem_s, targetEntNum, 0x10); + ASSERT_STRUCT_OFFSET(hudelem_s, fontScale, 0x14); + ASSERT_STRUCT_OFFSET(hudelem_s, fromFontScale, 0x18); + ASSERT_STRUCT_OFFSET(hudelem_s, fontScaleStartTime, 0x1C); + ASSERT_STRUCT_OFFSET(hudelem_s, fontScaleTime, 0x20); + ASSERT_STRUCT_OFFSET(hudelem_s, font, 0x24); + ASSERT_STRUCT_OFFSET(hudelem_s, alignOrg, 0x28); + ASSERT_STRUCT_OFFSET(hudelem_s, alignScreen, 0x2C); + ASSERT_STRUCT_OFFSET(hudelem_s, color, 0x30); + ASSERT_STRUCT_OFFSET(hudelem_s, fromColor, 0x34); + ASSERT_STRUCT_OFFSET(hudelem_s, fadeStartTime, 0x38); + ASSERT_STRUCT_OFFSET(hudelem_s, fadeTime, 0x3C); + ASSERT_STRUCT_OFFSET(hudelem_s, label, 0x40); + ASSERT_STRUCT_OFFSET(hudelem_s, width, 0x44); + ASSERT_STRUCT_OFFSET(hudelem_s, height, 0x48); + ASSERT_STRUCT_OFFSET(hudelem_s, materialIndex, 0x4C); + ASSERT_STRUCT_OFFSET(hudelem_s, offscreenMaterialIdx, 0x50); + ASSERT_STRUCT_OFFSET(hudelem_s, fromWidth, 0x54); + ASSERT_STRUCT_OFFSET(hudelem_s, fromHeight, 0x58); + ASSERT_STRUCT_OFFSET(hudelem_s, scaleStartTime, 0x5C); + ASSERT_STRUCT_OFFSET(hudelem_s, scaleTime, 0x60); + ASSERT_STRUCT_OFFSET(hudelem_s, fromX, 0x64); + ASSERT_STRUCT_OFFSET(hudelem_s, fromY, 0x68); + ASSERT_STRUCT_OFFSET(hudelem_s, fromAlignOrg, 0x6C); + ASSERT_STRUCT_OFFSET(hudelem_s, fromAlignScreen, 0x70); + ASSERT_STRUCT_OFFSET(hudelem_s, moveStartTime, 0x74); + ASSERT_STRUCT_OFFSET(hudelem_s, moveTime, 0x78); + ASSERT_STRUCT_OFFSET(hudelem_s, time, 0x7C); + ASSERT_STRUCT_OFFSET(hudelem_s, duration, 0x80); + ASSERT_STRUCT_OFFSET(hudelem_s, value, 0x84); + ASSERT_STRUCT_OFFSET(hudelem_s, text, 0x88); + ASSERT_STRUCT_OFFSET(hudelem_s, sort, 0x8C); + ASSERT_STRUCT_OFFSET(hudelem_s, glowColor, 0x90); + ASSERT_STRUCT_OFFSET(hudelem_s, fxBirthTime, 0x94); + ASSERT_STRUCT_OFFSET(hudelem_s, fxLetterTime, 0x98); + ASSERT_STRUCT_OFFSET(hudelem_s, fxDecayStartTime, 0x9C); + ASSERT_STRUCT_OFFSET(hudelem_s, fxDecayDuration, 0xA0); + ASSERT_STRUCT_OFFSET(hudelem_s, soundID, 0xA4); + ASSERT_STRUCT_OFFSET(hudelem_s, flags, 0xA8); + + union XAnimParent_u + { + XAnimParts * parts; //OFS: 0x0 SIZE: 0x4 + XAnimParent animParent; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimParent_u, 0x4); + + struct XAnimState + { + float currentAnimTime; //OFS: 0x0 SIZE: 0x4 + float oldTime; //OFS: 0x4 SIZE: 0x4 + __int16 cycleCount; //OFS: 0x8 SIZE: 0x2 + __int16 oldCycleCount; //OFS: 0xA SIZE: 0x2 + float goalTime; //OFS: 0xC SIZE: 0x4 + float goalWeight; //OFS: 0x10 SIZE: 0x4 + float weight; //OFS: 0x14 SIZE: 0x4 + float rate; //OFS: 0x18 SIZE: 0x4 + bool instantWeightChange; //OFS: 0x1C SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(XAnimState, 0x20); + ASSERT_STRUCT_OFFSET(XAnimState, currentAnimTime, 0x0); + ASSERT_STRUCT_OFFSET(XAnimState, oldTime, 0x4); + ASSERT_STRUCT_OFFSET(XAnimState, cycleCount, 0x8); + ASSERT_STRUCT_OFFSET(XAnimState, oldCycleCount, 0xA); + ASSERT_STRUCT_OFFSET(XAnimState, goalTime, 0xC); + ASSERT_STRUCT_OFFSET(XAnimState, goalWeight, 0x10); + ASSERT_STRUCT_OFFSET(XAnimState, weight, 0x14); + ASSERT_STRUCT_OFFSET(XAnimState, rate, 0x18); + ASSERT_STRUCT_OFFSET(XAnimState, instantWeightChange, 0x1C); + + struct XAnimInfo + { + unsigned __int16 notifyChild; //OFS: 0x0 SIZE: 0x2 + __int16 notifyIndex; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 notifyName; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 notifyType; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 prev; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 next; //OFS: 0xA SIZE: 0x2 + unsigned __int16 children; //OFS: 0xC SIZE: 0x2 + unsigned __int16 parent; //OFS: 0xE SIZE: 0x2 + unsigned __int16 animIndex; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 animToModel; //OFS: 0x12 SIZE: 0x2 + XAnimParent_u u; //OFS: 0x14 SIZE: 0x4 + XAnimState state; //OFS: 0x18 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(XAnimInfo, 0x38); + ASSERT_STRUCT_OFFSET(XAnimInfo, notifyChild, 0x0); + ASSERT_STRUCT_OFFSET(XAnimInfo, notifyIndex, 0x2); + ASSERT_STRUCT_OFFSET(XAnimInfo, notifyName, 0x4); + ASSERT_STRUCT_OFFSET(XAnimInfo, notifyType, 0x6); + ASSERT_STRUCT_OFFSET(XAnimInfo, prev, 0x8); + ASSERT_STRUCT_OFFSET(XAnimInfo, next, 0xA); + ASSERT_STRUCT_OFFSET(XAnimInfo, children, 0xC); + ASSERT_STRUCT_OFFSET(XAnimInfo, parent, 0xE); + ASSERT_STRUCT_OFFSET(XAnimInfo, animIndex, 0x10); + ASSERT_STRUCT_OFFSET(XAnimInfo, animToModel, 0x12); + ASSERT_STRUCT_OFFSET(XAnimInfo, u, 0x14); + ASSERT_STRUCT_OFFSET(XAnimInfo, state, 0x18); + + struct trace_t + { + float normal[4]; //OFS: 0x0 SIZE: 0x10 + float fraction; //OFS: 0x10 SIZE: 0x4 + int surfaceFlags; //OFS: 0x14 SIZE: 0x4 + int contents; //OFS: 0x18 SIZE: 0x4 + char * material; //OFS: 0x1C SIZE: 0x4 + TraceHitType hitType; //OFS: 0x20 SIZE: 0x4 + unsigned __int16 hitId; //OFS: 0x24 SIZE: 0x2 + unsigned __int16 modelIndex; //OFS: 0x26 SIZE: 0x2 + unsigned __int16 partName; //OFS: 0x28 SIZE: 0x2 + unsigned __int16 boneIndex; //OFS: 0x2A SIZE: 0x2 + unsigned __int16 partGroup; //OFS: 0x2C SIZE: 0x2 + bool allsolid; //OFS: 0x2E SIZE: 0x1 + bool startsolid; //OFS: 0x2F SIZE: 0x1 + bool walkable; //OFS: 0x30 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(trace_t, 0x34); + ASSERT_STRUCT_OFFSET(trace_t, normal, 0x0); + ASSERT_STRUCT_OFFSET(trace_t, fraction, 0x10); + ASSERT_STRUCT_OFFSET(trace_t, surfaceFlags, 0x14); + ASSERT_STRUCT_OFFSET(trace_t, contents, 0x18); + ASSERT_STRUCT_OFFSET(trace_t, material, 0x1C); + ASSERT_STRUCT_OFFSET(trace_t, hitType, 0x20); + ASSERT_STRUCT_OFFSET(trace_t, hitId, 0x24); + ASSERT_STRUCT_OFFSET(trace_t, modelIndex, 0x26); + ASSERT_STRUCT_OFFSET(trace_t, partName, 0x28); + ASSERT_STRUCT_OFFSET(trace_t, boneIndex, 0x2A); + ASSERT_STRUCT_OFFSET(trace_t, partGroup, 0x2C); + ASSERT_STRUCT_OFFSET(trace_t, allsolid, 0x2E); + ASSERT_STRUCT_OFFSET(trace_t, startsolid, 0x2F); + ASSERT_STRUCT_OFFSET(trace_t, walkable, 0x30); + + struct trajectory_t + { + trType_t trType; //OFS: 0x0 SIZE: 0x4 + int trTime; //OFS: 0x4 SIZE: 0x4 + int trDuration; //OFS: 0x8 SIZE: 0x4 + float trBase[3]; //OFS: 0xC SIZE: 0xC + float trDelta[3]; //OFS: 0x18 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(trajectory_t, 0x24); + ASSERT_STRUCT_OFFSET(trajectory_t, trType, 0x0); + ASSERT_STRUCT_OFFSET(trajectory_t, trTime, 0x4); + ASSERT_STRUCT_OFFSET(trajectory_t, trDuration, 0x8); + ASSERT_STRUCT_OFFSET(trajectory_t, trBase, 0xC); + ASSERT_STRUCT_OFFSET(trajectory_t, trDelta, 0x18); + + struct LerpEntityStateTurret + { + float gunAngles[3]; //OFS: 0x0 SIZE: 0xC + unsigned __int8 overheating; //OFS: 0xC SIZE: 0x1 + float heatVal; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateTurret, 0x14); + ASSERT_STRUCT_OFFSET(LerpEntityStateTurret, gunAngles, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateTurret, overheating, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStateTurret, heatVal, 0x10); + + struct LerpEntityStateLoopFx + { + float cullDist; //OFS: 0x0 SIZE: 0x4 + int period; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateLoopFx, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStateLoopFx, cullDist, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateLoopFx, period, 0x4); + + union LerpEntityStateActor_unnamed_type_index + { + int actorNum; //OFS: 0x0 SIZE: 0x4 + int corpseNum; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateActor_unnamed_type_index, 0x4); + + struct __declspec(align(2)) LerpEntityStateActor_unnamed_type_proneInfo + { + __int16 fBodyPitch; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateActor_unnamed_type_proneInfo, 0x2); + ASSERT_STRUCT_OFFSET(LerpEntityStateActor_unnamed_type_proneInfo, fBodyPitch, 0x0); + + struct LerpEntityStateActor + { + LerpEntityStateActor_unnamed_type_index index; //OFS: 0x0 SIZE: 0x4 + int species; //OFS: 0x4 SIZE: 0x4 + LerpEntityStateActor_unnamed_type_proneInfo proneInfo; //OFS: 0x8 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateActor, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStateActor, index, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateActor, species, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStateActor, proneInfo, 0x8); + + struct LerpEntityStatePrimaryLight + { + char colorAndExp[4]; //OFS: 0x0 SIZE: 0x4 + float intensity; //OFS: 0x4 SIZE: 0x4 + float radius; //OFS: 0x8 SIZE: 0x4 + float cosHalfFovOuter; //OFS: 0xC SIZE: 0x4 + float cosHalfFovInner; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStatePrimaryLight, 0x14); + ASSERT_STRUCT_OFFSET(LerpEntityStatePrimaryLight, colorAndExp, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStatePrimaryLight, intensity, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStatePrimaryLight, radius, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStatePrimaryLight, cosHalfFovOuter, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStatePrimaryLight, cosHalfFovInner, 0x10); + + struct LerpEntityStatePlayer + { + float leanf; //OFS: 0x0 SIZE: 0x4 + int movementDir; //OFS: 0x4 SIZE: 0x4 + char vehicleType; //OFS: 0x8 SIZE: 0x1 + char vehicleAnimBoneIndex; //OFS: 0x9 SIZE: 0x1 + char vehicleSeat; //OFS: 0xA SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(LerpEntityStatePlayer, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStatePlayer, leanf, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStatePlayer, movementDir, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStatePlayer, vehicleType, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStatePlayer, vehicleAnimBoneIndex, 0x9); + ASSERT_STRUCT_OFFSET(LerpEntityStatePlayer, vehicleSeat, 0xA); + + struct __declspec(align(2)) LerpEntityStateVehicleGunnerAngles + { + __int16 pitch; //OFS: 0x0 SIZE: 0x2 + __int16 yaw; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateVehicleGunnerAngles, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicleGunnerAngles, pitch, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicleGunnerAngles, yaw, 0x2); + + union LerpEntityStateVehicleThrottle_u + { + __int16 throttle; //OFS: 0x0 SIZE: 0x2 + __int16 bodyPitch; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateVehicleThrottle_u, 0x2); + + struct LerpEntityStateVehicle + { + float steerYaw; //OFS: 0x0 SIZE: 0x4 + float bodyRoll; //OFS: 0x4 SIZE: 0x4 + float bodyPitch; //OFS: 0x8 SIZE: 0x4 + LerpEntityStateVehicleGunnerAngles gunnerAngles[4]; //OFS: 0xC SIZE: 0x10 + LerpEntityStateVehicleThrottle_u ___u3; //OFS: 0x1C SIZE: 0x2 + __int16 gunPitch; //OFS: 0x1E SIZE: 0x2 + __int16 gunYaw; //OFS: 0x20 SIZE: 0x2 + char drawOnCompass; //OFS: 0x22 SIZE: 0x1 + int teamAndOwnerIndex; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateVehicle, 0x28); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, steerYaw, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, bodyRoll, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, bodyPitch, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, gunnerAngles, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, ___u3, 0x1C); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, gunPitch, 0x1E); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, gunYaw, 0x20); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, drawOnCompass, 0x22); + ASSERT_STRUCT_OFFSET(LerpEntityStateVehicle, teamAndOwnerIndex, 0x24); + + struct LerpEntityStateMissile + { + int launchTime; //OFS: 0x0 SIZE: 0x4 + int parentClientNum; //OFS: 0x4 SIZE: 0x4 + int fuseTime; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateMissile, 0xC); + ASSERT_STRUCT_OFFSET(LerpEntityStateMissile, launchTime, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateMissile, parentClientNum, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStateMissile, fuseTime, 0x8); + + struct LerpEntityStateScriptMover + { + char attachTagIndex[4]; //OFS: 0x0 SIZE: 0x4 + int attachedTagIndex; //OFS: 0x4 SIZE: 0x4 + __int16 attachModelIndex[4]; //OFS: 0x8 SIZE: 0x8 + __int16 animScriptedAnim; //OFS: 0x10 SIZE: 0x2 + int animScriptedAnimTime; //OFS: 0x14 SIZE: 0x4 + __int16 attachedEntNum; //OFS: 0x18 SIZE: 0x2 + __int16 exploderIndex; //OFS: 0x1A SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateScriptMover, 0x1C); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, attachTagIndex, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, attachedTagIndex, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, attachModelIndex, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, animScriptedAnim, 0x10); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, animScriptedAnimTime, 0x14); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, attachedEntNum, 0x18); + ASSERT_STRUCT_OFFSET(LerpEntityStateScriptMover, exploderIndex, 0x1A); + + struct LerpEntityStateSoundBlend + { + float lerp; //OFS: 0x0 SIZE: 0x4 + float volumeScale; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityStateSoundBlend, 0x8); + ASSERT_STRUCT_OFFSET(LerpEntityStateSoundBlend, lerp, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityStateSoundBlend, volumeScale, 0x4); + + struct LerpEntityStateAnonymous + { + int data[15]; //OFS: 0x0 SIZE: 0x3C + }; + ASSERT_STRUCT_SIZE(LerpEntityStateAnonymous, 0x3C); + ASSERT_STRUCT_OFFSET(LerpEntityStateAnonymous, data, 0x0); + + union LerpEntityStateTypeUnion + { + LerpEntityStateTurret turret; //OFS: 0x0 SIZE: 0x14 + LerpEntityStateLoopFx loopFx; //OFS: 0x1 SIZE: 0x8 + LerpEntityStateActor actor; //OFS: 0x2 SIZE: 0xC + LerpEntityStatePrimaryLight primaryLight; //OFS: 0x3 SIZE: 0x14 + LerpEntityStatePlayer player; //OFS: 0x4 SIZE: 0xC + LerpEntityStateVehicle vehicle; //OFS: 0x5 SIZE: 0x28 + LerpEntityStateMissile missile; //OFS: 0x6 SIZE: 0xC + LerpEntityStateScriptMover scriptMover; //OFS: 0x7 SIZE: 0x1C + LerpEntityStateSoundBlend soundBlend; //OFS: 0x8 SIZE: 0x8 + LerpEntityStateAnonymous anonymous; //OFS: 0x9 SIZE: 0x3C + }; + ASSERT_STRUCT_SIZE(LerpEntityStateTypeUnion, 0x3C); + + struct LerpEntityState + { + int eFlags; //OFS: 0x0 SIZE: 0x4 + trajectory_t pos; //OFS: 0x4 SIZE: 0x24 + trajectory_t apos; //OFS: 0x28 SIZE: 0x24 + LerpEntityStateTypeUnion u; //OFS: 0x4C SIZE: 0x3C + int usecount; //OFS: 0x88 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LerpEntityState, 0x8C); + ASSERT_STRUCT_OFFSET(LerpEntityState, eFlags, 0x0); + ASSERT_STRUCT_OFFSET(LerpEntityState, pos, 0x4); + ASSERT_STRUCT_OFFSET(LerpEntityState, apos, 0x28); + ASSERT_STRUCT_OFFSET(LerpEntityState, u, 0x4C); + ASSERT_STRUCT_OFFSET(LerpEntityState, usecount, 0x88); + + struct __declspec(align(2)) LoopSound + { + unsigned __int16 soundAlias; //OFS: 0x0 SIZE: 0x2 + __int16 fadeTime; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(LoopSound, 0x4); + ASSERT_STRUCT_OFFSET(LoopSound, soundAlias, 0x0); + ASSERT_STRUCT_OFFSET(LoopSound, fadeTime, 0x2); + + union entityState_index + { + __int16 brushmodel; //OFS: 0x0 SIZE: 0x2 + __int16 xmodel; //OFS: 0x1 SIZE: 0x2 + __int16 primaryLight; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 bone; //OFS: 0x3 SIZE: 0x2 + int pad; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(entityState_index, 0x4); + + union entityState_un1 + { + char destructibleid; //OFS: 0x0 SIZE: 0x1 + char pad[4]; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(entityState_un1, 0x4); + + struct playerAnimState_t + { + int legsAnim; //OFS: 0x0 SIZE: 0x4 + int torsoAnim; //OFS: 0x4 SIZE: 0x4 + float fTorsoPitch; //OFS: 0x8 SIZE: 0x4 + float fWaistPitch; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(playerAnimState_t, 0x10); + ASSERT_STRUCT_OFFSET(playerAnimState_t, legsAnim, 0x0); + ASSERT_STRUCT_OFFSET(playerAnimState_t, torsoAnim, 0x4); + ASSERT_STRUCT_OFFSET(playerAnimState_t, fTorsoPitch, 0x8); + ASSERT_STRUCT_OFFSET(playerAnimState_t, fWaistPitch, 0xC); + + union entityState_un2 + { + playerAnimState_t anim; //OFS: 0x0 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(entityState_un2, 0x10); + + union entityState_un3 + { + int item; //OFS: 0x0 SIZE: 0x4 + int hintString; //OFS: 0x1 SIZE: 0x4 + int vehicleXModel; //OFS: 0x2 SIZE: 0x4 + unsigned int secondBcAlias; //OFS: 0x3 SIZE: 0x4 + unsigned int soundTag; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(entityState_un3, 0x4); + + struct entityState_s + { + int number; //OFS: 0x0 SIZE: 0x4 + entityType_t eType; //OFS: 0x4 SIZE: 0x4 + LerpEntityState lerp; //OFS: 0x8 SIZE: 0x8C + int time2; //OFS: 0x94 SIZE: 0x4 + int otherEntityNum; //OFS: 0x98 SIZE: 0x4 + int groundEntityNum; //OFS: 0x9C SIZE: 0x4 + LoopSound loopSound; //OFS: 0xA0 SIZE: 0x4 + int surfType; //OFS: 0xA4 SIZE: 0x4 + entityState_index index; //OFS: 0xA8 SIZE: 0x4 + int clientnum; //OFS: 0xAC SIZE: 0x4 + int iHeadIcon; //OFS: 0xB0 SIZE: 0x4 + int solid; //OFS: 0xB4 SIZE: 0x4 + int eventParm; //OFS: 0xB8 SIZE: 0x4 + int eventSequence; //OFS: 0xBC SIZE: 0x4 + int events[4]; //OFS: 0xC0 SIZE: 0x10 + int eventParms[4]; //OFS: 0xD0 SIZE: 0x10 + int weapon; //OFS: 0xE0 SIZE: 0x4 + int weaponModel; //OFS: 0xE4 SIZE: 0x4 + int targetname; //OFS: 0xE8 SIZE: 0x4 + entityState_un1 un1; //OFS: 0xEC SIZE: 0x4 + entityState_un2 un2; //OFS: 0xF0 SIZE: 0x10 + entityState_un3 un3; //OFS: 0x100 SIZE: 0x4 + int animtreeIndex; //OFS: 0x104 SIZE: 0x4 + int partBits[4]; //OFS: 0x108 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(entityState_s, 0x118); + ASSERT_STRUCT_OFFSET(entityState_s, number, 0x0); + ASSERT_STRUCT_OFFSET(entityState_s, eType, 0x4); + ASSERT_STRUCT_OFFSET(entityState_s, lerp, 0x8); + ASSERT_STRUCT_OFFSET(entityState_s, time2, 0x94); + ASSERT_STRUCT_OFFSET(entityState_s, otherEntityNum, 0x98); + ASSERT_STRUCT_OFFSET(entityState_s, groundEntityNum, 0x9C); + ASSERT_STRUCT_OFFSET(entityState_s, loopSound, 0xA0); + ASSERT_STRUCT_OFFSET(entityState_s, surfType, 0xA4); + ASSERT_STRUCT_OFFSET(entityState_s, index, 0xA8); + ASSERT_STRUCT_OFFSET(entityState_s, clientnum, 0xAC); + ASSERT_STRUCT_OFFSET(entityState_s, iHeadIcon, 0xB0); + ASSERT_STRUCT_OFFSET(entityState_s, solid, 0xB4); + ASSERT_STRUCT_OFFSET(entityState_s, eventParm, 0xB8); + ASSERT_STRUCT_OFFSET(entityState_s, eventSequence, 0xBC); + ASSERT_STRUCT_OFFSET(entityState_s, events, 0xC0); + ASSERT_STRUCT_OFFSET(entityState_s, eventParms, 0xD0); + ASSERT_STRUCT_OFFSET(entityState_s, weapon, 0xE0); + ASSERT_STRUCT_OFFSET(entityState_s, weaponModel, 0xE4); + ASSERT_STRUCT_OFFSET(entityState_s, targetname, 0xE8); + ASSERT_STRUCT_OFFSET(entityState_s, un1, 0xEC); + ASSERT_STRUCT_OFFSET(entityState_s, un2, 0xF0); + ASSERT_STRUCT_OFFSET(entityState_s, un3, 0x100); + ASSERT_STRUCT_OFFSET(entityState_s, animtreeIndex, 0x104); + ASSERT_STRUCT_OFFSET(entityState_s, partBits, 0x108); + + struct __declspec(align(2)) EntHandle + { + unsigned __int16 number; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 infoIndex; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(EntHandle, 0x4); + ASSERT_STRUCT_OFFSET(EntHandle, number, 0x0); + ASSERT_STRUCT_OFFSET(EntHandle, infoIndex, 0x2); + + struct entityShared_s + { + unsigned __int8 linked; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 bmodel; //OFS: 0x1 SIZE: 0x1 + unsigned __int16 svFlags; //OFS: 0x2 SIZE: 0x2 + unsigned __int8 eventType; //OFS: 0x4 SIZE: 0x1 + unsigned __int8 inuse; //OFS: 0x5 SIZE: 0x1 + int clientMask[2]; //OFS: 0x8 SIZE: 0x8 + int broadcastTime; //OFS: 0x10 SIZE: 0x4 + float mins[3]; //OFS: 0x14 SIZE: 0xC + float maxs[3]; //OFS: 0x20 SIZE: 0xC + contents_e contents; //OFS: 0x2C SIZE: 0x4 + float absmin[3]; //OFS: 0x30 SIZE: 0xC + float absmax[3]; //OFS: 0x3C SIZE: 0xC + float currentOrigin[3]; //OFS: 0x48 SIZE: 0xC + float currentAngles[3]; //OFS: 0x54 SIZE: 0xC + EntHandle ownerNum; //OFS: 0x60 SIZE: 0x4 + int eventTime; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(entityShared_s, 0x68); + ASSERT_STRUCT_OFFSET(entityShared_s, linked, 0x0); + ASSERT_STRUCT_OFFSET(entityShared_s, bmodel, 0x1); + ASSERT_STRUCT_OFFSET(entityShared_s, svFlags, 0x2); + ASSERT_STRUCT_OFFSET(entityShared_s, eventType, 0x4); + ASSERT_STRUCT_OFFSET(entityShared_s, inuse, 0x5); + ASSERT_STRUCT_OFFSET(entityShared_s, clientMask, 0x8); + ASSERT_STRUCT_OFFSET(entityShared_s, broadcastTime, 0x10); + ASSERT_STRUCT_OFFSET(entityShared_s, mins, 0x14); + ASSERT_STRUCT_OFFSET(entityShared_s, maxs, 0x20); + ASSERT_STRUCT_OFFSET(entityShared_s, contents, 0x2C); + ASSERT_STRUCT_OFFSET(entityShared_s, absmin, 0x30); + ASSERT_STRUCT_OFFSET(entityShared_s, absmax, 0x3C); + ASSERT_STRUCT_OFFSET(entityShared_s, currentOrigin, 0x48); + ASSERT_STRUCT_OFFSET(entityShared_s, currentAngles, 0x54); + ASSERT_STRUCT_OFFSET(entityShared_s, ownerNum, 0x60); + ASSERT_STRUCT_OFFSET(entityShared_s, eventTime, 0x64); + + struct SprintState + { + int sprintButtonUpRequired; //OFS: 0x0 SIZE: 0x4 + int sprintDelay; //OFS: 0x4 SIZE: 0x4 + int lastSprintStart; //OFS: 0x8 SIZE: 0x4 + int lastSprintEnd; //OFS: 0xC SIZE: 0x4 + int sprintStartMaxLength; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SprintState, 0x14); + ASSERT_STRUCT_OFFSET(SprintState, sprintButtonUpRequired, 0x0); + ASSERT_STRUCT_OFFSET(SprintState, sprintDelay, 0x4); + ASSERT_STRUCT_OFFSET(SprintState, lastSprintStart, 0x8); + ASSERT_STRUCT_OFFSET(SprintState, lastSprintEnd, 0xC); + ASSERT_STRUCT_OFFSET(SprintState, sprintStartMaxLength, 0x10); + + struct MantleState + { + float yaw; //OFS: 0x0 SIZE: 0x4 + int timer; //OFS: 0x4 SIZE: 0x4 + int transIndex; //OFS: 0x8 SIZE: 0x4 + int flags; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MantleState, 0x10); + ASSERT_STRUCT_OFFSET(MantleState, yaw, 0x0); + ASSERT_STRUCT_OFFSET(MantleState, timer, 0x4); + ASSERT_STRUCT_OFFSET(MantleState, transIndex, 0x8); + ASSERT_STRUCT_OFFSET(MantleState, flags, 0xC); + + struct objective_t + { + objectiveState_t state; //OFS: 0x0 SIZE: 0x4 + float origin[3]; //OFS: 0x4 SIZE: 0xC + int entNum; //OFS: 0x10 SIZE: 0x4 + int teamNum; //OFS: 0x14 SIZE: 0x4 + int squadNum; //OFS: 0x18 SIZE: 0x4 + int icon; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(objective_t, 0x20); + ASSERT_STRUCT_OFFSET(objective_t, state, 0x0); + ASSERT_STRUCT_OFFSET(objective_t, origin, 0x4); + ASSERT_STRUCT_OFFSET(objective_t, entNum, 0x10); + ASSERT_STRUCT_OFFSET(objective_t, teamNum, 0x14); + ASSERT_STRUCT_OFFSET(objective_t, squadNum, 0x18); + ASSERT_STRUCT_OFFSET(objective_t, icon, 0x1C); + + struct playerState_s + { + int commandTime; //OFS: 0x0 SIZE: 0x4 + pmtype_t pm_type; //OFS: 0x4 SIZE: 0x4 + int bobCycle; //OFS: 0x8 SIZE: 0x4 + pmflags_t pm_flags; //OFS: 0xC SIZE: 0x4 + int weapFlags; //OFS: 0x10 SIZE: 0x4 + int otherFlags; //OFS: 0x14 SIZE: 0x4 + int pm_time; //OFS: 0x18 SIZE: 0x4 + LoopSound loopSound; //OFS: 0x1C SIZE: 0x4 + float origin[3]; //OFS: 0x20 SIZE: 0xC + float velocity[3]; //OFS: 0x2C SIZE: 0xC + float oldVelocity[2]; //OFS: 0x38 SIZE: 0x8 + int weaponTime; //OFS: 0x40 SIZE: 0x4 + int weaponDelay; //OFS: 0x44 SIZE: 0x4 + int grenadeTimeLeft; //OFS: 0x48 SIZE: 0x4 + int throwBackGrenadeOwner; //OFS: 0x4C SIZE: 0x4 + int throwBackGrenadeTimeLeft; //OFS: 0x50 SIZE: 0x4 + int weaponRestrictKickTime; //OFS: 0x54 SIZE: 0x4 + bool mountAvailable; //OFS: 0x58 SIZE: 0x1 + float mountPos[3]; //OFS: 0x5C SIZE: 0xC + float mountDir; //OFS: 0x68 SIZE: 0x4 + int foliageSoundTime; //OFS: 0x6C SIZE: 0x4 + int gravity; //OFS: 0x70 SIZE: 0x4 + float leanf; //OFS: 0x74 SIZE: 0x4 + int speed; //OFS: 0x78 SIZE: 0x4 + float delta_angles[3]; //OFS: 0x7C SIZE: 0xC + int groundEntityNum; //OFS: 0x88 SIZE: 0x4 + float vLadderVec[3]; //OFS: 0x8C SIZE: 0xC + int jumpTime; //OFS: 0x98 SIZE: 0x4 + float jumpOriginZ; //OFS: 0x9C SIZE: 0x4 + int legsTimer; //OFS: 0xA0 SIZE: 0x4 + int legsAnim; //OFS: 0xA4 SIZE: 0x4 + int torsoTimer; //OFS: 0xA8 SIZE: 0x4 + int torsoAnim; //OFS: 0xAC SIZE: 0x4 + int legsAnimDuration; //OFS: 0xB0 SIZE: 0x4 + int torsoAnimDuration; //OFS: 0xB4 SIZE: 0x4 + int damageTimer; //OFS: 0xB8 SIZE: 0x4 + int damageDuration; //OFS: 0xBC SIZE: 0x4 + int flinchYawAnim; //OFS: 0xC0 SIZE: 0x4 + int corpseIndex; //OFS: 0xC4 SIZE: 0x4 + int movementDir; //OFS: 0xC8 SIZE: 0x4 + int eFlags; //OFS: 0xCC SIZE: 0x4 + int eventSequence; //OFS: 0xD0 SIZE: 0x4 + int events[4]; //OFS: 0xD4 SIZE: 0x10 + unsigned int eventParms[4]; //OFS: 0xE4 SIZE: 0x10 + int oldEventSequence; //OFS: 0xF4 SIZE: 0x4 + int clientNum; //OFS: 0xF8 SIZE: 0x4 + int offHandIndex; //OFS: 0xFC SIZE: 0x4 + OffhandSecondaryClass offhandSecondary; //OFS: 0x100 SIZE: 0x4 + unsigned int weapon; //OFS: 0x104 SIZE: 0x4 + weaponstate_t weaponstate; //OFS: 0x108 SIZE: 0x4 + unsigned int weaponShotCount; //OFS: 0x10C SIZE: 0x4 + float fWeaponPosFrac; //OFS: 0x110 SIZE: 0x4 + int adsDelayTime; //OFS: 0x114 SIZE: 0x4 + int spreadOverride; //OFS: 0x118 SIZE: 0x4 + int spreadOverrideState; //OFS: 0x11C SIZE: 0x4 + int viewmodelIndex; //OFS: 0x120 SIZE: 0x4 + float viewangles[3]; //OFS: 0x124 SIZE: 0xC + int viewHeightTarget; //OFS: 0x130 SIZE: 0x4 + float viewHeightCurrent; //OFS: 0x134 SIZE: 0x4 + int viewHeightLerpTime; //OFS: 0x138 SIZE: 0x4 + int viewHeightLerpTarget; //OFS: 0x13C SIZE: 0x4 + int viewHeightLerpDown; //OFS: 0x140 SIZE: 0x4 + float viewAngleClampBase[2]; //OFS: 0x144 SIZE: 0x8 + float viewAngleClampRange[2]; //OFS: 0x14C SIZE: 0x8 + int damageEvent; //OFS: 0x154 SIZE: 0x4 + int damageYaw; //OFS: 0x158 SIZE: 0x4 + int damagePitch; //OFS: 0x15C SIZE: 0x4 + int damageCount; //OFS: 0x160 SIZE: 0x4 + int stats[6]; //OFS: 0x164 SIZE: 0x18 + int ammo[128]; //OFS: 0x17C SIZE: 0x200 + float heatpercent[128]; //OFS: 0x37C SIZE: 0x200 + bool overheating[128]; //OFS: 0x57C SIZE: 0x80 + int ammoclip[128]; //OFS: 0x5FC SIZE: 0x200 + unsigned int weapons[4]; //OFS: 0x7FC SIZE: 0x10 + unsigned int weaponold[4]; //OFS: 0x80C SIZE: 0x10 + unsigned int weaponrechamber[4]; //OFS: 0x81C SIZE: 0x10 + float proneDirection; //OFS: 0x82C SIZE: 0x4 + float proneDirectionPitch; //OFS: 0x830 SIZE: 0x4 + float proneTorsoPitch; //OFS: 0x834 SIZE: 0x4 + ViewLockTypes viewlocked; //OFS: 0x838 SIZE: 0x4 + int viewlocked_entNum; //OFS: 0x83C SIZE: 0x4 + int vehiclePos; //OFS: 0x840 SIZE: 0x4 + int vehicleType; //OFS: 0x844 SIZE: 0x4 + int vehicleAnimBoneIndex; //OFS: 0x848 SIZE: 0x4 + int linkFlags; //OFS: 0x84C SIZE: 0x4 + float linkAngles[3]; //OFS: 0x850 SIZE: 0xC + float groundTiltAngles[3]; //OFS: 0x85C SIZE: 0xC + int cursorHint; //OFS: 0x868 SIZE: 0x4 + int cursorHintString; //OFS: 0x86C SIZE: 0x4 + int cursorHintEntIndex; //OFS: 0x870 SIZE: 0x4 + int iCompassPlayerInfo; //OFS: 0x874 SIZE: 0x4 + int radarEnabled; //OFS: 0x878 SIZE: 0x4 + int locationSelectionInfo; //OFS: 0x87C SIZE: 0x4 + SprintState sprintState; //OFS: 0x880 SIZE: 0x14 + float fTorsoPitch; //OFS: 0x894 SIZE: 0x4 + float fWaistPitch; //OFS: 0x898 SIZE: 0x4 + float holdBreathScale; //OFS: 0x89C SIZE: 0x4 + int holdBreathTimer; //OFS: 0x8A0 SIZE: 0x4 + float moveSpeedScaleMultiplier; //OFS: 0x8A4 SIZE: 0x4 + MantleState mantleState; //OFS: 0x8A8 SIZE: 0x10 + int vehicleAnimStage; //OFS: 0x8B8 SIZE: 0x4 + int vehicleEntryPoint; //OFS: 0x8BC SIZE: 0x4 + unsigned int scriptedAnim; //OFS: 0x8C0 SIZE: 0x4 + int scriptedAnimTime; //OFS: 0x8C4 SIZE: 0x4 + float meleeChargeYaw; //OFS: 0x8C8 SIZE: 0x4 + int meleeChargeDist; //OFS: 0x8CC SIZE: 0x4 + int meleeChargeTime; //OFS: 0x8D0 SIZE: 0x4 + int weapLockFlags; //OFS: 0x8D4 SIZE: 0x4 + int weapLockedEntnum; //OFS: 0x8D8 SIZE: 0x4 + unsigned int forcedViewAnimWeaponIdx; //OFS: 0x8DC SIZE: 0x4 + int forcedViewAnimWeaponState; //OFS: 0x8E0 SIZE: 0x4 + unsigned int forcedViewAnimOriginalWeaponIdx; //OFS: 0x8E4 SIZE: 0x4 + int collectibles; //OFS: 0x8E8 SIZE: 0x4 + int actionSlotType[4]; //OFS: 0x8EC SIZE: 0x10 + int actionSlotParams[4]; //OFS: 0x8FC SIZE: 0x10 + int entityEventSequence; //OFS: 0x90C SIZE: 0x4 + int weapAnim; //OFS: 0x910 SIZE: 0x4 + float aimSpreadScale; //OFS: 0x914 SIZE: 0x4 + int shellshockIndex; //OFS: 0x918 SIZE: 0x4 + int shellshockTime; //OFS: 0x91C SIZE: 0x4 + int shellshockDuration; //OFS: 0x920 SIZE: 0x4 + float dofNearStart; //OFS: 0x924 SIZE: 0x4 + float dofNearEnd; //OFS: 0x928 SIZE: 0x4 + float dofFarStart; //OFS: 0x92C SIZE: 0x4 + float dofFarEnd; //OFS: 0x930 SIZE: 0x4 + float dofNearBlur; //OFS: 0x934 SIZE: 0x4 + float dofFarBlur; //OFS: 0x938 SIZE: 0x4 + float dofViewmodelStart; //OFS: 0x93C SIZE: 0x4 + float dofViewmodelEnd; //OFS: 0x940 SIZE: 0x4 + int waterlevel; //OFS: 0x944 SIZE: 0x4 + int hudElemLastAssignedSoundID; //OFS: 0x948 SIZE: 0x4 + int artilleryInboundIconLocation; //OFS: 0x94C SIZE: 0x4 + objective_t objectives[16]; //OFS: 0x950 SIZE: 0x200 + char weaponmodels[128]; //OFS: 0xB50 SIZE: 0x80 + int deltatime; //OFS: 0xBD0 SIZE: 0x4 + hudelem_s hudelems[31]; //OFS: 0xBD4 SIZE: 0x14D4 + int perks; //OFS: 0x20A8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(playerState_s, 0x20AC); + ASSERT_STRUCT_OFFSET(playerState_s, commandTime, 0x0); + ASSERT_STRUCT_OFFSET(playerState_s, pm_type, 0x4); + ASSERT_STRUCT_OFFSET(playerState_s, bobCycle, 0x8); + ASSERT_STRUCT_OFFSET(playerState_s, pm_flags, 0xC); + ASSERT_STRUCT_OFFSET(playerState_s, weapFlags, 0x10); + ASSERT_STRUCT_OFFSET(playerState_s, otherFlags, 0x14); + ASSERT_STRUCT_OFFSET(playerState_s, pm_time, 0x18); + ASSERT_STRUCT_OFFSET(playerState_s, loopSound, 0x1C); + ASSERT_STRUCT_OFFSET(playerState_s, origin, 0x20); + ASSERT_STRUCT_OFFSET(playerState_s, velocity, 0x2C); + ASSERT_STRUCT_OFFSET(playerState_s, oldVelocity, 0x38); + ASSERT_STRUCT_OFFSET(playerState_s, weaponTime, 0x40); + ASSERT_STRUCT_OFFSET(playerState_s, weaponDelay, 0x44); + ASSERT_STRUCT_OFFSET(playerState_s, grenadeTimeLeft, 0x48); + ASSERT_STRUCT_OFFSET(playerState_s, throwBackGrenadeOwner, 0x4C); + ASSERT_STRUCT_OFFSET(playerState_s, throwBackGrenadeTimeLeft, 0x50); + ASSERT_STRUCT_OFFSET(playerState_s, weaponRestrictKickTime, 0x54); + ASSERT_STRUCT_OFFSET(playerState_s, mountAvailable, 0x58); + ASSERT_STRUCT_OFFSET(playerState_s, mountPos, 0x5C); + ASSERT_STRUCT_OFFSET(playerState_s, mountDir, 0x68); + ASSERT_STRUCT_OFFSET(playerState_s, foliageSoundTime, 0x6C); + ASSERT_STRUCT_OFFSET(playerState_s, gravity, 0x70); + ASSERT_STRUCT_OFFSET(playerState_s, leanf, 0x74); + ASSERT_STRUCT_OFFSET(playerState_s, speed, 0x78); + ASSERT_STRUCT_OFFSET(playerState_s, delta_angles, 0x7C); + ASSERT_STRUCT_OFFSET(playerState_s, groundEntityNum, 0x88); + ASSERT_STRUCT_OFFSET(playerState_s, vLadderVec, 0x8C); + ASSERT_STRUCT_OFFSET(playerState_s, jumpTime, 0x98); + ASSERT_STRUCT_OFFSET(playerState_s, jumpOriginZ, 0x9C); + ASSERT_STRUCT_OFFSET(playerState_s, legsTimer, 0xA0); + ASSERT_STRUCT_OFFSET(playerState_s, legsAnim, 0xA4); + ASSERT_STRUCT_OFFSET(playerState_s, torsoTimer, 0xA8); + ASSERT_STRUCT_OFFSET(playerState_s, torsoAnim, 0xAC); + ASSERT_STRUCT_OFFSET(playerState_s, legsAnimDuration, 0xB0); + ASSERT_STRUCT_OFFSET(playerState_s, torsoAnimDuration, 0xB4); + ASSERT_STRUCT_OFFSET(playerState_s, damageTimer, 0xB8); + ASSERT_STRUCT_OFFSET(playerState_s, damageDuration, 0xBC); + ASSERT_STRUCT_OFFSET(playerState_s, flinchYawAnim, 0xC0); + ASSERT_STRUCT_OFFSET(playerState_s, corpseIndex, 0xC4); + ASSERT_STRUCT_OFFSET(playerState_s, movementDir, 0xC8); + ASSERT_STRUCT_OFFSET(playerState_s, eFlags, 0xCC); + ASSERT_STRUCT_OFFSET(playerState_s, eventSequence, 0xD0); + ASSERT_STRUCT_OFFSET(playerState_s, events, 0xD4); + ASSERT_STRUCT_OFFSET(playerState_s, eventParms, 0xE4); + ASSERT_STRUCT_OFFSET(playerState_s, oldEventSequence, 0xF4); + ASSERT_STRUCT_OFFSET(playerState_s, clientNum, 0xF8); + ASSERT_STRUCT_OFFSET(playerState_s, offHandIndex, 0xFC); + ASSERT_STRUCT_OFFSET(playerState_s, offhandSecondary, 0x100); + ASSERT_STRUCT_OFFSET(playerState_s, weapon, 0x104); + ASSERT_STRUCT_OFFSET(playerState_s, weaponstate, 0x108); + ASSERT_STRUCT_OFFSET(playerState_s, weaponShotCount, 0x10C); + ASSERT_STRUCT_OFFSET(playerState_s, fWeaponPosFrac, 0x110); + ASSERT_STRUCT_OFFSET(playerState_s, adsDelayTime, 0x114); + ASSERT_STRUCT_OFFSET(playerState_s, spreadOverride, 0x118); + ASSERT_STRUCT_OFFSET(playerState_s, spreadOverrideState, 0x11C); + ASSERT_STRUCT_OFFSET(playerState_s, viewmodelIndex, 0x120); + ASSERT_STRUCT_OFFSET(playerState_s, viewangles, 0x124); + ASSERT_STRUCT_OFFSET(playerState_s, viewHeightTarget, 0x130); + ASSERT_STRUCT_OFFSET(playerState_s, viewHeightCurrent, 0x134); + ASSERT_STRUCT_OFFSET(playerState_s, viewHeightLerpTime, 0x138); + ASSERT_STRUCT_OFFSET(playerState_s, viewHeightLerpTarget, 0x13C); + ASSERT_STRUCT_OFFSET(playerState_s, viewHeightLerpDown, 0x140); + ASSERT_STRUCT_OFFSET(playerState_s, viewAngleClampBase, 0x144); + ASSERT_STRUCT_OFFSET(playerState_s, viewAngleClampRange, 0x14C); + ASSERT_STRUCT_OFFSET(playerState_s, damageEvent, 0x154); + ASSERT_STRUCT_OFFSET(playerState_s, damageYaw, 0x158); + ASSERT_STRUCT_OFFSET(playerState_s, damagePitch, 0x15C); + ASSERT_STRUCT_OFFSET(playerState_s, damageCount, 0x160); + ASSERT_STRUCT_OFFSET(playerState_s, stats, 0x164); + ASSERT_STRUCT_OFFSET(playerState_s, ammo, 0x17C); + ASSERT_STRUCT_OFFSET(playerState_s, heatpercent, 0x37C); + ASSERT_STRUCT_OFFSET(playerState_s, overheating, 0x57C); + ASSERT_STRUCT_OFFSET(playerState_s, ammoclip, 0x5FC); + ASSERT_STRUCT_OFFSET(playerState_s, weapons, 0x7FC); + ASSERT_STRUCT_OFFSET(playerState_s, weaponold, 0x80C); + ASSERT_STRUCT_OFFSET(playerState_s, weaponrechamber, 0x81C); + ASSERT_STRUCT_OFFSET(playerState_s, proneDirection, 0x82C); + ASSERT_STRUCT_OFFSET(playerState_s, proneDirectionPitch, 0x830); + ASSERT_STRUCT_OFFSET(playerState_s, proneTorsoPitch, 0x834); + ASSERT_STRUCT_OFFSET(playerState_s, viewlocked, 0x838); + ASSERT_STRUCT_OFFSET(playerState_s, viewlocked_entNum, 0x83C); + ASSERT_STRUCT_OFFSET(playerState_s, vehiclePos, 0x840); + ASSERT_STRUCT_OFFSET(playerState_s, vehicleType, 0x844); + ASSERT_STRUCT_OFFSET(playerState_s, vehicleAnimBoneIndex, 0x848); + ASSERT_STRUCT_OFFSET(playerState_s, linkFlags, 0x84C); + ASSERT_STRUCT_OFFSET(playerState_s, linkAngles, 0x850); + ASSERT_STRUCT_OFFSET(playerState_s, groundTiltAngles, 0x85C); + ASSERT_STRUCT_OFFSET(playerState_s, cursorHint, 0x868); + ASSERT_STRUCT_OFFSET(playerState_s, cursorHintString, 0x86C); + ASSERT_STRUCT_OFFSET(playerState_s, cursorHintEntIndex, 0x870); + ASSERT_STRUCT_OFFSET(playerState_s, iCompassPlayerInfo, 0x874); + ASSERT_STRUCT_OFFSET(playerState_s, radarEnabled, 0x878); + ASSERT_STRUCT_OFFSET(playerState_s, locationSelectionInfo, 0x87C); + ASSERT_STRUCT_OFFSET(playerState_s, sprintState, 0x880); + ASSERT_STRUCT_OFFSET(playerState_s, fTorsoPitch, 0x894); + ASSERT_STRUCT_OFFSET(playerState_s, fWaistPitch, 0x898); + ASSERT_STRUCT_OFFSET(playerState_s, holdBreathScale, 0x89C); + ASSERT_STRUCT_OFFSET(playerState_s, holdBreathTimer, 0x8A0); + ASSERT_STRUCT_OFFSET(playerState_s, moveSpeedScaleMultiplier, 0x8A4); + ASSERT_STRUCT_OFFSET(playerState_s, mantleState, 0x8A8); + ASSERT_STRUCT_OFFSET(playerState_s, vehicleAnimStage, 0x8B8); + ASSERT_STRUCT_OFFSET(playerState_s, vehicleEntryPoint, 0x8BC); + ASSERT_STRUCT_OFFSET(playerState_s, scriptedAnim, 0x8C0); + ASSERT_STRUCT_OFFSET(playerState_s, scriptedAnimTime, 0x8C4); + ASSERT_STRUCT_OFFSET(playerState_s, meleeChargeYaw, 0x8C8); + ASSERT_STRUCT_OFFSET(playerState_s, meleeChargeDist, 0x8CC); + ASSERT_STRUCT_OFFSET(playerState_s, meleeChargeTime, 0x8D0); + ASSERT_STRUCT_OFFSET(playerState_s, weapLockFlags, 0x8D4); + ASSERT_STRUCT_OFFSET(playerState_s, weapLockedEntnum, 0x8D8); + ASSERT_STRUCT_OFFSET(playerState_s, forcedViewAnimWeaponIdx, 0x8DC); + ASSERT_STRUCT_OFFSET(playerState_s, forcedViewAnimWeaponState, 0x8E0); + ASSERT_STRUCT_OFFSET(playerState_s, forcedViewAnimOriginalWeaponIdx, 0x8E4); + ASSERT_STRUCT_OFFSET(playerState_s, collectibles, 0x8E8); + ASSERT_STRUCT_OFFSET(playerState_s, actionSlotType, 0x8EC); + ASSERT_STRUCT_OFFSET(playerState_s, actionSlotParams, 0x8FC); + ASSERT_STRUCT_OFFSET(playerState_s, entityEventSequence, 0x90C); + ASSERT_STRUCT_OFFSET(playerState_s, weapAnim, 0x910); + ASSERT_STRUCT_OFFSET(playerState_s, aimSpreadScale, 0x914); + ASSERT_STRUCT_OFFSET(playerState_s, shellshockIndex, 0x918); + ASSERT_STRUCT_OFFSET(playerState_s, shellshockTime, 0x91C); + ASSERT_STRUCT_OFFSET(playerState_s, shellshockDuration, 0x920); + ASSERT_STRUCT_OFFSET(playerState_s, dofNearStart, 0x924); + ASSERT_STRUCT_OFFSET(playerState_s, dofNearEnd, 0x928); + ASSERT_STRUCT_OFFSET(playerState_s, dofFarStart, 0x92C); + ASSERT_STRUCT_OFFSET(playerState_s, dofFarEnd, 0x930); + ASSERT_STRUCT_OFFSET(playerState_s, dofNearBlur, 0x934); + ASSERT_STRUCT_OFFSET(playerState_s, dofFarBlur, 0x938); + ASSERT_STRUCT_OFFSET(playerState_s, dofViewmodelStart, 0x93C); + ASSERT_STRUCT_OFFSET(playerState_s, dofViewmodelEnd, 0x940); + ASSERT_STRUCT_OFFSET(playerState_s, waterlevel, 0x944); + ASSERT_STRUCT_OFFSET(playerState_s, hudElemLastAssignedSoundID, 0x948); + ASSERT_STRUCT_OFFSET(playerState_s, artilleryInboundIconLocation, 0x94C); + ASSERT_STRUCT_OFFSET(playerState_s, objectives, 0x950); + ASSERT_STRUCT_OFFSET(playerState_s, weaponmodels, 0xB50); + ASSERT_STRUCT_OFFSET(playerState_s, deltatime, 0xBD0); + ASSERT_STRUCT_OFFSET(playerState_s, hudelems, 0xBD4); + ASSERT_STRUCT_OFFSET(playerState_s, perks, 0x20A8); + + struct usercmd_s + { + int serverTime; //OFS: 0x0 SIZE: 0x4 + button_mask buttons; //OFS: 0x4 SIZE: 0x4 + int angles[3]; //OFS: 0x8 SIZE: 0xC + char weapon; //OFS: 0x14 SIZE: 0x1 + char offHandIndex; //OFS: 0x15 SIZE: 0x1 + char forward; //OFS: 0x16 SIZE: 0x1 + char right; //OFS: 0x17 SIZE: 0x1 + char upmove; //OFS: 0x18 SIZE: 0x1 + char pitchmove; //OFS: 0x19 SIZE: 0x1 + char yawmove; //OFS: 0x1A SIZE: 0x1 + __int16 wiimoteGunPitch; //OFS: 0x1C SIZE: 0x2 + __int16 wiimoteGunYaw; //OFS: 0x1E SIZE: 0x2 + __int16 gunXOfs; //OFS: 0x20 SIZE: 0x2 + __int16 gunYOfs; //OFS: 0x22 SIZE: 0x2 + __int16 gunZOfs; //OFS: 0x24 SIZE: 0x2 + int meleeChargeYaw; //OFS: 0x28 SIZE: 0x4 + char meleeChargeDist; //OFS: 0x2C SIZE: 0x1 + int rollmove; //OFS: 0x30 SIZE: 0x4 + char selectedLocation[2]; //OFS: 0x34 SIZE: 0x2 + __int16 weapon_buddy; //OFS: 0x36 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(usercmd_s, 0x38); + ASSERT_STRUCT_OFFSET(usercmd_s, serverTime, 0x0); + ASSERT_STRUCT_OFFSET(usercmd_s, buttons, 0x4); + ASSERT_STRUCT_OFFSET(usercmd_s, angles, 0x8); + ASSERT_STRUCT_OFFSET(usercmd_s, weapon, 0x14); + ASSERT_STRUCT_OFFSET(usercmd_s, offHandIndex, 0x15); + ASSERT_STRUCT_OFFSET(usercmd_s, forward, 0x16); + ASSERT_STRUCT_OFFSET(usercmd_s, right, 0x17); + ASSERT_STRUCT_OFFSET(usercmd_s, upmove, 0x18); + ASSERT_STRUCT_OFFSET(usercmd_s, pitchmove, 0x19); + ASSERT_STRUCT_OFFSET(usercmd_s, yawmove, 0x1A); + ASSERT_STRUCT_OFFSET(usercmd_s, wiimoteGunPitch, 0x1C); + ASSERT_STRUCT_OFFSET(usercmd_s, wiimoteGunYaw, 0x1E); + ASSERT_STRUCT_OFFSET(usercmd_s, gunXOfs, 0x20); + ASSERT_STRUCT_OFFSET(usercmd_s, gunYOfs, 0x22); + ASSERT_STRUCT_OFFSET(usercmd_s, gunZOfs, 0x24); + ASSERT_STRUCT_OFFSET(usercmd_s, meleeChargeYaw, 0x28); + ASSERT_STRUCT_OFFSET(usercmd_s, meleeChargeDist, 0x2C); + ASSERT_STRUCT_OFFSET(usercmd_s, rollmove, 0x30); + ASSERT_STRUCT_OFFSET(usercmd_s, selectedLocation, 0x34); + ASSERT_STRUCT_OFFSET(usercmd_s, weapon_buddy, 0x36); + + struct clientState_s + { + int clientNum; //OFS: 0x0 SIZE: 0x4 + team_t team; //OFS: 0x4 SIZE: 0x4 + int modelindex; //OFS: 0x8 SIZE: 0x4 + int attachModelIndex[6]; //OFS: 0xC SIZE: 0x18 + int attachTagIndex[6]; //OFS: 0x24 SIZE: 0x18 + int lastDamageTime; //OFS: 0x3C SIZE: 0x4 + int lastStandStartTime; //OFS: 0x40 SIZE: 0x4 + int beingRevived; //OFS: 0x44 SIZE: 0x4 + int score; //OFS: 0x48 SIZE: 0x4 + int scoreMultiplier; //OFS: 0x4C SIZE: 0x4 + char name[32]; //OFS: 0x50 SIZE: 0x20 + float maxSprintTimeMultiplier; //OFS: 0x70 SIZE: 0x4 + int rank; //OFS: 0x74 SIZE: 0x4 + int prestige; //OFS: 0x78 SIZE: 0x4 + char clanAbbrev[8]; //OFS: 0x7C SIZE: 0x8 + int attachedEntNum; //OFS: 0x84 SIZE: 0x4 + int attachedTagIndex; //OFS: 0x88 SIZE: 0x4 + VehicleAnimState vehAnimState; //OFS: 0x8C SIZE: 0x4 + int perks; //OFS: 0x90 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientState_s, 0x94); + ASSERT_STRUCT_OFFSET(clientState_s, clientNum, 0x0); + ASSERT_STRUCT_OFFSET(clientState_s, team, 0x4); + ASSERT_STRUCT_OFFSET(clientState_s, modelindex, 0x8); + ASSERT_STRUCT_OFFSET(clientState_s, attachModelIndex, 0xC); + ASSERT_STRUCT_OFFSET(clientState_s, attachTagIndex, 0x24); + ASSERT_STRUCT_OFFSET(clientState_s, lastDamageTime, 0x3C); + ASSERT_STRUCT_OFFSET(clientState_s, lastStandStartTime, 0x40); + ASSERT_STRUCT_OFFSET(clientState_s, beingRevived, 0x44); + ASSERT_STRUCT_OFFSET(clientState_s, score, 0x48); + ASSERT_STRUCT_OFFSET(clientState_s, scoreMultiplier, 0x4C); + ASSERT_STRUCT_OFFSET(clientState_s, name, 0x50); + ASSERT_STRUCT_OFFSET(clientState_s, maxSprintTimeMultiplier, 0x70); + ASSERT_STRUCT_OFFSET(clientState_s, rank, 0x74); + ASSERT_STRUCT_OFFSET(clientState_s, prestige, 0x78); + ASSERT_STRUCT_OFFSET(clientState_s, clanAbbrev, 0x7C); + ASSERT_STRUCT_OFFSET(clientState_s, attachedEntNum, 0x84); + ASSERT_STRUCT_OFFSET(clientState_s, attachedTagIndex, 0x88); + ASSERT_STRUCT_OFFSET(clientState_s, vehAnimState, 0x8C); + ASSERT_STRUCT_OFFSET(clientState_s, perks, 0x90); + + struct clientSession_s + { + sessionState_t sessionState; //OFS: 0x0 SIZE: 0x4 + int forceSpectatorClient; //OFS: 0x4 SIZE: 0x4 + int status_icon; //OFS: 0x8 SIZE: 0x4 + int archiveTime; //OFS: 0xC SIZE: 0x4 + int score; //OFS: 0x10 SIZE: 0x4 + int kills; //OFS: 0x14 SIZE: 0x4 + int assists; //OFS: 0x18 SIZE: 0x4 + int downs; //OFS: 0x1C SIZE: 0x4 + int revives; //OFS: 0x20 SIZE: 0x4 + int headshots; //OFS: 0x24 SIZE: 0x4 + int rankxp; //OFS: 0x28 SIZE: 0x4 + int something; //OFS: 0x2C SIZE: 0x4 + __int16 scriptId; //OFS: 0x30 SIZE: 0x2 + _BYTE gap_32[2]; //OFS: 0x32 SIZE: 0x2 + clientConnected_t connected; //OFS: 0x34 SIZE: 0x4 + usercmd_s cmd; //OFS: 0x38 SIZE: 0x38 + usercmd_s oldcmd; //OFS: 0x70 SIZE: 0x38 + int localClient; //OFS: 0xA8 SIZE: 0x4 + int predictItemPickup; //OFS: 0xAC SIZE: 0x4 + char newnetname[32]; //OFS: 0xB0 SIZE: 0x20 + int maxHealth; //OFS: 0xD0 SIZE: 0x4 + int enterTime; //OFS: 0xD4 SIZE: 0x4 + int teamState; //OFS: 0xD8 SIZE: 0x4 + int voteCount; //OFS: 0xDC SIZE: 0x4 + int teamVoteCount; //OFS: 0xE0 SIZE: 0x4 + float moveSpeedScaleMultiplier; //OFS: 0xE4 SIZE: 0x4 + int viewmodelIndex; //OFS: 0xE8 SIZE: 0x4 + int noSpectate; //OFS: 0xEC SIZE: 0x4 + int teamInfo; //OFS: 0xF0 SIZE: 0x4 + clientState_s _cs; //OFS: 0xF4 SIZE: 0x94 + int psOffsetTime; //OFS: 0x188 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientSession_s, 0x18C); + ASSERT_STRUCT_OFFSET(clientSession_s, sessionState, 0x0); + ASSERT_STRUCT_OFFSET(clientSession_s, forceSpectatorClient, 0x4); + ASSERT_STRUCT_OFFSET(clientSession_s, status_icon, 0x8); + ASSERT_STRUCT_OFFSET(clientSession_s, archiveTime, 0xC); + ASSERT_STRUCT_OFFSET(clientSession_s, score, 0x10); + ASSERT_STRUCT_OFFSET(clientSession_s, kills, 0x14); + ASSERT_STRUCT_OFFSET(clientSession_s, assists, 0x18); + ASSERT_STRUCT_OFFSET(clientSession_s, downs, 0x1C); + ASSERT_STRUCT_OFFSET(clientSession_s, revives, 0x20); + ASSERT_STRUCT_OFFSET(clientSession_s, headshots, 0x24); + ASSERT_STRUCT_OFFSET(clientSession_s, rankxp, 0x28); + ASSERT_STRUCT_OFFSET(clientSession_s, something, 0x2C); + ASSERT_STRUCT_OFFSET(clientSession_s, scriptId, 0x30); + ASSERT_STRUCT_OFFSET(clientSession_s, gap_32, 0x32); + ASSERT_STRUCT_OFFSET(clientSession_s, connected, 0x34); + ASSERT_STRUCT_OFFSET(clientSession_s, cmd, 0x38); + ASSERT_STRUCT_OFFSET(clientSession_s, oldcmd, 0x70); + ASSERT_STRUCT_OFFSET(clientSession_s, localClient, 0xA8); + ASSERT_STRUCT_OFFSET(clientSession_s, predictItemPickup, 0xAC); + ASSERT_STRUCT_OFFSET(clientSession_s, newnetname, 0xB0); + ASSERT_STRUCT_OFFSET(clientSession_s, maxHealth, 0xD0); + ASSERT_STRUCT_OFFSET(clientSession_s, enterTime, 0xD4); + ASSERT_STRUCT_OFFSET(clientSession_s, teamState, 0xD8); + ASSERT_STRUCT_OFFSET(clientSession_s, voteCount, 0xDC); + ASSERT_STRUCT_OFFSET(clientSession_s, teamVoteCount, 0xE0); + ASSERT_STRUCT_OFFSET(clientSession_s, moveSpeedScaleMultiplier, 0xE4); + ASSERT_STRUCT_OFFSET(clientSession_s, viewmodelIndex, 0xE8); + ASSERT_STRUCT_OFFSET(clientSession_s, noSpectate, 0xEC); + ASSERT_STRUCT_OFFSET(clientSession_s, teamInfo, 0xF0); + ASSERT_STRUCT_OFFSET(clientSession_s, _cs, 0xF4); + ASSERT_STRUCT_OFFSET(clientSession_s, psOffsetTime, 0x188); + + struct gclient_s + { + playerState_s ps; //OFS: 0x0 SIZE: 0x20AC + clientSession_s sess; //OFS: 0x20AC SIZE: 0x18C + int spectatorClient; //OFS: 0x2238 SIZE: 0x4 + int noclip; //OFS: 0x223C SIZE: 0x4 + int ufo; //OFS: 0x2240 SIZE: 0x4 + int bFrozen; //OFS: 0x2244 SIZE: 0x4 + int buttons; //OFS: 0x2248 SIZE: 0x4 + int oldbuttons; //OFS: 0x224C SIZE: 0x4 + int latched_buttons; //OFS: 0x2250 SIZE: 0x4 + int buttonsSinceLastFrame; //OFS: 0x2254 SIZE: 0x4 + float fGunPitch; //OFS: 0x2258 SIZE: 0x4 + float fGunYaw; //OFS: 0x225C SIZE: 0x4 + float fGunXOfs; //OFS: 0x2260 SIZE: 0x4 + float fGunYOfs; //OFS: 0x2264 SIZE: 0x4 + float fGunZOfs; //OFS: 0x2268 SIZE: 0x4 + int damage_blood; //OFS: 0x226C SIZE: 0x4 + float damage_from[3]; //OFS: 0x2270 SIZE: 0xC + int damage_fromWorld; //OFS: 0x227C SIZE: 0x4 + int respawnTime; //OFS: 0x2280 SIZE: 0x4 + int lastBadArcCreateTime; //OFS: 0x2284 SIZE: 0x4 + int outWaterTime; //OFS: 0x2288 SIZE: 0x4 + float currentAimSpreadScale; //OFS: 0x228C SIZE: 0x4 + gentity_s * pHitHitEnt; //OFS: 0x2290 SIZE: 0x4 + EntHandle pLookatEnt; //OFS: 0x2294 SIZE: 0x4 + float prevLinkedInvQuat[4]; //OFS: 0x2298 SIZE: 0x10 + bool prevLinkAnglesSet; //OFS: 0x22A8 SIZE: 0x1 + bool link_doCollision; //OFS: 0x22A9 SIZE: 0x1 + bool linkAnglesLocked; //OFS: 0x22AA SIZE: 0x1 + float linkAnglesFrac; //OFS: 0x22AC SIZE: 0x4 + float linkAnglesMinClamp[2]; //OFS: 0x22B0 SIZE: 0x8 + float linkAnglesMaxClamp[2]; //OFS: 0x22B8 SIZE: 0x8 + int inControlTime; //OFS: 0x22C0 SIZE: 0x4 + int lastTouchTime; //OFS: 0x22C4 SIZE: 0x4 + EntHandle useHoldEntity; //OFS: 0x22C8 SIZE: 0x4 + int useHoldTime; //OFS: 0x22CC SIZE: 0x4 + int useButtonDone; //OFS: 0x22D0 SIZE: 0x4 + int bDisableAutoPickup; //OFS: 0x22D4 SIZE: 0x4 + int invulnerableExpireTime; //OFS: 0x22D8 SIZE: 0x4 + bool invulnerableActivated; //OFS: 0x22DC SIZE: 0x1 + bool invulnerableEnabled; //OFS: 0x22DD SIZE: 0x1 + bool playerMoved; //OFS: 0x22DE SIZE: 0x1 + float playerLOSCheckPos[2]; //OFS: 0x22E0 SIZE: 0x8 + float playerLOSCheckDir[2]; //OFS: 0x22E8 SIZE: 0x8 + int playerLOSPosTime; //OFS: 0x22F0 SIZE: 0x4 + int playerADSTargetTime; //OFS: 0x22F4 SIZE: 0x4 + unsigned int lastWeapon; //OFS: 0x22F8 SIZE: 0x4 + bool previouslyFiring; //OFS: 0x22FC SIZE: 0x1 + bool previouslyUsingNightVision; //OFS: 0x22FD SIZE: 0x1 + int groundTiltEntNum; //OFS: 0x2300 SIZE: 0x4 + int revive; //OFS: 0x2304 SIZE: 0x4 + int reviveTime; //OFS: 0x2308 SIZE: 0x4 + int lastStand; //OFS: 0x230C SIZE: 0x4 + int lastStandTime; //OFS: 0x2310 SIZE: 0x4 + int switchSeatTime; //OFS: 0x2314 SIZE: 0x4 + int lastCmdTime; //OFS: 0x2318 SIZE: 0x4 + int inactivityTime; //OFS: 0x231C SIZE: 0x4 + int inactivityWarning; //OFS: 0x2320 SIZE: 0x4 + int lastVoiceTime; //OFS: 0x2324 SIZE: 0x4 + int lastServerTime; //OFS: 0x2328 SIZE: 0x4 + int lastSpawnTime; //OFS: 0x232C SIZE: 0x4 + int damageTime; //OFS: 0x2330 SIZE: 0x4 + float vGunSpeed[3]; //OFS: 0x2334 SIZE: 0xC + int dropWeaponTime; //OFS: 0x2340 SIZE: 0x4 + bool previouslyChangingWeapon; //OFS: 0x2344 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(gclient_s, 0x2348); + ASSERT_STRUCT_OFFSET(gclient_s, ps, 0x0); + ASSERT_STRUCT_OFFSET(gclient_s, sess, 0x20AC); + ASSERT_STRUCT_OFFSET(gclient_s, spectatorClient, 0x2238); + ASSERT_STRUCT_OFFSET(gclient_s, noclip, 0x223C); + ASSERT_STRUCT_OFFSET(gclient_s, ufo, 0x2240); + ASSERT_STRUCT_OFFSET(gclient_s, bFrozen, 0x2244); + ASSERT_STRUCT_OFFSET(gclient_s, buttons, 0x2248); + ASSERT_STRUCT_OFFSET(gclient_s, oldbuttons, 0x224C); + ASSERT_STRUCT_OFFSET(gclient_s, latched_buttons, 0x2250); + ASSERT_STRUCT_OFFSET(gclient_s, buttonsSinceLastFrame, 0x2254); + ASSERT_STRUCT_OFFSET(gclient_s, fGunPitch, 0x2258); + ASSERT_STRUCT_OFFSET(gclient_s, fGunYaw, 0x225C); + ASSERT_STRUCT_OFFSET(gclient_s, fGunXOfs, 0x2260); + ASSERT_STRUCT_OFFSET(gclient_s, fGunYOfs, 0x2264); + ASSERT_STRUCT_OFFSET(gclient_s, fGunZOfs, 0x2268); + ASSERT_STRUCT_OFFSET(gclient_s, damage_blood, 0x226C); + ASSERT_STRUCT_OFFSET(gclient_s, damage_from, 0x2270); + ASSERT_STRUCT_OFFSET(gclient_s, damage_fromWorld, 0x227C); + ASSERT_STRUCT_OFFSET(gclient_s, respawnTime, 0x2280); + ASSERT_STRUCT_OFFSET(gclient_s, lastBadArcCreateTime, 0x2284); + ASSERT_STRUCT_OFFSET(gclient_s, outWaterTime, 0x2288); + ASSERT_STRUCT_OFFSET(gclient_s, currentAimSpreadScale, 0x228C); + ASSERT_STRUCT_OFFSET(gclient_s, pHitHitEnt, 0x2290); + ASSERT_STRUCT_OFFSET(gclient_s, pLookatEnt, 0x2294); + ASSERT_STRUCT_OFFSET(gclient_s, prevLinkedInvQuat, 0x2298); + ASSERT_STRUCT_OFFSET(gclient_s, prevLinkAnglesSet, 0x22A8); + ASSERT_STRUCT_OFFSET(gclient_s, link_doCollision, 0x22A9); + ASSERT_STRUCT_OFFSET(gclient_s, linkAnglesLocked, 0x22AA); + ASSERT_STRUCT_OFFSET(gclient_s, linkAnglesFrac, 0x22AC); + ASSERT_STRUCT_OFFSET(gclient_s, linkAnglesMinClamp, 0x22B0); + ASSERT_STRUCT_OFFSET(gclient_s, linkAnglesMaxClamp, 0x22B8); + ASSERT_STRUCT_OFFSET(gclient_s, inControlTime, 0x22C0); + ASSERT_STRUCT_OFFSET(gclient_s, lastTouchTime, 0x22C4); + ASSERT_STRUCT_OFFSET(gclient_s, useHoldEntity, 0x22C8); + ASSERT_STRUCT_OFFSET(gclient_s, useHoldTime, 0x22CC); + ASSERT_STRUCT_OFFSET(gclient_s, useButtonDone, 0x22D0); + ASSERT_STRUCT_OFFSET(gclient_s, bDisableAutoPickup, 0x22D4); + ASSERT_STRUCT_OFFSET(gclient_s, invulnerableExpireTime, 0x22D8); + ASSERT_STRUCT_OFFSET(gclient_s, invulnerableActivated, 0x22DC); + ASSERT_STRUCT_OFFSET(gclient_s, invulnerableEnabled, 0x22DD); + ASSERT_STRUCT_OFFSET(gclient_s, playerMoved, 0x22DE); + ASSERT_STRUCT_OFFSET(gclient_s, playerLOSCheckPos, 0x22E0); + ASSERT_STRUCT_OFFSET(gclient_s, playerLOSCheckDir, 0x22E8); + ASSERT_STRUCT_OFFSET(gclient_s, playerLOSPosTime, 0x22F0); + ASSERT_STRUCT_OFFSET(gclient_s, playerADSTargetTime, 0x22F4); + ASSERT_STRUCT_OFFSET(gclient_s, lastWeapon, 0x22F8); + ASSERT_STRUCT_OFFSET(gclient_s, previouslyFiring, 0x22FC); + ASSERT_STRUCT_OFFSET(gclient_s, previouslyUsingNightVision, 0x22FD); + ASSERT_STRUCT_OFFSET(gclient_s, groundTiltEntNum, 0x2300); + ASSERT_STRUCT_OFFSET(gclient_s, revive, 0x2304); + ASSERT_STRUCT_OFFSET(gclient_s, reviveTime, 0x2308); + ASSERT_STRUCT_OFFSET(gclient_s, lastStand, 0x230C); + ASSERT_STRUCT_OFFSET(gclient_s, lastStandTime, 0x2310); + ASSERT_STRUCT_OFFSET(gclient_s, switchSeatTime, 0x2314); + ASSERT_STRUCT_OFFSET(gclient_s, lastCmdTime, 0x2318); + ASSERT_STRUCT_OFFSET(gclient_s, inactivityTime, 0x231C); + ASSERT_STRUCT_OFFSET(gclient_s, inactivityWarning, 0x2320); + ASSERT_STRUCT_OFFSET(gclient_s, lastVoiceTime, 0x2324); + ASSERT_STRUCT_OFFSET(gclient_s, lastServerTime, 0x2328); + ASSERT_STRUCT_OFFSET(gclient_s, lastSpawnTime, 0x232C); + ASSERT_STRUCT_OFFSET(gclient_s, damageTime, 0x2330); + ASSERT_STRUCT_OFFSET(gclient_s, vGunSpeed, 0x2334); + ASSERT_STRUCT_OFFSET(gclient_s, dropWeaponTime, 0x2340); + ASSERT_STRUCT_OFFSET(gclient_s, previouslyChangingWeapon, 0x2344); + + struct sentient_s + { + gentity_s * ent; //OFS: 0x0 SIZE: 0x4 + team_t eTeam; //OFS: 0x4 SIZE: 0x4 + int iThreatBias; //OFS: 0x8 SIZE: 0x4 + int iThreatBiasGroupIndex; //OFS: 0xC SIZE: 0x4 + bool bIgnoreMe; //OFS: 0x10 SIZE: 0x1 + bool bIgnoreAll; //OFS: 0x11 SIZE: 0x1 + bool originChanged; //OFS: 0x12 SIZE: 0x1 + float oldOrigin[3]; //OFS: 0x14 SIZE: 0xC + float maxVisibleDist; //OFS: 0x20 SIZE: 0x4 + int iEnemyNotifyTime; //OFS: 0x24 SIZE: 0x4 + int attackerCount; //OFS: 0x28 SIZE: 0x4 + gentity_s * lastAttacker; //OFS: 0x2C SIZE: 0x4 + EntHandle syncedMeleeEnt; //OFS: 0x30 SIZE: 0x4 + EntHandle targetEnt; //OFS: 0x34 SIZE: 0x4 + EntHandle scriptTargetEnt; //OFS: 0x38 SIZE: 0x4 + float entityTargetThreat; //OFS: 0x3C SIZE: 0x4 + int meleeAttackerSpot[4]; //OFS: 0x40 SIZE: 0x10 + float attackerAccuracy; //OFS: 0x50 SIZE: 0x4 + bool ignoreRandomBulletDamage; //OFS: 0x54 SIZE: 0x1 + bool turretInvulnerability; //OFS: 0x55 SIZE: 0x1 + pathnode_t * pClaimedNode; //OFS: 0x58 SIZE: 0x4 + pathnode_t * pPrevClaimedNode; //OFS: 0x5C SIZE: 0x4 + pathnode_t * pActualChainPos; //OFS: 0x60 SIZE: 0x4 + int iActualChainPosTime; //OFS: 0x64 SIZE: 0x4 + pathnode_t * pNearestNode; //OFS: 0x68 SIZE: 0x4 + unsigned __int8 bNearestNodeValid; //OFS: 0x6C SIZE: 0x1 + unsigned __int8 bNearestNodeBad; //OFS: 0x6D SIZE: 0x1 + float vNearestNodeCheckPos[3]; //OFS: 0x70 SIZE: 0xC + bool inuse; //OFS: 0x7C SIZE: 0x1 + int banNodeTime; //OFS: 0x80 SIZE: 0x4 + bool bInMeleeCharge; //OFS: 0x84 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(sentient_s, 0x88); + ASSERT_STRUCT_OFFSET(sentient_s, ent, 0x0); + ASSERT_STRUCT_OFFSET(sentient_s, eTeam, 0x4); + ASSERT_STRUCT_OFFSET(sentient_s, iThreatBias, 0x8); + ASSERT_STRUCT_OFFSET(sentient_s, iThreatBiasGroupIndex, 0xC); + ASSERT_STRUCT_OFFSET(sentient_s, bIgnoreMe, 0x10); + ASSERT_STRUCT_OFFSET(sentient_s, bIgnoreAll, 0x11); + ASSERT_STRUCT_OFFSET(sentient_s, originChanged, 0x12); + ASSERT_STRUCT_OFFSET(sentient_s, oldOrigin, 0x14); + ASSERT_STRUCT_OFFSET(sentient_s, maxVisibleDist, 0x20); + ASSERT_STRUCT_OFFSET(sentient_s, iEnemyNotifyTime, 0x24); + ASSERT_STRUCT_OFFSET(sentient_s, attackerCount, 0x28); + ASSERT_STRUCT_OFFSET(sentient_s, lastAttacker, 0x2C); + ASSERT_STRUCT_OFFSET(sentient_s, syncedMeleeEnt, 0x30); + ASSERT_STRUCT_OFFSET(sentient_s, targetEnt, 0x34); + ASSERT_STRUCT_OFFSET(sentient_s, scriptTargetEnt, 0x38); + ASSERT_STRUCT_OFFSET(sentient_s, entityTargetThreat, 0x3C); + ASSERT_STRUCT_OFFSET(sentient_s, meleeAttackerSpot, 0x40); + ASSERT_STRUCT_OFFSET(sentient_s, attackerAccuracy, 0x50); + ASSERT_STRUCT_OFFSET(sentient_s, ignoreRandomBulletDamage, 0x54); + ASSERT_STRUCT_OFFSET(sentient_s, turretInvulnerability, 0x55); + ASSERT_STRUCT_OFFSET(sentient_s, pClaimedNode, 0x58); + ASSERT_STRUCT_OFFSET(sentient_s, pPrevClaimedNode, 0x5C); + ASSERT_STRUCT_OFFSET(sentient_s, pActualChainPos, 0x60); + ASSERT_STRUCT_OFFSET(sentient_s, iActualChainPosTime, 0x64); + ASSERT_STRUCT_OFFSET(sentient_s, pNearestNode, 0x68); + ASSERT_STRUCT_OFFSET(sentient_s, bNearestNodeValid, 0x6C); + ASSERT_STRUCT_OFFSET(sentient_s, bNearestNodeBad, 0x6D); + ASSERT_STRUCT_OFFSET(sentient_s, vNearestNodeCheckPos, 0x70); + ASSERT_STRUCT_OFFSET(sentient_s, inuse, 0x7C); + ASSERT_STRUCT_OFFSET(sentient_s, banNodeTime, 0x80); + ASSERT_STRUCT_OFFSET(sentient_s, bInMeleeCharge, 0x84); + + struct actorState_s + { + int actorIndex; //OFS: 0x0 SIZE: 0x4 + int entityNum; //OFS: 0x4 SIZE: 0x4 + team_t team; //OFS: 0x8 SIZE: 0x4 + int modelindex; //OFS: 0xC SIZE: 0x4 + int attachModelIndex[6]; //OFS: 0x10 SIZE: 0x18 + int attachTagIndex[6]; //OFS: 0x28 SIZE: 0x18 + char name[32]; //OFS: 0x40 SIZE: 0x20 + int attachedEntNum; //OFS: 0x60 SIZE: 0x4 + int attachedTagIndex; //OFS: 0x64 SIZE: 0x4 + int animScriptedAnim; //OFS: 0x68 SIZE: 0x4 + int hudwarningType; //OFS: 0x6C SIZE: 0x4 + int lookAtEntNum; //OFS: 0x70 SIZE: 0x4 + int lastLookAtEntNum; //OFS: 0x74 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(actorState_s, 0x78); + ASSERT_STRUCT_OFFSET(actorState_s, actorIndex, 0x0); + ASSERT_STRUCT_OFFSET(actorState_s, entityNum, 0x4); + ASSERT_STRUCT_OFFSET(actorState_s, team, 0x8); + ASSERT_STRUCT_OFFSET(actorState_s, modelindex, 0xC); + ASSERT_STRUCT_OFFSET(actorState_s, attachModelIndex, 0x10); + ASSERT_STRUCT_OFFSET(actorState_s, attachTagIndex, 0x28); + ASSERT_STRUCT_OFFSET(actorState_s, name, 0x40); + ASSERT_STRUCT_OFFSET(actorState_s, attachedEntNum, 0x60); + ASSERT_STRUCT_OFFSET(actorState_s, attachedTagIndex, 0x64); + ASSERT_STRUCT_OFFSET(actorState_s, animScriptedAnim, 0x68); + ASSERT_STRUCT_OFFSET(actorState_s, hudwarningType, 0x6C); + ASSERT_STRUCT_OFFSET(actorState_s, lookAtEntNum, 0x70); + ASSERT_STRUCT_OFFSET(actorState_s, lastLookAtEntNum, 0x74); + + struct ai_transition_cmd_t + { + ai_state_transition_t eTransition; //OFS: 0x0 SIZE: 0x4 + ai_state_t eState; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ai_transition_cmd_t, 0x8); + ASSERT_STRUCT_OFFSET(ai_transition_cmd_t, eTransition, 0x0); + ASSERT_STRUCT_OFFSET(ai_transition_cmd_t, eState, 0x4); + + struct __declspec(align(2)) ActorAnimSets + { + unsigned __int16 aimLow; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 aimLevel; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 aimHigh; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 shootLow; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 shootLevel; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 shootHigh; //OFS: 0xA SIZE: 0x2 + unsigned __int16 animProneLow; //OFS: 0xC SIZE: 0x2 + unsigned __int16 animProneLevel; //OFS: 0xE SIZE: 0x2 + unsigned __int16 animProneHigh; //OFS: 0x10 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ActorAnimSets, 0x12); + ASSERT_STRUCT_OFFSET(ActorAnimSets, aimLow, 0x0); + ASSERT_STRUCT_OFFSET(ActorAnimSets, aimLevel, 0x2); + ASSERT_STRUCT_OFFSET(ActorAnimSets, aimHigh, 0x4); + ASSERT_STRUCT_OFFSET(ActorAnimSets, shootLow, 0x6); + ASSERT_STRUCT_OFFSET(ActorAnimSets, shootLevel, 0x8); + ASSERT_STRUCT_OFFSET(ActorAnimSets, shootHigh, 0xA); + ASSERT_STRUCT_OFFSET(ActorAnimSets, animProneLow, 0xC); + ASSERT_STRUCT_OFFSET(ActorAnimSets, animProneLevel, 0xE); + ASSERT_STRUCT_OFFSET(ActorAnimSets, animProneHigh, 0x10); + + struct ActorCachedInfo + { + int time; //OFS: 0x0 SIZE: 0x4 + float pos[3]; //OFS: 0x4 SIZE: 0xC + float dir[3]; //OFS: 0x10 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(ActorCachedInfo, 0x1C); + ASSERT_STRUCT_OFFSET(ActorCachedInfo, time, 0x0); + ASSERT_STRUCT_OFFSET(ActorCachedInfo, pos, 0x4); + ASSERT_STRUCT_OFFSET(ActorCachedInfo, dir, 0x10); + + struct ActorLookAtInfo + { + float vLookAtPos[3]; //OFS: 0x0 SIZE: 0xC + float fLookAtTurnAngle; //OFS: 0xC SIZE: 0x4 + float fLookAtTurnSpeed; //OFS: 0x10 SIZE: 0x4 + float fLookAtTurnAccel; //OFS: 0x14 SIZE: 0x4 + float fLookAtAnimYawLimit; //OFS: 0x18 SIZE: 0x4 + float fLookAtYawLimit; //OFS: 0x1C SIZE: 0x4 + unsigned __int16 animLookAtStraight; //OFS: 0x20 SIZE: 0x2 + unsigned __int16 animLookAtLeft; //OFS: 0x22 SIZE: 0x2 + unsigned __int16 animLookAtRight; //OFS: 0x24 SIZE: 0x2 + bool bDoLookAt; //OFS: 0x26 SIZE: 0x1 + bool bLookAtSetup; //OFS: 0x27 SIZE: 0x1 + int iLookAtBlendEndTime; //OFS: 0x28 SIZE: 0x4 + float fLookAtAnimBlendRate; //OFS: 0x2C SIZE: 0x4 + float fLookAtLimitBlendRate; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ActorLookAtInfo, 0x34); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, vLookAtPos, 0x0); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtTurnAngle, 0xC); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtTurnSpeed, 0x10); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtTurnAccel, 0x14); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtAnimYawLimit, 0x18); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtYawLimit, 0x1C); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, animLookAtStraight, 0x20); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, animLookAtLeft, 0x22); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, animLookAtRight, 0x24); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, bDoLookAt, 0x26); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, bLookAtSetup, 0x27); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, iLookAtBlendEndTime, 0x28); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtAnimBlendRate, 0x2C); + ASSERT_STRUCT_OFFSET(ActorLookAtInfo, fLookAtLimitBlendRate, 0x30); + + struct visitor_base_t + { + void * __vftable; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(visitor_base_t, 0x4); + ASSERT_STRUCT_OFFSET(visitor_base_t, __vftable, 0x0); + + struct hybrid_vector + { + float vec[4]; //OFS: 0x0 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(hybrid_vector, 0x10); + ASSERT_STRUCT_OFFSET(hybrid_vector, vec, 0x0); + + struct colgeom_visitor_t + { + visitor_base_t baseclass_0; //OFS: 0x0 SIZE: 0x4 + hybrid_vector m_mn; //OFS: 0x4 SIZE: 0x10 + hybrid_vector m_mx; //OFS: 0x14 SIZE: 0x10 + hybrid_vector m_p0; //OFS: 0x24 SIZE: 0x10 + hybrid_vector m_p1; //OFS: 0x34 SIZE: 0x10 + hybrid_vector m_delta; //OFS: 0x44 SIZE: 0x10 + hybrid_vector m_rvec; //OFS: 0x54 SIZE: 0x10 + float m_radius; //OFS: 0x64 SIZE: 0x4 + int m_mask; //OFS: 0x68 SIZE: 0x4 + void * m_threadInfo; //OFS: 0x6C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(colgeom_visitor_t, 0x70); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, baseclass_0, 0x0); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_mn, 0x4); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_mx, 0x14); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_p0, 0x24); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_p1, 0x34); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_delta, 0x44); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_rvec, 0x54); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_radius, 0x64); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_mask, 0x68); + ASSERT_STRUCT_OFFSET(colgeom_visitor_t, m_threadInfo, 0x6C); + + union col_prim_t_u + { + const CollisionAabbTree * tree; //OFS: 0x0 SIZE: 0x4 + const cbrush_t * brush; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(col_prim_t_u, 0x4); + + struct col_prim_t + { + int type; //OFS: 0x0 SIZE: 0x4 + col_prim_t_u u; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(col_prim_t, 0x8); + ASSERT_STRUCT_OFFSET(col_prim_t, type, 0x0); + ASSERT_STRUCT_OFFSET(col_prim_t, u, 0x4); + + struct colgeom_visitor_inlined_t + { + colgeom_visitor_t baseclass_0; //OFS: 0x0 SIZE: 0x70 + int nprims; //OFS: 0x70 SIZE: 0x4 + col_prim_t prims[200]; //OFS: 0x74 SIZE: 0x640 + }; + ASSERT_STRUCT_SIZE(colgeom_visitor_inlined_t, 0x6B4); + ASSERT_STRUCT_OFFSET(colgeom_visitor_inlined_t, baseclass_0, 0x0); + ASSERT_STRUCT_OFFSET(colgeom_visitor_inlined_t, nprims, 0x70); + ASSERT_STRUCT_OFFSET(colgeom_visitor_inlined_t, prims, 0x74); + + struct actor_physics_t + { + float vOrigin[3]; //OFS: 0x0 SIZE: 0xC + float vVelocity[3]; //OFS: 0xC SIZE: 0xC + __int16 groundEntNum; //OFS: 0x18 SIZE: 0x2 + int iFootstepTimer; //OFS: 0x1C SIZE: 0x4 + int bHasGroundPlane; //OFS: 0x20 SIZE: 0x4 + int groundplaneSlope; //OFS: 0x24 SIZE: 0x4 + int iSurfaceType; //OFS: 0x28 SIZE: 0x4 + float vWishDelta[3]; //OFS: 0x2C SIZE: 0xC + int bIsAlive; //OFS: 0x38 SIZE: 0x4 + int iEntNum; //OFS: 0x3C SIZE: 0x4 + int ePhysicsType; //OFS: 0x40 SIZE: 0x4 + float fGravity; //OFS: 0x44 SIZE: 0x4 + int iMsec; //OFS: 0x48 SIZE: 0x4 + float vMins[3]; //OFS: 0x4C SIZE: 0xC + float vMaxs[3]; //OFS: 0x58 SIZE: 0xC + bool prone; //OFS: 0x64 SIZE: 0x1 + int iTraceMask; //OFS: 0x68 SIZE: 0x4 + int foliageSoundTime; //OFS: 0x6C SIZE: 0x4 + int iNumTouch; //OFS: 0x70 SIZE: 0x4 + int iTouchEnts[32]; //OFS: 0x74 SIZE: 0x80 + int iHitEntnum; //OFS: 0xF4 SIZE: 0x4 + float vHitOrigin[2]; //OFS: 0xF8 SIZE: 0x8 + float vHitNormal[2]; //OFS: 0x100 SIZE: 0x8 + unsigned __int8 bStuck; //OFS: 0x108 SIZE: 0x1 + unsigned __int8 bDeflected; //OFS: 0x109 SIZE: 0x1 + colgeom_visitor_inlined_t proximity_data; //OFS: 0x10C SIZE: 0x6B4 + }; + ASSERT_STRUCT_SIZE(actor_physics_t, 0x7C0); + ASSERT_STRUCT_OFFSET(actor_physics_t, vOrigin, 0x0); + ASSERT_STRUCT_OFFSET(actor_physics_t, vVelocity, 0xC); + ASSERT_STRUCT_OFFSET(actor_physics_t, groundEntNum, 0x18); + ASSERT_STRUCT_OFFSET(actor_physics_t, iFootstepTimer, 0x1C); + ASSERT_STRUCT_OFFSET(actor_physics_t, bHasGroundPlane, 0x20); + ASSERT_STRUCT_OFFSET(actor_physics_t, groundplaneSlope, 0x24); + ASSERT_STRUCT_OFFSET(actor_physics_t, iSurfaceType, 0x28); + ASSERT_STRUCT_OFFSET(actor_physics_t, vWishDelta, 0x2C); + ASSERT_STRUCT_OFFSET(actor_physics_t, bIsAlive, 0x38); + ASSERT_STRUCT_OFFSET(actor_physics_t, iEntNum, 0x3C); + ASSERT_STRUCT_OFFSET(actor_physics_t, ePhysicsType, 0x40); + ASSERT_STRUCT_OFFSET(actor_physics_t, fGravity, 0x44); + ASSERT_STRUCT_OFFSET(actor_physics_t, iMsec, 0x48); + ASSERT_STRUCT_OFFSET(actor_physics_t, vMins, 0x4C); + ASSERT_STRUCT_OFFSET(actor_physics_t, vMaxs, 0x58); + ASSERT_STRUCT_OFFSET(actor_physics_t, prone, 0x64); + ASSERT_STRUCT_OFFSET(actor_physics_t, iTraceMask, 0x68); + ASSERT_STRUCT_OFFSET(actor_physics_t, foliageSoundTime, 0x6C); + ASSERT_STRUCT_OFFSET(actor_physics_t, iNumTouch, 0x70); + ASSERT_STRUCT_OFFSET(actor_physics_t, iTouchEnts, 0x74); + ASSERT_STRUCT_OFFSET(actor_physics_t, iHitEntnum, 0xF4); + ASSERT_STRUCT_OFFSET(actor_physics_t, vHitOrigin, 0xF8); + ASSERT_STRUCT_OFFSET(actor_physics_t, vHitNormal, 0x100); + ASSERT_STRUCT_OFFSET(actor_physics_t, bStuck, 0x108); + ASSERT_STRUCT_OFFSET(actor_physics_t, bDeflected, 0x109); + ASSERT_STRUCT_OFFSET(actor_physics_t, proximity_data, 0x10C); + + struct pathpoint_t + { + float vOrigPoint[3]; //OFS: 0x0 SIZE: 0xC + float fDir2D[2]; //OFS: 0xC SIZE: 0x8 + float fOrigLength; //OFS: 0x14 SIZE: 0x4 + int iNodeNum; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathpoint_t, 0x1C); + ASSERT_STRUCT_OFFSET(pathpoint_t, vOrigPoint, 0x0); + ASSERT_STRUCT_OFFSET(pathpoint_t, fDir2D, 0xC); + ASSERT_STRUCT_OFFSET(pathpoint_t, fOrigLength, 0x14); + ASSERT_STRUCT_OFFSET(pathpoint_t, iNodeNum, 0x18); + + struct path_t + { + pathpoint_t pts[32]; //OFS: 0x0 SIZE: 0x380 + __int16 wPathLen; //OFS: 0x380 SIZE: 0x2 + __int16 wOrigPathLen; //OFS: 0x382 SIZE: 0x2 + __int16 wDodgeCount; //OFS: 0x384 SIZE: 0x2 + __int16 wNegotiationStartNode; //OFS: 0x386 SIZE: 0x2 + __int16 lookaheadNextNode; //OFS: 0x388 SIZE: 0x2 + __int16 wDodgeEntity; //OFS: 0x38A SIZE: 0x2 + float vFinalGoal[3]; //OFS: 0x38C SIZE: 0xC + float lookaheadDir[3]; //OFS: 0x398 SIZE: 0xC + float forwardLookaheadDir2D[2]; //OFS: 0x3A4 SIZE: 0x8 + float fLookaheadDist; //OFS: 0x3AC SIZE: 0x4 + float fLookaheadAmount; //OFS: 0x3B0 SIZE: 0x4 + float fLookaheadDistToNextNode; //OFS: 0x3B4 SIZE: 0x4 + int minLookAheadNodes; //OFS: 0x3B8 SIZE: 0x4 + int flags; //OFS: 0x3BC SIZE: 0x4 + int iPathTime; //OFS: 0x3C0 SIZE: 0x4 + team_t eTeam; //OFS: 0x3C4 SIZE: 0x4 + float fCurrLength; //OFS: 0x3C8 SIZE: 0x4 + float vCurrPoint[3]; //OFS: 0x3CC SIZE: 0xC + int iPathEndTime; //OFS: 0x3D8 SIZE: 0x4 + float pathEndAnimDistSq; //OFS: 0x3DC SIZE: 0x4 + int pathEndAnimNotified; //OFS: 0x3E0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(path_t, 0x3E4); + ASSERT_STRUCT_OFFSET(path_t, pts, 0x0); + ASSERT_STRUCT_OFFSET(path_t, wPathLen, 0x380); + ASSERT_STRUCT_OFFSET(path_t, wOrigPathLen, 0x382); + ASSERT_STRUCT_OFFSET(path_t, wDodgeCount, 0x384); + ASSERT_STRUCT_OFFSET(path_t, wNegotiationStartNode, 0x386); + ASSERT_STRUCT_OFFSET(path_t, lookaheadNextNode, 0x388); + ASSERT_STRUCT_OFFSET(path_t, wDodgeEntity, 0x38A); + ASSERT_STRUCT_OFFSET(path_t, vFinalGoal, 0x38C); + ASSERT_STRUCT_OFFSET(path_t, lookaheadDir, 0x398); + ASSERT_STRUCT_OFFSET(path_t, forwardLookaheadDir2D, 0x3A4); + ASSERT_STRUCT_OFFSET(path_t, fLookaheadDist, 0x3AC); + ASSERT_STRUCT_OFFSET(path_t, fLookaheadAmount, 0x3B0); + ASSERT_STRUCT_OFFSET(path_t, fLookaheadDistToNextNode, 0x3B4); + ASSERT_STRUCT_OFFSET(path_t, minLookAheadNodes, 0x3B8); + ASSERT_STRUCT_OFFSET(path_t, flags, 0x3BC); + ASSERT_STRUCT_OFFSET(path_t, iPathTime, 0x3C0); + ASSERT_STRUCT_OFFSET(path_t, eTeam, 0x3C4); + ASSERT_STRUCT_OFFSET(path_t, fCurrLength, 0x3C8); + ASSERT_STRUCT_OFFSET(path_t, vCurrPoint, 0x3CC); + ASSERT_STRUCT_OFFSET(path_t, iPathEndTime, 0x3D8); + ASSERT_STRUCT_OFFSET(path_t, pathEndAnimDistSq, 0x3DC); + ASSERT_STRUCT_OFFSET(path_t, pathEndAnimNotified, 0x3E0); + + struct path_trim_t + { + int iIndex; //OFS: 0x0 SIZE: 0x4 + int iDelta; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(path_trim_t, 0x8); + ASSERT_STRUCT_OFFSET(path_trim_t, iIndex, 0x0); + ASSERT_STRUCT_OFFSET(path_trim_t, iDelta, 0x4); + + struct actor_goal_s + { + float pos[3]; //OFS: 0x0 SIZE: 0xC + float ang[3]; //OFS: 0xC SIZE: 0xC + float radius; //OFS: 0x18 SIZE: 0x4 + float height; //OFS: 0x1C SIZE: 0x4 + pathnode_t * node; //OFS: 0x20 SIZE: 0x4 + gentity_s * volume; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(actor_goal_s, 0x28); + ASSERT_STRUCT_OFFSET(actor_goal_s, pos, 0x0); + ASSERT_STRUCT_OFFSET(actor_goal_s, ang, 0xC); + ASSERT_STRUCT_OFFSET(actor_goal_s, radius, 0x18); + ASSERT_STRUCT_OFFSET(actor_goal_s, height, 0x1C); + ASSERT_STRUCT_OFFSET(actor_goal_s, node, 0x20); + ASSERT_STRUCT_OFFSET(actor_goal_s, volume, 0x24); + + struct ActorCoverArrivalInfo + { + int arrivalNotifyRequested; //OFS: 0x0 SIZE: 0x4 + int animscriptOverrideRunTo; //OFS: 0x4 SIZE: 0x4 + float animscriptOverrideRunToPos[3]; //OFS: 0x8 SIZE: 0xC + float animscriptOverrideOriginError[3]; //OFS: 0x14 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(ActorCoverArrivalInfo, 0x20); + ASSERT_STRUCT_OFFSET(ActorCoverArrivalInfo, arrivalNotifyRequested, 0x0); + ASSERT_STRUCT_OFFSET(ActorCoverArrivalInfo, animscriptOverrideRunTo, 0x4); + ASSERT_STRUCT_OFFSET(ActorCoverArrivalInfo, animscriptOverrideRunToPos, 0x8); + ASSERT_STRUCT_OFFSET(ActorCoverArrivalInfo, animscriptOverrideOriginError, 0x14); + + struct vis_cache_t + { + bool bVisible; //OFS: 0x0 SIZE: 0x1 + int iLastUpdateTime; //OFS: 0x4 SIZE: 0x4 + int iLastVisTime; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vis_cache_t, 0xC); + ASSERT_STRUCT_OFFSET(vis_cache_t, bVisible, 0x0); + ASSERT_STRUCT_OFFSET(vis_cache_t, iLastUpdateTime, 0x4); + ASSERT_STRUCT_OFFSET(vis_cache_t, iLastVisTime, 0x8); + + struct sentient_info_t + { + vis_cache_t VisCache; //OFS: 0x0 SIZE: 0xC + int iLastAttackMeTime; //OFS: 0xC SIZE: 0x4 + int lastKnownPosTime; //OFS: 0x10 SIZE: 0x4 + int attackTime; //OFS: 0x14 SIZE: 0x4 + float vLastKnownPos[3]; //OFS: 0x18 SIZE: 0xC + pathnode_t * pLastKnownNode; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sentient_info_t, 0x28); + ASSERT_STRUCT_OFFSET(sentient_info_t, VisCache, 0x0); + ASSERT_STRUCT_OFFSET(sentient_info_t, iLastAttackMeTime, 0xC); + ASSERT_STRUCT_OFFSET(sentient_info_t, lastKnownPosTime, 0x10); + ASSERT_STRUCT_OFFSET(sentient_info_t, attackTime, 0x14); + ASSERT_STRUCT_OFFSET(sentient_info_t, vLastKnownPos, 0x18); + ASSERT_STRUCT_OFFSET(sentient_info_t, pLastKnownNode, 0x24); + + struct ai_suppression_t + { + int iTime; //OFS: 0x0 SIZE: 0x4 + sentient_s * pSuppressor; //OFS: 0x4 SIZE: 0x4 + float clipPlane[3]; //OFS: 0x8 SIZE: 0xC + int movementOnly; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ai_suppression_t, 0x18); + ASSERT_STRUCT_OFFSET(ai_suppression_t, iTime, 0x0); + ASSERT_STRUCT_OFFSET(ai_suppression_t, pSuppressor, 0x4); + ASSERT_STRUCT_OFFSET(ai_suppression_t, clipPlane, 0x8); + ASSERT_STRUCT_OFFSET(ai_suppression_t, movementOnly, 0x14); + + struct potential_threat_t + { + bool isEnabled; //OFS: 0x0 SIZE: 0x1 + float direction[2]; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(potential_threat_t, 0xC); + ASSERT_STRUCT_OFFSET(potential_threat_t, isEnabled, 0x0); + ASSERT_STRUCT_OFFSET(potential_threat_t, direction, 0x4); + + struct actor_s + { + gentity_s * ent; //OFS: 0x0 SIZE: 0x4 + sentient_s * sentient; //OFS: 0x4 SIZE: 0x4 + AISpecies species; //OFS: 0x8 SIZE: 0x4 + actorState_s as; //OFS: 0xC SIZE: 0x78 + _BYTE gap84[40]; //OFS: 0x84 SIZE: 0x28 + _BYTE gapAC[716]; //OFS: 0xAC SIZE: 0x2CC + _BYTE gap_378[2068]; //OFS: 0x378 SIZE: 0x814 + ai_state_t eState[5]; //OFS: 0xB8C SIZE: 0x14 + ai_substate_t eSubState[5]; //OFS: 0xBA0 SIZE: 0x14 + int stateLevel; //OFS: 0xBB4 SIZE: 0x4 + int iStateTime; //OFS: 0xBB8 SIZE: 0x4 + int preThinkTime; //OFS: 0xBBC SIZE: 0x4 + ai_transition_cmd_t StateTransitions[11]; //OFS: 0xBC0 SIZE: 0x58 + int transitionCount; //OFS: 0xC18 SIZE: 0x4 + ai_state_t eSimulatedState[5]; //OFS: 0xC1C SIZE: 0x14 + int simulatedStateLevel; //OFS: 0xC30 SIZE: 0x4 + int iPainTime; //OFS: 0xC34 SIZE: 0x4 + char allowPain; //OFS: 0xC38 SIZE: 0x1 + char allowDeath; //OFS: 0xC39 SIZE: 0x1 + char delayedDeath; //OFS: 0xC3A SIZE: 0x1 + char provideCoveringFire; //OFS: 0xC3B SIZE: 0x1 + int accuracy; //OFS: 0xC3C SIZE: 0x4 + int playerSightAccuracy; //OFS: 0xC40 SIZE: 0x4 + int missCount; //OFS: 0xC44 SIZE: 0x4 + int hitCount; //OFS: 0xC48 SIZE: 0x4 + int debugLastAccuracy; //OFS: 0xC4C SIZE: 0x4 + int lastShotTime; //OFS: 0xC50 SIZE: 0x4 + __int16 properName; //OFS: 0xC54 SIZE: 0x2 + __int16 weaponName; //OFS: 0xC56 SIZE: 0x2 + int iTraceCount; //OFS: 0xC58 SIZE: 0x4 + int fLookPitch; //OFS: 0xC5C SIZE: 0x4 + int fLookYaw; //OFS: 0xC60 SIZE: 0x4 + float vLookForward[3]; //OFS: 0xC64 SIZE: 0xC + float vLookRight[3]; //OFS: 0xC70 SIZE: 0xC + float vLookUp[3]; //OFS: 0xC7C SIZE: 0xC + ai_orient_t CodeOrient; //OFS: 0xC88 SIZE: 0x10 + ai_orient_t ScriptOrient; //OFS: 0xC98 SIZE: 0x10 + float fDesiredBodyYaw; //OFS: 0xCA8 SIZE: 0x4 + ActorAnimSets animSets; //OFS: 0xCAC SIZE: 0x12 + __int16 anim_pose; //OFS: 0xCBE SIZE: 0x2 + int fInvProneAnimLowPitch; //OFS: 0xCC0 SIZE: 0x4 + int fInvProneAnimHighPitch; //OFS: 0xCC4 SIZE: 0x4 + float fProneLastDiff; //OFS: 0xCC8 SIZE: 0x4 + int bProneOK; //OFS: 0xCCC SIZE: 0x4 + actor_prone_info_s ProneInfo; //OFS: 0xCD0 SIZE: 0x18 + ActorCachedInfo eyeInfo; //OFS: 0xCE8 SIZE: 0x1C + ActorCachedInfo muzzleInfo; //OFS: 0xD04 SIZE: 0x1C + ActorLookAtInfo lookAtInfo; //OFS: 0xD20 SIZE: 0x34 + int iDamageTaken; //OFS: 0xD54 SIZE: 0x4 + int iDamageYaw; //OFS: 0xD58 SIZE: 0x4 + float damageDir[3]; //OFS: 0xD5C SIZE: 0xC + __int16 damageHitLoc; //OFS: 0xD68 SIZE: 0x2 + __int16 damageWeapon; //OFS: 0xD6A SIZE: 0x2 + __int16 damageMod; //OFS: 0xD6C SIZE: 0x2 + ai_stance_e eAllowedStances; //OFS: 0xD70 SIZE: 0x4 + __int16 AnimScriptHandle; //OFS: 0xD74 SIZE: 0x2 + scr_animscript_t * pAnimScriptFunc; //OFS: 0xD78 SIZE: 0x4 + scr_animscript_t AnimScriptSpecific; //OFS: 0xD7C SIZE: 0x8 + ai_traverse_mode_t eTraverseMode; //OFS: 0xD84 SIZE: 0x4 + unsigned __int8 moveMode; //OFS: 0xD88 SIZE: 0x1 + bool safeToChangeScript; //OFS: 0xD89 SIZE: 0x1 + char bUseGoalWeight; //OFS: 0xD8A SIZE: 0x1 + ai_animmode_t eAnimMode; //OFS: 0xD8C SIZE: 0x4 + ai_animmode_t eScriptSetAnimMode; //OFS: 0xD90 SIZE: 0x4 + actor_physics_t Physics; //OFS: 0xD94 SIZE: 0x7C0 + path_t Path; //OFS: 0x1554 SIZE: 0x3E4 + float fWalkDist; //OFS: 0x1938 SIZE: 0x4 + path_trim_t TrimInfo; //OFS: 0x193C SIZE: 0x8 + int iFollowMin; //OFS: 0x1944 SIZE: 0x4 + int iFollowMax; //OFS: 0x1948 SIZE: 0x4 + float fInterval; //OFS: 0x194C SIZE: 0x4 + int pathWaitTime; //OFS: 0x1950 SIZE: 0x4 + int iTeamMoveWaitTime; //OFS: 0x1954 SIZE: 0x4 + int iTeamMoveDodgeTime; //OFS: 0x1958 SIZE: 0x4 + int pPileUpActor; //OFS: 0x195C SIZE: 0x4 + int pPileUpEnt; //OFS: 0x1960 SIZE: 0x4 + int bDontAvoidPlayer; //OFS: 0x1964 SIZE: 0x4 + __int16 chainFallback; //OFS: 0x1968 SIZE: 0x2 + int sideMove; //OFS: 0x196C SIZE: 0x4 + __int8 keepClaimedNode; //OFS: 0x1970 SIZE: 0x1 + __int8 keepClaimedNodeInGoal; //OFS: 0x1971 SIZE: 0x1 + unsigned __int8 keepNodeDuringScriptedAnim; //OFS: 0x1972 SIZE: 0x1 + bool noDodgeMove; //OFS: 0x1973 SIZE: 0x1 + int mayMoveTime; //OFS: 0x1974 SIZE: 0x4 + float prevMoveDir[2]; //OFS: 0x1978 SIZE: 0x8 + float leanAmount; //OFS: 0x1980 SIZE: 0x4 + int exposedStartTime; //OFS: 0x1984 SIZE: 0x4 + int exposedDuration; //OFS: 0x1988 SIZE: 0x4 + actor_goal_s codeGoal; //OFS: 0x198C SIZE: 0x28 + aiGoalSources codeGoalSrc; //OFS: 0x19B4 SIZE: 0x4 + actor_goal_s scriptGoal; //OFS: 0x19B8 SIZE: 0x28 + EntHandle scriptGoalEnt; //OFS: 0x19E0 SIZE: 0x4 + float pathEnemyLookahead; //OFS: 0x19E4 SIZE: 0x4 + float pathEnemyFightDist; //OFS: 0x19E8 SIZE: 0x4 + float meleeAttackDist; //OFS: 0x19EC SIZE: 0x4 + bool useEnemyGoal; //OFS: 0x19F0 SIZE: 0x1 + bool useMeleeAttackSpot; //OFS: 0x19F1 SIZE: 0x1 + bool goalPosChanged; //OFS: 0x19F2 SIZE: 0x1 + bool commitToFixedNode; //OFS: 0x19F3 SIZE: 0x1 + bool ignoreForFixedNodeSafeCheck; //OFS: 0x19F4 SIZE: 0x1 + bool fixedNode; //OFS: 0x19F5 SIZE: 0x1 + float fixedNodeSafeRadius; //OFS: 0x19F8 SIZE: 0x4 + float fixedNodeSafeVolumeRadiusSq; //OFS: 0x19FC SIZE: 0x4 + EntHandle fixedNodeSafeVolume; //OFS: 0x1A00 SIZE: 0x4 + int bNotifyTurnDone; //OFS: 0x1A04 SIZE: 0x4 + pathnode_t * pDesiredChainPos; //OFS: 0x1A08 SIZE: 0x4 + ActorCoverArrivalInfo arrivalInfo; //OFS: 0x1A0C SIZE: 0x20 + int bPacifist; //OFS: 0x1A2C SIZE: 0x4 + int iPacifistWait; //OFS: 0x1A30 SIZE: 0x4 + int numCoverNodesInGoal; //OFS: 0x1A34 SIZE: 0x4 + int iPotentialCoverNodeCount; //OFS: 0x1A38 SIZE: 0x4 + pathnode_t * pPotentialReacquireNode[10]; //OFS: 0x1A3C SIZE: 0x28 + int iPotentialReacquireNodeCount; //OFS: 0x1A64 SIZE: 0x4 + float engageMinDist; //OFS: 0x1A68 SIZE: 0x4 + float engageMinFalloffDist; //OFS: 0x1A6C SIZE: 0x4 + float engageMaxDist; //OFS: 0x1A70 SIZE: 0x4 + float engageMaxFalloffDist; //OFS: 0x1A74 SIZE: 0x4 + scr_animscript_t * pAttackScriptFunc; //OFS: 0x1A78 SIZE: 0x4 + float fovDot; //OFS: 0x1A7C SIZE: 0x4 + float fMaxSightDistSqrd; //OFS: 0x1A80 SIZE: 0x4 + int ignoreCloseFoliage; //OFS: 0x1A84 SIZE: 0x4 + sentient_info_t sentientInfo[36]; //OFS: 0x1A88 SIZE: 0x5A0 + SentientHandle pFavoriteEnemy; //OFS: 0x2028 SIZE: 0x4 + int talkToSpecies; //OFS: 0x202C SIZE: 0x4 + float lastEnemySightPos[3]; //OFS: 0x2030 SIZE: 0xC + bool lastEnemySightPosValid; //OFS: 0x203C SIZE: 0x1 + float anglesToLikelyEnemyPath[3]; //OFS: 0x2040 SIZE: 0xC + int faceLikelyEnemyPathNeedCheckTime; //OFS: 0x204C SIZE: 0x4 + int faceLikelyEnemyPathNeedRecalculateTime; //OFS: 0x2050 SIZE: 0x4 + pathnode_t * faceLikelyEnemyPathNode; //OFS: 0x2054 SIZE: 0x4 + ai_suppression_t Suppressant[4]; //OFS: 0x2058 SIZE: 0x60 + int ignoreSuppression; //OFS: 0x20B8 SIZE: 0x4 + int suppressionWait; //OFS: 0x20BC SIZE: 0x4 + int suppressionDuration; //OFS: 0x20C0 SIZE: 0x4 + int suppressionStartTime; //OFS: 0x20C4 SIZE: 0x4 + float suppressionMeter; //OFS: 0x20C8 SIZE: 0x4 + potential_threat_t potentialThreat; //OFS: 0x20CC SIZE: 0xC + int threatUpdateTime; //OFS: 0x20D8 SIZE: 0x4 + int hasThreateningEnemy; //OFS: 0x20DC SIZE: 0x4 + float grenadeAwareness; //OFS: 0x20E0 SIZE: 0x4 + int bThrowbackGrenades; //OFS: 0x20E4 SIZE: 0x4 + EntHandle pGrenade; //OFS: 0x20E8 SIZE: 0x4 + int iGrenadeWeaponIndex; //OFS: 0x20EC SIZE: 0x4 + unsigned __int16 GrenadeTossMethod; //OFS: 0x20F0 SIZE: 0x2 + int bGrenadeTossValid; //OFS: 0x20F4 SIZE: 0x4 + int bGrenadeTargetValid; //OFS: 0x20F8 SIZE: 0x4 + int iGrenadeAmmo; //OFS: 0x20FC SIZE: 0x4 + float vGrenadeTossPos[3]; //OFS: 0x2100 SIZE: 0xC + float vGrenadeTargetPos[3]; //OFS: 0x210C SIZE: 0xC + float vGrenadeTossVel[3]; //OFS: 0x2118 SIZE: 0xC + int bDropWeapon; //OFS: 0x2124 SIZE: 0x4 + int bDrawOnCompass; //OFS: 0x2128 SIZE: 0x4 + int bActivateCrosshair; //OFS: 0x212C SIZE: 0x4 + int iUseHintString; //OFS: 0x2130 SIZE: 0x4 + gentity_s * pTurret; //OFS: 0x2134 SIZE: 0x4 + unsigned __int16 turretAnim; //OFS: 0x2138 SIZE: 0x2 + unsigned __int8 turretAnimSet; //OFS: 0x213A SIZE: 0x1 + unsigned __int8 useable; //OFS: 0x213B SIZE: 0x1 + char ignoreTriggers; //OFS: 0x213C SIZE: 0x1 + bool pushable; //OFS: 0x213D SIZE: 0x1 + int inuse; //OFS: 0x2140 SIZE: 0x4 + ai_badplace_t aiBadPlace; //OFS: 0x2144 SIZE: 0x4 + float badPlaceAwareness; //OFS: 0x2148 SIZE: 0x4 + float goodShootPos[3]; //OFS: 0x214C SIZE: 0xC + int goodShootPosValid; //OFS: 0x2158 SIZE: 0x4 + __int16 scriptState; //OFS: 0x215C SIZE: 0x2 + unsigned __int16 lastScriptState; //OFS: 0x215E SIZE: 0x2 + __int16 stateChangeReason; //OFS: 0x2160 SIZE: 0x2 + EntHandle pCloseEnt; //OFS: 0x2162 SIZE: 0x4 + int moveHistoryIndex; //OFS: 0x2168 SIZE: 0x4 + float moveHistory[10][2]; //OFS: 0x216C SIZE: 0x50 + EntHandle throwBackGrenadeKilledOriginalOwner; //OFS: 0x21BC SIZE: 0x4 + int flashBanged; //OFS: 0x21C0 SIZE: 0x4 + float flashBangedStrength; //OFS: 0x21C4 SIZE: 0x4 + int flashBangImmunity; //OFS: 0x21C8 SIZE: 0x4 + char * pszDebugInfo; //OFS: 0x21CC SIZE: 0x4 + pathnode_t * pPotentialCoverNode[1000]; //OFS: 0x21D0 SIZE: 0xFA0 + unsigned __int16 vis_blockers[36]; //OFS: 0x3170 SIZE: 0x48 + }; + ASSERT_STRUCT_SIZE(actor_s, 0x31B8); + ASSERT_STRUCT_OFFSET(actor_s, ent, 0x0); + ASSERT_STRUCT_OFFSET(actor_s, sentient, 0x4); + ASSERT_STRUCT_OFFSET(actor_s, species, 0x8); + ASSERT_STRUCT_OFFSET(actor_s, as, 0xC); + ASSERT_STRUCT_OFFSET(actor_s, gap84, 0x84); + ASSERT_STRUCT_OFFSET(actor_s, gapAC, 0xAC); + ASSERT_STRUCT_OFFSET(actor_s, gap_378, 0x378); + ASSERT_STRUCT_OFFSET(actor_s, eState, 0xB8C); + ASSERT_STRUCT_OFFSET(actor_s, eSubState, 0xBA0); + ASSERT_STRUCT_OFFSET(actor_s, stateLevel, 0xBB4); + ASSERT_STRUCT_OFFSET(actor_s, iStateTime, 0xBB8); + ASSERT_STRUCT_OFFSET(actor_s, preThinkTime, 0xBBC); + ASSERT_STRUCT_OFFSET(actor_s, StateTransitions, 0xBC0); + ASSERT_STRUCT_OFFSET(actor_s, transitionCount, 0xC18); + ASSERT_STRUCT_OFFSET(actor_s, eSimulatedState, 0xC1C); + ASSERT_STRUCT_OFFSET(actor_s, simulatedStateLevel, 0xC30); + ASSERT_STRUCT_OFFSET(actor_s, iPainTime, 0xC34); + ASSERT_STRUCT_OFFSET(actor_s, allowPain, 0xC38); + ASSERT_STRUCT_OFFSET(actor_s, allowDeath, 0xC39); + ASSERT_STRUCT_OFFSET(actor_s, delayedDeath, 0xC3A); + ASSERT_STRUCT_OFFSET(actor_s, provideCoveringFire, 0xC3B); + ASSERT_STRUCT_OFFSET(actor_s, accuracy, 0xC3C); + ASSERT_STRUCT_OFFSET(actor_s, playerSightAccuracy, 0xC40); + ASSERT_STRUCT_OFFSET(actor_s, missCount, 0xC44); + ASSERT_STRUCT_OFFSET(actor_s, hitCount, 0xC48); + ASSERT_STRUCT_OFFSET(actor_s, debugLastAccuracy, 0xC4C); + ASSERT_STRUCT_OFFSET(actor_s, lastShotTime, 0xC50); + ASSERT_STRUCT_OFFSET(actor_s, properName, 0xC54); + ASSERT_STRUCT_OFFSET(actor_s, weaponName, 0xC56); + ASSERT_STRUCT_OFFSET(actor_s, iTraceCount, 0xC58); + ASSERT_STRUCT_OFFSET(actor_s, fLookPitch, 0xC5C); + ASSERT_STRUCT_OFFSET(actor_s, fLookYaw, 0xC60); + ASSERT_STRUCT_OFFSET(actor_s, vLookForward, 0xC64); + ASSERT_STRUCT_OFFSET(actor_s, vLookRight, 0xC70); + ASSERT_STRUCT_OFFSET(actor_s, vLookUp, 0xC7C); + ASSERT_STRUCT_OFFSET(actor_s, CodeOrient, 0xC88); + ASSERT_STRUCT_OFFSET(actor_s, ScriptOrient, 0xC98); + ASSERT_STRUCT_OFFSET(actor_s, fDesiredBodyYaw, 0xCA8); + ASSERT_STRUCT_OFFSET(actor_s, animSets, 0xCAC); + ASSERT_STRUCT_OFFSET(actor_s, anim_pose, 0xCBE); + ASSERT_STRUCT_OFFSET(actor_s, fInvProneAnimLowPitch, 0xCC0); + ASSERT_STRUCT_OFFSET(actor_s, fInvProneAnimHighPitch, 0xCC4); + ASSERT_STRUCT_OFFSET(actor_s, fProneLastDiff, 0xCC8); + ASSERT_STRUCT_OFFSET(actor_s, bProneOK, 0xCCC); + ASSERT_STRUCT_OFFSET(actor_s, ProneInfo, 0xCD0); + ASSERT_STRUCT_OFFSET(actor_s, eyeInfo, 0xCE8); + ASSERT_STRUCT_OFFSET(actor_s, muzzleInfo, 0xD04); + ASSERT_STRUCT_OFFSET(actor_s, lookAtInfo, 0xD20); + ASSERT_STRUCT_OFFSET(actor_s, iDamageTaken, 0xD54); + ASSERT_STRUCT_OFFSET(actor_s, iDamageYaw, 0xD58); + ASSERT_STRUCT_OFFSET(actor_s, damageDir, 0xD5C); + ASSERT_STRUCT_OFFSET(actor_s, damageHitLoc, 0xD68); + ASSERT_STRUCT_OFFSET(actor_s, damageWeapon, 0xD6A); + ASSERT_STRUCT_OFFSET(actor_s, damageMod, 0xD6C); + ASSERT_STRUCT_OFFSET(actor_s, eAllowedStances, 0xD70); + ASSERT_STRUCT_OFFSET(actor_s, AnimScriptHandle, 0xD74); + ASSERT_STRUCT_OFFSET(actor_s, pAnimScriptFunc, 0xD78); + ASSERT_STRUCT_OFFSET(actor_s, AnimScriptSpecific, 0xD7C); + ASSERT_STRUCT_OFFSET(actor_s, eTraverseMode, 0xD84); + ASSERT_STRUCT_OFFSET(actor_s, moveMode, 0xD88); + ASSERT_STRUCT_OFFSET(actor_s, safeToChangeScript, 0xD89); + ASSERT_STRUCT_OFFSET(actor_s, bUseGoalWeight, 0xD8A); + ASSERT_STRUCT_OFFSET(actor_s, eAnimMode, 0xD8C); + ASSERT_STRUCT_OFFSET(actor_s, eScriptSetAnimMode, 0xD90); + ASSERT_STRUCT_OFFSET(actor_s, Physics, 0xD94); + ASSERT_STRUCT_OFFSET(actor_s, Path, 0x1554); + ASSERT_STRUCT_OFFSET(actor_s, fWalkDist, 0x1938); + ASSERT_STRUCT_OFFSET(actor_s, TrimInfo, 0x193C); + ASSERT_STRUCT_OFFSET(actor_s, iFollowMin, 0x1944); + ASSERT_STRUCT_OFFSET(actor_s, iFollowMax, 0x1948); + ASSERT_STRUCT_OFFSET(actor_s, fInterval, 0x194C); + ASSERT_STRUCT_OFFSET(actor_s, pathWaitTime, 0x1950); + ASSERT_STRUCT_OFFSET(actor_s, iTeamMoveWaitTime, 0x1954); + ASSERT_STRUCT_OFFSET(actor_s, iTeamMoveDodgeTime, 0x1958); + ASSERT_STRUCT_OFFSET(actor_s, pPileUpActor, 0x195C); + ASSERT_STRUCT_OFFSET(actor_s, pPileUpEnt, 0x1960); + ASSERT_STRUCT_OFFSET(actor_s, bDontAvoidPlayer, 0x1964); + ASSERT_STRUCT_OFFSET(actor_s, chainFallback, 0x1968); + ASSERT_STRUCT_OFFSET(actor_s, sideMove, 0x196C); + ASSERT_STRUCT_OFFSET(actor_s, keepClaimedNode, 0x1970); + ASSERT_STRUCT_OFFSET(actor_s, keepClaimedNodeInGoal, 0x1971); + ASSERT_STRUCT_OFFSET(actor_s, keepNodeDuringScriptedAnim, 0x1972); + ASSERT_STRUCT_OFFSET(actor_s, noDodgeMove, 0x1973); + ASSERT_STRUCT_OFFSET(actor_s, mayMoveTime, 0x1974); + ASSERT_STRUCT_OFFSET(actor_s, prevMoveDir, 0x1978); + ASSERT_STRUCT_OFFSET(actor_s, leanAmount, 0x1980); + ASSERT_STRUCT_OFFSET(actor_s, exposedStartTime, 0x1984); + ASSERT_STRUCT_OFFSET(actor_s, exposedDuration, 0x1988); + ASSERT_STRUCT_OFFSET(actor_s, codeGoal, 0x198C); + ASSERT_STRUCT_OFFSET(actor_s, codeGoalSrc, 0x19B4); + ASSERT_STRUCT_OFFSET(actor_s, scriptGoal, 0x19B8); + ASSERT_STRUCT_OFFSET(actor_s, scriptGoalEnt, 0x19E0); + ASSERT_STRUCT_OFFSET(actor_s, pathEnemyLookahead, 0x19E4); + ASSERT_STRUCT_OFFSET(actor_s, pathEnemyFightDist, 0x19E8); + ASSERT_STRUCT_OFFSET(actor_s, meleeAttackDist, 0x19EC); + ASSERT_STRUCT_OFFSET(actor_s, useEnemyGoal, 0x19F0); + ASSERT_STRUCT_OFFSET(actor_s, useMeleeAttackSpot, 0x19F1); + ASSERT_STRUCT_OFFSET(actor_s, goalPosChanged, 0x19F2); + ASSERT_STRUCT_OFFSET(actor_s, commitToFixedNode, 0x19F3); + ASSERT_STRUCT_OFFSET(actor_s, ignoreForFixedNodeSafeCheck, 0x19F4); + ASSERT_STRUCT_OFFSET(actor_s, fixedNode, 0x19F5); + ASSERT_STRUCT_OFFSET(actor_s, fixedNodeSafeRadius, 0x19F8); + ASSERT_STRUCT_OFFSET(actor_s, fixedNodeSafeVolumeRadiusSq, 0x19FC); + ASSERT_STRUCT_OFFSET(actor_s, fixedNodeSafeVolume, 0x1A00); + ASSERT_STRUCT_OFFSET(actor_s, bNotifyTurnDone, 0x1A04); + ASSERT_STRUCT_OFFSET(actor_s, pDesiredChainPos, 0x1A08); + ASSERT_STRUCT_OFFSET(actor_s, arrivalInfo, 0x1A0C); + ASSERT_STRUCT_OFFSET(actor_s, bPacifist, 0x1A2C); + ASSERT_STRUCT_OFFSET(actor_s, iPacifistWait, 0x1A30); + ASSERT_STRUCT_OFFSET(actor_s, numCoverNodesInGoal, 0x1A34); + ASSERT_STRUCT_OFFSET(actor_s, iPotentialCoverNodeCount, 0x1A38); + ASSERT_STRUCT_OFFSET(actor_s, pPotentialReacquireNode, 0x1A3C); + ASSERT_STRUCT_OFFSET(actor_s, iPotentialReacquireNodeCount, 0x1A64); + ASSERT_STRUCT_OFFSET(actor_s, engageMinDist, 0x1A68); + ASSERT_STRUCT_OFFSET(actor_s, engageMinFalloffDist, 0x1A6C); + ASSERT_STRUCT_OFFSET(actor_s, engageMaxDist, 0x1A70); + ASSERT_STRUCT_OFFSET(actor_s, engageMaxFalloffDist, 0x1A74); + ASSERT_STRUCT_OFFSET(actor_s, pAttackScriptFunc, 0x1A78); + ASSERT_STRUCT_OFFSET(actor_s, fovDot, 0x1A7C); + ASSERT_STRUCT_OFFSET(actor_s, fMaxSightDistSqrd, 0x1A80); + ASSERT_STRUCT_OFFSET(actor_s, ignoreCloseFoliage, 0x1A84); + ASSERT_STRUCT_OFFSET(actor_s, sentientInfo, 0x1A88); + ASSERT_STRUCT_OFFSET(actor_s, pFavoriteEnemy, 0x2028); + ASSERT_STRUCT_OFFSET(actor_s, talkToSpecies, 0x202C); + ASSERT_STRUCT_OFFSET(actor_s, lastEnemySightPos, 0x2030); + ASSERT_STRUCT_OFFSET(actor_s, lastEnemySightPosValid, 0x203C); + ASSERT_STRUCT_OFFSET(actor_s, anglesToLikelyEnemyPath, 0x2040); + ASSERT_STRUCT_OFFSET(actor_s, faceLikelyEnemyPathNeedCheckTime, 0x204C); + ASSERT_STRUCT_OFFSET(actor_s, faceLikelyEnemyPathNeedRecalculateTime, 0x2050); + ASSERT_STRUCT_OFFSET(actor_s, faceLikelyEnemyPathNode, 0x2054); + ASSERT_STRUCT_OFFSET(actor_s, Suppressant, 0x2058); + ASSERT_STRUCT_OFFSET(actor_s, ignoreSuppression, 0x20B8); + ASSERT_STRUCT_OFFSET(actor_s, suppressionWait, 0x20BC); + ASSERT_STRUCT_OFFSET(actor_s, suppressionDuration, 0x20C0); + ASSERT_STRUCT_OFFSET(actor_s, suppressionStartTime, 0x20C4); + ASSERT_STRUCT_OFFSET(actor_s, suppressionMeter, 0x20C8); + ASSERT_STRUCT_OFFSET(actor_s, potentialThreat, 0x20CC); + ASSERT_STRUCT_OFFSET(actor_s, threatUpdateTime, 0x20D8); + ASSERT_STRUCT_OFFSET(actor_s, hasThreateningEnemy, 0x20DC); + ASSERT_STRUCT_OFFSET(actor_s, grenadeAwareness, 0x20E0); + ASSERT_STRUCT_OFFSET(actor_s, bThrowbackGrenades, 0x20E4); + ASSERT_STRUCT_OFFSET(actor_s, pGrenade, 0x20E8); + ASSERT_STRUCT_OFFSET(actor_s, iGrenadeWeaponIndex, 0x20EC); + ASSERT_STRUCT_OFFSET(actor_s, GrenadeTossMethod, 0x20F0); + ASSERT_STRUCT_OFFSET(actor_s, bGrenadeTossValid, 0x20F4); + ASSERT_STRUCT_OFFSET(actor_s, bGrenadeTargetValid, 0x20F8); + ASSERT_STRUCT_OFFSET(actor_s, iGrenadeAmmo, 0x20FC); + ASSERT_STRUCT_OFFSET(actor_s, vGrenadeTossPos, 0x2100); + ASSERT_STRUCT_OFFSET(actor_s, vGrenadeTargetPos, 0x210C); + ASSERT_STRUCT_OFFSET(actor_s, vGrenadeTossVel, 0x2118); + ASSERT_STRUCT_OFFSET(actor_s, bDropWeapon, 0x2124); + ASSERT_STRUCT_OFFSET(actor_s, bDrawOnCompass, 0x2128); + ASSERT_STRUCT_OFFSET(actor_s, bActivateCrosshair, 0x212C); + ASSERT_STRUCT_OFFSET(actor_s, iUseHintString, 0x2130); + ASSERT_STRUCT_OFFSET(actor_s, pTurret, 0x2134); + ASSERT_STRUCT_OFFSET(actor_s, turretAnim, 0x2138); + ASSERT_STRUCT_OFFSET(actor_s, turretAnimSet, 0x213A); + ASSERT_STRUCT_OFFSET(actor_s, useable, 0x213B); + ASSERT_STRUCT_OFFSET(actor_s, ignoreTriggers, 0x213C); + ASSERT_STRUCT_OFFSET(actor_s, pushable, 0x213D); + ASSERT_STRUCT_OFFSET(actor_s, inuse, 0x2140); + ASSERT_STRUCT_OFFSET(actor_s, aiBadPlace, 0x2144); + ASSERT_STRUCT_OFFSET(actor_s, badPlaceAwareness, 0x2148); + ASSERT_STRUCT_OFFSET(actor_s, goodShootPos, 0x214C); + ASSERT_STRUCT_OFFSET(actor_s, goodShootPosValid, 0x2158); + ASSERT_STRUCT_OFFSET(actor_s, scriptState, 0x215C); + ASSERT_STRUCT_OFFSET(actor_s, lastScriptState, 0x215E); + ASSERT_STRUCT_OFFSET(actor_s, stateChangeReason, 0x2160); + ASSERT_STRUCT_OFFSET(actor_s, pCloseEnt, 0x2162); + ASSERT_STRUCT_OFFSET(actor_s, moveHistoryIndex, 0x2168); + ASSERT_STRUCT_OFFSET(actor_s, moveHistory, 0x216C); + ASSERT_STRUCT_OFFSET(actor_s, throwBackGrenadeKilledOriginalOwner, 0x21BC); + ASSERT_STRUCT_OFFSET(actor_s, flashBanged, 0x21C0); + ASSERT_STRUCT_OFFSET(actor_s, flashBangedStrength, 0x21C4); + ASSERT_STRUCT_OFFSET(actor_s, flashBangImmunity, 0x21C8); + ASSERT_STRUCT_OFFSET(actor_s, pszDebugInfo, 0x21CC); + ASSERT_STRUCT_OFFSET(actor_s, pPotentialCoverNode, 0x21D0); + ASSERT_STRUCT_OFFSET(actor_s, vis_blockers, 0x3170); + + struct vehicle_node_t + { + unsigned __int16 name; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 target; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 script_linkname; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 script_noteworthy; //OFS: 0x6 SIZE: 0x2 + __int16 index; //OFS: 0x8 SIZE: 0x2 + int rotated; //OFS: 0xC SIZE: 0x4 + float speed; //OFS: 0x10 SIZE: 0x4 + float lookAhead; //OFS: 0x14 SIZE: 0x4 + float origin[3]; //OFS: 0x18 SIZE: 0xC + float dir[3]; //OFS: 0x24 SIZE: 0xC + float angles[3]; //OFS: 0x30 SIZE: 0xC + float length; //OFS: 0x3C SIZE: 0x4 + __int16 nextIdx; //OFS: 0x40 SIZE: 0x2 + __int16 prevIdx; //OFS: 0x42 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(vehicle_node_t, 0x44); + ASSERT_STRUCT_OFFSET(vehicle_node_t, name, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_node_t, target, 0x2); + ASSERT_STRUCT_OFFSET(vehicle_node_t, script_linkname, 0x4); + ASSERT_STRUCT_OFFSET(vehicle_node_t, script_noteworthy, 0x6); + ASSERT_STRUCT_OFFSET(vehicle_node_t, index, 0x8); + ASSERT_STRUCT_OFFSET(vehicle_node_t, rotated, 0xC); + ASSERT_STRUCT_OFFSET(vehicle_node_t, speed, 0x10); + ASSERT_STRUCT_OFFSET(vehicle_node_t, lookAhead, 0x14); + ASSERT_STRUCT_OFFSET(vehicle_node_t, origin, 0x18); + ASSERT_STRUCT_OFFSET(vehicle_node_t, dir, 0x24); + ASSERT_STRUCT_OFFSET(vehicle_node_t, angles, 0x30); + ASSERT_STRUCT_OFFSET(vehicle_node_t, length, 0x3C); + ASSERT_STRUCT_OFFSET(vehicle_node_t, nextIdx, 0x40); + ASSERT_STRUCT_OFFSET(vehicle_node_t, prevIdx, 0x42); + + struct vehicle_pathpos_t + { + __int16 nodeIdx; //OFS: 0x0 SIZE: 0x2 + __int16 endOfPath; //OFS: 0x2 SIZE: 0x2 + float frac; //OFS: 0x4 SIZE: 0x4 + float speed; //OFS: 0x8 SIZE: 0x4 + float lookAhead; //OFS: 0xC SIZE: 0x4 + float slide; //OFS: 0x10 SIZE: 0x4 + float origin[3]; //OFS: 0x14 SIZE: 0xC + float angles[3]; //OFS: 0x20 SIZE: 0xC + float lookPos[3]; //OFS: 0x2C SIZE: 0xC + vehicle_node_t switchNode[2]; //OFS: 0x38 SIZE: 0x88 + }; + ASSERT_STRUCT_SIZE(vehicle_pathpos_t, 0xC0); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, nodeIdx, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, endOfPath, 0x2); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, frac, 0x4); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, speed, 0x8); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, lookAhead, 0xC); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, slide, 0x10); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, origin, 0x14); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, angles, 0x20); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, lookPos, 0x2C); + ASSERT_STRUCT_OFFSET(vehicle_pathpos_t, switchNode, 0x38); + + struct vehicle_physic_t + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float prevOrigin[3]; //OFS: 0xC SIZE: 0xC + float angles[3]; //OFS: 0x18 SIZE: 0xC + float prevAngles[3]; //OFS: 0x24 SIZE: 0xC + float maxAngleVel[3]; //OFS: 0x30 SIZE: 0xC + float yawAccel; //OFS: 0x3C SIZE: 0x4 + float yawDecel; //OFS: 0x40 SIZE: 0x4 + float mins[3]; //OFS: 0x44 SIZE: 0xC + float maxs[3]; //OFS: 0x50 SIZE: 0xC + float vel[3]; //OFS: 0x5C SIZE: 0xC + float bodyVel[3]; //OFS: 0x68 SIZE: 0xC + float rotVel[3]; //OFS: 0x74 SIZE: 0xC + float accel[3]; //OFS: 0x80 SIZE: 0xC + float maxPitchAngle; //OFS: 0x8C SIZE: 0x4 + float maxRollAngle; //OFS: 0x90 SIZE: 0x4 + float wheelZVel[6]; //OFS: 0x94 SIZE: 0x18 + float wheelZPos[6]; //OFS: 0xAC SIZE: 0x18 + int wheelSurfType[6]; //OFS: 0xC4 SIZE: 0x18 + float worldTilt[3]; //OFS: 0xDC SIZE: 0xC + float worldTiltVel[3]; //OFS: 0xE8 SIZE: 0xC + float curveLength; //OFS: 0xF4 SIZE: 0x4 + int curveID; //OFS: 0xF8 SIZE: 0x4 + float curveStep; //OFS: 0xFC SIZE: 0x4 + float curveTime; //OFS: 0x100 SIZE: 0x4 + float timeStep; //OFS: 0x104 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vehicle_physic_t, 0x108); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, origin, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, prevOrigin, 0xC); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, angles, 0x18); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, prevAngles, 0x24); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, maxAngleVel, 0x30); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, yawAccel, 0x3C); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, yawDecel, 0x40); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, mins, 0x44); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, maxs, 0x50); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, vel, 0x5C); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, bodyVel, 0x68); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, rotVel, 0x74); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, accel, 0x80); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, maxPitchAngle, 0x8C); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, maxRollAngle, 0x90); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, wheelZVel, 0x94); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, wheelZPos, 0xAC); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, wheelSurfType, 0xC4); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, worldTilt, 0xDC); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, worldTiltVel, 0xE8); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, curveLength, 0xF4); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, curveID, 0xF8); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, curveStep, 0xFC); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, curveTime, 0x100); + ASSERT_STRUCT_OFFSET(vehicle_physic_t, timeStep, 0x104); + + struct VehicleTurret + { + int fireTime; //OFS: 0x0 SIZE: 0x4 + int fireBarrel; //OFS: 0x4 SIZE: 0x4 + float barrelOffset; //OFS: 0x8 SIZE: 0x4 + int flags; //OFS: 0xC SIZE: 0x4 + float heatVal; //OFS: 0x10 SIZE: 0x4 + int overheating; //OFS: 0x14 SIZE: 0x4 + VehicleTurretState turretState; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleTurret, 0x1C); + ASSERT_STRUCT_OFFSET(VehicleTurret, fireTime, 0x0); + ASSERT_STRUCT_OFFSET(VehicleTurret, fireBarrel, 0x4); + ASSERT_STRUCT_OFFSET(VehicleTurret, barrelOffset, 0x8); + ASSERT_STRUCT_OFFSET(VehicleTurret, flags, 0xC); + ASSERT_STRUCT_OFFSET(VehicleTurret, heatVal, 0x10); + ASSERT_STRUCT_OFFSET(VehicleTurret, overheating, 0x14); + ASSERT_STRUCT_OFFSET(VehicleTurret, turretState, 0x18); + + struct VehicleJitter + { + int jitterPeriodMin; //OFS: 0x0 SIZE: 0x4 + int jitterPeriodMax; //OFS: 0x4 SIZE: 0x4 + int jitterEndTime; //OFS: 0x8 SIZE: 0x4 + float jitterOffsetRange[3]; //OFS: 0xC SIZE: 0xC + float jitterDeltaAccel[3]; //OFS: 0x18 SIZE: 0xC + float jitterAccel[3]; //OFS: 0x24 SIZE: 0xC + float jitterPos[3]; //OFS: 0x30 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(VehicleJitter, 0x3C); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterPeriodMin, 0x0); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterPeriodMax, 0x4); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterEndTime, 0x8); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterOffsetRange, 0xC); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterDeltaAccel, 0x18); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterAccel, 0x24); + ASSERT_STRUCT_OFFSET(VehicleJitter, jitterPos, 0x30); + + struct VehicleHover + { + float hoverRadius; //OFS: 0x0 SIZE: 0x4 + float hoverSpeed; //OFS: 0x4 SIZE: 0x4 + float hoverAccel; //OFS: 0x8 SIZE: 0x4 + float hoverGoalPos[3]; //OFS: 0xC SIZE: 0xC + int useHoverAccelForAngles; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleHover, 0x1C); + ASSERT_STRUCT_OFFSET(VehicleHover, hoverRadius, 0x0); + ASSERT_STRUCT_OFFSET(VehicleHover, hoverSpeed, 0x4); + ASSERT_STRUCT_OFFSET(VehicleHover, hoverAccel, 0x8); + ASSERT_STRUCT_OFFSET(VehicleHover, hoverGoalPos, 0xC); + ASSERT_STRUCT_OFFSET(VehicleHover, useHoverAccelForAngles, 0x18); + + struct VehicleTarget + { + int valid; //OFS: 0x0 SIZE: 0x4 + int hasTargetYaw; //OFS: 0x4 SIZE: 0x4 + int targetEnt; //OFS: 0x8 SIZE: 0x4 + int lookAtEnt; //OFS: 0xC SIZE: 0x4 + float targetOrigin[3]; //OFS: 0x10 SIZE: 0xC + float targetOffset[3]; //OFS: 0x1C SIZE: 0xC + float targetYaw; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleTarget, 0x2C); + ASSERT_STRUCT_OFFSET(VehicleTarget, valid, 0x0); + ASSERT_STRUCT_OFFSET(VehicleTarget, hasTargetYaw, 0x4); + ASSERT_STRUCT_OFFSET(VehicleTarget, targetEnt, 0x8); + ASSERT_STRUCT_OFFSET(VehicleTarget, lookAtEnt, 0xC); + ASSERT_STRUCT_OFFSET(VehicleTarget, targetOrigin, 0x10); + ASSERT_STRUCT_OFFSET(VehicleTarget, targetOffset, 0x1C); + ASSERT_STRUCT_OFFSET(VehicleTarget, targetYaw, 0x28); + + struct VehicleGunnerTags + { + int turret; //OFS: 0x0 SIZE: 0x4 + int barrel; //OFS: 0x4 SIZE: 0x4 + int flash; //OFS: 0x8 SIZE: 0x4 + int flash2; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleGunnerTags, 0x10); + ASSERT_STRUCT_OFFSET(VehicleGunnerTags, turret, 0x0); + ASSERT_STRUCT_OFFSET(VehicleGunnerTags, barrel, 0x4); + ASSERT_STRUCT_OFFSET(VehicleGunnerTags, flash, 0x8); + ASSERT_STRUCT_OFFSET(VehicleGunnerTags, flash2, 0xC); + + struct VehicleTags + { + int player; //OFS: 0x0 SIZE: 0x4 + int detach; //OFS: 0x4 SIZE: 0x4 + int popout; //OFS: 0x8 SIZE: 0x4 + int body; //OFS: 0xC SIZE: 0x4 + int turret; //OFS: 0x10 SIZE: 0x4 + int turret_base; //OFS: 0x14 SIZE: 0x4 + int barrel; //OFS: 0x18 SIZE: 0x4 + int flash[5]; //OFS: 0x1C SIZE: 0x14 + VehicleGunnerTags gunnerTags[4]; //OFS: 0x30 SIZE: 0x40 + int wheel[6]; //OFS: 0x70 SIZE: 0x18 + int seats[10]; //OFS: 0x88 SIZE: 0x28 + int entryPoints[3]; //OFS: 0xB0 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(VehicleTags, 0xBC); + ASSERT_STRUCT_OFFSET(VehicleTags, player, 0x0); + ASSERT_STRUCT_OFFSET(VehicleTags, detach, 0x4); + ASSERT_STRUCT_OFFSET(VehicleTags, popout, 0x8); + ASSERT_STRUCT_OFFSET(VehicleTags, body, 0xC); + ASSERT_STRUCT_OFFSET(VehicleTags, turret, 0x10); + ASSERT_STRUCT_OFFSET(VehicleTags, turret_base, 0x14); + ASSERT_STRUCT_OFFSET(VehicleTags, barrel, 0x18); + ASSERT_STRUCT_OFFSET(VehicleTags, flash, 0x1C); + ASSERT_STRUCT_OFFSET(VehicleTags, gunnerTags, 0x30); + ASSERT_STRUCT_OFFSET(VehicleTags, wheel, 0x70); + ASSERT_STRUCT_OFFSET(VehicleTags, seats, 0x88); + ASSERT_STRUCT_OFFSET(VehicleTags, entryPoints, 0xB0); + + struct VehicleSeat + { + int _occupantEntNum; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleSeat, 0x4); + ASSERT_STRUCT_OFFSET(VehicleSeat, _occupantEntNum, 0x0); + + struct Float4 + { + float x; //OFS: 0x0 SIZE: 0x4 + float y; //OFS: 0x4 SIZE: 0x4 + float z; //OFS: 0x8 SIZE: 0x4 + float w; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Float4, 0x10); + ASSERT_STRUCT_OFFSET(Float4, x, 0x0); + ASSERT_STRUCT_OFFSET(Float4, y, 0x4); + ASSERT_STRUCT_OFFSET(Float4, z, 0x8); + ASSERT_STRUCT_OFFSET(Float4, w, 0xC); + + struct Dir3 + { + Float4 v; //OFS: 0x0 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(Dir3, 0x10); + ASSERT_STRUCT_OFFSET(Dir3, v, 0x0); + + struct Position3 + { + Float4 v; //OFS: 0x0 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(Position3, 0x10); + ASSERT_STRUCT_OFFSET(Position3, v, 0x0); + + struct Mat43 + { + Dir3 x; //OFS: 0x0 SIZE: 0x10 + Dir3 y; //OFS: 0x10 SIZE: 0x10 + Dir3 z; //OFS: 0x20 SIZE: 0x10 + Position3 w; //OFS: 0x30 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(Mat43, 0x40); + ASSERT_STRUCT_OFFSET(Mat43, x, 0x0); + ASSERT_STRUCT_OFFSET(Mat43, y, 0x10); + ASSERT_STRUCT_OFFSET(Mat43, z, 0x20); + ASSERT_STRUCT_OFFSET(Mat43, w, 0x30); + + struct VehicleParameter + { + float m_speed_max; //OFS: 0x0 SIZE: 0x4 + float m_accel_max; //OFS: 0x4 SIZE: 0x4 + float m_reverse_scale; //OFS: 0x8 SIZE: 0x4 + float m_steer_angle_max; //OFS: 0xC SIZE: 0x4 + float m_steer_speed; //OFS: 0x10 SIZE: 0x4 + float m_wheel_radius; //OFS: 0x14 SIZE: 0x4 + float m_susp_spring_k; //OFS: 0x18 SIZE: 0x4 + float m_susp_damp_k; //OFS: 0x1C SIZE: 0x4 + float m_susp_adj; //OFS: 0x20 SIZE: 0x4 + float m_susp_hard_limit; //OFS: 0x24 SIZE: 0x4 + float m_tire_fric_fwd; //OFS: 0x28 SIZE: 0x4 + float m_tire_fric_side; //OFS: 0x2C SIZE: 0x4 + float m_tire_fric_brake; //OFS: 0x30 SIZE: 0x4 + float m_tire_fric_hand_brake; //OFS: 0x34 SIZE: 0x4 + float m_body_mass; //OFS: 0x38 SIZE: 0x4 + float m_roll_stability; //OFS: 0x3C SIZE: 0x4 + float m_roll_resistance; //OFS: 0x40 SIZE: 0x4 + float m_upright_strength; //OFS: 0x44 SIZE: 0x4 + float m_tilt_fakey; //OFS: 0x48 SIZE: 0x4 + float m_peel_out_max_speed; //OFS: 0x4C SIZE: 0x4 + float m_inertia_scale_x; //OFS: 0x50 SIZE: 0x4 + float m_tire_damp_coast; //OFS: 0x54 SIZE: 0x4 + float m_tire_damp_brake; //OFS: 0x58 SIZE: 0x4 + float m_tire_damp_hand; //OFS: 0x5C SIZE: 0x4 + TractionType m_traction_type; //OFS: 0x60 SIZE: 0x4 + char m_name[64]; //OFS: 0x64 SIZE: 0x40 + float m_bbox_min[3]; //OFS: 0xA4 SIZE: 0xC + float m_bbox_max[3]; //OFS: 0xB0 SIZE: 0xC + float m_mass_center_offset[3]; //OFS: 0xBC SIZE: 0xC + float m_buoyancybox_min[3]; //OFS: 0xC8 SIZE: 0xC + float m_buoyancybox_max[3]; //OFS: 0xD4 SIZE: 0xC + float m_water_speed_max; //OFS: 0xE0 SIZE: 0x4 + float m_water_accel_max; //OFS: 0xE4 SIZE: 0x4 + float m_water_turn_accel; //OFS: 0xE8 SIZE: 0x4 + float m_water_turn_speed_max; //OFS: 0xEC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleParameter, 0xF0); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_speed_max, 0x0); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_accel_max, 0x4); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_reverse_scale, 0x8); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_steer_angle_max, 0xC); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_steer_speed, 0x10); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_wheel_radius, 0x14); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_susp_spring_k, 0x18); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_susp_damp_k, 0x1C); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_susp_adj, 0x20); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_susp_hard_limit, 0x24); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_fric_fwd, 0x28); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_fric_side, 0x2C); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_fric_brake, 0x30); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_fric_hand_brake, 0x34); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_body_mass, 0x38); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_roll_stability, 0x3C); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_roll_resistance, 0x40); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_upright_strength, 0x44); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tilt_fakey, 0x48); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_peel_out_max_speed, 0x4C); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_inertia_scale_x, 0x50); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_damp_coast, 0x54); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_damp_brake, 0x58); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_tire_damp_hand, 0x5C); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_traction_type, 0x60); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_name, 0x64); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_bbox_min, 0xA4); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_bbox_max, 0xB0); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_mass_center_offset, 0xBC); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_buoyancybox_min, 0xC8); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_buoyancybox_max, 0xD4); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_water_speed_max, 0xE0); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_water_accel_max, 0xE4); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_water_turn_accel, 0xE8); + ASSERT_STRUCT_OFFSET(VehicleParameter, m_water_turn_speed_max, 0xEC); + + struct vehicle_info_t + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + __int16 type; //OFS: 0x40 SIZE: 0x2 + int steerWheels; //OFS: 0x44 SIZE: 0x4 + int texScroll; //OFS: 0x48 SIZE: 0x4 + int quadBarrel; //OFS: 0x4C SIZE: 0x4 + int bulletDamage; //OFS: 0x50 SIZE: 0x4 + int armorPiercingDamage; //OFS: 0x54 SIZE: 0x4 + int grenadeDamage; //OFS: 0x58 SIZE: 0x4 + int projectileDamage; //OFS: 0x5C SIZE: 0x4 + int projectileSplashDamage; //OFS: 0x60 SIZE: 0x4 + int heavyExplosiveDamage; //OFS: 0x64 SIZE: 0x4 + int isDrivable; //OFS: 0x68 SIZE: 0x4 + int numberOfSeats; //OFS: 0x6C SIZE: 0x4 + int numberOfGunners; //OFS: 0x70 SIZE: 0x4 + int noSwitchToDriver; //OFS: 0x74 SIZE: 0x4 + int driverControlledGunPos; //OFS: 0x78 SIZE: 0x4 + float texScrollScale; //OFS: 0x7C SIZE: 0x4 + float wheelRotRate; //OFS: 0x80 SIZE: 0x4 + float maxSpeed; //OFS: 0x84 SIZE: 0x4 + float accel; //OFS: 0x88 SIZE: 0x4 + float rotRate; //OFS: 0x8C SIZE: 0x4 + float rotAccel; //OFS: 0x90 SIZE: 0x4 + float maxBodyPitch; //OFS: 0x94 SIZE: 0x4 + float maxBodyRoll; //OFS: 0x98 SIZE: 0x4 + float collisionDamage; //OFS: 0x9C SIZE: 0x4 + float collisionSpeed; //OFS: 0xA0 SIZE: 0x4 + float suspensionTravel; //OFS: 0xA4 SIZE: 0x4 + int a; //OFS: 0xA8 SIZE: 0x4 + char turretWeapon[64]; //OFS: 0xAC SIZE: 0x40 + float turretHorizSpanLeft; //OFS: 0xEC SIZE: 0x4 + float turretHorizSpanRight; //OFS: 0xF0 SIZE: 0x4 + float turretVertSpanUp; //OFS: 0xF4 SIZE: 0x4 + float turretVertSpanDown; //OFS: 0xF8 SIZE: 0x4 + float turretRotRate; //OFS: 0xFC SIZE: 0x4 + int turretClampPlayerView; //OFS: 0x100 SIZE: 0x4 + char gunnerWeapon[4][64]; //OFS: 0x104 SIZE: 0x100 + unsigned __int8 gunnerWeaponIndex[4]; //OFS: 0x204 SIZE: 0x4 + float gunnerRotRate; //OFS: 0x208 SIZE: 0x4 + float gunnerRestAngles[4][2]; //OFS: 0x20C SIZE: 0x20 + char sndNames[20][64]; //OFS: 0x22C SIZE: 0x500 + unsigned __int16 sndIndices[20]; //OFS: 0x72C SIZE: 0x28 + float engineSndSpeed; //OFS: 0x754 SIZE: 0x4 + int wheelMtrlSndCounts[2]; //OFS: 0x758 SIZE: 0x8 + float engineModLoopNaturalRPMs; //OFS: 0x760 SIZE: 0x4 + float idleRPMs; //OFS: 0x764 SIZE: 0x4 + float gear1MinRPMs; //OFS: 0x768 SIZE: 0x4 + float gear1MaxRPMs; //OFS: 0x76C SIZE: 0x4 + float gearChangeMPH; //OFS: 0x770 SIZE: 0x4 + float gear2MinRPMs; //OFS: 0x774 SIZE: 0x4 + float gear2MaxRPMs; //OFS: 0x778 SIZE: 0x4 + float engineModLoopModRate; //OFS: 0x77C SIZE: 0x4 + float engineModLoopAttenuation; //OFS: 0x780 SIZE: 0x4 + float engineModLoopCrossfadeLoadScale; //OFS: 0x784 SIZE: 0x4 + float engineModLoopCrossfadeDamageScale; //OFS: 0x788 SIZE: 0x4 + int trackLengthInches; //OFS: 0x78C SIZE: 0x4 + float clacksCurveDamageStart; //OFS: 0x790 SIZE: 0x4 + float clacksCurveDamageEnd; //OFS: 0x794 SIZE: 0x4 + float clacksCurveMaxOmitted; //OFS: 0x798 SIZE: 0x4 + float treadGrindAttenuation; //OFS: 0x79C SIZE: 0x4 + float treadDamageLoopHealthRatio; //OFS: 0x7A0 SIZE: 0x4 + int animType; //OFS: 0x7A4 SIZE: 0x4 + char animSet[64]; //OFS: 0x7A8 SIZE: 0x40 + float mantleAngles[4]; //OFS: 0x7E8 SIZE: 0x10 + char pad[16]; //OFS: 0x7F8 SIZE: 0x10 + int isNitrous; //OFS: 0x808 SIZE: 0x4 + VehicleParameter nitrousVehParams; //OFS: 0x80C SIZE: 0xF0 + }; + ASSERT_STRUCT_SIZE(vehicle_info_t, 0x8FC); + ASSERT_STRUCT_OFFSET(vehicle_info_t, name, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_info_t, type, 0x40); + ASSERT_STRUCT_OFFSET(vehicle_info_t, steerWheels, 0x44); + ASSERT_STRUCT_OFFSET(vehicle_info_t, texScroll, 0x48); + ASSERT_STRUCT_OFFSET(vehicle_info_t, quadBarrel, 0x4C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, bulletDamage, 0x50); + ASSERT_STRUCT_OFFSET(vehicle_info_t, armorPiercingDamage, 0x54); + ASSERT_STRUCT_OFFSET(vehicle_info_t, grenadeDamage, 0x58); + ASSERT_STRUCT_OFFSET(vehicle_info_t, projectileDamage, 0x5C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, projectileSplashDamage, 0x60); + ASSERT_STRUCT_OFFSET(vehicle_info_t, heavyExplosiveDamage, 0x64); + ASSERT_STRUCT_OFFSET(vehicle_info_t, isDrivable, 0x68); + ASSERT_STRUCT_OFFSET(vehicle_info_t, numberOfSeats, 0x6C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, numberOfGunners, 0x70); + ASSERT_STRUCT_OFFSET(vehicle_info_t, noSwitchToDriver, 0x74); + ASSERT_STRUCT_OFFSET(vehicle_info_t, driverControlledGunPos, 0x78); + ASSERT_STRUCT_OFFSET(vehicle_info_t, texScrollScale, 0x7C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, wheelRotRate, 0x80); + ASSERT_STRUCT_OFFSET(vehicle_info_t, maxSpeed, 0x84); + ASSERT_STRUCT_OFFSET(vehicle_info_t, accel, 0x88); + ASSERT_STRUCT_OFFSET(vehicle_info_t, rotRate, 0x8C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, rotAccel, 0x90); + ASSERT_STRUCT_OFFSET(vehicle_info_t, maxBodyPitch, 0x94); + ASSERT_STRUCT_OFFSET(vehicle_info_t, maxBodyRoll, 0x98); + ASSERT_STRUCT_OFFSET(vehicle_info_t, collisionDamage, 0x9C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, collisionSpeed, 0xA0); + ASSERT_STRUCT_OFFSET(vehicle_info_t, suspensionTravel, 0xA4); + ASSERT_STRUCT_OFFSET(vehicle_info_t, a, 0xA8); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretWeapon, 0xAC); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretHorizSpanLeft, 0xEC); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretHorizSpanRight, 0xF0); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretVertSpanUp, 0xF4); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretVertSpanDown, 0xF8); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretRotRate, 0xFC); + ASSERT_STRUCT_OFFSET(vehicle_info_t, turretClampPlayerView, 0x100); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gunnerWeapon, 0x104); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gunnerWeaponIndex, 0x204); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gunnerRotRate, 0x208); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gunnerRestAngles, 0x20C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, sndNames, 0x22C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, sndIndices, 0x72C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineSndSpeed, 0x754); + ASSERT_STRUCT_OFFSET(vehicle_info_t, wheelMtrlSndCounts, 0x758); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineModLoopNaturalRPMs, 0x760); + ASSERT_STRUCT_OFFSET(vehicle_info_t, idleRPMs, 0x764); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gear1MinRPMs, 0x768); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gear1MaxRPMs, 0x76C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gearChangeMPH, 0x770); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gear2MinRPMs, 0x774); + ASSERT_STRUCT_OFFSET(vehicle_info_t, gear2MaxRPMs, 0x778); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineModLoopModRate, 0x77C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineModLoopAttenuation, 0x780); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineModLoopCrossfadeLoadScale, 0x784); + ASSERT_STRUCT_OFFSET(vehicle_info_t, engineModLoopCrossfadeDamageScale, 0x788); + ASSERT_STRUCT_OFFSET(vehicle_info_t, trackLengthInches, 0x78C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, clacksCurveDamageStart, 0x790); + ASSERT_STRUCT_OFFSET(vehicle_info_t, clacksCurveDamageEnd, 0x794); + ASSERT_STRUCT_OFFSET(vehicle_info_t, clacksCurveMaxOmitted, 0x798); + ASSERT_STRUCT_OFFSET(vehicle_info_t, treadGrindAttenuation, 0x79C); + ASSERT_STRUCT_OFFSET(vehicle_info_t, treadDamageLoopHealthRatio, 0x7A0); + ASSERT_STRUCT_OFFSET(vehicle_info_t, animType, 0x7A4); + ASSERT_STRUCT_OFFSET(vehicle_info_t, animSet, 0x7A8); + ASSERT_STRUCT_OFFSET(vehicle_info_t, mantleAngles, 0x7E8); + ASSERT_STRUCT_OFFSET(vehicle_info_t, pad, 0x7F8); + ASSERT_STRUCT_OFFSET(vehicle_info_t, isNitrous, 0x808); + ASSERT_STRUCT_OFFSET(vehicle_info_t, nitrousVehParams, 0x80C); + + struct PhysObjUserData + { + void * body; //OFS: 0x0 SIZE: 0x4 + NitrousVehicle * vehicle; //OFS: 0x4 SIZE: 0x4 + void * m_gjk_geom; //OFS: 0x8 SIZE: 0x4 + void * m_next_link; //OFS: 0xC SIZE: 0x4 + Mat43 cg2rb; //OFS: 0x10 SIZE: 0x40 + Mat43 cg2w; //OFS: 0x50 SIZE: 0x40 + void * m_bpb; //OFS: 0x90 SIZE: 0x4 + float savedPos[3]; //OFS: 0x94 SIZE: 0xC + float savedRot[3][3]; //OFS: 0xA0 SIZE: 0x24 + int sndClass; //OFS: 0xC4 SIZE: 0x4 + float friction; //OFS: 0xC8 SIZE: 0x4 + float bounce; //OFS: 0xCC SIZE: 0x4 + int id; //OFS: 0xD0 SIZE: 0x4 + int refcount; //OFS: 0xD4 SIZE: 0x4 + int underwater; //OFS: 0xD8 SIZE: 0x4 + int buoyancy; //OFS: 0xDC SIZE: 0x4 + int timeBuoyant; //OFS: 0xE0 SIZE: 0x4 + int timeRipple; //OFS: 0xE4 SIZE: 0x4 + unsigned __int16 trDuration; //OFS: 0xE8 SIZE: 0x2 + float m_time_since_last_event; //OFS: 0xEC SIZE: 0x4 + float m_time_since_last_reeval; //OFS: 0xF0 SIZE: 0x4 + int m_flags; //OFS: 0xF4 SIZE: 0x4 + float mass; //OFS: 0xF8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysObjUserData, 0xFC); + ASSERT_STRUCT_OFFSET(PhysObjUserData, body, 0x0); + ASSERT_STRUCT_OFFSET(PhysObjUserData, vehicle, 0x4); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_gjk_geom, 0x8); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_next_link, 0xC); + ASSERT_STRUCT_OFFSET(PhysObjUserData, cg2rb, 0x10); + ASSERT_STRUCT_OFFSET(PhysObjUserData, cg2w, 0x50); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_bpb, 0x90); + ASSERT_STRUCT_OFFSET(PhysObjUserData, savedPos, 0x94); + ASSERT_STRUCT_OFFSET(PhysObjUserData, savedRot, 0xA0); + ASSERT_STRUCT_OFFSET(PhysObjUserData, sndClass, 0xC4); + ASSERT_STRUCT_OFFSET(PhysObjUserData, friction, 0xC8); + ASSERT_STRUCT_OFFSET(PhysObjUserData, bounce, 0xCC); + ASSERT_STRUCT_OFFSET(PhysObjUserData, id, 0xD0); + ASSERT_STRUCT_OFFSET(PhysObjUserData, refcount, 0xD4); + ASSERT_STRUCT_OFFSET(PhysObjUserData, underwater, 0xD8); + ASSERT_STRUCT_OFFSET(PhysObjUserData, buoyancy, 0xDC); + ASSERT_STRUCT_OFFSET(PhysObjUserData, timeBuoyant, 0xE0); + ASSERT_STRUCT_OFFSET(PhysObjUserData, timeRipple, 0xE4); + ASSERT_STRUCT_OFFSET(PhysObjUserData, trDuration, 0xE8); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_time_since_last_event, 0xEC); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_time_since_last_reeval, 0xF0); + ASSERT_STRUCT_OFFSET(PhysObjUserData, m_flags, 0xF4); + ASSERT_STRUCT_OFFSET(PhysObjUserData, mass, 0xF8); + + struct NitrousVehicleController + { + Dir3 m_script_goal_position; //OFS: 0x0 SIZE: 0x10 + float m_script_goal_radius; //OFS: 0x10 SIZE: 0x4 + float m_script_goal_speed; //OFS: 0x14 SIZE: 0x4 + float m_stuck_time; //OFS: 0x18 SIZE: 0x4 + Dir3 m_stuck_position; //OFS: 0x1C SIZE: 0x10 + usercmd_s m_cmd; //OFS: 0x2C SIZE: 0x38 + int m_cmd_local_client_num; //OFS: 0x64 SIZE: 0x4 + bool m_cmd_valid; //OFS: 0x68 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(NitrousVehicleController, 0x6C); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_script_goal_position, 0x0); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_script_goal_radius, 0x10); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_script_goal_speed, 0x14); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_stuck_time, 0x18); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_stuck_position, 0x1C); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_cmd, 0x2C); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_cmd_local_client_num, 0x64); + ASSERT_STRUCT_OFFSET(NitrousVehicleController, m_cmd_valid, 0x68); + + struct NitrousVehicle + { + WheelEffectState m_wheel_effect_state[4]; //OFS: 0x0 SIZE: 0x10 + Mat43 m_wheel_orig_relpo[6]; //OFS: 0x10 SIZE: 0x180 + int m_wheel_damage[6]; //OFS: 0x190 SIZE: 0x18 + int m_wheel_surf_types[6]; //OFS: 0x1A8 SIZE: 0x18 + VehicleParameter * m_parameter; //OFS: 0x1C0 SIZE: 0x4 + float m_throttle; //OFS: 0x1C4 SIZE: 0x4 + float m_brake; //OFS: 0x1C8 SIZE: 0x4 + float m_hand_brake; //OFS: 0x1CC SIZE: 0x4 + float m_script_brake; //OFS: 0x1D0 SIZE: 0x4 + float m_steer_factor; //OFS: 0x1D4 SIZE: 0x4 + float m_forward_vel; //OFS: 0x1D8 SIZE: 0x4 + float m_hand_brake_friction_time; //OFS: 0x1DC SIZE: 0x4 + gentity_s * m_owner; //OFS: 0x1E0 SIZE: 0x4 + int m_entnum; //OFS: 0x1E4 SIZE: 0x4 + vehicle_info_t * m_vehicle_info; //OFS: 0x1E8 SIZE: 0x4 + PhysObjUserData * m_phys_user_data; //OFS: 0x1EC SIZE: 0x4 + XModel * m_xmodel; //OFS: 0x1F0 SIZE: 0x4 + float m_origin[3]; //OFS: 0x1F4 SIZE: 0xC + float m_angles[3]; //OFS: 0x200 SIZE: 0xC + void * m_orientation_constraint; //OFS: 0x20C SIZE: 0x4 + void * m_vpc; //OFS: 0x210 SIZE: 0x4 + int m_flags; //OFS: 0x214 SIZE: 0x4 + Mat43 m_prev_rb_mat; //OFS: 0x218 SIZE: 0x40 + NitrousVehicleController mVehicleController; //OFS: 0x258 SIZE: 0x6C + float m_fake_rpm; //OFS: 0x2C4 SIZE: 0x4 + int m_num_colliding_wheels; //OFS: 0x2C8 SIZE: 0x4 + float m_current_side_fric_scale; //OFS: 0x2CC SIZE: 0x4 + float m_current_fwd_fric_scale; //OFS: 0x2D0 SIZE: 0x4 + float m_stuck_time; //OFS: 0x2D4 SIZE: 0x4 + int m_lastNetworkTime; //OFS: 0x2D8 SIZE: 0x4 + int m_lastErrorReductionTime; //OFS: 0x2DC SIZE: 0x4 + float m_networkErrorOrigin[3]; //OFS: 0x2E0 SIZE: 0xC + float m_networkErrorAngles[3]; //OFS: 0x2EC SIZE: 0xC + int m_trackDistAccumLeftInches; //OFS: 0x2F8 SIZE: 0x4 + int m_trackDistAccumRightInches; //OFS: 0x2FC SIZE: 0x4 + int m_sfx_state_flags; //OFS: 0x300 SIZE: 0x4 + float m_speed_scale; //OFS: 0x304 SIZE: 0x4 + int m_boost_start_time; //OFS: 0x308 SIZE: 0x4 + int b[3]; //OFS: 0x30C SIZE: 0xC + int id; //OFS: 0x318 SIZE: 0x4 + int refcount; //OFS: 0x31C SIZE: 0x4 + void * m_wheels[6]; //OFS: 0x320 SIZE: 0x18 + float m_desired_speed_factor; //OFS: 0x338 SIZE: 0x4 + float m_acceleration_factor; //OFS: 0x33C SIZE: 0x4 + float m_power_braking_factor; //OFS: 0x340 SIZE: 0x4 + float m_braking_factor; //OFS: 0x344 SIZE: 0x4 + float m_coasting_factor; //OFS: 0x348 SIZE: 0x4 + float m_reference_wheel_radius; //OFS: 0x34C SIZE: 0x4 + float m_steer_current_angle; //OFS: 0x350 SIZE: 0x4 + float m_steer_max_angle; //OFS: 0x354 SIZE: 0x4 + float m_steer_speed; //OFS: 0x358 SIZE: 0x4 + Dir3 m_steer_front_pt_loc; //OFS: 0x35C SIZE: 0x10 + float m_steer_front_back_length; //OFS: 0x36C SIZE: 0x4 + unsigned int m_state_flags; //OFS: 0x370 SIZE: 0x4 + void * m_vci; //OFS: 0x374 SIZE: 0x4 + int a[2]; //OFS: 0x378 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(NitrousVehicle, 0x380); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_wheel_effect_state, 0x0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_wheel_orig_relpo, 0x10); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_wheel_damage, 0x190); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_wheel_surf_types, 0x1A8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_parameter, 0x1C0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_throttle, 0x1C4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_brake, 0x1C8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_hand_brake, 0x1CC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_script_brake, 0x1D0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_factor, 0x1D4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_forward_vel, 0x1D8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_hand_brake_friction_time, 0x1DC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_owner, 0x1E0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_entnum, 0x1E4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_vehicle_info, 0x1E8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_phys_user_data, 0x1EC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_xmodel, 0x1F0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_origin, 0x1F4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_angles, 0x200); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_orientation_constraint, 0x20C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_vpc, 0x210); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_flags, 0x214); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_prev_rb_mat, 0x218); + ASSERT_STRUCT_OFFSET(NitrousVehicle, mVehicleController, 0x258); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_fake_rpm, 0x2C4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_num_colliding_wheels, 0x2C8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_current_side_fric_scale, 0x2CC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_current_fwd_fric_scale, 0x2D0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_stuck_time, 0x2D4); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_lastNetworkTime, 0x2D8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_lastErrorReductionTime, 0x2DC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_networkErrorOrigin, 0x2E0); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_networkErrorAngles, 0x2EC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_trackDistAccumLeftInches, 0x2F8); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_trackDistAccumRightInches, 0x2FC); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_sfx_state_flags, 0x300); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_speed_scale, 0x304); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_boost_start_time, 0x308); + ASSERT_STRUCT_OFFSET(NitrousVehicle, b, 0x30C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, id, 0x318); + ASSERT_STRUCT_OFFSET(NitrousVehicle, refcount, 0x31C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_wheels, 0x320); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_desired_speed_factor, 0x338); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_acceleration_factor, 0x33C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_power_braking_factor, 0x340); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_braking_factor, 0x344); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_coasting_factor, 0x348); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_reference_wheel_radius, 0x34C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_current_angle, 0x350); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_max_angle, 0x354); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_speed, 0x358); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_front_pt_loc, 0x35C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_steer_front_back_length, 0x36C); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_state_flags, 0x370); + ASSERT_STRUCT_OFFSET(NitrousVehicle, m_vci, 0x374); + ASSERT_STRUCT_OFFSET(NitrousVehicle, a, 0x378); + + struct __declspec(align(8)) vehicle_cache_t + { + float lastOrigin[3]; //OFS: 0x0 SIZE: 0xC + float lastAngles[3]; //OFS: 0xC SIZE: 0xC + int hit_indices[6]; //OFS: 0x18 SIZE: 0x18 + int hit_sflags[6]; //OFS: 0x30 SIZE: 0x18 + float hit_normals[6][3]; //OFS: 0x48 SIZE: 0x48 + float hit_fractions[6]; //OFS: 0x90 SIZE: 0x18 + colgeom_visitor_inlined_t proximity_data; //OFS: 0xA8 SIZE: 0x6B4 + int wheel_mask; //OFS: 0x75C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vehicle_cache_t, 0x760); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, lastOrigin, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, lastAngles, 0xC); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, hit_indices, 0x18); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, hit_sflags, 0x30); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, hit_normals, 0x48); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, hit_fractions, 0x90); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, proximity_data, 0xA8); + ASSERT_STRUCT_OFFSET(vehicle_cache_t, wheel_mask, 0x75C); + + struct __declspec(align(8)) scr_vehicle_s + { + vehicle_pathpos_t pathPos; //OFS: 0x0 SIZE: 0xC0 + vehicle_physic_t phys; //OFS: 0xC0 SIZE: 0x108 + int entNum; //OFS: 0x1C8 SIZE: 0x4 + __int16 infoIdx; //OFS: 0x1CC SIZE: 0x2 + int flags; //OFS: 0x1D0 SIZE: 0x4 + int team; //OFS: 0x1D4 SIZE: 0x4 + VehicleMoveState moveState; //OFS: 0x1D8 SIZE: 0x4 + __int16 waitNode; //OFS: 0x1DC SIZE: 0x2 + float waitSpeed; //OFS: 0x1E0 SIZE: 0x4 + VehicleTurret turret; //OFS: 0x1E4 SIZE: 0x1C + float turretRotScale; //OFS: 0x200 SIZE: 0x4 + VehicleJitter jitter; //OFS: 0x204 SIZE: 0x3C + VehicleHover hover; //OFS: 0x240 SIZE: 0x1C + VehicleTurret gunnerTurrets[4]; //OFS: 0x25C SIZE: 0x70 + VehicleJitter gunnerJitter[4]; //OFS: 0x2CC SIZE: 0xF0 + unsigned __int16 lookAtText0; //OFS: 0x3BC SIZE: 0x2 + unsigned __int16 lookAtText1; //OFS: 0x3BE SIZE: 0x2 + int manualMode; //OFS: 0x3C0 SIZE: 0x4 + float manualSpeed; //OFS: 0x3C4 SIZE: 0x4 + float manualAccel; //OFS: 0x3C8 SIZE: 0x4 + float manualDecel; //OFS: 0x3CC SIZE: 0x4 + float manualTime; //OFS: 0x3D0 SIZE: 0x4 + float speed; //OFS: 0x3D4 SIZE: 0x4 + float maxSpeedOverride; //OFS: 0x3D8 SIZE: 0x4 + float maxDragSpeed; //OFS: 0x3DC SIZE: 0x4 + float turningAbility; //OFS: 0x3E0 SIZE: 0x4 + int hasTarget; //OFS: 0x3E4 SIZE: 0x4 + int hasTargetYaw; //OFS: 0x3E8 SIZE: 0x4 + int hasGoalYaw; //OFS: 0x3EC SIZE: 0x4 + int stopAtGoal; //OFS: 0x3F0 SIZE: 0x4 + int stopping; //OFS: 0x3F4 SIZE: 0x4 + int targetEnt; //OFS: 0x3F8 SIZE: 0x4 + EntHandle lookAtEnt; //OFS: 0x3FC SIZE: 0x4 + float targetOrigin[3]; //OFS: 0x400 SIZE: 0xC + float targetOffset[3]; //OFS: 0x40C SIZE: 0xC + float targetYaw; //OFS: 0x418 SIZE: 0x4 + float goalPosition[3]; //OFS: 0x41C SIZE: 0xC + float goalYaw; //OFS: 0x428 SIZE: 0x4 + float prevGoalYaw; //OFS: 0x42C SIZE: 0x4 + float yawOverShoot; //OFS: 0x430 SIZE: 0x4 + int yawSlowDown; //OFS: 0x434 SIZE: 0x4 + float hasGoalRoll; //OFS: 0x438 SIZE: 0x4 + float goalRoll; //OFS: 0x43C SIZE: 0x4 + float goalRollTime; //OFS: 0x440 SIZE: 0x4 + float currentRollTime; //OFS: 0x444 SIZE: 0x4 + int numRolls; //OFS: 0x448 SIZE: 0x4 + VehicleTarget gunnerTargets[4]; //OFS: 0x44C SIZE: 0xB0 + float nearGoalNotifyDist; //OFS: 0x4FC SIZE: 0x4 + float joltDir[2]; //OFS: 0x500 SIZE: 0x8 + float joltTime; //OFS: 0x508 SIZE: 0x4 + float joltWave; //OFS: 0x50C SIZE: 0x4 + float joltSpeed; //OFS: 0x510 SIZE: 0x4 + float joltDecel; //OFS: 0x514 SIZE: 0x4 + VehicleTags boneIndex; //OFS: 0x518 SIZE: 0xBC + int turretHitNum; //OFS: 0x5D4 SIZE: 0x4 + VehicleSeat seats[8]; //OFS: 0x5D8 SIZE: 0x20 + float forcedMaterialSpeed; //OFS: 0x5F8 SIZE: 0x4 + NitrousVehicle * nitrousVehicle; //OFS: 0x5FC SIZE: 0x4 + vehicle_cache_t vehicle_cache; //OFS: 0x600 SIZE: 0x760 + }; + ASSERT_STRUCT_SIZE(scr_vehicle_s, 0xD60); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, pathPos, 0x0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, phys, 0xC0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, entNum, 0x1C8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, infoIdx, 0x1CC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, flags, 0x1D0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, team, 0x1D4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, moveState, 0x1D8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, waitNode, 0x1DC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, waitSpeed, 0x1E0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, turret, 0x1E4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, turretRotScale, 0x200); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, jitter, 0x204); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, hover, 0x240); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, gunnerTurrets, 0x25C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, gunnerJitter, 0x2CC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, lookAtText0, 0x3BC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, lookAtText1, 0x3BE); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, manualMode, 0x3C0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, manualSpeed, 0x3C4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, manualAccel, 0x3C8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, manualDecel, 0x3CC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, manualTime, 0x3D0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, speed, 0x3D4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, maxSpeedOverride, 0x3D8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, maxDragSpeed, 0x3DC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, turningAbility, 0x3E0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, hasTarget, 0x3E4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, hasTargetYaw, 0x3E8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, hasGoalYaw, 0x3EC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, stopAtGoal, 0x3F0); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, stopping, 0x3F4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, targetEnt, 0x3F8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, lookAtEnt, 0x3FC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, targetOrigin, 0x400); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, targetOffset, 0x40C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, targetYaw, 0x418); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, goalPosition, 0x41C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, goalYaw, 0x428); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, prevGoalYaw, 0x42C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, yawOverShoot, 0x430); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, yawSlowDown, 0x434); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, hasGoalRoll, 0x438); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, goalRoll, 0x43C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, goalRollTime, 0x440); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, currentRollTime, 0x444); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, numRolls, 0x448); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, gunnerTargets, 0x44C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, nearGoalNotifyDist, 0x4FC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, joltDir, 0x500); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, joltTime, 0x508); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, joltWave, 0x50C); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, joltSpeed, 0x510); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, joltDecel, 0x514); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, boneIndex, 0x518); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, turretHitNum, 0x5D4); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, seats, 0x5D8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, forcedMaterialSpeed, 0x5F8); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, nitrousVehicle, 0x5FC); + ASSERT_STRUCT_OFFSET(scr_vehicle_s, vehicle_cache, 0x600); + + struct TurretInfo + { + bool inuse; //OFS: 0x0 SIZE: 0x1 + int state; //OFS: 0x4 SIZE: 0x4 + int flags; //OFS: 0x8 SIZE: 0x4 + int fireTime; //OFS: 0xC SIZE: 0x4 + EntHandle manualTarget; //OFS: 0x10 SIZE: 0x4 + EntHandle target; //OFS: 0x14 SIZE: 0x4 + float targetPos[3]; //OFS: 0x18 SIZE: 0xC + int targetTime; //OFS: 0x24 SIZE: 0x4 + float missOffsetNormalized[3]; //OFS: 0x28 SIZE: 0xC + float arcmin[2]; //OFS: 0x34 SIZE: 0x8 + float arcmax[2]; //OFS: 0x3C SIZE: 0x8 + float initialYawmin; //OFS: 0x44 SIZE: 0x4 + float initialYawmax; //OFS: 0x48 SIZE: 0x4 + float forwardAngleDot; //OFS: 0x4C SIZE: 0x4 + float dropPitch; //OFS: 0x50 SIZE: 0x4 + int convergenceTime[2]; //OFS: 0x54 SIZE: 0x8 + int suppressTime; //OFS: 0x5C SIZE: 0x4 + float maxRangeSquared; //OFS: 0x60 SIZE: 0x4 + SentientHandle detachSentient; //OFS: 0x64 SIZE: 0x4 + int stance; //OFS: 0x68 SIZE: 0x4 + int prevStance; //OFS: 0x6C SIZE: 0x4 + int fireSndDelay; //OFS: 0x70 SIZE: 0x4 + float accuracy; //OFS: 0x74 SIZE: 0x4 + float userOrigin[3]; //OFS: 0x78 SIZE: 0xC + int prevSentTarget; //OFS: 0x84 SIZE: 0x4 + float aiSpread; //OFS: 0x88 SIZE: 0x4 + float playerSpread; //OFS: 0x8C SIZE: 0x4 + team_t eTeam; //OFS: 0x90 SIZE: 0x4 + float heatVal; //OFS: 0x94 SIZE: 0x4 + bool overheating; //OFS: 0x98 SIZE: 0x1 + float originError[3]; //OFS: 0x9C SIZE: 0xC + float anglesError[3]; //OFS: 0xA8 SIZE: 0xC + float pitchCap; //OFS: 0xB4 SIZE: 0x4 + int triggerDown; //OFS: 0xB8 SIZE: 0x4 + unsigned __int16 fireSnd; //OFS: 0xBC SIZE: 0x2 + unsigned __int16 fireSndPlayer; //OFS: 0xBE SIZE: 0x2 + unsigned __int16 stopSnd; //OFS: 0xC0 SIZE: 0x2 + unsigned __int16 stopSndPlayer; //OFS: 0xC2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(TurretInfo, 0xC4); + ASSERT_STRUCT_OFFSET(TurretInfo, inuse, 0x0); + ASSERT_STRUCT_OFFSET(TurretInfo, state, 0x4); + ASSERT_STRUCT_OFFSET(TurretInfo, flags, 0x8); + ASSERT_STRUCT_OFFSET(TurretInfo, fireTime, 0xC); + ASSERT_STRUCT_OFFSET(TurretInfo, manualTarget, 0x10); + ASSERT_STRUCT_OFFSET(TurretInfo, target, 0x14); + ASSERT_STRUCT_OFFSET(TurretInfo, targetPos, 0x18); + ASSERT_STRUCT_OFFSET(TurretInfo, targetTime, 0x24); + ASSERT_STRUCT_OFFSET(TurretInfo, missOffsetNormalized, 0x28); + ASSERT_STRUCT_OFFSET(TurretInfo, arcmin, 0x34); + ASSERT_STRUCT_OFFSET(TurretInfo, arcmax, 0x3C); + ASSERT_STRUCT_OFFSET(TurretInfo, initialYawmin, 0x44); + ASSERT_STRUCT_OFFSET(TurretInfo, initialYawmax, 0x48); + ASSERT_STRUCT_OFFSET(TurretInfo, forwardAngleDot, 0x4C); + ASSERT_STRUCT_OFFSET(TurretInfo, dropPitch, 0x50); + ASSERT_STRUCT_OFFSET(TurretInfo, convergenceTime, 0x54); + ASSERT_STRUCT_OFFSET(TurretInfo, suppressTime, 0x5C); + ASSERT_STRUCT_OFFSET(TurretInfo, maxRangeSquared, 0x60); + ASSERT_STRUCT_OFFSET(TurretInfo, detachSentient, 0x64); + ASSERT_STRUCT_OFFSET(TurretInfo, stance, 0x68); + ASSERT_STRUCT_OFFSET(TurretInfo, prevStance, 0x6C); + ASSERT_STRUCT_OFFSET(TurretInfo, fireSndDelay, 0x70); + ASSERT_STRUCT_OFFSET(TurretInfo, accuracy, 0x74); + ASSERT_STRUCT_OFFSET(TurretInfo, userOrigin, 0x78); + ASSERT_STRUCT_OFFSET(TurretInfo, prevSentTarget, 0x84); + ASSERT_STRUCT_OFFSET(TurretInfo, aiSpread, 0x88); + ASSERT_STRUCT_OFFSET(TurretInfo, playerSpread, 0x8C); + ASSERT_STRUCT_OFFSET(TurretInfo, eTeam, 0x90); + ASSERT_STRUCT_OFFSET(TurretInfo, heatVal, 0x94); + ASSERT_STRUCT_OFFSET(TurretInfo, overheating, 0x98); + ASSERT_STRUCT_OFFSET(TurretInfo, originError, 0x9C); + ASSERT_STRUCT_OFFSET(TurretInfo, anglesError, 0xA8); + ASSERT_STRUCT_OFFSET(TurretInfo, pitchCap, 0xB4); + ASSERT_STRUCT_OFFSET(TurretInfo, triggerDown, 0xB8); + ASSERT_STRUCT_OFFSET(TurretInfo, fireSnd, 0xBC); + ASSERT_STRUCT_OFFSET(TurretInfo, fireSndPlayer, 0xBE); + ASSERT_STRUCT_OFFSET(TurretInfo, stopSnd, 0xC0); + ASSERT_STRUCT_OFFSET(TurretInfo, stopSndPlayer, 0xC2); + + struct DestructibleBurnData + { + int burnTime; //OFS: 0x0 SIZE: 0x4 + unsigned int fx; //OFS: 0x4 SIZE: 0x4 + int sndId; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DestructibleBurnData, 0xC); + ASSERT_STRUCT_OFFSET(DestructibleBurnData, burnTime, 0x0); + ASSERT_STRUCT_OFFSET(DestructibleBurnData, fx, 0x4); + ASSERT_STRUCT_OFFSET(DestructibleBurnData, sndId, 0x8); + + struct Destructible + { + int entNum; //OFS: 0x0 SIZE: 0x4 + __int16 pieceHealth[32]; //OFS: 0x4 SIZE: 0x40 + int xdollHandles[32]; //OFS: 0x44 SIZE: 0x80 + DestructibleBurnData burnData[32]; //OFS: 0xC4 SIZE: 0x180 + int oldestBurnTime; //OFS: 0x244 SIZE: 0x4 + unsigned __int8 clientNum; //OFS: 0x248 SIZE: 0x1 + unsigned __int8 destructiblePoseID; //OFS: 0x249 SIZE: 0x1 + DestructibleDef * ddef; //OFS: 0x24C SIZE: 0x4 + unsigned int flags; //OFS: 0x250 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Destructible, 0x254); + ASSERT_STRUCT_OFFSET(Destructible, entNum, 0x0); + ASSERT_STRUCT_OFFSET(Destructible, pieceHealth, 0x4); + ASSERT_STRUCT_OFFSET(Destructible, xdollHandles, 0x44); + ASSERT_STRUCT_OFFSET(Destructible, burnData, 0xC4); + ASSERT_STRUCT_OFFSET(Destructible, oldestBurnTime, 0x244); + ASSERT_STRUCT_OFFSET(Destructible, clientNum, 0x248); + ASSERT_STRUCT_OFFSET(Destructible, destructiblePoseID, 0x249); + ASSERT_STRUCT_OFFSET(Destructible, ddef, 0x24C); + ASSERT_STRUCT_OFFSET(Destructible, flags, 0x250); + + struct flame_timed_damage_t + { + gentity_s * attacker; //OFS: 0x0 SIZE: 0x4 + int damage; //OFS: 0x4 SIZE: 0x4 + float damageDuration; //OFS: 0x8 SIZE: 0x4 + float damageInterval; //OFS: 0xC SIZE: 0x4 + int start_timestamp; //OFS: 0x10 SIZE: 0x4 + int end_timestamp; //OFS: 0x14 SIZE: 0x4 + int lastupdate_timestamp; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flame_timed_damage_t, 0x1C); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, attacker, 0x0); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, damage, 0x4); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, damageDuration, 0x8); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, damageInterval, 0xC); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, start_timestamp, 0x10); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, end_timestamp, 0x14); + ASSERT_STRUCT_OFFSET(flame_timed_damage_t, lastupdate_timestamp, 0x18); + + struct missile_ent_t + { + float predictLandPos[3]; //OFS: 0x0 SIZE: 0xC + int predictLandTime; //OFS: 0xC SIZE: 0x4 + int timestamp; //OFS: 0x10 SIZE: 0x4 + float time; //OFS: 0x14 SIZE: 0x4 + int timeOfBirth; //OFS: 0x18 SIZE: 0x4 + float travelDist; //OFS: 0x1C SIZE: 0x4 + float surfaceNormal[3]; //OFS: 0x20 SIZE: 0xC + team_t team; //OFS: 0x2C SIZE: 0x4 + int thrownBack; //OFS: 0x30 SIZE: 0x4 + float curvature[3]; //OFS: 0x34 SIZE: 0xC + float targetOffset[3]; //OFS: 0x40 SIZE: 0xC + MissileStage stage; //OFS: 0x4C SIZE: 0x4 + MissileFlightMode flightMode; //OFS: 0x50 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(missile_ent_t, 0x54); + ASSERT_STRUCT_OFFSET(missile_ent_t, predictLandPos, 0x0); + ASSERT_STRUCT_OFFSET(missile_ent_t, predictLandTime, 0xC); + ASSERT_STRUCT_OFFSET(missile_ent_t, timestamp, 0x10); + ASSERT_STRUCT_OFFSET(missile_ent_t, time, 0x14); + ASSERT_STRUCT_OFFSET(missile_ent_t, timeOfBirth, 0x18); + ASSERT_STRUCT_OFFSET(missile_ent_t, travelDist, 0x1C); + ASSERT_STRUCT_OFFSET(missile_ent_t, surfaceNormal, 0x20); + ASSERT_STRUCT_OFFSET(missile_ent_t, team, 0x2C); + ASSERT_STRUCT_OFFSET(missile_ent_t, thrownBack, 0x30); + ASSERT_STRUCT_OFFSET(missile_ent_t, curvature, 0x34); + ASSERT_STRUCT_OFFSET(missile_ent_t, targetOffset, 0x40); + ASSERT_STRUCT_OFFSET(missile_ent_t, stage, 0x4C); + ASSERT_STRUCT_OFFSET(missile_ent_t, flightMode, 0x50); + + struct mover_ent_t + { + float decelTime; //OFS: 0x0 SIZE: 0x4 + float aDecelTime; //OFS: 0x4 SIZE: 0x4 + float speed; //OFS: 0x8 SIZE: 0x4 + float aSpeed; //OFS: 0xC SIZE: 0x4 + float midTime; //OFS: 0x10 SIZE: 0x4 + float aMidTime; //OFS: 0x14 SIZE: 0x4 + float pos1[3]; //OFS: 0x18 SIZE: 0xC + float pos2[3]; //OFS: 0x24 SIZE: 0xC + float pos3[3]; //OFS: 0x30 SIZE: 0xC + float apos1[3]; //OFS: 0x3C SIZE: 0xC + float apos2[3]; //OFS: 0x48 SIZE: 0xC + float apos3[3]; //OFS: 0x54 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(mover_ent_t, 0x60); + ASSERT_STRUCT_OFFSET(mover_ent_t, decelTime, 0x0); + ASSERT_STRUCT_OFFSET(mover_ent_t, aDecelTime, 0x4); + ASSERT_STRUCT_OFFSET(mover_ent_t, speed, 0x8); + ASSERT_STRUCT_OFFSET(mover_ent_t, aSpeed, 0xC); + ASSERT_STRUCT_OFFSET(mover_ent_t, midTime, 0x10); + ASSERT_STRUCT_OFFSET(mover_ent_t, aMidTime, 0x14); + ASSERT_STRUCT_OFFSET(mover_ent_t, pos1, 0x18); + ASSERT_STRUCT_OFFSET(mover_ent_t, pos2, 0x24); + ASSERT_STRUCT_OFFSET(mover_ent_t, pos3, 0x30); + ASSERT_STRUCT_OFFSET(mover_ent_t, apos1, 0x3C); + ASSERT_STRUCT_OFFSET(mover_ent_t, apos2, 0x48); + ASSERT_STRUCT_OFFSET(mover_ent_t, apos3, 0x54); + + struct trigger_ent_t + { + int threshold; //OFS: 0x0 SIZE: 0x4 + int accumulate; //OFS: 0x4 SIZE: 0x4 + int timestamp; //OFS: 0x8 SIZE: 0x4 + int singleUserEntIndex; //OFS: 0xC SIZE: 0x4 + bool requireLookAt; //OFS: 0x10 SIZE: 0x1 + int exposureIndex; //OFS: 0x14 SIZE: 0x4 + float exposureLerpToLighter; //OFS: 0x18 SIZE: 0x4 + float exposureLerpToDarker; //OFS: 0x1C SIZE: 0x4 + float exposureFeather[3]; //OFS: 0x20 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(trigger_ent_t, 0x2C); + ASSERT_STRUCT_OFFSET(trigger_ent_t, threshold, 0x0); + ASSERT_STRUCT_OFFSET(trigger_ent_t, accumulate, 0x4); + ASSERT_STRUCT_OFFSET(trigger_ent_t, timestamp, 0x8); + ASSERT_STRUCT_OFFSET(trigger_ent_t, singleUserEntIndex, 0xC); + ASSERT_STRUCT_OFFSET(trigger_ent_t, requireLookAt, 0x10); + ASSERT_STRUCT_OFFSET(trigger_ent_t, exposureIndex, 0x14); + ASSERT_STRUCT_OFFSET(trigger_ent_t, exposureLerpToLighter, 0x18); + ASSERT_STRUCT_OFFSET(trigger_ent_t, exposureLerpToDarker, 0x1C); + ASSERT_STRUCT_OFFSET(trigger_ent_t, exposureFeather, 0x20); + + union gentity_u + { + missile_ent_t missile; //OFS: 0x0 SIZE: 0x54 + mover_ent_t mover; //OFS: 0x1 SIZE: 0x60 + trigger_ent_t trigger; //OFS: 0x2 SIZE: 0x2C + }; + ASSERT_STRUCT_SIZE(gentity_u, 0x60); + + struct snd_wait_t + { + unsigned __int16 notifyString; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 index; //OFS: 0x2 SIZE: 0x2 + unsigned __int8 stoppable; //OFS: 0x4 SIZE: 0x1 + int basetime; //OFS: 0x8 SIZE: 0x4 + int duration; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_wait_t, 0x10); + ASSERT_STRUCT_OFFSET(snd_wait_t, notifyString, 0x0); + ASSERT_STRUCT_OFFSET(snd_wait_t, index, 0x2); + ASSERT_STRUCT_OFFSET(snd_wait_t, stoppable, 0x4); + ASSERT_STRUCT_OFFSET(snd_wait_t, basetime, 0x8); + ASSERT_STRUCT_OFFSET(snd_wait_t, duration, 0xC); + + struct tagInfo_s + { + gentity_s * parent; //OFS: 0x0 SIZE: 0x4 + gentity_s * next; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 name; //OFS: 0x8 SIZE: 0x2 + int index; //OFS: 0xC SIZE: 0x4 + float axis[4][3]; //OFS: 0x10 SIZE: 0x30 + float parentInvAxis[4][3]; //OFS: 0x40 SIZE: 0x30 + }; + ASSERT_STRUCT_SIZE(tagInfo_s, 0x70); + ASSERT_STRUCT_OFFSET(tagInfo_s, parent, 0x0); + ASSERT_STRUCT_OFFSET(tagInfo_s, next, 0x4); + ASSERT_STRUCT_OFFSET(tagInfo_s, name, 0x8); + ASSERT_STRUCT_OFFSET(tagInfo_s, index, 0xC); + ASSERT_STRUCT_OFFSET(tagInfo_s, axis, 0x10); + ASSERT_STRUCT_OFFSET(tagInfo_s, parentInvAxis, 0x40); + + struct animscripted_s + { + float axis[4][3]; //OFS: 0x0 SIZE: 0x30 + float originError[3]; //OFS: 0x30 SIZE: 0xC + float anglesError[3]; //OFS: 0x3C SIZE: 0xC + unsigned __int16 anim; //OFS: 0x48 SIZE: 0x2 + unsigned __int16 root; //OFS: 0x4A SIZE: 0x2 + unsigned __int8 bStarted; //OFS: 0x4C SIZE: 0x1 + unsigned __int8 mode; //OFS: 0x4D SIZE: 0x1 + int startTime; //OFS: 0x50 SIZE: 0x4 + float fHeightOfs; //OFS: 0x54 SIZE: 0x4 + float fEndPitch; //OFS: 0x58 SIZE: 0x4 + float fEndRoll; //OFS: 0x5C SIZE: 0x4 + float fOrientLerp; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animscripted_s, 0x64); + ASSERT_STRUCT_OFFSET(animscripted_s, axis, 0x0); + ASSERT_STRUCT_OFFSET(animscripted_s, originError, 0x30); + ASSERT_STRUCT_OFFSET(animscripted_s, anglesError, 0x3C); + ASSERT_STRUCT_OFFSET(animscripted_s, anim, 0x48); + ASSERT_STRUCT_OFFSET(animscripted_s, root, 0x4A); + ASSERT_STRUCT_OFFSET(animscripted_s, bStarted, 0x4C); + ASSERT_STRUCT_OFFSET(animscripted_s, mode, 0x4D); + ASSERT_STRUCT_OFFSET(animscripted_s, startTime, 0x50); + ASSERT_STRUCT_OFFSET(animscripted_s, fHeightOfs, 0x54); + ASSERT_STRUCT_OFFSET(animscripted_s, fEndPitch, 0x58); + ASSERT_STRUCT_OFFSET(animscripted_s, fEndRoll, 0x5C); + ASSERT_STRUCT_OFFSET(animscripted_s, fOrientLerp, 0x60); + + struct __declspec(align(8)) gentity_s + { + entityState_s s; //OFS: 0x0 SIZE: 0x118 + entityShared_s r; //OFS: 0x118 SIZE: 0x68 + gclient_s * client; //OFS: 0x180 SIZE: 0x4 + actor_s * actor; //OFS: 0x184 SIZE: 0x4 + sentient_s * sentient; //OFS: 0x188 SIZE: 0x4 + scr_vehicle_s * scr_vehicle; //OFS: 0x18C SIZE: 0x4 + TurretInfo * pTurretInfo; //OFS: 0x190 SIZE: 0x4 + Destructible * destructible; //OFS: 0x194 SIZE: 0x4 + unsigned __int16 model; //OFS: 0x198 SIZE: 0x2 + unsigned __int8 physicsObject; //OFS: 0x19A SIZE: 0x1 + unsigned __int8 takedamage; //OFS: 0x19B SIZE: 0x1 + unsigned __int8 active; //OFS: 0x19C SIZE: 0x1 + unsigned __int8 nopickup; //OFS: 0x19D SIZE: 0x1 + unsigned __int8 handler; //OFS: 0x19E SIZE: 0x1 + unsigned __int16 classname; //OFS: 0x1A0 SIZE: 0x2 + unsigned __int16 script_linkName; //OFS: 0x1A2 SIZE: 0x2 + unsigned __int16 script_noteworthy; //OFS: 0x1A4 SIZE: 0x2 + unsigned __int16 target; //OFS: 0x1A6 SIZE: 0x2 + int targetname; //OFS: 0x1A8 SIZE: 0x4 + int spawnflags2; //OFS: 0x1AC SIZE: 0x4 + int spawnflags; //OFS: 0x1B0 SIZE: 0x4 + int flags; //OFS: 0x1B4 SIZE: 0x4 + int clipmask; //OFS: 0x1B8 SIZE: 0x4 + int processedFrame; //OFS: 0x1BC SIZE: 0x4 + EntHandle parent; //OFS: 0x1C0 SIZE: 0x4 + int nextthink; //OFS: 0x1C4 SIZE: 0x4 + int health; //OFS: 0x1C8 SIZE: 0x4 + int maxhealth; //OFS: 0x1CC SIZE: 0x4 + int nexteq; //OFS: 0x1D0 SIZE: 0x4 + int damage; //OFS: 0x1D4 SIZE: 0x4 + flame_timed_damage_t flame_timed_damage[4]; //OFS: 0x1D8 SIZE: 0x70 + int last_timed_radius_damage; //OFS: 0x248 SIZE: 0x4 + int count; //OFS: 0x24C SIZE: 0x4 + gentity_s * chain; //OFS: 0x250 SIZE: 0x4 + gentity_s * activator; //OFS: 0x254 SIZE: 0x4 + gentity_u u; //OFS: 0x258 SIZE: 0x60 + EntHandle missileTargetEnt; //OFS: 0x2B8 SIZE: 0x4 + __int16 lookAtText0; //OFS: 0x2BC SIZE: 0x2 + __int16 lookAtText1; //OFS: 0x2BE SIZE: 0x2 + snd_wait_t snd_wait; //OFS: 0x2C0 SIZE: 0x10 + tagInfo_s * tagInfo; //OFS: 0x2D0 SIZE: 0x4 + gentity_s * tagChildren; //OFS: 0x2D4 SIZE: 0x4 + animscripted_s * scripted; //OFS: 0x2D8 SIZE: 0x4 + __int16 attachTagNames[31]; //OFS: 0x2DC SIZE: 0x3E + __int16 attachModelNames[31]; //OFS: 0x31A SIZE: 0x3E + int disconnectedLinks; //OFS: 0x358 SIZE: 0x4 + int iDisconnectTime; //OFS: 0x35C SIZE: 0x4 + float angleLerpRate; //OFS: 0x360 SIZE: 0x4 + int physObjId; //OFS: 0x364 SIZE: 0x4 + XAnimTree_s * pAnimTree; //OFS: 0x368 SIZE: 0x4 + gentity_s * nextFree; //OFS: 0x36C SIZE: 0x4 + int scriptUse; //OFS: 0x370 SIZE: 0x4 + int birthTime; //OFS: 0x374 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(gentity_s, 0x378); + ASSERT_STRUCT_OFFSET(gentity_s, s, 0x0); + ASSERT_STRUCT_OFFSET(gentity_s, r, 0x118); + ASSERT_STRUCT_OFFSET(gentity_s, client, 0x180); + ASSERT_STRUCT_OFFSET(gentity_s, actor, 0x184); + ASSERT_STRUCT_OFFSET(gentity_s, sentient, 0x188); + ASSERT_STRUCT_OFFSET(gentity_s, scr_vehicle, 0x18C); + ASSERT_STRUCT_OFFSET(gentity_s, pTurretInfo, 0x190); + ASSERT_STRUCT_OFFSET(gentity_s, destructible, 0x194); + ASSERT_STRUCT_OFFSET(gentity_s, model, 0x198); + ASSERT_STRUCT_OFFSET(gentity_s, physicsObject, 0x19A); + ASSERT_STRUCT_OFFSET(gentity_s, takedamage, 0x19B); + ASSERT_STRUCT_OFFSET(gentity_s, active, 0x19C); + ASSERT_STRUCT_OFFSET(gentity_s, nopickup, 0x19D); + ASSERT_STRUCT_OFFSET(gentity_s, handler, 0x19E); + ASSERT_STRUCT_OFFSET(gentity_s, classname, 0x1A0); + ASSERT_STRUCT_OFFSET(gentity_s, script_linkName, 0x1A2); + ASSERT_STRUCT_OFFSET(gentity_s, script_noteworthy, 0x1A4); + ASSERT_STRUCT_OFFSET(gentity_s, target, 0x1A6); + ASSERT_STRUCT_OFFSET(gentity_s, targetname, 0x1A8); + ASSERT_STRUCT_OFFSET(gentity_s, spawnflags2, 0x1AC); + ASSERT_STRUCT_OFFSET(gentity_s, spawnflags, 0x1B0); + ASSERT_STRUCT_OFFSET(gentity_s, flags, 0x1B4); + ASSERT_STRUCT_OFFSET(gentity_s, clipmask, 0x1B8); + ASSERT_STRUCT_OFFSET(gentity_s, processedFrame, 0x1BC); + ASSERT_STRUCT_OFFSET(gentity_s, parent, 0x1C0); + ASSERT_STRUCT_OFFSET(gentity_s, nextthink, 0x1C4); + ASSERT_STRUCT_OFFSET(gentity_s, health, 0x1C8); + ASSERT_STRUCT_OFFSET(gentity_s, maxhealth, 0x1CC); + ASSERT_STRUCT_OFFSET(gentity_s, nexteq, 0x1D0); + ASSERT_STRUCT_OFFSET(gentity_s, damage, 0x1D4); + ASSERT_STRUCT_OFFSET(gentity_s, flame_timed_damage, 0x1D8); + ASSERT_STRUCT_OFFSET(gentity_s, last_timed_radius_damage, 0x248); + ASSERT_STRUCT_OFFSET(gentity_s, count, 0x24C); + ASSERT_STRUCT_OFFSET(gentity_s, chain, 0x250); + ASSERT_STRUCT_OFFSET(gentity_s, activator, 0x254); + ASSERT_STRUCT_OFFSET(gentity_s, u, 0x258); + ASSERT_STRUCT_OFFSET(gentity_s, missileTargetEnt, 0x2B8); + ASSERT_STRUCT_OFFSET(gentity_s, lookAtText0, 0x2BC); + ASSERT_STRUCT_OFFSET(gentity_s, lookAtText1, 0x2BE); + ASSERT_STRUCT_OFFSET(gentity_s, snd_wait, 0x2C0); + ASSERT_STRUCT_OFFSET(gentity_s, tagInfo, 0x2D0); + ASSERT_STRUCT_OFFSET(gentity_s, tagChildren, 0x2D4); + ASSERT_STRUCT_OFFSET(gentity_s, scripted, 0x2D8); + ASSERT_STRUCT_OFFSET(gentity_s, attachTagNames, 0x2DC); + ASSERT_STRUCT_OFFSET(gentity_s, attachModelNames, 0x31A); + ASSERT_STRUCT_OFFSET(gentity_s, disconnectedLinks, 0x358); + ASSERT_STRUCT_OFFSET(gentity_s, iDisconnectTime, 0x35C); + ASSERT_STRUCT_OFFSET(gentity_s, angleLerpRate, 0x360); + ASSERT_STRUCT_OFFSET(gentity_s, physObjId, 0x364); + ASSERT_STRUCT_OFFSET(gentity_s, pAnimTree, 0x368); + ASSERT_STRUCT_OFFSET(gentity_s, nextFree, 0x36C); + ASSERT_STRUCT_OFFSET(gentity_s, scriptUse, 0x370); + ASSERT_STRUCT_OFFSET(gentity_s, birthTime, 0x374); + + struct BulletTraceResults + { + trace_t trace; //OFS: 0x0 SIZE: 0x34 + gentity_s * hitEnt; //OFS: 0x34 SIZE: 0x4 + float hitPos[3]; //OFS: 0x38 SIZE: 0xC + bool ignoreHitEnt; //OFS: 0x44 SIZE: 0x1 + int depthSurfaceType; //OFS: 0x48 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BulletTraceResults, 0x4C); + ASSERT_STRUCT_OFFSET(BulletTraceResults, trace, 0x0); + ASSERT_STRUCT_OFFSET(BulletTraceResults, hitEnt, 0x34); + ASSERT_STRUCT_OFFSET(BulletTraceResults, hitPos, 0x38); + ASSERT_STRUCT_OFFSET(BulletTraceResults, ignoreHitEnt, 0x44); + ASSERT_STRUCT_OFFSET(BulletTraceResults, depthSurfaceType, 0x48); + + struct svEntity_t + { + int worldSector; //OFS: 0x0 SIZE: 0x4 + int nextEntityInWorldSector; //OFS: 0x4 SIZE: 0x4 + entityState_s baseline; //OFS: 0x8 SIZE: 0x118 + int pad[10]; //OFS: 0x120 SIZE: 0x28 + int numClusters; //OFS: 0x148 SIZE: 0x4 + int clusternums[16]; //OFS: 0x14C SIZE: 0x40 + int lastCluster; //OFS: 0x18C SIZE: 0x4 + int linkcontents; //OFS: 0x190 SIZE: 0x4 + float linkmin[3]; //OFS: 0x194 SIZE: 0xC + float linkmax[3]; //OFS: 0x1A0 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(svEntity_t, 0x1AC); + ASSERT_STRUCT_OFFSET(svEntity_t, worldSector, 0x0); + ASSERT_STRUCT_OFFSET(svEntity_t, nextEntityInWorldSector, 0x4); + ASSERT_STRUCT_OFFSET(svEntity_t, baseline, 0x8); + ASSERT_STRUCT_OFFSET(svEntity_t, pad, 0x120); + ASSERT_STRUCT_OFFSET(svEntity_t, numClusters, 0x148); + ASSERT_STRUCT_OFFSET(svEntity_t, clusternums, 0x14C); + ASSERT_STRUCT_OFFSET(svEntity_t, lastCluster, 0x18C); + ASSERT_STRUCT_OFFSET(svEntity_t, linkcontents, 0x190); + ASSERT_STRUCT_OFFSET(svEntity_t, linkmin, 0x194); + ASSERT_STRUCT_OFFSET(svEntity_t, linkmax, 0x1A0); + + struct __declspec(align(1)) struc_72 + { + char field_0[795]; //OFS: 0x0 SIZE: 0x31B + char field_31B; //OFS: 0x31B SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(struc_72, 0x31C); + ASSERT_STRUCT_OFFSET(struc_72, field_0, 0x0); + ASSERT_STRUCT_OFFSET(struc_72, field_31B, 0x31B); + + struct va_info_t + { + char va_string[16][1024]; //OFS: 0x0 SIZE: 0x4000 + int index; //OFS: 0x4000 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(va_info_t, 0x4004); + ASSERT_STRUCT_OFFSET(va_info_t, va_string, 0x0); + ASSERT_STRUCT_OFFSET(va_info_t, index, 0x4000); + + struct TraceCheckCount + { + int global; //OFS: 0x0 SIZE: 0x4 + int * partitions; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(TraceCheckCount, 0x8); + ASSERT_STRUCT_OFFSET(TraceCheckCount, global, 0x0); + ASSERT_STRUCT_OFFSET(TraceCheckCount, partitions, 0x4); + + struct TraceThreadInfo + { + TraceCheckCount checkcount; //OFS: 0x0 SIZE: 0x8 + cbrush_t * box_brush; //OFS: 0x8 SIZE: 0x4 + cmodel_t * box_model; //OFS: 0xC SIZE: 0x4 + PhysGeomList ** geoms; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(TraceThreadInfo, 0x14); + ASSERT_STRUCT_OFFSET(TraceThreadInfo, checkcount, 0x0); + ASSERT_STRUCT_OFFSET(TraceThreadInfo, box_brush, 0x8); + ASSERT_STRUCT_OFFSET(TraceThreadInfo, box_model, 0xC); + ASSERT_STRUCT_OFFSET(TraceThreadInfo, geoms, 0x10); + + struct TLSDataThreadInfo_t + { + int g_threadValue; //OFS: 0x0 SIZE: 0x4 + va_info_t * va_info; //OFS: 0x4 SIZE: 0x4 + jmp_buf * g_com_error; //OFS: 0x8 SIZE: 0x4 + TraceThreadInfo * g_traceThreadInfo; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(TLSDataThreadInfo_t, 0x10); + ASSERT_STRUCT_OFFSET(TLSDataThreadInfo_t, g_threadValue, 0x0); + ASSERT_STRUCT_OFFSET(TLSDataThreadInfo_t, va_info, 0x4); + ASSERT_STRUCT_OFFSET(TLSDataThreadInfo_t, g_com_error, 0x8); + ASSERT_STRUCT_OFFSET(TLSDataThreadInfo_t, g_traceThreadInfo, 0xC); + + struct TLSData_t + { + int field_0; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + int field_8; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + int field_10; //OFS: 0x10 SIZE: 0x4 + TLSDataThreadInfo_t * TLSDataThreadInfo; //OFS: 0x14 SIZE: 0x4 + int field_18; //OFS: 0x18 SIZE: 0x4 + int field_1C; //OFS: 0x1C SIZE: 0x4 + int CurrentThreadId; //OFS: 0x20 SIZE: 0x4 + int field_24; //OFS: 0x24 SIZE: 0x4 + int field_28; //OFS: 0x28 SIZE: 0x4 + int field_2C; //OFS: 0x2C SIZE: 0x4 + int field_30; //OFS: 0x30 SIZE: 0x4 + int field_34; //OFS: 0x34 SIZE: 0x4 + int field_38; //OFS: 0x38 SIZE: 0x4 + int field_3C; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(TLSData_t, 0x40); + ASSERT_STRUCT_OFFSET(TLSData_t, field_0, 0x0); + ASSERT_STRUCT_OFFSET(TLSData_t, field_4, 0x4); + ASSERT_STRUCT_OFFSET(TLSData_t, field_8, 0x8); + ASSERT_STRUCT_OFFSET(TLSData_t, field_C, 0xC); + ASSERT_STRUCT_OFFSET(TLSData_t, field_10, 0x10); + ASSERT_STRUCT_OFFSET(TLSData_t, TLSDataThreadInfo, 0x14); + ASSERT_STRUCT_OFFSET(TLSData_t, field_18, 0x18); + ASSERT_STRUCT_OFFSET(TLSData_t, field_1C, 0x1C); + ASSERT_STRUCT_OFFSET(TLSData_t, CurrentThreadId, 0x20); + ASSERT_STRUCT_OFFSET(TLSData_t, field_24, 0x24); + ASSERT_STRUCT_OFFSET(TLSData_t, field_28, 0x28); + ASSERT_STRUCT_OFFSET(TLSData_t, field_2C, 0x2C); + ASSERT_STRUCT_OFFSET(TLSData_t, field_30, 0x30); + ASSERT_STRUCT_OFFSET(TLSData_t, field_34, 0x34); + ASSERT_STRUCT_OFFSET(TLSData_t, field_38, 0x38); + ASSERT_STRUCT_OFFSET(TLSData_t, field_3C, 0x3C); + + struct XZoneInfo + { + char * name; //OFS: 0x0 SIZE: 0x4 + int allocFlags; //OFS: 0x4 SIZE: 0x4 + int freeFlags; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XZoneInfo, 0xC); + ASSERT_STRUCT_OFFSET(XZoneInfo, name, 0x0); + ASSERT_STRUCT_OFFSET(XZoneInfo, allocFlags, 0x4); + ASSERT_STRUCT_OFFSET(XZoneInfo, freeFlags, 0x8); + + union DvarValue + { + bool enabled; //OFS: 0x0 SIZE: 0x1 + int integer; //OFS: 0x1 SIZE: 0x4 + unsigned int unsignedInt; //OFS: 0x2 SIZE: 0x4 + float value; //OFS: 0x3 SIZE: 0x4 + float vector[4]; //OFS: 0x4 SIZE: 0x10 + const char * string; //OFS: 0x5 SIZE: 0x4 + char color[4]; //OFS: 0x6 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DvarValue, 0x10); + + struct DvarLimits_enum + { + int stringCount; //OFS: 0x0 SIZE: 0x4 + const char ** strings; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DvarLimits_enum, 0x8); + ASSERT_STRUCT_OFFSET(DvarLimits_enum, stringCount, 0x0); + ASSERT_STRUCT_OFFSET(DvarLimits_enum, strings, 0x4); + + struct DvarLimits_minmax + { + int min; //OFS: 0x0 SIZE: 0x4 + int max; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DvarLimits_minmax, 0x8); + ASSERT_STRUCT_OFFSET(DvarLimits_minmax, min, 0x0); + ASSERT_STRUCT_OFFSET(DvarLimits_minmax, max, 0x4); + + struct DvarLimits_float_minmax + { + float min; //OFS: 0x0 SIZE: 0x4 + float max; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DvarLimits_float_minmax, 0x8); + ASSERT_STRUCT_OFFSET(DvarLimits_float_minmax, min, 0x0); + ASSERT_STRUCT_OFFSET(DvarLimits_float_minmax, max, 0x4); + + union DvarLimits + { + DvarLimits_enum enumeration; //OFS: 0x0 SIZE: 0x8 + DvarLimits_minmax integer; //OFS: 0x1 SIZE: 0x8 + DvarLimits_float_minmax value; //OFS: 0x2 SIZE: 0x8 + DvarLimits_float_minmax vector; //OFS: 0x3 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(DvarLimits, 0x8); + + struct dvar_s + { + const char * name; //OFS: 0x0 SIZE: 0x4 + const char * description; //OFS: 0x4 SIZE: 0x4 + DvarFlags flags; //OFS: 0x8 SIZE: 0x2 + dvarType_t type; //OFS: 0xA SIZE: 0x1 + char modified; //OFS: 0xB SIZE: 0x1 + char saveRestorable; //OFS: 0xC SIZE: 0x1 + DvarValue current; //OFS: 0x10 SIZE: 0x10 + DvarValue latched; //OFS: 0x20 SIZE: 0x10 + DvarValue reset; //OFS: 0x30 SIZE: 0x10 + DvarValue saved; //OFS: 0x40 SIZE: 0x10 + DvarLimits domain; //OFS: 0x50 SIZE: 0x8 + dvar_s * hashNext; //OFS: 0x58 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(dvar_s, 0x5C); + ASSERT_STRUCT_OFFSET(dvar_s, name, 0x0); + ASSERT_STRUCT_OFFSET(dvar_s, description, 0x4); + ASSERT_STRUCT_OFFSET(dvar_s, flags, 0x8); + ASSERT_STRUCT_OFFSET(dvar_s, type, 0xA); + ASSERT_STRUCT_OFFSET(dvar_s, modified, 0xB); + ASSERT_STRUCT_OFFSET(dvar_s, saveRestorable, 0xC); + ASSERT_STRUCT_OFFSET(dvar_s, current, 0x10); + ASSERT_STRUCT_OFFSET(dvar_s, latched, 0x20); + ASSERT_STRUCT_OFFSET(dvar_s, reset, 0x30); + ASSERT_STRUCT_OFFSET(dvar_s, saved, 0x40); + ASSERT_STRUCT_OFFSET(dvar_s, domain, 0x50); + ASSERT_STRUCT_OFFSET(dvar_s, hashNext, 0x58); + + struct cmd_function_s + { + cmd_function_s * next; //OFS: 0x0 SIZE: 0x4 + const char * name; //OFS: 0x4 SIZE: 0x4 + const char * autoCompleteDir; //OFS: 0x8 SIZE: 0x4 + const char * autoCompleteExt; //OFS: 0xC SIZE: 0x4 + void (__cdecl *function)(); //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cmd_function_s, 0x14); + ASSERT_STRUCT_OFFSET(cmd_function_s, next, 0x0); + ASSERT_STRUCT_OFFSET(cmd_function_s, name, 0x4); + ASSERT_STRUCT_OFFSET(cmd_function_s, autoCompleteDir, 0x8); + ASSERT_STRUCT_OFFSET(cmd_function_s, autoCompleteExt, 0xC); + ASSERT_STRUCT_OFFSET(cmd_function_s, function, 0x10); + + struct msg_s + { + int overflowed; //OFS: 0x0 SIZE: 0x4 + int readonly; //OFS: 0x4 SIZE: 0x4 + char * data; //OFS: 0x8 SIZE: 0x4 + char * splitData; //OFS: 0xC SIZE: 0x4 + int maxsize; //OFS: 0x10 SIZE: 0x4 + int cursize; //OFS: 0x14 SIZE: 0x4 + int splitSize; //OFS: 0x18 SIZE: 0x4 + int readcount; //OFS: 0x1C SIZE: 0x4 + int bit; //OFS: 0x20 SIZE: 0x4 + int lastEntityRef; //OFS: 0x24 SIZE: 0x4 + int flush; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(msg_s, 0x2C); + ASSERT_STRUCT_OFFSET(msg_s, overflowed, 0x0); + ASSERT_STRUCT_OFFSET(msg_s, readonly, 0x4); + ASSERT_STRUCT_OFFSET(msg_s, data, 0x8); + ASSERT_STRUCT_OFFSET(msg_s, splitData, 0xC); + ASSERT_STRUCT_OFFSET(msg_s, maxsize, 0x10); + ASSERT_STRUCT_OFFSET(msg_s, cursize, 0x14); + ASSERT_STRUCT_OFFSET(msg_s, splitSize, 0x18); + ASSERT_STRUCT_OFFSET(msg_s, readcount, 0x1C); + ASSERT_STRUCT_OFFSET(msg_s, bit, 0x20); + ASSERT_STRUCT_OFFSET(msg_s, lastEntityRef, 0x24); + ASSERT_STRUCT_OFFSET(msg_s, flush, 0x28); + + union netadr_s_ip + { + unsigned __int8 _ip[4]; //OFS: 0x0 SIZE: 0x4 + unsigned int ip_packed; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(netadr_s_ip, 0x4); + + struct netadr_s + { + netadrtype_t type; //OFS: 0x0 SIZE: 0x4 + union netadr_s_ip anonymous_0; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 port; //OFS: 0x8 SIZE: 0x2 + unsigned __int8 netnum[4]; //OFS: 0xA SIZE: 0x4 + unsigned __int8 nodenum[6]; //OFS: 0xE SIZE: 0x6 + unsigned int routerHandle; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(netadr_s, 0x18); + ASSERT_STRUCT_OFFSET(netadr_s, type, 0x0); + ASSERT_STRUCT_OFFSET(netadr_s, anonymous_0, 0x4); + ASSERT_STRUCT_OFFSET(netadr_s, port, 0x8); + ASSERT_STRUCT_OFFSET(netadr_s, netnum, 0xA); + ASSERT_STRUCT_OFFSET(netadr_s, nodenum, 0xE); + ASSERT_STRUCT_OFFSET(netadr_s, routerHandle, 0x14); + + struct netProfilePacket_t + { + int iTime; //OFS: 0x0 SIZE: 0x4 + int iSize; //OFS: 0x4 SIZE: 0x4 + int bFragment; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(netProfilePacket_t, 0xC); + ASSERT_STRUCT_OFFSET(netProfilePacket_t, iTime, 0x0); + ASSERT_STRUCT_OFFSET(netProfilePacket_t, iSize, 0x4); + ASSERT_STRUCT_OFFSET(netProfilePacket_t, bFragment, 0x8); + + struct netProfileStream_t + { + netProfilePacket_t packets[60]; //OFS: 0x0 SIZE: 0x2D0 + int iCurrPacket; //OFS: 0x2D0 SIZE: 0x4 + int iBytesPerSecond; //OFS: 0x2D4 SIZE: 0x4 + int iLastBPSCalcTime; //OFS: 0x2D8 SIZE: 0x4 + int iCountedPackets; //OFS: 0x2DC SIZE: 0x4 + int iCountedFragments; //OFS: 0x2E0 SIZE: 0x4 + int iFragmentPercentage; //OFS: 0x2E4 SIZE: 0x4 + int iLargestPacket; //OFS: 0x2E8 SIZE: 0x4 + int iSmallestPacket; //OFS: 0x2EC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(netProfileStream_t, 0x2F0); + ASSERT_STRUCT_OFFSET(netProfileStream_t, packets, 0x0); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iCurrPacket, 0x2D0); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iBytesPerSecond, 0x2D4); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iLastBPSCalcTime, 0x2D8); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iCountedPackets, 0x2DC); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iCountedFragments, 0x2E0); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iFragmentPercentage, 0x2E4); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iLargestPacket, 0x2E8); + ASSERT_STRUCT_OFFSET(netProfileStream_t, iSmallestPacket, 0x2EC); + + struct netProfileInfo_t + { + netProfileStream_t send; //OFS: 0x0 SIZE: 0x2F0 + netProfileStream_t recieve; //OFS: 0x2F0 SIZE: 0x2F0 + }; + ASSERT_STRUCT_SIZE(netProfileInfo_t, 0x5E0); + ASSERT_STRUCT_OFFSET(netProfileInfo_t, send, 0x0); + ASSERT_STRUCT_OFFSET(netProfileInfo_t, recieve, 0x2F0); + + struct netchan_s + { + int outgoingSequence; //OFS: 0x0 SIZE: 0x4 + netsrc_t sock; //OFS: 0x4 SIZE: 0x4 + int dropped; //OFS: 0x8 SIZE: 0x4 + int incomingSequence; //OFS: 0xC SIZE: 0x4 + netadr_s remoteAddress; //OFS: 0x10 SIZE: 0x18 + int qport; //OFS: 0x28 SIZE: 0x4 + int fragmentSequence; //OFS: 0x2C SIZE: 0x4 + int fragmentLength; //OFS: 0x30 SIZE: 0x4 + char * fragmentBuffer; //OFS: 0x34 SIZE: 0x4 + int fragmentBufferSize; //OFS: 0x38 SIZE: 0x4 + int unsentFragments; //OFS: 0x3C SIZE: 0x4 + int unsentFragmentStart; //OFS: 0x40 SIZE: 0x4 + int unsentLength; //OFS: 0x44 SIZE: 0x4 + int unsentBuffer; //OFS: 0x48 SIZE: 0x4 + int unsentBufferSize; //OFS: 0x4C SIZE: 0x4 + int reliable_fragments; //OFS: 0x50 SIZE: 0x4 + char fragment_send_count[128]; //OFS: 0x54 SIZE: 0x80 + int fragment_ack[4]; //OFS: 0xD4 SIZE: 0x10 + int lowest_send_count; //OFS: 0xE4 SIZE: 0x4 + netProfileInfo_t prof; //OFS: 0xE8 SIZE: 0x5E0 + }; + ASSERT_STRUCT_SIZE(netchan_s, 0x6C8); + ASSERT_STRUCT_OFFSET(netchan_s, outgoingSequence, 0x0); + ASSERT_STRUCT_OFFSET(netchan_s, sock, 0x4); + ASSERT_STRUCT_OFFSET(netchan_s, dropped, 0x8); + ASSERT_STRUCT_OFFSET(netchan_s, incomingSequence, 0xC); + ASSERT_STRUCT_OFFSET(netchan_s, remoteAddress, 0x10); + ASSERT_STRUCT_OFFSET(netchan_s, qport, 0x28); + ASSERT_STRUCT_OFFSET(netchan_s, fragmentSequence, 0x2C); + ASSERT_STRUCT_OFFSET(netchan_s, fragmentLength, 0x30); + ASSERT_STRUCT_OFFSET(netchan_s, fragmentBuffer, 0x34); + ASSERT_STRUCT_OFFSET(netchan_s, fragmentBufferSize, 0x38); + ASSERT_STRUCT_OFFSET(netchan_s, unsentFragments, 0x3C); + ASSERT_STRUCT_OFFSET(netchan_s, unsentFragmentStart, 0x40); + ASSERT_STRUCT_OFFSET(netchan_s, unsentLength, 0x44); + ASSERT_STRUCT_OFFSET(netchan_s, unsentBuffer, 0x48); + ASSERT_STRUCT_OFFSET(netchan_s, unsentBufferSize, 0x4C); + ASSERT_STRUCT_OFFSET(netchan_s, reliable_fragments, 0x50); + ASSERT_STRUCT_OFFSET(netchan_s, fragment_send_count, 0x54); + ASSERT_STRUCT_OFFSET(netchan_s, fragment_ack, 0xD4); + ASSERT_STRUCT_OFFSET(netchan_s, lowest_send_count, 0xE4); + ASSERT_STRUCT_OFFSET(netchan_s, prof, 0xE8); + + struct clientHeader_s + { + clientconn_e state; //OFS: 0x0 SIZE: 0x4 + connstate_t clientReportedState; //OFS: 0x4 SIZE: 0x4 + int huh; //OFS: 0x8 SIZE: 0x4 + int deltaMessage; //OFS: 0xC SIZE: 0x4 + int rateDelayed; //OFS: 0x10 SIZE: 0x4 + netchan_s netchan; //OFS: 0x14 SIZE: 0x6C8 + float predictedOrigin[3]; //OFS: 0x6DC SIZE: 0xC + int predictedOriginServerTime; //OFS: 0x6E8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientHeader_s, 0x6EC); + ASSERT_STRUCT_OFFSET(clientHeader_s, state, 0x0); + ASSERT_STRUCT_OFFSET(clientHeader_s, clientReportedState, 0x4); + ASSERT_STRUCT_OFFSET(clientHeader_s, huh, 0x8); + ASSERT_STRUCT_OFFSET(clientHeader_s, deltaMessage, 0xC); + ASSERT_STRUCT_OFFSET(clientHeader_s, rateDelayed, 0x10); + ASSERT_STRUCT_OFFSET(clientHeader_s, netchan, 0x14); + ASSERT_STRUCT_OFFSET(clientHeader_s, predictedOrigin, 0x6DC); + ASSERT_STRUCT_OFFSET(clientHeader_s, predictedOriginServerTime, 0x6E8); + + struct reliableCommands_s + { + char cmd[512]; //OFS: 0x0 SIZE: 0x200 + int time; //OFS: 0x200 SIZE: 0x4 + int type; //OFS: 0x204 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(reliableCommands_s, 0x208); + ASSERT_STRUCT_OFFSET(reliableCommands_s, cmd, 0x0); + ASSERT_STRUCT_OFFSET(reliableCommands_s, time, 0x200); + ASSERT_STRUCT_OFFSET(reliableCommands_s, type, 0x204); + + struct clientSnapshot_t + { + playerState_s ps; //OFS: 0x0 SIZE: 0x20AC + int num_entities; //OFS: 0x20AC SIZE: 0x4 + int num_clients; //OFS: 0x20B0 SIZE: 0x4 + int num_actors; //OFS: 0x20B4 SIZE: 0x4 + int first_entity; //OFS: 0x20B8 SIZE: 0x4 + int first_client; //OFS: 0x20BC SIZE: 0x4 + int first_actor; //OFS: 0x20C0 SIZE: 0x4 + int num_animCmds; //OFS: 0x20C4 SIZE: 0x4 + int first_animCmd; //OFS: 0x20C8 SIZE: 0x4 + int messageSent; //OFS: 0x20CC SIZE: 0x4 + int messageAcked; //OFS: 0x20D0 SIZE: 0x4 + int messageSize; //OFS: 0x20D4 SIZE: 0x4 + int field_20D8; //OFS: 0x20D8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientSnapshot_t, 0x20DC); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, ps, 0x0); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, num_entities, 0x20AC); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, num_clients, 0x20B0); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, num_actors, 0x20B4); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, first_entity, 0x20B8); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, first_client, 0x20BC); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, first_actor, 0x20C0); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, num_animCmds, 0x20C4); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, first_animCmd, 0x20C8); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, messageSent, 0x20CC); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, messageAcked, 0x20D0); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, messageSize, 0x20D4); + ASSERT_STRUCT_OFFSET(clientSnapshot_t, field_20D8, 0x20D8); + +#pragma pack(push, 1) + struct __declspec(align(1)) VoicePacket_t + { + char talker; //OFS: 0x0 SIZE: 0x1 + char data[256]; //OFS: 0x1 SIZE: 0x100 + int dataSize; //OFS: 0x101 SIZE: 0x4 + }; +#pragma pack(pop) + ASSERT_STRUCT_SIZE(VoicePacket_t, 0x105); + ASSERT_STRUCT_OFFSET(VoicePacket_t, talker, 0x0); + ASSERT_STRUCT_OFFSET(VoicePacket_t, data, 0x1); + ASSERT_STRUCT_OFFSET(VoicePacket_t, dataSize, 0x101); + + struct client_s + { + clientHeader_s header; //OFS: 0x0 SIZE: 0x6EC + char * dropReason; //OFS: 0x6EC SIZE: 0x4 + char userinfo[1536]; //OFS: 0x6F0 SIZE: 0x600 + reliableCommands_s reliableCommands[128]; //OFS: 0xCF0 SIZE: 0x10400 + int reliableSequence; //OFS: 0x110F0 SIZE: 0x4 + int reliableAcknowledge; //OFS: 0x110F4 SIZE: 0x4 + int reliableSent; //OFS: 0x110F8 SIZE: 0x4 + int messageAcknowledge; //OFS: 0x110FC SIZE: 0x4 + int gamestateMessageNum; //OFS: 0x11100 SIZE: 0x4 + int challenge; //OFS: 0x11104 SIZE: 0x4 + usercmd_s lastUsercmd; //OFS: 0x11108 SIZE: 0x38 + int lastClientCommand; //OFS: 0x11140 SIZE: 0x4 + char lastClientCommandString[1024]; //OFS: 0x11144 SIZE: 0x400 + gentity_s * gentity; //OFS: 0x11544 SIZE: 0x4 + char name[32]; //OFS: 0x11548 SIZE: 0x20 + char clanAbbrev[8]; //OFS: 0x11568 SIZE: 0x8 + char downloadName[64]; //OFS: 0x11570 SIZE: 0x40 + int download; //OFS: 0x115B0 SIZE: 0x4 + int downloadSize; //OFS: 0x115B4 SIZE: 0x4 + int downloadCount; //OFS: 0x115B8 SIZE: 0x4 + int downloadClientBlock; //OFS: 0x115BC SIZE: 0x4 + int downloadCurrentBlock; //OFS: 0x115C0 SIZE: 0x4 + int downloadXmitBlock; //OFS: 0x115C4 SIZE: 0x4 + unsigned __int8 * downloadBlocks[8]; //OFS: 0x115C8 SIZE: 0x20 + int downloadBlockSize[8]; //OFS: 0x115E8 SIZE: 0x20 + int downloadEOF; //OFS: 0x11608 SIZE: 0x4 + int downloadSendTime; //OFS: 0x1160C SIZE: 0x4 + int nextReliableTime; //OFS: 0x11610 SIZE: 0x4 + int lastPacketTime; //OFS: 0x11614 SIZE: 0x4 + int lastConnectTime; //OFS: 0x11618 SIZE: 0x4 + int nextSnapshotTime; //OFS: 0x1161C SIZE: 0x4 + int timeoutCount; //OFS: 0x11620 SIZE: 0x4 + clientSnapshot_t frames[16]; //OFS: 0x11624 SIZE: 0x20DC0 + int ping; //OFS: 0x323E4 SIZE: 0x4 + int rate; //OFS: 0x323E8 SIZE: 0x4 + int snapshotMsec; //OFS: 0x323EC SIZE: 0x4 + int pureAuthentic; //OFS: 0x323F0 SIZE: 0x4 + char netchanOutgoingBuffer[131072]; //OFS: 0x323F4 SIZE: 0x20000 + char netchanIncomingBuffer[2048]; //OFS: 0x523F4 SIZE: 0x800 + int guid; //OFS: 0x52BF4 SIZE: 0x4 + int scriptId; //OFS: 0x52BF8 SIZE: 0x4 + int bIsTestClient; //OFS: 0x52BFC SIZE: 0x4 + int serverId; //OFS: 0x52C00 SIZE: 0x4 + VoicePacket_t voicePackets[40]; //OFS: 0x52C04 SIZE: 0x28C8 + int voicePacketCount; //OFS: 0x554CC SIZE: 0x4 + char muteList[4]; //OFS: 0x554D0 SIZE: 0x4 + char sendVoice; //OFS: 0x554D4 SIZE: 0x1 + char stats[8192]; //OFS: 0x554D5 SIZE: 0x2000 + char statPacketsReceived; //OFS: 0x574D5 SIZE: 0x1 + char PBguid[33]; //OFS: 0x574D6 SIZE: 0x21 + char clientPBguid[33]; //OFS: 0x574F7 SIZE: 0x21 + _BYTE gap_57518[6167]; //OFS: 0x57518 SIZE: 0x1817 + char field_0; //OFS: 0x58D2F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(client_s, 0x58D30); + ASSERT_STRUCT_OFFSET(client_s, header, 0x0); + ASSERT_STRUCT_OFFSET(client_s, dropReason, 0x6EC); + ASSERT_STRUCT_OFFSET(client_s, userinfo, 0x6F0); + ASSERT_STRUCT_OFFSET(client_s, reliableCommands, 0xCF0); + ASSERT_STRUCT_OFFSET(client_s, reliableSequence, 0x110F0); + ASSERT_STRUCT_OFFSET(client_s, reliableAcknowledge, 0x110F4); + ASSERT_STRUCT_OFFSET(client_s, reliableSent, 0x110F8); + ASSERT_STRUCT_OFFSET(client_s, messageAcknowledge, 0x110FC); + ASSERT_STRUCT_OFFSET(client_s, gamestateMessageNum, 0x11100); + ASSERT_STRUCT_OFFSET(client_s, challenge, 0x11104); + ASSERT_STRUCT_OFFSET(client_s, lastUsercmd, 0x11108); + ASSERT_STRUCT_OFFSET(client_s, lastClientCommand, 0x11140); + ASSERT_STRUCT_OFFSET(client_s, lastClientCommandString, 0x11144); + ASSERT_STRUCT_OFFSET(client_s, gentity, 0x11544); + ASSERT_STRUCT_OFFSET(client_s, name, 0x11548); + ASSERT_STRUCT_OFFSET(client_s, clanAbbrev, 0x11568); + ASSERT_STRUCT_OFFSET(client_s, downloadName, 0x11570); + ASSERT_STRUCT_OFFSET(client_s, download, 0x115B0); + ASSERT_STRUCT_OFFSET(client_s, downloadSize, 0x115B4); + ASSERT_STRUCT_OFFSET(client_s, downloadCount, 0x115B8); + ASSERT_STRUCT_OFFSET(client_s, downloadClientBlock, 0x115BC); + ASSERT_STRUCT_OFFSET(client_s, downloadCurrentBlock, 0x115C0); + ASSERT_STRUCT_OFFSET(client_s, downloadXmitBlock, 0x115C4); + ASSERT_STRUCT_OFFSET(client_s, downloadBlocks, 0x115C8); + ASSERT_STRUCT_OFFSET(client_s, downloadBlockSize, 0x115E8); + ASSERT_STRUCT_OFFSET(client_s, downloadEOF, 0x11608); + ASSERT_STRUCT_OFFSET(client_s, downloadSendTime, 0x1160C); + ASSERT_STRUCT_OFFSET(client_s, nextReliableTime, 0x11610); + ASSERT_STRUCT_OFFSET(client_s, lastPacketTime, 0x11614); + ASSERT_STRUCT_OFFSET(client_s, lastConnectTime, 0x11618); + ASSERT_STRUCT_OFFSET(client_s, nextSnapshotTime, 0x1161C); + ASSERT_STRUCT_OFFSET(client_s, timeoutCount, 0x11620); + ASSERT_STRUCT_OFFSET(client_s, frames, 0x11624); + ASSERT_STRUCT_OFFSET(client_s, ping, 0x323E4); + ASSERT_STRUCT_OFFSET(client_s, rate, 0x323E8); + ASSERT_STRUCT_OFFSET(client_s, snapshotMsec, 0x323EC); + ASSERT_STRUCT_OFFSET(client_s, pureAuthentic, 0x323F0); + ASSERT_STRUCT_OFFSET(client_s, netchanOutgoingBuffer, 0x323F4); + ASSERT_STRUCT_OFFSET(client_s, netchanIncomingBuffer, 0x523F4); + ASSERT_STRUCT_OFFSET(client_s, guid, 0x52BF4); + ASSERT_STRUCT_OFFSET(client_s, scriptId, 0x52BF8); + ASSERT_STRUCT_OFFSET(client_s, bIsTestClient, 0x52BFC); + ASSERT_STRUCT_OFFSET(client_s, serverId, 0x52C00); + ASSERT_STRUCT_OFFSET(client_s, voicePackets, 0x52C04); + ASSERT_STRUCT_OFFSET(client_s, voicePacketCount, 0x554CC); + ASSERT_STRUCT_OFFSET(client_s, muteList, 0x554D0); + ASSERT_STRUCT_OFFSET(client_s, sendVoice, 0x554D4); + ASSERT_STRUCT_OFFSET(client_s, stats, 0x554D5); + ASSERT_STRUCT_OFFSET(client_s, statPacketsReceived, 0x574D5); + ASSERT_STRUCT_OFFSET(client_s, PBguid, 0x574D6); + ASSERT_STRUCT_OFFSET(client_s, clientPBguid, 0x574F7); + ASSERT_STRUCT_OFFSET(client_s, gap_57518, 0x57518); + ASSERT_STRUCT_OFFSET(client_s, field_0, 0x58D2F); + + union UILocalVar_u + { + int integer; //OFS: 0x0 SIZE: 0x4 + float value; //OFS: 0x1 SIZE: 0x4 + const char * string; //OFS: 0x2 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(UILocalVar_u, 0x4); + + struct UILocalVar + { + UILocalVarType type; //OFS: 0x0 SIZE: 0x4 + const char * name; //OFS: 0x4 SIZE: 0x4 + UILocalVar_u u; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(UILocalVar, 0xC); + ASSERT_STRUCT_OFFSET(UILocalVar, type, 0x0); + ASSERT_STRUCT_OFFSET(UILocalVar, name, 0x4); + ASSERT_STRUCT_OFFSET(UILocalVar, u, 0x8); + + struct UILocalVarContext + { + UILocalVar table[256]; //OFS: 0x0 SIZE: 0xC00 + }; + ASSERT_STRUCT_SIZE(UILocalVarContext, 0xC00); + ASSERT_STRUCT_OFFSET(UILocalVarContext, table, 0x0); + + struct UiContext + { + int contextIndex; //OFS: 0x0 SIZE: 0x4 + float bias; //OFS: 0x4 SIZE: 0x4 + int realTime; //OFS: 0x8 SIZE: 0x4 + int frameTime; //OFS: 0xC SIZE: 0x4 + float cur_x; //OFS: 0x10 SIZE: 0x4 + float cur_y; //OFS: 0x14 SIZE: 0x4 + int isCursorVisible; //OFS: 0x18 SIZE: 0x4 + int screenWidth; //OFS: 0x1C SIZE: 0x4 + int screenHeight; //OFS: 0x20 SIZE: 0x4 + float screenAspect; //OFS: 0x24 SIZE: 0x4 + float FPS; //OFS: 0x28 SIZE: 0x4 + float blurRadiusOut; //OFS: 0x2C SIZE: 0x4 + menuDef_t * Menus[512]; //OFS: 0x30 SIZE: 0x800 + int menuCount; //OFS: 0x830 SIZE: 0x4 + menuDef_t * menuStack[16]; //OFS: 0x834 SIZE: 0x40 + int openMenuCount; //OFS: 0x874 SIZE: 0x4 + UILocalVarContext localVars; //OFS: 0x878 SIZE: 0xC00 + StringTable * cinematicSubtitles; //OFS: 0x1478 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(UiContext, 0x147C); + ASSERT_STRUCT_OFFSET(UiContext, contextIndex, 0x0); + ASSERT_STRUCT_OFFSET(UiContext, bias, 0x4); + ASSERT_STRUCT_OFFSET(UiContext, realTime, 0x8); + ASSERT_STRUCT_OFFSET(UiContext, frameTime, 0xC); + ASSERT_STRUCT_OFFSET(UiContext, cur_x, 0x10); + ASSERT_STRUCT_OFFSET(UiContext, cur_y, 0x14); + ASSERT_STRUCT_OFFSET(UiContext, isCursorVisible, 0x18); + ASSERT_STRUCT_OFFSET(UiContext, screenWidth, 0x1C); + ASSERT_STRUCT_OFFSET(UiContext, screenHeight, 0x20); + ASSERT_STRUCT_OFFSET(UiContext, screenAspect, 0x24); + ASSERT_STRUCT_OFFSET(UiContext, FPS, 0x28); + ASSERT_STRUCT_OFFSET(UiContext, blurRadiusOut, 0x2C); + ASSERT_STRUCT_OFFSET(UiContext, Menus, 0x30); + ASSERT_STRUCT_OFFSET(UiContext, menuCount, 0x830); + ASSERT_STRUCT_OFFSET(UiContext, menuStack, 0x834); + ASSERT_STRUCT_OFFSET(UiContext, openMenuCount, 0x874); + ASSERT_STRUCT_OFFSET(UiContext, localVars, 0x878); + ASSERT_STRUCT_OFFSET(UiContext, cinematicSubtitles, 0x1478); + + union cpose_u + { + char pad[136]; //OFS: 0x0 SIZE: 0x88 + }; + ASSERT_STRUCT_SIZE(cpose_u, 0x88); + + struct cpose_t + { + unsigned __int16 lightingHandle; //OFS: 0x0 SIZE: 0x2 + unsigned __int8 eType; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 eTypeUnion; //OFS: 0x3 SIZE: 0x1 + unsigned __int8 localClientNum; //OFS: 0x4 SIZE: 0x1 + bool isRagdoll; //OFS: 0x5 SIZE: 0x1 + int ragdollHandle; //OFS: 0x8 SIZE: 0x4 + int physObjId; //OFS: 0xC SIZE: 0x4 + int physUserBody; //OFS: 0x10 SIZE: 0x4 + unsigned __int8 destructiblePose; //OFS: 0x14 SIZE: 0x1 + int startBurnTime; //OFS: 0x18 SIZE: 0x4 + float wetness; //OFS: 0x1C SIZE: 0x4 + int cullIn; //OFS: 0x20 SIZE: 0x4 + float origin[3]; //OFS: 0x24 SIZE: 0xC + float angles[3]; //OFS: 0x30 SIZE: 0xC + float mins[3]; //OFS: 0x3C SIZE: 0xC + cpose_u u; //OFS: 0x48 SIZE: 0x88 + }; + ASSERT_STRUCT_SIZE(cpose_t, 0xD0); + ASSERT_STRUCT_OFFSET(cpose_t, lightingHandle, 0x0); + ASSERT_STRUCT_OFFSET(cpose_t, eType, 0x2); + ASSERT_STRUCT_OFFSET(cpose_t, eTypeUnion, 0x3); + ASSERT_STRUCT_OFFSET(cpose_t, localClientNum, 0x4); + ASSERT_STRUCT_OFFSET(cpose_t, isRagdoll, 0x5); + ASSERT_STRUCT_OFFSET(cpose_t, ragdollHandle, 0x8); + ASSERT_STRUCT_OFFSET(cpose_t, physObjId, 0xC); + ASSERT_STRUCT_OFFSET(cpose_t, physUserBody, 0x10); + ASSERT_STRUCT_OFFSET(cpose_t, destructiblePose, 0x14); + ASSERT_STRUCT_OFFSET(cpose_t, startBurnTime, 0x18); + ASSERT_STRUCT_OFFSET(cpose_t, wetness, 0x1C); + ASSERT_STRUCT_OFFSET(cpose_t, cullIn, 0x20); + ASSERT_STRUCT_OFFSET(cpose_t, origin, 0x24); + ASSERT_STRUCT_OFFSET(cpose_t, angles, 0x30); + ASSERT_STRUCT_OFFSET(cpose_t, mins, 0x3C); + ASSERT_STRUCT_OFFSET(cpose_t, u, 0x48); + + struct canimscripted_s + { + float axis[4][3]; //OFS: 0x0 SIZE: 0x30 + unsigned __int16 anim; //OFS: 0x30 SIZE: 0x2 + unsigned __int8 bStarted; //OFS: 0x32 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(canimscripted_s, 0x34); + ASSERT_STRUCT_OFFSET(canimscripted_s, axis, 0x0); + ASSERT_STRUCT_OFFSET(canimscripted_s, anim, 0x30); + ASSERT_STRUCT_OFFSET(canimscripted_s, bStarted, 0x32); + + struct cLinkInfo_s + { + float axis[4][3]; //OFS: 0x0 SIZE: 0x30 + int linkEnt; //OFS: 0x30 SIZE: 0x4 + int linkTag; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cLinkInfo_s, 0x38); + ASSERT_STRUCT_OFFSET(cLinkInfo_s, axis, 0x0); + ASSERT_STRUCT_OFFSET(cLinkInfo_s, linkEnt, 0x30); + ASSERT_STRUCT_OFFSET(cLinkInfo_s, linkTag, 0x34); + + struct cgVehicle_s + { + int lastGunnerFire[4]; //OFS: 0x0 SIZE: 0x10 + int wheelSurfType[6]; //OFS: 0x10 SIZE: 0x18 + float materialTime; //OFS: 0x28 SIZE: 0x4 + vehicle_cache_t * vehicle_cache; //OFS: 0x2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cgVehicle_s, 0x30); + ASSERT_STRUCT_OFFSET(cgVehicle_s, lastGunnerFire, 0x0); + ASSERT_STRUCT_OFFSET(cgVehicle_s, wheelSurfType, 0x10); + ASSERT_STRUCT_OFFSET(cgVehicle_s, materialTime, 0x28); + ASSERT_STRUCT_OFFSET(cgVehicle_s, vehicle_cache, 0x2C); + + struct centity_s + { + cpose_t pose; //OFS: 0x0 SIZE: 0xD0 + entityState_s nextState; //OFS: 0xD0 SIZE: 0x118 + LerpEntityState currentState; //OFS: 0x1E8 SIZE: 0x8C + int previousEventSequence; //OFS: 0x274 SIZE: 0x4 + int miscTime; //OFS: 0x278 SIZE: 0x4 + int lastMuzzleFlash; //OFS: 0x27C SIZE: 0x4 + float lightingOrigin[3]; //OFS: 0x280 SIZE: 0xC + XAnimTree_s * tree; //OFS: 0x28C SIZE: 0x4 + Destructible * destructible; //OFS: 0x290 SIZE: 0x4 + NitrousVehicle * nitrousVeh; //OFS: 0x294 SIZE: 0x4 + canimscripted_s * scripted; //OFS: 0x298 SIZE: 0x4 + cLinkInfo_s * linkInfo; //OFS: 0x29C SIZE: 0x4 + cgVehicle_s * vehicleInfo; //OFS: 0x2A0 SIZE: 0x4 + int nextRippleTime; //OFS: 0x2A4 SIZE: 0x4 + int numBulletImpacts; //OFS: 0x2A8 SIZE: 0x4 + unsigned __int16 attachModelNames[2]; //OFS: 0x2AC SIZE: 0x4 + unsigned __int16 attachTagNames[2]; //OFS: 0x2B0 SIZE: 0x4 + float originError[3]; //OFS: 0x2B4 SIZE: 0xC + float anglesError[3]; //OFS: 0x2C0 SIZE: 0xC + int firstAnimationTime; //OFS: 0x2CC SIZE: 0x4 + __int16 _bf_2d0; //OFS: 0x2D0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(centity_s, 0x2D4); + ASSERT_STRUCT_OFFSET(centity_s, pose, 0x0); + ASSERT_STRUCT_OFFSET(centity_s, nextState, 0xD0); + ASSERT_STRUCT_OFFSET(centity_s, currentState, 0x1E8); + ASSERT_STRUCT_OFFSET(centity_s, previousEventSequence, 0x274); + ASSERT_STRUCT_OFFSET(centity_s, miscTime, 0x278); + ASSERT_STRUCT_OFFSET(centity_s, lastMuzzleFlash, 0x27C); + ASSERT_STRUCT_OFFSET(centity_s, lightingOrigin, 0x280); + ASSERT_STRUCT_OFFSET(centity_s, tree, 0x28C); + ASSERT_STRUCT_OFFSET(centity_s, destructible, 0x290); + ASSERT_STRUCT_OFFSET(centity_s, nitrousVeh, 0x294); + ASSERT_STRUCT_OFFSET(centity_s, scripted, 0x298); + ASSERT_STRUCT_OFFSET(centity_s, linkInfo, 0x29C); + ASSERT_STRUCT_OFFSET(centity_s, vehicleInfo, 0x2A0); + ASSERT_STRUCT_OFFSET(centity_s, nextRippleTime, 0x2A4); + ASSERT_STRUCT_OFFSET(centity_s, numBulletImpacts, 0x2A8); + ASSERT_STRUCT_OFFSET(centity_s, attachModelNames, 0x2AC); + ASSERT_STRUCT_OFFSET(centity_s, attachTagNames, 0x2B0); + ASSERT_STRUCT_OFFSET(centity_s, originError, 0x2B4); + ASSERT_STRUCT_OFFSET(centity_s, anglesError, 0x2C0); + ASSERT_STRUCT_OFFSET(centity_s, firstAnimationTime, 0x2CC); + ASSERT_STRUCT_OFFSET(centity_s, _bf_2d0, 0x2D0); + + struct clSnapshot_s + { + int valid; //OFS: 0x0 SIZE: 0x4 + int snapFlags; //OFS: 0x4 SIZE: 0x4 + int serverTime; //OFS: 0x8 SIZE: 0x4 + int messageNum; //OFS: 0xC SIZE: 0x4 + int deltaNum; //OFS: 0x10 SIZE: 0x4 + int ping; //OFS: 0x14 SIZE: 0x4 + int whatistthis; //OFS: 0x18 SIZE: 0x4 + playerState_s ps; //OFS: 0x1C SIZE: 0x20AC + int numEntities; //OFS: 0x20C8 SIZE: 0x4 + int numClients; //OFS: 0x20CC SIZE: 0x4 + int numActors; //OFS: 0x20D0 SIZE: 0x4 + int parseEntitiesNum; //OFS: 0x20D4 SIZE: 0x4 + int parseClientsNum; //OFS: 0x20D8 SIZE: 0x4 + int parseActorsNum; //OFS: 0x20DC SIZE: 0x4 + int parseAnimCmdsNum; //OFS: 0x20E0 SIZE: 0x4 + int numAnimCmds; //OFS: 0x20E4 SIZE: 0x4 + int serverCommandSequence; //OFS: 0x20E8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clSnapshot_s, 0x20EC); + ASSERT_STRUCT_OFFSET(clSnapshot_s, valid, 0x0); + ASSERT_STRUCT_OFFSET(clSnapshot_s, snapFlags, 0x4); + ASSERT_STRUCT_OFFSET(clSnapshot_s, serverTime, 0x8); + ASSERT_STRUCT_OFFSET(clSnapshot_s, messageNum, 0xC); + ASSERT_STRUCT_OFFSET(clSnapshot_s, deltaNum, 0x10); + ASSERT_STRUCT_OFFSET(clSnapshot_s, ping, 0x14); + ASSERT_STRUCT_OFFSET(clSnapshot_s, whatistthis, 0x18); + ASSERT_STRUCT_OFFSET(clSnapshot_s, ps, 0x1C); + ASSERT_STRUCT_OFFSET(clSnapshot_s, numEntities, 0x20C8); + ASSERT_STRUCT_OFFSET(clSnapshot_s, numClients, 0x20CC); + ASSERT_STRUCT_OFFSET(clSnapshot_s, numActors, 0x20D0); + ASSERT_STRUCT_OFFSET(clSnapshot_s, parseEntitiesNum, 0x20D4); + ASSERT_STRUCT_OFFSET(clSnapshot_s, parseClientsNum, 0x20D8); + ASSERT_STRUCT_OFFSET(clSnapshot_s, parseActorsNum, 0x20DC); + ASSERT_STRUCT_OFFSET(clSnapshot_s, parseAnimCmdsNum, 0x20E0); + ASSERT_STRUCT_OFFSET(clSnapshot_s, numAnimCmds, 0x20E4); + ASSERT_STRUCT_OFFSET(clSnapshot_s, serverCommandSequence, 0x20E8); + + struct gameState_s + { + int stringOffsets[3056]; //OFS: 0x0 SIZE: 0x2FC0 + char stringData[131072]; //OFS: 0x2FC0 SIZE: 0x20000 + int dataCount; //OFS: 0x22FC0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(gameState_s, 0x22FC4); + ASSERT_STRUCT_OFFSET(gameState_s, stringOffsets, 0x0); + ASSERT_STRUCT_OFFSET(gameState_s, stringData, 0x2FC0); + ASSERT_STRUCT_OFFSET(gameState_s, dataCount, 0x22FC0); + + struct ClientArchiveData + { + int serverTime; //OFS: 0x0 SIZE: 0x4 + float origin[3]; //OFS: 0x4 SIZE: 0xC + float velocity[3]; //OFS: 0x10 SIZE: 0xC + int bobCycle; //OFS: 0x1C SIZE: 0x4 + int movementDir; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ClientArchiveData, 0x24); + ASSERT_STRUCT_OFFSET(ClientArchiveData, serverTime, 0x0); + ASSERT_STRUCT_OFFSET(ClientArchiveData, origin, 0x4); + ASSERT_STRUCT_OFFSET(ClientArchiveData, velocity, 0x10); + ASSERT_STRUCT_OFFSET(ClientArchiveData, bobCycle, 0x1C); + ASSERT_STRUCT_OFFSET(ClientArchiveData, movementDir, 0x20); + + struct outPacket_t + { + int p_cmdNumber; //OFS: 0x0 SIZE: 0x4 + int p_serverTime; //OFS: 0x4 SIZE: 0x4 + int p_realtime; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(outPacket_t, 0xC); + ASSERT_STRUCT_OFFSET(outPacket_t, p_cmdNumber, 0x0); + ASSERT_STRUCT_OFFSET(outPacket_t, p_serverTime, 0x4); + ASSERT_STRUCT_OFFSET(outPacket_t, p_realtime, 0x8); + + struct animCmdState_s + { + int field_0; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + int field_8; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + int field_10; //OFS: 0x10 SIZE: 0x4 + int field_14; //OFS: 0x14 SIZE: 0x4 + int field_18; //OFS: 0x18 SIZE: 0x4 + int field_1C; //OFS: 0x1C SIZE: 0x4 + int field_20; //OFS: 0x20 SIZE: 0x4 + int field_24; //OFS: 0x24 SIZE: 0x4 + int field_28; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animCmdState_s, 0x2C); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_0, 0x0); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_4, 0x4); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_8, 0x8); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_C, 0xC); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_10, 0x10); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_14, 0x14); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_18, 0x18); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_1C, 0x1C); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_20, 0x20); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_24, 0x24); + ASSERT_STRUCT_OFFSET(animCmdState_s, field_28, 0x28); + + struct clientActive_s + { + char usingAds; //OFS: 0x0 SIZE: 0x1 + int timeoutcount; //OFS: 0x4 SIZE: 0x4 + clSnapshot_s snap; //OFS: 0x8 SIZE: 0x20EC + char alwaysFalse; //OFS: 0x20F4 SIZE: 0x1 + int serverTime; //OFS: 0x20F8 SIZE: 0x4 + int oldServerTime; //OFS: 0x20FC SIZE: 0x4 + int oldFrameServerTime; //OFS: 0x2100 SIZE: 0x4 + int serverTimeDelta; //OFS: 0x2104 SIZE: 0x4 + int oldSnapServerTime; //OFS: 0x2108 SIZE: 0x4 + int extrapolatedSnapshot; //OFS: 0x210C SIZE: 0x4 + int newSnapshots; //OFS: 0x2110 SIZE: 0x4 + gameState_s gameState; //OFS: 0x2114 SIZE: 0x22FC4 + char mapname[64]; //OFS: 0x250D8 SIZE: 0x40 + int parseEntitiesNum; //OFS: 0x25118 SIZE: 0x4 + int parseClientsNum; //OFS: 0x2511C SIZE: 0x4 + int parseActorsNum; //OFS: 0x25120 SIZE: 0x4 + int parseAnimCmdsNum; //OFS: 0x25124 SIZE: 0x4 + int mouseDx[2]; //OFS: 0x25128 SIZE: 0x8 + int mouseDy[2]; //OFS: 0x25130 SIZE: 0x8 + int mouseIndex; //OFS: 0x25138 SIZE: 0x4 + char stanceHeld; //OFS: 0x2513C SIZE: 0x1 + StanceState stance; //OFS: 0x25140 SIZE: 0x4 + StanceState stancePosition; //OFS: 0x25144 SIZE: 0x4 + int stanceTime; //OFS: 0x25148 SIZE: 0x4 + int cgameUserCmdWeapon; //OFS: 0x2514C SIZE: 0x4 + int cgameUserCmdOffHandIndex; //OFS: 0x25150 SIZE: 0x4 + int cgameUserCmdGunPitch; //OFS: 0x25154 SIZE: 0x4 + int cgameUserCmdGunYaw; //OFS: 0x25158 SIZE: 0x4 + int field_2515C; //OFS: 0x2515C SIZE: 0x4 + int field_25160; //OFS: 0x25160 SIZE: 0x4 + int field_25164; //OFS: 0x25164 SIZE: 0x4 + int cgameFOVSensitivityScale; //OFS: 0x25168 SIZE: 0x4 + float cgameMaxPitchSpeed; //OFS: 0x2516C SIZE: 0x4 + float cgameMaxYawSpeed; //OFS: 0x25170 SIZE: 0x4 + float cgameKickAngles[3]; //OFS: 0x25174 SIZE: 0xC + float cgameOrigin[3]; //OFS: 0x25180 SIZE: 0xC + float cgameVelocity[3]; //OFS: 0x2518C SIZE: 0xC + int cgameBobCycle; //OFS: 0x25198 SIZE: 0x4 + int cgameMovementDir; //OFS: 0x2519C SIZE: 0x4 + int cgameExtraButtons; //OFS: 0x251A0 SIZE: 0x4 + int cgamePredictedDataServerTime; //OFS: 0x251A4 SIZE: 0x4 + float viewangles[3]; //OFS: 0x251A8 SIZE: 0xC + int serverId; //OFS: 0x251B4 SIZE: 0x4 + int bCmdForceValues; //OFS: 0x251B8 SIZE: 0x4 + int iForceButtons; //OFS: 0x251BC SIZE: 0x4 + int iForceWeapon; //OFS: 0x251C0 SIZE: 0x4 + int forceOffhand; //OFS: 0x251C4 SIZE: 0x4 + int skelTimeStamp; //OFS: 0x251C8 SIZE: 0x4 + int skelMemPos; //OFS: 0x251CC SIZE: 0x4 + char skelMemory[524288]; //OFS: 0x251D0 SIZE: 0x80000 + int skelMemoryStart; //OFS: 0xA51D0 SIZE: 0x4 + char allowedAllocSkel; //OFS: 0xA51D4 SIZE: 0x1 + usercmd_s cmds[128]; //OFS: 0xA51D8 SIZE: 0x1C00 + int cmdNumber; //OFS: 0xA6DD8 SIZE: 0x4 + ClientArchiveData clientArchive[256]; //OFS: 0xA6DDC SIZE: 0x2400 + int clientArchiveIndex; //OFS: 0xA91DC SIZE: 0x4 + outPacket_t outPackets[16]; //OFS: 0xA91E0 SIZE: 0xC0 + clSnapshot_s snapshots[16]; //OFS: 0xA92A0 SIZE: 0x20EC0 + entityState_s entityBaselines[1023]; //OFS: 0xCA160 SIZE: 0x45EE8 + entityState_s cachedEntityBaselines[351]; //OFS: 0x110048 SIZE: 0x17FE8 + entityState_s parseEntities[4096]; //OFS: 0x128030 SIZE: 0x118000 + entityState_s * parseEntitiesPtr; //OFS: 0x240030 SIZE: 0x4 + int maxEntities; //OFS: 0x240034 SIZE: 0x4 + clientState_s parseClients[64]; //OFS: 0x240038 SIZE: 0x2500 + clientState_s * parseClientsPtr; //OFS: 0x242538 SIZE: 0x4 + int maxClientStates; //OFS: 0x24253C SIZE: 0x4 + actorState_s parseActors[512]; //OFS: 0x242540 SIZE: 0xF000 + actorState_s * parseActorsPtr; //OFS: 0x251540 SIZE: 0x4 + int maxActorStates; //OFS: 0x251544 SIZE: 0x4 + animCmdState_s parseAnimCmds[16384]; //OFS: 0x251548 SIZE: 0xB0000 + animCmdState_s * parseAnimCmdsPtr; //OFS: 0x301548 SIZE: 0x4 + int maxAnimCmds; //OFS: 0x30154C SIZE: 0x4 + int corruptedTranslationFile; //OFS: 0x301550 SIZE: 0x4 + char translationVersion[256]; //OFS: 0x301554 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(clientActive_s, 0x301654); + ASSERT_STRUCT_OFFSET(clientActive_s, usingAds, 0x0); + ASSERT_STRUCT_OFFSET(clientActive_s, timeoutcount, 0x4); + ASSERT_STRUCT_OFFSET(clientActive_s, snap, 0x8); + ASSERT_STRUCT_OFFSET(clientActive_s, alwaysFalse, 0x20F4); + ASSERT_STRUCT_OFFSET(clientActive_s, serverTime, 0x20F8); + ASSERT_STRUCT_OFFSET(clientActive_s, oldServerTime, 0x20FC); + ASSERT_STRUCT_OFFSET(clientActive_s, oldFrameServerTime, 0x2100); + ASSERT_STRUCT_OFFSET(clientActive_s, serverTimeDelta, 0x2104); + ASSERT_STRUCT_OFFSET(clientActive_s, oldSnapServerTime, 0x2108); + ASSERT_STRUCT_OFFSET(clientActive_s, extrapolatedSnapshot, 0x210C); + ASSERT_STRUCT_OFFSET(clientActive_s, newSnapshots, 0x2110); + ASSERT_STRUCT_OFFSET(clientActive_s, gameState, 0x2114); + ASSERT_STRUCT_OFFSET(clientActive_s, mapname, 0x250D8); + ASSERT_STRUCT_OFFSET(clientActive_s, parseEntitiesNum, 0x25118); + ASSERT_STRUCT_OFFSET(clientActive_s, parseClientsNum, 0x2511C); + ASSERT_STRUCT_OFFSET(clientActive_s, parseActorsNum, 0x25120); + ASSERT_STRUCT_OFFSET(clientActive_s, parseAnimCmdsNum, 0x25124); + ASSERT_STRUCT_OFFSET(clientActive_s, mouseDx, 0x25128); + ASSERT_STRUCT_OFFSET(clientActive_s, mouseDy, 0x25130); + ASSERT_STRUCT_OFFSET(clientActive_s, mouseIndex, 0x25138); + ASSERT_STRUCT_OFFSET(clientActive_s, stanceHeld, 0x2513C); + ASSERT_STRUCT_OFFSET(clientActive_s, stance, 0x25140); + ASSERT_STRUCT_OFFSET(clientActive_s, stancePosition, 0x25144); + ASSERT_STRUCT_OFFSET(clientActive_s, stanceTime, 0x25148); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameUserCmdWeapon, 0x2514C); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameUserCmdOffHandIndex, 0x25150); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameUserCmdGunPitch, 0x25154); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameUserCmdGunYaw, 0x25158); + ASSERT_STRUCT_OFFSET(clientActive_s, field_2515C, 0x2515C); + ASSERT_STRUCT_OFFSET(clientActive_s, field_25160, 0x25160); + ASSERT_STRUCT_OFFSET(clientActive_s, field_25164, 0x25164); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameFOVSensitivityScale, 0x25168); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameMaxPitchSpeed, 0x2516C); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameMaxYawSpeed, 0x25170); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameKickAngles, 0x25174); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameOrigin, 0x25180); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameVelocity, 0x2518C); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameBobCycle, 0x25198); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameMovementDir, 0x2519C); + ASSERT_STRUCT_OFFSET(clientActive_s, cgameExtraButtons, 0x251A0); + ASSERT_STRUCT_OFFSET(clientActive_s, cgamePredictedDataServerTime, 0x251A4); + ASSERT_STRUCT_OFFSET(clientActive_s, viewangles, 0x251A8); + ASSERT_STRUCT_OFFSET(clientActive_s, serverId, 0x251B4); + ASSERT_STRUCT_OFFSET(clientActive_s, bCmdForceValues, 0x251B8); + ASSERT_STRUCT_OFFSET(clientActive_s, iForceButtons, 0x251BC); + ASSERT_STRUCT_OFFSET(clientActive_s, iForceWeapon, 0x251C0); + ASSERT_STRUCT_OFFSET(clientActive_s, forceOffhand, 0x251C4); + ASSERT_STRUCT_OFFSET(clientActive_s, skelTimeStamp, 0x251C8); + ASSERT_STRUCT_OFFSET(clientActive_s, skelMemPos, 0x251CC); + ASSERT_STRUCT_OFFSET(clientActive_s, skelMemory, 0x251D0); + ASSERT_STRUCT_OFFSET(clientActive_s, skelMemoryStart, 0xA51D0); + ASSERT_STRUCT_OFFSET(clientActive_s, allowedAllocSkel, 0xA51D4); + ASSERT_STRUCT_OFFSET(clientActive_s, cmds, 0xA51D8); + ASSERT_STRUCT_OFFSET(clientActive_s, cmdNumber, 0xA6DD8); + ASSERT_STRUCT_OFFSET(clientActive_s, clientArchive, 0xA6DDC); + ASSERT_STRUCT_OFFSET(clientActive_s, clientArchiveIndex, 0xA91DC); + ASSERT_STRUCT_OFFSET(clientActive_s, outPackets, 0xA91E0); + ASSERT_STRUCT_OFFSET(clientActive_s, snapshots, 0xA92A0); + ASSERT_STRUCT_OFFSET(clientActive_s, entityBaselines, 0xCA160); + ASSERT_STRUCT_OFFSET(clientActive_s, cachedEntityBaselines, 0x110048); + ASSERT_STRUCT_OFFSET(clientActive_s, parseEntities, 0x128030); + ASSERT_STRUCT_OFFSET(clientActive_s, parseEntitiesPtr, 0x240030); + ASSERT_STRUCT_OFFSET(clientActive_s, maxEntities, 0x240034); + ASSERT_STRUCT_OFFSET(clientActive_s, parseClients, 0x240038); + ASSERT_STRUCT_OFFSET(clientActive_s, parseClientsPtr, 0x242538); + ASSERT_STRUCT_OFFSET(clientActive_s, maxClientStates, 0x24253C); + ASSERT_STRUCT_OFFSET(clientActive_s, parseActors, 0x242540); + ASSERT_STRUCT_OFFSET(clientActive_s, parseActorsPtr, 0x251540); + ASSERT_STRUCT_OFFSET(clientActive_s, maxActorStates, 0x251544); + ASSERT_STRUCT_OFFSET(clientActive_s, parseAnimCmds, 0x251548); + ASSERT_STRUCT_OFFSET(clientActive_s, parseAnimCmdsPtr, 0x301548); + ASSERT_STRUCT_OFFSET(clientActive_s, maxAnimCmds, 0x30154C); + ASSERT_STRUCT_OFFSET(clientActive_s, corruptedTranslationFile, 0x301550); + ASSERT_STRUCT_OFFSET(clientActive_s, translationVersion, 0x301554); + + struct shellshock_parms_t_screenBlend + { + int blurredFadeTime; //OFS: 0x0 SIZE: 0x4 + int blurredEffectTime; //OFS: 0x4 SIZE: 0x4 + int flashWhiteFadeTime; //OFS: 0x8 SIZE: 0x4 + int flashShotFadeTime; //OFS: 0xC SIZE: 0x4 + ShockViewTypes type; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t_screenBlend, 0x14); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_screenBlend, blurredFadeTime, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_screenBlend, blurredEffectTime, 0x4); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_screenBlend, flashWhiteFadeTime, 0x8); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_screenBlend, flashShotFadeTime, 0xC); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_screenBlend, type, 0x10); + + struct shellshock_parms_t_view + { + int fadeTime; //OFS: 0x0 SIZE: 0x4 + float kickRate; //OFS: 0x4 SIZE: 0x4 + float kickRadius; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t_view, 0xC); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_view, fadeTime, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_view, kickRate, 0x4); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_view, kickRadius, 0x8); + + struct shellshock_parms_t_sound + { + bool affect; //OFS: 0x0 SIZE: 0x1 + char loop[64]; //OFS: 0x1 SIZE: 0x40 + char loopSilent[64]; //OFS: 0x41 SIZE: 0x40 + char end[64]; //OFS: 0x81 SIZE: 0x40 + char endAbort[64]; //OFS: 0xC1 SIZE: 0x40 + int fadeInTime; //OFS: 0x104 SIZE: 0x4 + int fadeOutTime; //OFS: 0x108 SIZE: 0x4 + float drylevel; //OFS: 0x10C SIZE: 0x4 + float wetlevel; //OFS: 0x110 SIZE: 0x4 + char roomtype[64]; //OFS: 0x114 SIZE: 0x40 + float busVolume[64]; //OFS: 0x154 SIZE: 0x100 + int modEndDelay; //OFS: 0x254 SIZE: 0x4 + int loopFadeTime; //OFS: 0x258 SIZE: 0x4 + int loopEndDelay; //OFS: 0x25C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t_sound, 0x260); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, affect, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, loop, 0x1); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, loopSilent, 0x41); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, end, 0x81); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, endAbort, 0xC1); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, fadeInTime, 0x104); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, fadeOutTime, 0x108); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, drylevel, 0x10C); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, wetlevel, 0x110); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, roomtype, 0x114); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, busVolume, 0x154); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, modEndDelay, 0x254); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, loopFadeTime, 0x258); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_sound, loopEndDelay, 0x25C); + + struct shellshock_parms_t_lookControl + { + bool affect; //OFS: 0x0 SIZE: 0x1 + int fadeTime; //OFS: 0x4 SIZE: 0x4 + float mouseSensitivity; //OFS: 0x8 SIZE: 0x4 + float maxPitchSpeed; //OFS: 0xC SIZE: 0x4 + float maxYawSpeed; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t_lookControl, 0x14); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_lookControl, affect, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_lookControl, fadeTime, 0x4); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_lookControl, mouseSensitivity, 0x8); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_lookControl, maxPitchSpeed, 0xC); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_lookControl, maxYawSpeed, 0x10); + + struct __declspec(align(1)) shellshock_parms_t_movement + { + bool affect; //OFS: 0x0 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t_movement, 0x1); + ASSERT_STRUCT_OFFSET(shellshock_parms_t_movement, affect, 0x0); + + struct shellshock_parms_t + { + shellshock_parms_t_screenBlend screenBlend; //OFS: 0x0 SIZE: 0x14 + shellshock_parms_t_view view; //OFS: 0x14 SIZE: 0xC + shellshock_parms_t_sound sound; //OFS: 0x20 SIZE: 0x260 + shellshock_parms_t_lookControl lookControl; //OFS: 0x280 SIZE: 0x14 + shellshock_parms_t_movement movement; //OFS: 0x294 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(shellshock_parms_t, 0x298); + ASSERT_STRUCT_OFFSET(shellshock_parms_t, screenBlend, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_parms_t, view, 0x14); + ASSERT_STRUCT_OFFSET(shellshock_parms_t, sound, 0x20); + ASSERT_STRUCT_OFFSET(shellshock_parms_t, lookControl, 0x280); + ASSERT_STRUCT_OFFSET(shellshock_parms_t, movement, 0x294); + + struct __declspec(align(8)) animation_s + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + int initialLerp; //OFS: 0x40 SIZE: 0x4 + float moveSpeed; //OFS: 0x44 SIZE: 0x4 + int duration; //OFS: 0x48 SIZE: 0x4 + int nameHash; //OFS: 0x4C SIZE: 0x4 + int flags; //OFS: 0x50 SIZE: 0x4 + __int64 movetype; //OFS: 0x58 SIZE: 0x8 + int noteType; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animation_s, 0x68); + ASSERT_STRUCT_OFFSET(animation_s, name, 0x0); + ASSERT_STRUCT_OFFSET(animation_s, initialLerp, 0x40); + ASSERT_STRUCT_OFFSET(animation_s, moveSpeed, 0x44); + ASSERT_STRUCT_OFFSET(animation_s, duration, 0x48); + ASSERT_STRUCT_OFFSET(animation_s, nameHash, 0x4C); + ASSERT_STRUCT_OFFSET(animation_s, flags, 0x50); + ASSERT_STRUCT_OFFSET(animation_s, movetype, 0x58); + ASSERT_STRUCT_OFFSET(animation_s, noteType, 0x60); + + struct lerpFrame_t + { + float yawAngle; //OFS: 0x0 SIZE: 0x4 + int yawing; //OFS: 0x4 SIZE: 0x4 + float pitchAngle; //OFS: 0x8 SIZE: 0x4 + int pitching; //OFS: 0xC SIZE: 0x4 + int animationNumber; //OFS: 0x10 SIZE: 0x4 + animation_s * animation; //OFS: 0x14 SIZE: 0x4 + int animationTime; //OFS: 0x18 SIZE: 0x4 + float oldFramePos[3]; //OFS: 0x1C SIZE: 0xC + float animSpeedScale; //OFS: 0x28 SIZE: 0x4 + int oldFrameSnapshotTime; //OFS: 0x2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(lerpFrame_t, 0x30); + ASSERT_STRUCT_OFFSET(lerpFrame_t, yawAngle, 0x0); + ASSERT_STRUCT_OFFSET(lerpFrame_t, yawing, 0x4); + ASSERT_STRUCT_OFFSET(lerpFrame_t, pitchAngle, 0x8); + ASSERT_STRUCT_OFFSET(lerpFrame_t, pitching, 0xC); + ASSERT_STRUCT_OFFSET(lerpFrame_t, animationNumber, 0x10); + ASSERT_STRUCT_OFFSET(lerpFrame_t, animation, 0x14); + ASSERT_STRUCT_OFFSET(lerpFrame_t, animationTime, 0x18); + ASSERT_STRUCT_OFFSET(lerpFrame_t, oldFramePos, 0x1C); + ASSERT_STRUCT_OFFSET(lerpFrame_t, animSpeedScale, 0x28); + ASSERT_STRUCT_OFFSET(lerpFrame_t, oldFrameSnapshotTime, 0x2C); + + struct clientControllers_t + { + float angles[6][3]; //OFS: 0x0 SIZE: 0x48 + float tag_origin_angles[3]; //OFS: 0x48 SIZE: 0xC + float tag_origin_offset[3]; //OFS: 0x54 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(clientControllers_t, 0x60); + ASSERT_STRUCT_OFFSET(clientControllers_t, angles, 0x0); + ASSERT_STRUCT_OFFSET(clientControllers_t, tag_origin_angles, 0x48); + ASSERT_STRUCT_OFFSET(clientControllers_t, tag_origin_offset, 0x54); + + struct clientInfo_t + { + int infoValid; //OFS: 0x0 SIZE: 0x4 + int nextValid; //OFS: 0x4 SIZE: 0x4 + int clientNum; //OFS: 0x8 SIZE: 0x4 + char name[32]; //OFS: 0xC SIZE: 0x20 + team_t team; //OFS: 0x2C SIZE: 0x4 + team_t oldteam; //OFS: 0x30 SIZE: 0x4 + int rank; //OFS: 0x34 SIZE: 0x4 + int prestige; //OFS: 0x38 SIZE: 0x4 + int perks; //OFS: 0x3C SIZE: 0x4 + int needsRevive; //OFS: 0x40 SIZE: 0x4 + char clanAbbrev[8]; //OFS: 0x44 SIZE: 0x8 + int score; //OFS: 0x4C SIZE: 0x4 + int location; //OFS: 0x50 SIZE: 0x4 + int health; //OFS: 0x54 SIZE: 0x4 + char model[64]; //OFS: 0x58 SIZE: 0x40 + char attachModelNames[6][64]; //OFS: 0x98 SIZE: 0x180 + char attachTagNames[6][64]; //OFS: 0x218 SIZE: 0x180 + lerpFrame_t legs; //OFS: 0x398 SIZE: 0x30 + lerpFrame_t torso; //OFS: 0x3C8 SIZE: 0x30 + float lerpMoveDir; //OFS: 0x3F8 SIZE: 0x4 + float lerpLean; //OFS: 0x3FC SIZE: 0x4 + float playerAngles[3]; //OFS: 0x400 SIZE: 0xC + int leftHandGun; //OFS: 0x40C SIZE: 0x4 + int dobjDirty; //OFS: 0x410 SIZE: 0x4 + clientControllers_t control; //OFS: 0x414 SIZE: 0x60 + int lastDamageTime; //OFS: 0x474 SIZE: 0x4 + int lastStandStartTime; //OFS: 0x478 SIZE: 0x4 + int beingRevived; //OFS: 0x47C SIZE: 0x4 + unsigned int clientConditions[17][2]; //OFS: 0x480 SIZE: 0x88 + XAnimTree_s * pXAnimTree; //OFS: 0x508 SIZE: 0x4 + int iDObjWeapon; //OFS: 0x50C SIZE: 0x4 + unsigned __int8 weaponModel; //OFS: 0x510 SIZE: 0x1 + int stanceTransitionTime; //OFS: 0x514 SIZE: 0x4 + int turnAnimEndTime; //OFS: 0x518 SIZE: 0x4 + char turnAnimType; //OFS: 0x51C SIZE: 0x1 + int attachedEntNum; //OFS: 0x520 SIZE: 0x4 + char attachedTagName[64]; //OFS: 0x524 SIZE: 0x40 + bool hideWeapon; //OFS: 0x564 SIZE: 0x1 + bool usingKnife; //OFS: 0x565 SIZE: 0x1 + int nextHideWeaponTime; //OFS: 0x568 SIZE: 0x4 + float vehAnimLastOrg[3]; //OFS: 0x56C SIZE: 0xC + float vehAnimLastAngle[3]; //OFS: 0x578 SIZE: 0xC + int vehAnimLastBone; //OFS: 0x584 SIZE: 0x4 + int vehAnimLastTime; //OFS: 0x588 SIZE: 0x4 + int vehAnimLerpStartTime; //OFS: 0x58C SIZE: 0x4 + int vehAnimLerpEndTime; //OFS: 0x590 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientInfo_t, 0x594); + ASSERT_STRUCT_OFFSET(clientInfo_t, infoValid, 0x0); + ASSERT_STRUCT_OFFSET(clientInfo_t, nextValid, 0x4); + ASSERT_STRUCT_OFFSET(clientInfo_t, clientNum, 0x8); + ASSERT_STRUCT_OFFSET(clientInfo_t, name, 0xC); + ASSERT_STRUCT_OFFSET(clientInfo_t, team, 0x2C); + ASSERT_STRUCT_OFFSET(clientInfo_t, oldteam, 0x30); + ASSERT_STRUCT_OFFSET(clientInfo_t, rank, 0x34); + ASSERT_STRUCT_OFFSET(clientInfo_t, prestige, 0x38); + ASSERT_STRUCT_OFFSET(clientInfo_t, perks, 0x3C); + ASSERT_STRUCT_OFFSET(clientInfo_t, needsRevive, 0x40); + ASSERT_STRUCT_OFFSET(clientInfo_t, clanAbbrev, 0x44); + ASSERT_STRUCT_OFFSET(clientInfo_t, score, 0x4C); + ASSERT_STRUCT_OFFSET(clientInfo_t, location, 0x50); + ASSERT_STRUCT_OFFSET(clientInfo_t, health, 0x54); + ASSERT_STRUCT_OFFSET(clientInfo_t, model, 0x58); + ASSERT_STRUCT_OFFSET(clientInfo_t, attachModelNames, 0x98); + ASSERT_STRUCT_OFFSET(clientInfo_t, attachTagNames, 0x218); + ASSERT_STRUCT_OFFSET(clientInfo_t, legs, 0x398); + ASSERT_STRUCT_OFFSET(clientInfo_t, torso, 0x3C8); + ASSERT_STRUCT_OFFSET(clientInfo_t, lerpMoveDir, 0x3F8); + ASSERT_STRUCT_OFFSET(clientInfo_t, lerpLean, 0x3FC); + ASSERT_STRUCT_OFFSET(clientInfo_t, playerAngles, 0x400); + ASSERT_STRUCT_OFFSET(clientInfo_t, leftHandGun, 0x40C); + ASSERT_STRUCT_OFFSET(clientInfo_t, dobjDirty, 0x410); + ASSERT_STRUCT_OFFSET(clientInfo_t, control, 0x414); + ASSERT_STRUCT_OFFSET(clientInfo_t, lastDamageTime, 0x474); + ASSERT_STRUCT_OFFSET(clientInfo_t, lastStandStartTime, 0x478); + ASSERT_STRUCT_OFFSET(clientInfo_t, beingRevived, 0x47C); + ASSERT_STRUCT_OFFSET(clientInfo_t, clientConditions, 0x480); + ASSERT_STRUCT_OFFSET(clientInfo_t, pXAnimTree, 0x508); + ASSERT_STRUCT_OFFSET(clientInfo_t, iDObjWeapon, 0x50C); + ASSERT_STRUCT_OFFSET(clientInfo_t, weaponModel, 0x510); + ASSERT_STRUCT_OFFSET(clientInfo_t, stanceTransitionTime, 0x514); + ASSERT_STRUCT_OFFSET(clientInfo_t, turnAnimEndTime, 0x518); + ASSERT_STRUCT_OFFSET(clientInfo_t, turnAnimType, 0x51C); + ASSERT_STRUCT_OFFSET(clientInfo_t, attachedEntNum, 0x520); + ASSERT_STRUCT_OFFSET(clientInfo_t, attachedTagName, 0x524); + ASSERT_STRUCT_OFFSET(clientInfo_t, hideWeapon, 0x564); + ASSERT_STRUCT_OFFSET(clientInfo_t, usingKnife, 0x565); + ASSERT_STRUCT_OFFSET(clientInfo_t, nextHideWeaponTime, 0x568); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLastOrg, 0x56C); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLastAngle, 0x578); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLastBone, 0x584); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLastTime, 0x588); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLerpStartTime, 0x58C); + ASSERT_STRUCT_OFFSET(clientInfo_t, vehAnimLerpEndTime, 0x590); + + struct actorInfo_t + { + int infoValid; //OFS: 0x0 SIZE: 0x4 + int nextValid; //OFS: 0x4 SIZE: 0x4 + int actorNum; //OFS: 0x8 SIZE: 0x4 + int entityNum; //OFS: 0xC SIZE: 0x4 + char name[32]; //OFS: 0x10 SIZE: 0x20 + team_t team; //OFS: 0x30 SIZE: 0x4 + char model[64]; //OFS: 0x34 SIZE: 0x40 + char attachModelNames[6][64]; //OFS: 0x74 SIZE: 0x180 + char attachTagNames[6][64]; //OFS: 0x1F4 SIZE: 0x180 + lerpFrame_t legs; //OFS: 0x374 SIZE: 0x30 + lerpFrame_t torso; //OFS: 0x3A4 SIZE: 0x30 + int dobjDirty; //OFS: 0x3D4 SIZE: 0x4 + int animsDirty; //OFS: 0x3D8 SIZE: 0x4 + XAnimTree_s * pXAnimTree; //OFS: 0x3DC SIZE: 0x4 + int iDObjWeapon; //OFS: 0x3E0 SIZE: 0x4 + int stanceTransitionTime; //OFS: 0x3E4 SIZE: 0x4 + int turnAnimEndTime; //OFS: 0x3E8 SIZE: 0x4 + char turnAnimType; //OFS: 0x3EC SIZE: 0x1 + int attachedEntNum; //OFS: 0x3F0 SIZE: 0x4 + char attachedTagName[64]; //OFS: 0x3F4 SIZE: 0x40 + int animScriptedAnim; //OFS: 0x434 SIZE: 0x4 + bool hideWeapon; //OFS: 0x438 SIZE: 0x1 + int hudwarningType; //OFS: 0x43C SIZE: 0x4 + int lookAtEntNum; //OFS: 0x440 SIZE: 0x4 + int lastLookAtEntNum; //OFS: 0x444 SIZE: 0x4 + float lookAtBlend; //OFS: 0x448 SIZE: 0x4 + int lookAtBlendedIn; //OFS: 0x44C SIZE: 0x4 + int lookAtTime; //OFS: 0x450 SIZE: 0x4 + int pad; //OFS: 0x454 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(actorInfo_t, 0x458); + ASSERT_STRUCT_OFFSET(actorInfo_t, infoValid, 0x0); + ASSERT_STRUCT_OFFSET(actorInfo_t, nextValid, 0x4); + ASSERT_STRUCT_OFFSET(actorInfo_t, actorNum, 0x8); + ASSERT_STRUCT_OFFSET(actorInfo_t, entityNum, 0xC); + ASSERT_STRUCT_OFFSET(actorInfo_t, name, 0x10); + ASSERT_STRUCT_OFFSET(actorInfo_t, team, 0x30); + ASSERT_STRUCT_OFFSET(actorInfo_t, model, 0x34); + ASSERT_STRUCT_OFFSET(actorInfo_t, attachModelNames, 0x74); + ASSERT_STRUCT_OFFSET(actorInfo_t, attachTagNames, 0x1F4); + ASSERT_STRUCT_OFFSET(actorInfo_t, legs, 0x374); + ASSERT_STRUCT_OFFSET(actorInfo_t, torso, 0x3A4); + ASSERT_STRUCT_OFFSET(actorInfo_t, dobjDirty, 0x3D4); + ASSERT_STRUCT_OFFSET(actorInfo_t, animsDirty, 0x3D8); + ASSERT_STRUCT_OFFSET(actorInfo_t, pXAnimTree, 0x3DC); + ASSERT_STRUCT_OFFSET(actorInfo_t, iDObjWeapon, 0x3E0); + ASSERT_STRUCT_OFFSET(actorInfo_t, stanceTransitionTime, 0x3E4); + ASSERT_STRUCT_OFFSET(actorInfo_t, turnAnimEndTime, 0x3E8); + ASSERT_STRUCT_OFFSET(actorInfo_t, turnAnimType, 0x3EC); + ASSERT_STRUCT_OFFSET(actorInfo_t, attachedEntNum, 0x3F0); + ASSERT_STRUCT_OFFSET(actorInfo_t, attachedTagName, 0x3F4); + ASSERT_STRUCT_OFFSET(actorInfo_t, animScriptedAnim, 0x434); + ASSERT_STRUCT_OFFSET(actorInfo_t, hideWeapon, 0x438); + ASSERT_STRUCT_OFFSET(actorInfo_t, hudwarningType, 0x43C); + ASSERT_STRUCT_OFFSET(actorInfo_t, lookAtEntNum, 0x440); + ASSERT_STRUCT_OFFSET(actorInfo_t, lastLookAtEntNum, 0x444); + ASSERT_STRUCT_OFFSET(actorInfo_t, lookAtBlend, 0x448); + ASSERT_STRUCT_OFFSET(actorInfo_t, lookAtBlendedIn, 0x44C); + ASSERT_STRUCT_OFFSET(actorInfo_t, lookAtTime, 0x450); + ASSERT_STRUCT_OFFSET(actorInfo_t, pad, 0x454); + + struct cgs_s + { + int viewX; //OFS: 0x0 SIZE: 0x4 + int viewY; //OFS: 0x4 SIZE: 0x4 + int viewWidth; //OFS: 0x8 SIZE: 0x4 + int viewHeight; //OFS: 0xC SIZE: 0x4 + float viewAspect; //OFS: 0x10 SIZE: 0x4 + int serverCommandSequence; //OFS: 0x14 SIZE: 0x4 + int processedSnapshotNum; //OFS: 0x18 SIZE: 0x4 + int localServer; //OFS: 0x1C SIZE: 0x4 + char gametype[32]; //OFS: 0x20 SIZE: 0x20 + char szHostName[256]; //OFS: 0x40 SIZE: 0x100 + int maxclients; //OFS: 0x140 SIZE: 0x4 + int privateClients; //OFS: 0x144 SIZE: 0x4 + char mapname[64]; //OFS: 0x148 SIZE: 0x40 + int voteTime; //OFS: 0x188 SIZE: 0x4 + int voteYes; //OFS: 0x18C SIZE: 0x4 + int voteNo; //OFS: 0x190 SIZE: 0x4 + char voteString[256]; //OFS: 0x194 SIZE: 0x100 + int redCrosshair; //OFS: 0x294 SIZE: 0x4 + XModel * gameModels[512]; //OFS: 0x298 SIZE: 0x800 + FxEffectDef * fxs[196]; //OFS: 0xA98 SIZE: 0x310 + FxEffectDef * grenadeFx[24]; //OFS: 0xDA8 SIZE: 0x60 + shellshock_parms_t holdBreathParams; //OFS: 0xE08 SIZE: 0x298 + char teamChatMsgs[8][151]; //OFS: 0x10A0 SIZE: 0x4B8 + int teamChatMsgTimes[8]; //OFS: 0x1558 SIZE: 0x20 + int teamChatPos; //OFS: 0x1578 SIZE: 0x4 + int teamLastChatPos; //OFS: 0x157C SIZE: 0x4 + int compassWidth; //OFS: 0x1580 SIZE: 0x4 + int compassHeight; //OFS: 0x1584 SIZE: 0x4 + int compassY; //OFS: 0x1588 SIZE: 0x4 + clientInfo_t corpseinfo[8]; //OFS: 0x158C SIZE: 0x2CA0 + actorInfo_t actorCorpseInfo[32]; //OFS: 0x422C SIZE: 0x8B00 + XAnim_s * generic_human; //OFS: 0xCD2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cgs_s, 0xCD30); + ASSERT_STRUCT_OFFSET(cgs_s, viewX, 0x0); + ASSERT_STRUCT_OFFSET(cgs_s, viewY, 0x4); + ASSERT_STRUCT_OFFSET(cgs_s, viewWidth, 0x8); + ASSERT_STRUCT_OFFSET(cgs_s, viewHeight, 0xC); + ASSERT_STRUCT_OFFSET(cgs_s, viewAspect, 0x10); + ASSERT_STRUCT_OFFSET(cgs_s, serverCommandSequence, 0x14); + ASSERT_STRUCT_OFFSET(cgs_s, processedSnapshotNum, 0x18); + ASSERT_STRUCT_OFFSET(cgs_s, localServer, 0x1C); + ASSERT_STRUCT_OFFSET(cgs_s, gametype, 0x20); + ASSERT_STRUCT_OFFSET(cgs_s, szHostName, 0x40); + ASSERT_STRUCT_OFFSET(cgs_s, maxclients, 0x140); + ASSERT_STRUCT_OFFSET(cgs_s, privateClients, 0x144); + ASSERT_STRUCT_OFFSET(cgs_s, mapname, 0x148); + ASSERT_STRUCT_OFFSET(cgs_s, voteTime, 0x188); + ASSERT_STRUCT_OFFSET(cgs_s, voteYes, 0x18C); + ASSERT_STRUCT_OFFSET(cgs_s, voteNo, 0x190); + ASSERT_STRUCT_OFFSET(cgs_s, voteString, 0x194); + ASSERT_STRUCT_OFFSET(cgs_s, redCrosshair, 0x294); + ASSERT_STRUCT_OFFSET(cgs_s, gameModels, 0x298); + ASSERT_STRUCT_OFFSET(cgs_s, fxs, 0xA98); + ASSERT_STRUCT_OFFSET(cgs_s, grenadeFx, 0xDA8); + ASSERT_STRUCT_OFFSET(cgs_s, holdBreathParams, 0xE08); + ASSERT_STRUCT_OFFSET(cgs_s, teamChatMsgs, 0x10A0); + ASSERT_STRUCT_OFFSET(cgs_s, teamChatMsgTimes, 0x1558); + ASSERT_STRUCT_OFFSET(cgs_s, teamChatPos, 0x1578); + ASSERT_STRUCT_OFFSET(cgs_s, teamLastChatPos, 0x157C); + ASSERT_STRUCT_OFFSET(cgs_s, compassWidth, 0x1580); + ASSERT_STRUCT_OFFSET(cgs_s, compassHeight, 0x1584); + ASSERT_STRUCT_OFFSET(cgs_s, compassY, 0x1588); + ASSERT_STRUCT_OFFSET(cgs_s, corpseinfo, 0x158C); + ASSERT_STRUCT_OFFSET(cgs_s, actorCorpseInfo, 0x422C); + ASSERT_STRUCT_OFFSET(cgs_s, generic_human, 0xCD2C); + + struct snapshot_s + { + int snapFlags; //OFS: 0x0 SIZE: 0x4 + int ping; //OFS: 0x4 SIZE: 0x4 + int serverTime; //OFS: 0x8 SIZE: 0x4 + playerState_s ps; //OFS: 0xC SIZE: 0x20AC + int numEntities; //OFS: 0x20B8 SIZE: 0x4 + int numClients; //OFS: 0x20BC SIZE: 0x4 + int numActors; //OFS: 0x20C0 SIZE: 0x4 + int field_20C4; //OFS: 0x20C4 SIZE: 0x4 + animCmdState_s parseAnimCmds[1117]; //OFS: 0x20C8 SIZE: 0xBFFC + int field_E0C4; //OFS: 0xE0C4 SIZE: 0x4 + char what; //OFS: 0xE0C8 SIZE: 0x1 + char whatthe[1024]; //OFS: 0xE0C9 SIZE: 0x400 + _BYTE gap_E4C9[3]; //OFS: 0xE4C9 SIZE: 0x3 + entityState_s parseEntities[1024]; //OFS: 0xE4CC SIZE: 0x46000 + clientState_s parseClients[4]; //OFS: 0x544CC SIZE: 0x250 + actorState_s parseActors[32]; //OFS: 0x5471C SIZE: 0xF00 + int serverCommandSequence; //OFS: 0x5561C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snapshot_s, 0x55620); + ASSERT_STRUCT_OFFSET(snapshot_s, snapFlags, 0x0); + ASSERT_STRUCT_OFFSET(snapshot_s, ping, 0x4); + ASSERT_STRUCT_OFFSET(snapshot_s, serverTime, 0x8); + ASSERT_STRUCT_OFFSET(snapshot_s, ps, 0xC); + ASSERT_STRUCT_OFFSET(snapshot_s, numEntities, 0x20B8); + ASSERT_STRUCT_OFFSET(snapshot_s, numClients, 0x20BC); + ASSERT_STRUCT_OFFSET(snapshot_s, numActors, 0x20C0); + ASSERT_STRUCT_OFFSET(snapshot_s, field_20C4, 0x20C4); + ASSERT_STRUCT_OFFSET(snapshot_s, parseAnimCmds, 0x20C8); + ASSERT_STRUCT_OFFSET(snapshot_s, field_E0C4, 0xE0C4); + ASSERT_STRUCT_OFFSET(snapshot_s, what, 0xE0C8); + ASSERT_STRUCT_OFFSET(snapshot_s, whatthe, 0xE0C9); + ASSERT_STRUCT_OFFSET(snapshot_s, gap_E4C9, 0xE4C9); + ASSERT_STRUCT_OFFSET(snapshot_s, parseEntities, 0xE4CC); + ASSERT_STRUCT_OFFSET(snapshot_s, parseClients, 0x544CC); + ASSERT_STRUCT_OFFSET(snapshot_s, parseActors, 0x5471C); + ASSERT_STRUCT_OFFSET(snapshot_s, serverCommandSequence, 0x5561C); + + struct playerEntity_t + { + float fLastWeaponPosFrac; //OFS: 0x0 SIZE: 0x4 + int bPositionToADS; //OFS: 0x4 SIZE: 0x4 + float vPositionLastOrg[3]; //OFS: 0x8 SIZE: 0xC + float vPositionLastAng[3]; //OFS: 0x14 SIZE: 0xC + float fLastIdleFactor; //OFS: 0x20 SIZE: 0x4 + float vLastMoveOrg[3]; //OFS: 0x24 SIZE: 0xC + float vLastMoveAng[3]; //OFS: 0x30 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(playerEntity_t, 0x3C); + ASSERT_STRUCT_OFFSET(playerEntity_t, fLastWeaponPosFrac, 0x0); + ASSERT_STRUCT_OFFSET(playerEntity_t, bPositionToADS, 0x4); + ASSERT_STRUCT_OFFSET(playerEntity_t, vPositionLastOrg, 0x8); + ASSERT_STRUCT_OFFSET(playerEntity_t, vPositionLastAng, 0x14); + ASSERT_STRUCT_OFFSET(playerEntity_t, fLastIdleFactor, 0x20); + ASSERT_STRUCT_OFFSET(playerEntity_t, vLastMoveOrg, 0x24); + ASSERT_STRUCT_OFFSET(playerEntity_t, vLastMoveAng, 0x30); + + struct refdef_s + { + _BYTE gap_0[28]; //OFS: 0x0 SIZE: 0x1C + float vieworg[3]; //OFS: 0x1C SIZE: 0xC + _BYTE gap_28[17083]; //OFS: 0x28 SIZE: 0x42BB + char field_42E3; //OFS: 0x42E3 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(refdef_s, 0x42E4); + ASSERT_STRUCT_OFFSET(refdef_s, gap_0, 0x0); + ASSERT_STRUCT_OFFSET(refdef_s, vieworg, 0x1C); + ASSERT_STRUCT_OFFSET(refdef_s, gap_28, 0x28); + ASSERT_STRUCT_OFFSET(refdef_s, field_42E3, 0x42E3); + + struct Camera + { + float lastViewOrg[3]; //OFS: 0x0 SIZE: 0xC + float lastViewAngles[3]; //OFS: 0xC SIZE: 0xC + float tweenStartOrg[3]; //OFS: 0x18 SIZE: 0xC + float tweenStartAngles[3]; //OFS: 0x24 SIZE: 0xC + float tweenStartFOV; //OFS: 0x30 SIZE: 0x4 + int tweenStartTime; //OFS: 0x34 SIZE: 0x4 + float tweenDuration; //OFS: 0x38 SIZE: 0x4 + float lastViewLockedEntOrg[3]; //OFS: 0x3C SIZE: 0xC + CameraMode lastCamMode; //OFS: 0x48 SIZE: 0x4 + int lastVehicleSeatPos; //OFS: 0x4C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Camera, 0x50); + ASSERT_STRUCT_OFFSET(Camera, lastViewOrg, 0x0); + ASSERT_STRUCT_OFFSET(Camera, lastViewAngles, 0xC); + ASSERT_STRUCT_OFFSET(Camera, tweenStartOrg, 0x18); + ASSERT_STRUCT_OFFSET(Camera, tweenStartAngles, 0x24); + ASSERT_STRUCT_OFFSET(Camera, tweenStartFOV, 0x30); + ASSERT_STRUCT_OFFSET(Camera, tweenStartTime, 0x34); + ASSERT_STRUCT_OFFSET(Camera, tweenDuration, 0x38); + ASSERT_STRUCT_OFFSET(Camera, lastViewLockedEntOrg, 0x3C); + ASSERT_STRUCT_OFFSET(Camera, lastCamMode, 0x48); + ASSERT_STRUCT_OFFSET(Camera, lastVehicleSeatPos, 0x4C); + + struct score_t + { + int client; //OFS: 0x0 SIZE: 0x4 + int score; //OFS: 0x4 SIZE: 0x4 + int ping; //OFS: 0x8 SIZE: 0x4 + int team; //OFS: 0xC SIZE: 0x4 + int kills; //OFS: 0x10 SIZE: 0x4 + int rank; //OFS: 0x14 SIZE: 0x4 + int assists; //OFS: 0x18 SIZE: 0x4 + int downs; //OFS: 0x1C SIZE: 0x4 + int revives; //OFS: 0x20 SIZE: 0x4 + int headshots; //OFS: 0x24 SIZE: 0x4 + int scoreMultiplier; //OFS: 0x28 SIZE: 0x4 + Material * hStatusIcon; //OFS: 0x2C SIZE: 0x4 + Material * hRankIcon; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(score_t, 0x34); + ASSERT_STRUCT_OFFSET(score_t, client, 0x0); + ASSERT_STRUCT_OFFSET(score_t, score, 0x4); + ASSERT_STRUCT_OFFSET(score_t, ping, 0x8); + ASSERT_STRUCT_OFFSET(score_t, team, 0xC); + ASSERT_STRUCT_OFFSET(score_t, kills, 0x10); + ASSERT_STRUCT_OFFSET(score_t, rank, 0x14); + ASSERT_STRUCT_OFFSET(score_t, assists, 0x18); + ASSERT_STRUCT_OFFSET(score_t, downs, 0x1C); + ASSERT_STRUCT_OFFSET(score_t, revives, 0x20); + ASSERT_STRUCT_OFFSET(score_t, headshots, 0x24); + ASSERT_STRUCT_OFFSET(score_t, scoreMultiplier, 0x28); + ASSERT_STRUCT_OFFSET(score_t, hStatusIcon, 0x2C); + ASSERT_STRUCT_OFFSET(score_t, hRankIcon, 0x30); + + struct viewDamage_t + { + int time; //OFS: 0x0 SIZE: 0x4 + int duration; //OFS: 0x4 SIZE: 0x4 + float yaw; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(viewDamage_t, 0xC); + ASSERT_STRUCT_OFFSET(viewDamage_t, time, 0x0); + ASSERT_STRUCT_OFFSET(viewDamage_t, duration, 0x4); + ASSERT_STRUCT_OFFSET(viewDamage_t, yaw, 0x8); + + struct objectiveInfo_t + { + objectiveState_t state; //OFS: 0x0 SIZE: 0x4 + float origin[8][3]; //OFS: 0x4 SIZE: 0x60 + int centNum[8]; //OFS: 0x64 SIZE: 0x20 + char string[1024]; //OFS: 0x84 SIZE: 0x400 + int ringTime; //OFS: 0x484 SIZE: 0x4 + int ringToggle; //OFS: 0x488 SIZE: 0x4 + int icon; //OFS: 0x48C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(objectiveInfo_t, 0x490); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, state, 0x0); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, origin, 0x4); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, centNum, 0x64); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, string, 0x84); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, ringTime, 0x484); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, ringToggle, 0x488); + ASSERT_STRUCT_OFFSET(objectiveInfo_t, icon, 0x48C); + + struct targetInfo_t + { + int entNum; //OFS: 0x0 SIZE: 0x4 + float offset[3]; //OFS: 0x4 SIZE: 0xC + int materialIndex; //OFS: 0x10 SIZE: 0x4 + int offscreenMaterialIndex; //OFS: 0x14 SIZE: 0x4 + int flags; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(targetInfo_t, 0x1C); + ASSERT_STRUCT_OFFSET(targetInfo_t, entNum, 0x0); + ASSERT_STRUCT_OFFSET(targetInfo_t, offset, 0x4); + ASSERT_STRUCT_OFFSET(targetInfo_t, materialIndex, 0x10); + ASSERT_STRUCT_OFFSET(targetInfo_t, offscreenMaterialIndex, 0x14); + ASSERT_STRUCT_OFFSET(targetInfo_t, flags, 0x18); + + struct shellshock_t + { + shellshock_parms_t * parms; //OFS: 0x0 SIZE: 0x4 + int startTime; //OFS: 0x4 SIZE: 0x4 + int duration; //OFS: 0x8 SIZE: 0x4 + int loopEndTime; //OFS: 0xC SIZE: 0x4 + float sensitivity; //OFS: 0x10 SIZE: 0x4 + float viewDelta[2]; //OFS: 0x14 SIZE: 0x8 + int hasSavedScreen; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(shellshock_t, 0x20); + ASSERT_STRUCT_OFFSET(shellshock_t, parms, 0x0); + ASSERT_STRUCT_OFFSET(shellshock_t, startTime, 0x4); + ASSERT_STRUCT_OFFSET(shellshock_t, duration, 0x8); + ASSERT_STRUCT_OFFSET(shellshock_t, loopEndTime, 0xC); + ASSERT_STRUCT_OFFSET(shellshock_t, sensitivity, 0x10); + ASSERT_STRUCT_OFFSET(shellshock_t, viewDelta, 0x14); + ASSERT_STRUCT_OFFSET(shellshock_t, hasSavedScreen, 0x1C); + + struct animScriptCondition_t + { + int index; //OFS: 0x0 SIZE: 0x4 + unsigned int value[2]; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(animScriptCondition_t, 0xC); + ASSERT_STRUCT_OFFSET(animScriptCondition_t, index, 0x0); + ASSERT_STRUCT_OFFSET(animScriptCondition_t, value, 0x4); + + struct animScriptCommand_t + { + __int16 bodyPart[2]; //OFS: 0x0 SIZE: 0x4 + __int16 animIndex[2]; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 animDuration[2]; //OFS: 0x8 SIZE: 0x4 + snd_alias_list_t * soundAlias; //OFS: 0xC SIZE: 0x4 + unsigned __int16 tagName; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 flags; //OFS: 0x12 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(animScriptCommand_t, 0x14); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, bodyPart, 0x0); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, animIndex, 0x4); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, animDuration, 0x8); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, soundAlias, 0xC); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, tagName, 0x10); + ASSERT_STRUCT_OFFSET(animScriptCommand_t, flags, 0x12); + + struct animScriptItem_t + { + int numConditions; //OFS: 0x0 SIZE: 0x4 + animScriptCondition_t conditions[4]; //OFS: 0x4 SIZE: 0x30 + int numCommands; //OFS: 0x34 SIZE: 0x4 + animScriptCommand_t commands[8]; //OFS: 0x38 SIZE: 0xA0 + }; + ASSERT_STRUCT_SIZE(animScriptItem_t, 0xD8); + ASSERT_STRUCT_OFFSET(animScriptItem_t, numConditions, 0x0); + ASSERT_STRUCT_OFFSET(animScriptItem_t, conditions, 0x4); + ASSERT_STRUCT_OFFSET(animScriptItem_t, numCommands, 0x34); + ASSERT_STRUCT_OFFSET(animScriptItem_t, commands, 0x38); + + struct animScript_t + { + int numItems; //OFS: 0x0 SIZE: 0x4 + animScriptItem_t * items[128]; //OFS: 0x4 SIZE: 0x200 + }; + ASSERT_STRUCT_SIZE(animScript_t, 0x204); + ASSERT_STRUCT_OFFSET(animScript_t, numItems, 0x0); + ASSERT_STRUCT_OFFSET(animScript_t, items, 0x4); + + struct __declspec(align(8)) animScriptData_t + { + animation_s animations[512]; //OFS: 0x0 SIZE: 0xD000 + unsigned int numAnimations; //OFS: 0xD000 SIZE: 0x4 + animScript_t scriptAnims[1][45]; //OFS: 0xD004 SIZE: 0x5AB4 + animScript_t scriptCannedAnims[1][45]; //OFS: 0x12AB8 SIZE: 0x5AB4 + animScript_t scriptStateChange[1][1]; //OFS: 0x1856C SIZE: 0x204 + animScript_t scriptEvents[25]; //OFS: 0x18770 SIZE: 0x3264 + animScriptItem_t scriptItems[2048]; //OFS: 0x1B9D4 SIZE: 0x6C000 + int numScriptItems; //OFS: 0x879D4 SIZE: 0x4 + scr_animtree_t animTree; //OFS: 0x879D8 SIZE: 0x4 + unsigned __int16 bodyAnim; //OFS: 0x879DC SIZE: 0x2 + unsigned __int16 mainAnim; //OFS: 0x879DE SIZE: 0x2 + unsigned __int16 torsoAnim; //OFS: 0x879E0 SIZE: 0x2 + unsigned __int16 legsAnim; //OFS: 0x879E2 SIZE: 0x2 + snd_alias_list_t *(__cdecl *soundAlias)(const char *); //OFS: 0x879E4 SIZE: 0x4 + void (__cdecl *playSoundAlias)(int, snd_alias_list_t *); //OFS: 0x879E8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animScriptData_t, 0x879F0); + ASSERT_STRUCT_OFFSET(animScriptData_t, animations, 0x0); + ASSERT_STRUCT_OFFSET(animScriptData_t, numAnimations, 0xD000); + ASSERT_STRUCT_OFFSET(animScriptData_t, scriptAnims, 0xD004); + ASSERT_STRUCT_OFFSET(animScriptData_t, scriptCannedAnims, 0x12AB8); + ASSERT_STRUCT_OFFSET(animScriptData_t, scriptStateChange, 0x1856C); + ASSERT_STRUCT_OFFSET(animScriptData_t, scriptEvents, 0x18770); + ASSERT_STRUCT_OFFSET(animScriptData_t, scriptItems, 0x1B9D4); + ASSERT_STRUCT_OFFSET(animScriptData_t, numScriptItems, 0x879D4); + ASSERT_STRUCT_OFFSET(animScriptData_t, animTree, 0x879D8); + ASSERT_STRUCT_OFFSET(animScriptData_t, bodyAnim, 0x879DC); + ASSERT_STRUCT_OFFSET(animScriptData_t, mainAnim, 0x879DE); + ASSERT_STRUCT_OFFSET(animScriptData_t, torsoAnim, 0x879E0); + ASSERT_STRUCT_OFFSET(animScriptData_t, legsAnim, 0x879E2); + ASSERT_STRUCT_OFFSET(animScriptData_t, soundAlias, 0x879E4); + ASSERT_STRUCT_OFFSET(animScriptData_t, playSoundAlias, 0x879E8); + + struct __declspec(align(2)) scr_anim_u_u + { + unsigned __int16 index; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 tree; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(scr_anim_u_u, 0x4); + ASSERT_STRUCT_OFFSET(scr_anim_u_u, index, 0x0); + ASSERT_STRUCT_OFFSET(scr_anim_u_u, tree, 0x2); + + union scr_anim_u + { + scr_anim_u_u s; //OFS: 0x0 SIZE: 0x4 + const char * linkPointer; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scr_anim_u, 0x4); + + struct scr_anim_s + { + scr_anim_u u; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(scr_anim_s, 0x4); + ASSERT_STRUCT_OFFSET(scr_anim_s, u, 0x0); + + struct bgs_t_generic_human + { + scr_animtree_t tree; //OFS: 0x0 SIZE: 0x4 + scr_anim_s torso; //OFS: 0x4 SIZE: 0x4 + scr_anim_s legs; //OFS: 0x8 SIZE: 0x4 + scr_anim_s turning; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(bgs_t_generic_human, 0x10); + ASSERT_STRUCT_OFFSET(bgs_t_generic_human, tree, 0x0); + ASSERT_STRUCT_OFFSET(bgs_t_generic_human, torso, 0x4); + ASSERT_STRUCT_OFFSET(bgs_t_generic_human, legs, 0x8); + ASSERT_STRUCT_OFFSET(bgs_t_generic_human, turning, 0xC); + + struct DSkelPartBits + { + int anim[4]; //OFS: 0x0 SIZE: 0x10 + int control[4]; //OFS: 0x10 SIZE: 0x10 + int skel[4]; //OFS: 0x20 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(DSkelPartBits, 0x30); + ASSERT_STRUCT_OFFSET(DSkelPartBits, anim, 0x0); + ASSERT_STRUCT_OFFSET(DSkelPartBits, control, 0x10); + ASSERT_STRUCT_OFFSET(DSkelPartBits, skel, 0x20); + + struct DSkel + { + DSkelPartBits partBits; //OFS: 0x0 SIZE: 0x30 + int timeStamp; //OFS: 0x30 SIZE: 0x4 + DObjAnimMat * mat; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DSkel, 0x38); + ASSERT_STRUCT_OFFSET(DSkel, partBits, 0x0); + ASSERT_STRUCT_OFFSET(DSkel, timeStamp, 0x30); + ASSERT_STRUCT_OFFSET(DSkel, mat, 0x34); + + struct DObj_s + { + XAnimTree_s * tree; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 duplicateParts; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 entnum; //OFS: 0x6 SIZE: 0x2 + unsigned __int8 duplicatePartsSize; //OFS: 0x8 SIZE: 0x1 + unsigned __int8 numModels; //OFS: 0x9 SIZE: 0x1 + unsigned __int8 numBones; //OFS: 0xA SIZE: 0x1 + unsigned int ignoreCollision; //OFS: 0xC SIZE: 0x4 + int locked; //OFS: 0x10 SIZE: 0x4 + DSkel skel; //OFS: 0x14 SIZE: 0x38 + float radius; //OFS: 0x4C SIZE: 0x4 + unsigned int hidePartBits[4]; //OFS: 0x50 SIZE: 0x10 + char localClientIndex; //OFS: 0x60 SIZE: 0x1 + unsigned __int8 flags; //OFS: 0x61 SIZE: 0x1 + unsigned __int16 ikStateIndex; //OFS: 0x62 SIZE: 0x2 + XModel ** models; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DObj_s, 0x68); + ASSERT_STRUCT_OFFSET(DObj_s, tree, 0x0); + ASSERT_STRUCT_OFFSET(DObj_s, duplicateParts, 0x4); + ASSERT_STRUCT_OFFSET(DObj_s, entnum, 0x6); + ASSERT_STRUCT_OFFSET(DObj_s, duplicatePartsSize, 0x8); + ASSERT_STRUCT_OFFSET(DObj_s, numModels, 0x9); + ASSERT_STRUCT_OFFSET(DObj_s, numBones, 0xA); + ASSERT_STRUCT_OFFSET(DObj_s, ignoreCollision, 0xC); + ASSERT_STRUCT_OFFSET(DObj_s, locked, 0x10); + ASSERT_STRUCT_OFFSET(DObj_s, skel, 0x14); + ASSERT_STRUCT_OFFSET(DObj_s, radius, 0x4C); + ASSERT_STRUCT_OFFSET(DObj_s, hidePartBits, 0x50); + ASSERT_STRUCT_OFFSET(DObj_s, localClientIndex, 0x60); + ASSERT_STRUCT_OFFSET(DObj_s, flags, 0x61); + ASSERT_STRUCT_OFFSET(DObj_s, ikStateIndex, 0x62); + ASSERT_STRUCT_OFFSET(DObj_s, models, 0x64); + + struct __declspec(align(8)) bgs_s + { + animScriptData_t animScriptData; //OFS: 0x0 SIZE: 0x879F0 + bgs_t_generic_human generic_human; //OFS: 0x879F0 SIZE: 0x10 + int time; //OFS: 0x87A00 SIZE: 0x4 + int latestSnapshotTime; //OFS: 0x87A04 SIZE: 0x4 + int frametime; //OFS: 0x87A08 SIZE: 0x4 + int anim_user; //OFS: 0x87A0C SIZE: 0x4 + XModel *(__cdecl *GetXModel)(const char *); //OFS: 0x87A10 SIZE: 0x4 + void (__cdecl *CreateDObj)(DObjModel_s *, unsigned __int16, XAnimTree_s *, int, int, clientInfo_t *); //OFS: 0x87A14 SIZE: 0x4 + unsigned __int16 (__cdecl *AttachWeapon)(DObjModel_s *, unsigned __int16, clientInfo_t *); //OFS: 0x87A18 SIZE: 0x4 + DObj_s *(__cdecl *GetDObj)(int handle, int localClientNum); //OFS: 0x87A1C SIZE: 0x4 + void (__cdecl *SafeDObjFree)(int, int); //OFS: 0x87A20 SIZE: 0x4 + void *(__cdecl *AllocXAnim)(int); //OFS: 0x87A24 SIZE: 0x4 + clientInfo_t clientInfo[4]; //OFS: 0x87A28 SIZE: 0x1650 + actorInfo_t actorinfo[32]; //OFS: 0x89078 SIZE: 0x8B00 + }; + ASSERT_STRUCT_SIZE(bgs_s, 0x91B78); + ASSERT_STRUCT_OFFSET(bgs_s, animScriptData, 0x0); + ASSERT_STRUCT_OFFSET(bgs_s, generic_human, 0x879F0); + ASSERT_STRUCT_OFFSET(bgs_s, time, 0x87A00); + ASSERT_STRUCT_OFFSET(bgs_s, latestSnapshotTime, 0x87A04); + ASSERT_STRUCT_OFFSET(bgs_s, frametime, 0x87A08); + ASSERT_STRUCT_OFFSET(bgs_s, anim_user, 0x87A0C); + ASSERT_STRUCT_OFFSET(bgs_s, GetXModel, 0x87A10); + ASSERT_STRUCT_OFFSET(bgs_s, CreateDObj, 0x87A14); + ASSERT_STRUCT_OFFSET(bgs_s, AttachWeapon, 0x87A18); + ASSERT_STRUCT_OFFSET(bgs_s, GetDObj, 0x87A1C); + ASSERT_STRUCT_OFFSET(bgs_s, SafeDObjFree, 0x87A20); + ASSERT_STRUCT_OFFSET(bgs_s, AllocXAnim, 0x87A24); + ASSERT_STRUCT_OFFSET(bgs_s, clientInfo, 0x87A28); + ASSERT_STRUCT_OFFSET(bgs_s, actorinfo, 0x89078); + + struct visionSetVars_t + { + bool glowEnable; //OFS: 0x0 SIZE: 0x1 + float glowBloomCutoff; //OFS: 0x4 SIZE: 0x4 + float glowBloomDesaturation; //OFS: 0x8 SIZE: 0x4 + float glowBloomIntensity0; //OFS: 0xC SIZE: 0x4 + float glowBloomIntensity1; //OFS: 0x10 SIZE: 0x4 + float glowRadius0; //OFS: 0x14 SIZE: 0x4 + float glowRadius1; //OFS: 0x18 SIZE: 0x4 + float glowSkyBleedIntensity0; //OFS: 0x1C SIZE: 0x4 + float glowSkyBleedIntensity1; //OFS: 0x20 SIZE: 0x4 + float glowRayExpansion; //OFS: 0x24 SIZE: 0x4 + float glowRayIntensity; //OFS: 0x28 SIZE: 0x4 + bool filmEnable; //OFS: 0x2C SIZE: 0x1 + float filmBrightness; //OFS: 0x30 SIZE: 0x4 + float filmContrast; //OFS: 0x34 SIZE: 0x4 + float filmDesaturation; //OFS: 0x38 SIZE: 0x4 + bool filmInvert; //OFS: 0x3C SIZE: 0x1 + float filmLightTint[3]; //OFS: 0x40 SIZE: 0xC + float filmDarkTint[3]; //OFS: 0x4C SIZE: 0xC + bool reviveEnable; //OFS: 0x58 SIZE: 0x1 + float reviveContrastEdge; //OFS: 0x5C SIZE: 0x4 + float reviveBrightnessEdge; //OFS: 0x60 SIZE: 0x4 + float reviveDesaturationEdge; //OFS: 0x64 SIZE: 0x4 + float reviveDarkTintEdge[3]; //OFS: 0x68 SIZE: 0xC + float reviveLightTintEdge[3]; //OFS: 0x74 SIZE: 0xC + float reviveBlurRadiusEdge; //OFS: 0x80 SIZE: 0x4 + float reviveMotionblurWeight; //OFS: 0x84 SIZE: 0x4 + float reviveContrastCenter; //OFS: 0x88 SIZE: 0x4 + float reviveBrightnessCenter; //OFS: 0x8C SIZE: 0x4 + float reviveDesaturationCenter; //OFS: 0x90 SIZE: 0x4 + float reviveDarkTintCenter[3]; //OFS: 0x94 SIZE: 0xC + float reviveLightTintCenter[3]; //OFS: 0xA0 SIZE: 0xC + float masterRingmod; //OFS: 0xAC SIZE: 0x4 + float reverbRingmod; //OFS: 0xB0 SIZE: 0x4 + float hiFilter; //OFS: 0xB4 SIZE: 0x4 + float lowFilter; //OFS: 0xB8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(visionSetVars_t, 0xBC); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowEnable, 0x0); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowBloomCutoff, 0x4); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowBloomDesaturation, 0x8); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowBloomIntensity0, 0xC); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowBloomIntensity1, 0x10); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowRadius0, 0x14); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowRadius1, 0x18); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowSkyBleedIntensity0, 0x1C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowSkyBleedIntensity1, 0x20); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowRayExpansion, 0x24); + ASSERT_STRUCT_OFFSET(visionSetVars_t, glowRayIntensity, 0x28); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmEnable, 0x2C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmBrightness, 0x30); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmContrast, 0x34); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmDesaturation, 0x38); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmInvert, 0x3C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmLightTint, 0x40); + ASSERT_STRUCT_OFFSET(visionSetVars_t, filmDarkTint, 0x4C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveEnable, 0x58); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveContrastEdge, 0x5C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveBrightnessEdge, 0x60); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveDesaturationEdge, 0x64); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveDarkTintEdge, 0x68); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveLightTintEdge, 0x74); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveBlurRadiusEdge, 0x80); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveMotionblurWeight, 0x84); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveContrastCenter, 0x88); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveBrightnessCenter, 0x8C); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveDesaturationCenter, 0x90); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveDarkTintCenter, 0x94); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reviveLightTintCenter, 0xA0); + ASSERT_STRUCT_OFFSET(visionSetVars_t, masterRingmod, 0xAC); + ASSERT_STRUCT_OFFSET(visionSetVars_t, reverbRingmod, 0xB0); + ASSERT_STRUCT_OFFSET(visionSetVars_t, hiFilter, 0xB4); + ASSERT_STRUCT_OFFSET(visionSetVars_t, lowFilter, 0xB8); + + struct visionSetLerpData_t + { + int timeStart; //OFS: 0x0 SIZE: 0x4 + int timeDuration; //OFS: 0x4 SIZE: 0x4 + visionSetLerpStyle_t style; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(visionSetLerpData_t, 0xC); + ASSERT_STRUCT_OFFSET(visionSetLerpData_t, timeStart, 0x0); + ASSERT_STRUCT_OFFSET(visionSetLerpData_t, timeDuration, 0x4); + ASSERT_STRUCT_OFFSET(visionSetLerpData_t, style, 0x8); + + struct cg_s_lastFrame + { + float aimSpreadScale; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cg_s_lastFrame, 0x4); + ASSERT_STRUCT_OFFSET(cg_s_lastFrame, aimSpreadScale, 0x0); + + struct hudElemSoundInfo_t + { + int lastPlayedTime; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(hudElemSoundInfo_t, 0x4); + ASSERT_STRUCT_OFFSET(hudElemSoundInfo_t, lastPlayedTime, 0x0); + + struct markerInfo_t + { + markerState_t state; //OFS: 0x0 SIZE: 0x4 + char shader[1024]; //OFS: 0x4 SIZE: 0x400 + float scale; //OFS: 0x404 SIZE: 0x4 + int entityNum; //OFS: 0x408 SIZE: 0x4 + float vector[3]; //OFS: 0x40C SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(markerInfo_t, 0x418); + ASSERT_STRUCT_OFFSET(markerInfo_t, state, 0x0); + ASSERT_STRUCT_OFFSET(markerInfo_t, shader, 0x4); + ASSERT_STRUCT_OFFSET(markerInfo_t, scale, 0x404); + ASSERT_STRUCT_OFFSET(markerInfo_t, entityNum, 0x408); + ASSERT_STRUCT_OFFSET(markerInfo_t, vector, 0x40C); + + struct cg_s + { + int clientNum; //OFS: 0x0 SIZE: 0x4 + int localClientNum; //OFS: 0x4 SIZE: 0x4 + DemoType demoType; //OFS: 0x8 SIZE: 0x4 + CubemapShot cubemapShot; //OFS: 0xC SIZE: 0x4 + int cubemapSize; //OFS: 0x10 SIZE: 0x4 + int renderScreen; //OFS: 0x14 SIZE: 0x4 + int latestSnapshotNum; //OFS: 0x18 SIZE: 0x4 + int snapServerTime; //OFS: 0x1C SIZE: 0x4 + int loaded; //OFS: 0x20 SIZE: 0x4 + snapshot_s * snap; //OFS: 0x24 SIZE: 0x4 + snapshot_s * nextSnap; //OFS: 0x28 SIZE: 0x4 + snapshot_s activeSnapshots[2]; //OFS: 0x2C SIZE: 0xAAC40 + centity_s * currTarget; //OFS: 0xAAC6C SIZE: 0x4 + XModel * knifeModel; //OFS: 0xAAC70 SIZE: 0x4 + float frameInterpolation; //OFS: 0xAAC74 SIZE: 0x4 + int frametime; //OFS: 0xAAC78 SIZE: 0x4 + int time; //OFS: 0xAAC7C SIZE: 0x4 + int time_real; //OFS: 0xAAC80 SIZE: 0x4 + int oldTime; //OFS: 0xAAC84 SIZE: 0x4 + int physicsTime; //OFS: 0xAAC88 SIZE: 0x4 + char mapRestart; //OFS: 0xAAC8C SIZE: 0x1 + int renderingThirdPerson; //OFS: 0xAAC90 SIZE: 0x4 + void * script_camera; //OFS: 0xAAC94 SIZE: 0x4 + playerState_s predictedPlayerState; //OFS: 0xAAC98 SIZE: 0x20AC + centity_s predictedPlayerEntity; //OFS: 0xACD44 SIZE: 0x2D4 + playerEntity_t playerEntity; //OFS: 0xAD018 SIZE: 0x3C + int predictedErrorTime; //OFS: 0xAD054 SIZE: 0x4 + float predictedError[3]; //OFS: 0xAD058 SIZE: 0xC + _BYTE gapAD064[12]; //OFS: 0xAD064 SIZE: 0xC + float landChange; //OFS: 0xAD070 SIZE: 0x4 + int landTime; //OFS: 0xAD074 SIZE: 0x4 + float heightToCeiling; //OFS: 0xAD078 SIZE: 0x4 + int heightToCeilingTS; //OFS: 0xAD07C SIZE: 0x4 + refdef_s refdef; //OFS: 0xAD080 SIZE: 0x42E4 + float refdefViewAngles[3]; //OFS: 0xB1364 SIZE: 0xC + Camera cameraData; //OFS: 0xB1370 SIZE: 0x50 + float swayViewAngles[3]; //OFS: 0xB13C0 SIZE: 0xC + float swayAngles[3]; //OFS: 0xB13CC SIZE: 0xC + float swayOffset[3]; //OFS: 0xB13D8 SIZE: 0xC + float lastStandSwayAngles[3]; //OFS: 0xB13E4 SIZE: 0xC + float lastStandSwayAVel[3]; //OFS: 0xB13F0 SIZE: 0xC + float lastStandSwayTarget[3]; //OFS: 0xB13FC SIZE: 0xC + int iEntityLastType[2048]; //OFS: 0xB1408 SIZE: 0x2000 + XModel * pEntityLastXMode[2048]; //OFS: 0xB3408 SIZE: 0x2000 + bool bEntityDObjDirty[2048]; //OFS: 0xB5408 SIZE: 0x800 + int iEntityLastAnimtree[2048]; //OFS: 0xB5C08 SIZE: 0x2000 + float zoomSensitivity; //OFS: 0xB7C08 SIZE: 0x4 + char isLoading; //OFS: 0xB7C0C SIZE: 0x1 + char objectiveText[1024]; //OFS: 0xB7C0D SIZE: 0x400 + int vehicleInitView; //OFS: 0xB8010 SIZE: 0x4 + float prevVehicleInvAxis[3][3]; //OFS: 0xB8014 SIZE: 0x24 + char vehicleViewLocked; //OFS: 0xB8038 SIZE: 0x1 + float vehicleViewLockedAngles[3]; //OFS: 0xB803C SIZE: 0xC + char scriptMainMenu[256]; //OFS: 0xB8048 SIZE: 0x100 + int scoresRequestTime; //OFS: 0xB8148 SIZE: 0x4 + int numScores; //OFS: 0xB814C SIZE: 0x4 + score_t scores[4]; //OFS: 0xB8150 SIZE: 0xD0 + int showScores_real; //OFS: 0xB8220 SIZE: 0x4 + int scoreFadeTime_real; //OFS: 0xB8224 SIZE: 0x4 + int scoresOffBottom; //OFS: 0xB8228 SIZE: 0x4 + int scoresBottom; //OFS: 0xB822C SIZE: 0x4 + int firstLineVisible; //OFS: 0xB8230 SIZE: 0x4 + int lastLineVisible; //OFS: 0xB8234 SIZE: 0x4 + int drawHud; //OFS: 0xB8238 SIZE: 0x4 + int timeScaleTimeStart; //OFS: 0xB823C SIZE: 0x4 + float timeScaleStart; //OFS: 0xB8240 SIZE: 0x4 + int timeScaleTimeEnd; //OFS: 0xB8244 SIZE: 0x4 + float timeScaleEnd; //OFS: 0xB8248 SIZE: 0x4 + int crosshairClientNum; //OFS: 0xB824C SIZE: 0x4 + int crosshairClientLastTime; //OFS: 0xB8250 SIZE: 0x4 + int crosshairClientStartTime; //OFS: 0xB8254 SIZE: 0x4 + int identifyClientNum; //OFS: 0xB8258 SIZE: 0x4 + int deadquoteStartTime; //OFS: 0xB825C SIZE: 0x4 + int cursorHintIcon; //OFS: 0xB8260 SIZE: 0x4 + int cursorHintTime; //OFS: 0xB8264 SIZE: 0x4 + int cursorHintFade; //OFS: 0xB8268 SIZE: 0x4 + int cursorHintString; //OFS: 0xB826C SIZE: 0x4 + int lastClipFlashTime; //OFS: 0xB8270 SIZE: 0x4 + int invalidCmdHintType; //OFS: 0xB8274 SIZE: 0x4 + int invalidCmdHintTime; //OFS: 0xB8278 SIZE: 0x4 + int successfulCmdHintType; //OFS: 0xB827C SIZE: 0x4 + int successfulCmdHintTime; //OFS: 0xB8280 SIZE: 0x4 + int lastHealthPulseTime; //OFS: 0xB8284 SIZE: 0x4 + int lastHealthLerpDelay; //OFS: 0xB8288 SIZE: 0x4 + int lastHealthClient; //OFS: 0xB828C SIZE: 0x4 + float lastHealth; //OFS: 0xB8290 SIZE: 0x4 + float healthOverlayFromAlpha; //OFS: 0xB8294 SIZE: 0x4 + float healthOverlayToAlpha; //OFS: 0xB8298 SIZE: 0x4 + int healthOverlayPulseTime; //OFS: 0xB829C SIZE: 0x4 + int healthOverlayPulseDuration; //OFS: 0xB82A0 SIZE: 0x4 + int healthOverlayPulsePhase; //OFS: 0xB82A4 SIZE: 0x4 + bool healthOverlayHurt; //OFS: 0xB82A8 SIZE: 0x1 + int healthOverlayLastHitTime; //OFS: 0xB82AC SIZE: 0x4 + float healthOverlayOldHealth; //OFS: 0xB82B0 SIZE: 0x4 + int healthOverlayPulseIndex; //OFS: 0xB82B4 SIZE: 0x4 + int proneBlockedEndTime; //OFS: 0xB82B8 SIZE: 0x4 + int lastStance; //OFS: 0xB82BC SIZE: 0x4 + int lastStanceChangeTime; //OFS: 0xB82C0 SIZE: 0x4 + int lastStanceFlashTime; //OFS: 0xB82C4 SIZE: 0x4 + int voiceTime; //OFS: 0xB82C8 SIZE: 0x4 + int weaponSelect; //OFS: 0xB82CC SIZE: 0x4 + int weaponSelectTime; //OFS: 0xB82D0 SIZE: 0x4 + int weaponLatestPrimaryIdx; //OFS: 0xB82D4 SIZE: 0x4 + int prevViewmodelWeapon; //OFS: 0xB82D8 SIZE: 0x4 + int equippedOffHand; //OFS: 0xB82DC SIZE: 0x4 + viewDamage_t viewDamage[8]; //OFS: 0xB82E0 SIZE: 0x60 + int damageTime; //OFS: 0xB8340 SIZE: 0x4 + float damageX; //OFS: 0xB8344 SIZE: 0x4 + float damageY; //OFS: 0xB8348 SIZE: 0x4 + float damageValue; //OFS: 0xB834C SIZE: 0x4 + float viewFade; //OFS: 0xB8350 SIZE: 0x4 + int waterDropCount; //OFS: 0xB8354 SIZE: 0x4 + int waterDropStartTime; //OFS: 0xB8358 SIZE: 0x4 + int waterDropStopTime; //OFS: 0xB835C SIZE: 0x4 + int weapIdleTime; //OFS: 0xB8360 SIZE: 0x4 + int nomarks; //OFS: 0xB8364 SIZE: 0x4 + int v_dmg_time; //OFS: 0xB8368 SIZE: 0x4 + float v_dmg_pitch; //OFS: 0xB836C SIZE: 0x4 + float v_dmg_roll; //OFS: 0xB8370 SIZE: 0x4 + float fBobCycle; //OFS: 0xB8374 SIZE: 0x4 + float xyspeed; //OFS: 0xB8378 SIZE: 0x4 + float kickAVel[3]; //OFS: 0xB837C SIZE: 0xC + float kickAngles[3]; //OFS: 0xB8388 SIZE: 0xC + float offsetAngles[3]; //OFS: 0xB8394 SIZE: 0xC + char field_B83A0; //OFS: 0xB83A0 SIZE: 0x1 + int gunPitch; //OFS: 0xB83A4 SIZE: 0x4 + int gunYaw; //OFS: 0xB83A8 SIZE: 0x4 + int gunXOfs; //OFS: 0xB83AC SIZE: 0x4 + int gunYOfs; //OFS: 0xB83B0 SIZE: 0x4 + int gunZOfs; //OFS: 0xB83B4 SIZE: 0x4 + float vGunOffset[3]; //OFS: 0xB83B8 SIZE: 0xC + float recoilSpeed[3]; //OFS: 0xB83C4 SIZE: 0xC + float vAngOfs[3]; //OFS: 0xB83D0 SIZE: 0xC + float flamethrowerYawCap; //OFS: 0xB83DC SIZE: 0x4 + float flamethrowerPitchCap; //OFS: 0xB83E0 SIZE: 0x4 + float flamethrowerKickOffset[3]; //OFS: 0xB83E4 SIZE: 0xC + float viewModelAxis[4][3]; //OFS: 0xB83F0 SIZE: 0x30 + char hideViewModel; //OFS: 0xB8420 SIZE: 0x1 + float rumbleScale; //OFS: 0xB8424 SIZE: 0x4 + int compassNorthYaw; //OFS: 0xB8428 SIZE: 0x4 + float compassNorth[2]; //OFS: 0xB842C SIZE: 0x8 + Material * compassMapMaterial; //OFS: 0xB8434 SIZE: 0x4 + float compassMapUpperLeft[2]; //OFS: 0xB8438 SIZE: 0x8 + float compassMapWorldSize[2]; //OFS: 0xB8440 SIZE: 0x8 + int compassLastTime; //OFS: 0xB8448 SIZE: 0x4 + float compassYaw; //OFS: 0xB844C SIZE: 0x4 + float compassSpeed; //OFS: 0xB8450 SIZE: 0x4 + int compassFadeTime; //OFS: 0xB8454 SIZE: 0x4 + int healthFadeTime; //OFS: 0xB8458 SIZE: 0x4 + int ammoFadeTime; //OFS: 0xB845C SIZE: 0x4 + int stanceFadeTime; //OFS: 0xB8460 SIZE: 0x4 + int sprintFadeTime; //OFS: 0xB8464 SIZE: 0x4 + int offhandFadeTime; //OFS: 0xB8468 SIZE: 0x4 + int offhandFlashTime; //OFS: 0xB846C SIZE: 0x4 + objectiveInfo_t objectiveInfo_t[16]; //OFS: 0xB8470 SIZE: 0x4900 + int showScores; //OFS: 0xBCD70 SIZE: 0x4 + int scoreFadeTime; //OFS: 0xBCD74 SIZE: 0x4 + targetInfo_t targets[32]; //OFS: 0xBCD78 SIZE: 0x380 + shellshock_t shellshock; //OFS: 0xBD0F8 SIZE: 0x20 + int field_BD118; //OFS: 0xBD118 SIZE: 0x4 + int field_BD11C; //OFS: 0xBD11C SIZE: 0x4 + int field_BD120; //OFS: 0xBD120 SIZE: 0x4 + int holdBreathTime; //OFS: 0xBD124 SIZE: 0x4 + int holdBreathInTime; //OFS: 0xBD128 SIZE: 0x4 + int holdBreathDelay; //OFS: 0xBD12C SIZE: 0x4 + float holdBreathFrac; //OFS: 0xBD130 SIZE: 0x4 + int waterBob; //OFS: 0xBD134 SIZE: 0x4 + int bloodLastTime; //OFS: 0xBD138 SIZE: 0x4 + int radarProgress; //OFS: 0xBD13C SIZE: 0x4 + float selectedLocation[2]; //OFS: 0xBD140 SIZE: 0x8 + SprintState sprintStates; //OFS: 0xBD148 SIZE: 0x14 + int adsViewErrorDone; //OFS: 0xBD15C SIZE: 0x4 + int inKillCam; //OFS: 0xBD160 SIZE: 0x4 + int field_BD164; //OFS: 0xBD164 SIZE: 0x4 + bgs_s bgs; //OFS: 0xBD168 SIZE: 0x91B78 + char field_14ECE0[45056]; //OFS: 0x14ECE0 SIZE: 0xB000 + float vehReticleOffset[2]; //OFS: 0x159CE0 SIZE: 0x8 + float vehReticleVel[2]; //OFS: 0x159CE8 SIZE: 0x8 + int vehReticleLockOnStartTime; //OFS: 0x159CF0 SIZE: 0x4 + int vehReticleLockOnDuration; //OFS: 0x159CF4 SIZE: 0x4 + int vehReticleLockOnEntNum; //OFS: 0x159CF8 SIZE: 0x4 + cpose_t viewModelPose; //OFS: 0x159CFC SIZE: 0xD0 + visionSetVars_t visionSetPreLoaded[8]; //OFS: 0x159DCC SIZE: 0x5E0 + char visionSetPreLoadedName[512]; //OFS: 0x15A3AC SIZE: 0x200 + visionSetVars_t visionSetFrom[6]; //OFS: 0x15A5AC SIZE: 0x468 + visionSetVars_t visionSetTo[6]; //OFS: 0x15AA14 SIZE: 0x468 + visionSetVars_t visionSetCurrent[6]; //OFS: 0x15AE7C SIZE: 0x468 + visionSetLerpData_t visionSetLerpData[6]; //OFS: 0x15B2E4 SIZE: 0x48 + char visionNameNaked[64]; //OFS: 0x15B32C SIZE: 0x40 + char visionNameNight[64]; //OFS: 0x15B36C SIZE: 0x40 + char visionNameVampire0[64]; //OFS: 0x15B3AC SIZE: 0x40 + char visionNameVampire1[64]; //OFS: 0x15B3EC SIZE: 0x40 + char visionNameBerserker0[64]; //OFS: 0x15B42C SIZE: 0x40 + char visionNameBerserker1[64]; //OFS: 0x15B46C SIZE: 0x40 + char visionNameLastStand[64]; //OFS: 0x15B4AC SIZE: 0x40 + char visionNameDeath[64]; //OFS: 0x15B4EC SIZE: 0x40 + int extraButtons; //OFS: 0x15B52C SIZE: 0x4 + int lastActionSlotTime; //OFS: 0x15B530 SIZE: 0x4 + int playerTeleported; //OFS: 0x15B534 SIZE: 0x4 + int stepViewStart; //OFS: 0x15B538 SIZE: 0x4 + float stepViewChange; //OFS: 0x15B53C SIZE: 0x4 + cg_s_lastFrame lastFrame; //OFS: 0x15B540 SIZE: 0x4 + int nextRippleTime; //OFS: 0x15B544 SIZE: 0x4 + float zNear; //OFS: 0x15B548 SIZE: 0x4 + float prevLinkedInvQuat[4]; //OFS: 0x15B54C SIZE: 0x10 + float linkAnglesFrac; //OFS: 0x15B55C SIZE: 0x4 + char prevLinkAnglesSet; //OFS: 0x15B560 SIZE: 0x1 + hudElemSoundInfo_t hudElemSound[32]; //OFS: 0x15B564 SIZE: 0x80 + markerInfo_t markers[8]; //OFS: 0x15B5E4 SIZE: 0x20C0 + int impactEffectsNext; //OFS: 0x15D6A4 SIZE: 0x4 + int impactEffects[256]; //OFS: 0x15D6A8 SIZE: 0x400 + char visionsetVampireEnable; //OFS: 0x15DAA8 SIZE: 0x1 + char visionsetBerserkerEnable; //OFS: 0x15DAA9 SIZE: 0x1 + char visionsetDeathEnable; //OFS: 0x15DAAA SIZE: 0x1 + int generateClientSave; //OFS: 0x15DAAC SIZE: 0x4 + int commitClientSave; //OFS: 0x15DAB0 SIZE: 0x4 + char zapperMenuActive; //OFS: 0x15DAB4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(cg_s, 0x15DAB8); + ASSERT_STRUCT_OFFSET(cg_s, clientNum, 0x0); + ASSERT_STRUCT_OFFSET(cg_s, localClientNum, 0x4); + ASSERT_STRUCT_OFFSET(cg_s, demoType, 0x8); + ASSERT_STRUCT_OFFSET(cg_s, cubemapShot, 0xC); + ASSERT_STRUCT_OFFSET(cg_s, cubemapSize, 0x10); + ASSERT_STRUCT_OFFSET(cg_s, renderScreen, 0x14); + ASSERT_STRUCT_OFFSET(cg_s, latestSnapshotNum, 0x18); + ASSERT_STRUCT_OFFSET(cg_s, snapServerTime, 0x1C); + ASSERT_STRUCT_OFFSET(cg_s, loaded, 0x20); + ASSERT_STRUCT_OFFSET(cg_s, snap, 0x24); + ASSERT_STRUCT_OFFSET(cg_s, nextSnap, 0x28); + ASSERT_STRUCT_OFFSET(cg_s, activeSnapshots, 0x2C); + ASSERT_STRUCT_OFFSET(cg_s, currTarget, 0xAAC6C); + ASSERT_STRUCT_OFFSET(cg_s, knifeModel, 0xAAC70); + ASSERT_STRUCT_OFFSET(cg_s, frameInterpolation, 0xAAC74); + ASSERT_STRUCT_OFFSET(cg_s, frametime, 0xAAC78); + ASSERT_STRUCT_OFFSET(cg_s, time, 0xAAC7C); + ASSERT_STRUCT_OFFSET(cg_s, time_real, 0xAAC80); + ASSERT_STRUCT_OFFSET(cg_s, oldTime, 0xAAC84); + ASSERT_STRUCT_OFFSET(cg_s, physicsTime, 0xAAC88); + ASSERT_STRUCT_OFFSET(cg_s, mapRestart, 0xAAC8C); + ASSERT_STRUCT_OFFSET(cg_s, renderingThirdPerson, 0xAAC90); + ASSERT_STRUCT_OFFSET(cg_s, script_camera, 0xAAC94); + ASSERT_STRUCT_OFFSET(cg_s, predictedPlayerState, 0xAAC98); + ASSERT_STRUCT_OFFSET(cg_s, predictedPlayerEntity, 0xACD44); + ASSERT_STRUCT_OFFSET(cg_s, playerEntity, 0xAD018); + ASSERT_STRUCT_OFFSET(cg_s, predictedErrorTime, 0xAD054); + ASSERT_STRUCT_OFFSET(cg_s, predictedError, 0xAD058); + ASSERT_STRUCT_OFFSET(cg_s, gapAD064, 0xAD064); + ASSERT_STRUCT_OFFSET(cg_s, landChange, 0xAD070); + ASSERT_STRUCT_OFFSET(cg_s, landTime, 0xAD074); + ASSERT_STRUCT_OFFSET(cg_s, heightToCeiling, 0xAD078); + ASSERT_STRUCT_OFFSET(cg_s, heightToCeilingTS, 0xAD07C); + ASSERT_STRUCT_OFFSET(cg_s, refdef, 0xAD080); + ASSERT_STRUCT_OFFSET(cg_s, refdefViewAngles, 0xB1364); + ASSERT_STRUCT_OFFSET(cg_s, cameraData, 0xB1370); + ASSERT_STRUCT_OFFSET(cg_s, swayViewAngles, 0xB13C0); + ASSERT_STRUCT_OFFSET(cg_s, swayAngles, 0xB13CC); + ASSERT_STRUCT_OFFSET(cg_s, swayOffset, 0xB13D8); + ASSERT_STRUCT_OFFSET(cg_s, lastStandSwayAngles, 0xB13E4); + ASSERT_STRUCT_OFFSET(cg_s, lastStandSwayAVel, 0xB13F0); + ASSERT_STRUCT_OFFSET(cg_s, lastStandSwayTarget, 0xB13FC); + ASSERT_STRUCT_OFFSET(cg_s, iEntityLastType, 0xB1408); + ASSERT_STRUCT_OFFSET(cg_s, pEntityLastXMode, 0xB3408); + ASSERT_STRUCT_OFFSET(cg_s, bEntityDObjDirty, 0xB5408); + ASSERT_STRUCT_OFFSET(cg_s, iEntityLastAnimtree, 0xB5C08); + ASSERT_STRUCT_OFFSET(cg_s, zoomSensitivity, 0xB7C08); + ASSERT_STRUCT_OFFSET(cg_s, isLoading, 0xB7C0C); + ASSERT_STRUCT_OFFSET(cg_s, objectiveText, 0xB7C0D); + ASSERT_STRUCT_OFFSET(cg_s, vehicleInitView, 0xB8010); + ASSERT_STRUCT_OFFSET(cg_s, prevVehicleInvAxis, 0xB8014); + ASSERT_STRUCT_OFFSET(cg_s, vehicleViewLocked, 0xB8038); + ASSERT_STRUCT_OFFSET(cg_s, vehicleViewLockedAngles, 0xB803C); + ASSERT_STRUCT_OFFSET(cg_s, scriptMainMenu, 0xB8048); + ASSERT_STRUCT_OFFSET(cg_s, scoresRequestTime, 0xB8148); + ASSERT_STRUCT_OFFSET(cg_s, numScores, 0xB814C); + ASSERT_STRUCT_OFFSET(cg_s, scores, 0xB8150); + ASSERT_STRUCT_OFFSET(cg_s, showScores_real, 0xB8220); + ASSERT_STRUCT_OFFSET(cg_s, scoreFadeTime_real, 0xB8224); + ASSERT_STRUCT_OFFSET(cg_s, scoresOffBottom, 0xB8228); + ASSERT_STRUCT_OFFSET(cg_s, scoresBottom, 0xB822C); + ASSERT_STRUCT_OFFSET(cg_s, firstLineVisible, 0xB8230); + ASSERT_STRUCT_OFFSET(cg_s, lastLineVisible, 0xB8234); + ASSERT_STRUCT_OFFSET(cg_s, drawHud, 0xB8238); + ASSERT_STRUCT_OFFSET(cg_s, timeScaleTimeStart, 0xB823C); + ASSERT_STRUCT_OFFSET(cg_s, timeScaleStart, 0xB8240); + ASSERT_STRUCT_OFFSET(cg_s, timeScaleTimeEnd, 0xB8244); + ASSERT_STRUCT_OFFSET(cg_s, timeScaleEnd, 0xB8248); + ASSERT_STRUCT_OFFSET(cg_s, crosshairClientNum, 0xB824C); + ASSERT_STRUCT_OFFSET(cg_s, crosshairClientLastTime, 0xB8250); + ASSERT_STRUCT_OFFSET(cg_s, crosshairClientStartTime, 0xB8254); + ASSERT_STRUCT_OFFSET(cg_s, identifyClientNum, 0xB8258); + ASSERT_STRUCT_OFFSET(cg_s, deadquoteStartTime, 0xB825C); + ASSERT_STRUCT_OFFSET(cg_s, cursorHintIcon, 0xB8260); + ASSERT_STRUCT_OFFSET(cg_s, cursorHintTime, 0xB8264); + ASSERT_STRUCT_OFFSET(cg_s, cursorHintFade, 0xB8268); + ASSERT_STRUCT_OFFSET(cg_s, cursorHintString, 0xB826C); + ASSERT_STRUCT_OFFSET(cg_s, lastClipFlashTime, 0xB8270); + ASSERT_STRUCT_OFFSET(cg_s, invalidCmdHintType, 0xB8274); + ASSERT_STRUCT_OFFSET(cg_s, invalidCmdHintTime, 0xB8278); + ASSERT_STRUCT_OFFSET(cg_s, successfulCmdHintType, 0xB827C); + ASSERT_STRUCT_OFFSET(cg_s, successfulCmdHintTime, 0xB8280); + ASSERT_STRUCT_OFFSET(cg_s, lastHealthPulseTime, 0xB8284); + ASSERT_STRUCT_OFFSET(cg_s, lastHealthLerpDelay, 0xB8288); + ASSERT_STRUCT_OFFSET(cg_s, lastHealthClient, 0xB828C); + ASSERT_STRUCT_OFFSET(cg_s, lastHealth, 0xB8290); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayFromAlpha, 0xB8294); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayToAlpha, 0xB8298); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayPulseTime, 0xB829C); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayPulseDuration, 0xB82A0); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayPulsePhase, 0xB82A4); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayHurt, 0xB82A8); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayLastHitTime, 0xB82AC); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayOldHealth, 0xB82B0); + ASSERT_STRUCT_OFFSET(cg_s, healthOverlayPulseIndex, 0xB82B4); + ASSERT_STRUCT_OFFSET(cg_s, proneBlockedEndTime, 0xB82B8); + ASSERT_STRUCT_OFFSET(cg_s, lastStance, 0xB82BC); + ASSERT_STRUCT_OFFSET(cg_s, lastStanceChangeTime, 0xB82C0); + ASSERT_STRUCT_OFFSET(cg_s, lastStanceFlashTime, 0xB82C4); + ASSERT_STRUCT_OFFSET(cg_s, voiceTime, 0xB82C8); + ASSERT_STRUCT_OFFSET(cg_s, weaponSelect, 0xB82CC); + ASSERT_STRUCT_OFFSET(cg_s, weaponSelectTime, 0xB82D0); + ASSERT_STRUCT_OFFSET(cg_s, weaponLatestPrimaryIdx, 0xB82D4); + ASSERT_STRUCT_OFFSET(cg_s, prevViewmodelWeapon, 0xB82D8); + ASSERT_STRUCT_OFFSET(cg_s, equippedOffHand, 0xB82DC); + ASSERT_STRUCT_OFFSET(cg_s, viewDamage, 0xB82E0); + ASSERT_STRUCT_OFFSET(cg_s, damageTime, 0xB8340); + ASSERT_STRUCT_OFFSET(cg_s, damageX, 0xB8344); + ASSERT_STRUCT_OFFSET(cg_s, damageY, 0xB8348); + ASSERT_STRUCT_OFFSET(cg_s, damageValue, 0xB834C); + ASSERT_STRUCT_OFFSET(cg_s, viewFade, 0xB8350); + ASSERT_STRUCT_OFFSET(cg_s, waterDropCount, 0xB8354); + ASSERT_STRUCT_OFFSET(cg_s, waterDropStartTime, 0xB8358); + ASSERT_STRUCT_OFFSET(cg_s, waterDropStopTime, 0xB835C); + ASSERT_STRUCT_OFFSET(cg_s, weapIdleTime, 0xB8360); + ASSERT_STRUCT_OFFSET(cg_s, nomarks, 0xB8364); + ASSERT_STRUCT_OFFSET(cg_s, v_dmg_time, 0xB8368); + ASSERT_STRUCT_OFFSET(cg_s, v_dmg_pitch, 0xB836C); + ASSERT_STRUCT_OFFSET(cg_s, v_dmg_roll, 0xB8370); + ASSERT_STRUCT_OFFSET(cg_s, fBobCycle, 0xB8374); + ASSERT_STRUCT_OFFSET(cg_s, xyspeed, 0xB8378); + ASSERT_STRUCT_OFFSET(cg_s, kickAVel, 0xB837C); + ASSERT_STRUCT_OFFSET(cg_s, kickAngles, 0xB8388); + ASSERT_STRUCT_OFFSET(cg_s, offsetAngles, 0xB8394); + ASSERT_STRUCT_OFFSET(cg_s, field_B83A0, 0xB83A0); + ASSERT_STRUCT_OFFSET(cg_s, gunPitch, 0xB83A4); + ASSERT_STRUCT_OFFSET(cg_s, gunYaw, 0xB83A8); + ASSERT_STRUCT_OFFSET(cg_s, gunXOfs, 0xB83AC); + ASSERT_STRUCT_OFFSET(cg_s, gunYOfs, 0xB83B0); + ASSERT_STRUCT_OFFSET(cg_s, gunZOfs, 0xB83B4); + ASSERT_STRUCT_OFFSET(cg_s, vGunOffset, 0xB83B8); + ASSERT_STRUCT_OFFSET(cg_s, recoilSpeed, 0xB83C4); + ASSERT_STRUCT_OFFSET(cg_s, vAngOfs, 0xB83D0); + ASSERT_STRUCT_OFFSET(cg_s, flamethrowerYawCap, 0xB83DC); + ASSERT_STRUCT_OFFSET(cg_s, flamethrowerPitchCap, 0xB83E0); + ASSERT_STRUCT_OFFSET(cg_s, flamethrowerKickOffset, 0xB83E4); + ASSERT_STRUCT_OFFSET(cg_s, viewModelAxis, 0xB83F0); + ASSERT_STRUCT_OFFSET(cg_s, hideViewModel, 0xB8420); + ASSERT_STRUCT_OFFSET(cg_s, rumbleScale, 0xB8424); + ASSERT_STRUCT_OFFSET(cg_s, compassNorthYaw, 0xB8428); + ASSERT_STRUCT_OFFSET(cg_s, compassNorth, 0xB842C); + ASSERT_STRUCT_OFFSET(cg_s, compassMapMaterial, 0xB8434); + ASSERT_STRUCT_OFFSET(cg_s, compassMapUpperLeft, 0xB8438); + ASSERT_STRUCT_OFFSET(cg_s, compassMapWorldSize, 0xB8440); + ASSERT_STRUCT_OFFSET(cg_s, compassLastTime, 0xB8448); + ASSERT_STRUCT_OFFSET(cg_s, compassYaw, 0xB844C); + ASSERT_STRUCT_OFFSET(cg_s, compassSpeed, 0xB8450); + ASSERT_STRUCT_OFFSET(cg_s, compassFadeTime, 0xB8454); + ASSERT_STRUCT_OFFSET(cg_s, healthFadeTime, 0xB8458); + ASSERT_STRUCT_OFFSET(cg_s, ammoFadeTime, 0xB845C); + ASSERT_STRUCT_OFFSET(cg_s, stanceFadeTime, 0xB8460); + ASSERT_STRUCT_OFFSET(cg_s, sprintFadeTime, 0xB8464); + ASSERT_STRUCT_OFFSET(cg_s, offhandFadeTime, 0xB8468); + ASSERT_STRUCT_OFFSET(cg_s, offhandFlashTime, 0xB846C); + ASSERT_STRUCT_OFFSET(cg_s, objectiveInfo_t, 0xB8470); + ASSERT_STRUCT_OFFSET(cg_s, showScores, 0xBCD70); + ASSERT_STRUCT_OFFSET(cg_s, scoreFadeTime, 0xBCD74); + ASSERT_STRUCT_OFFSET(cg_s, targets, 0xBCD78); + ASSERT_STRUCT_OFFSET(cg_s, shellshock, 0xBD0F8); + ASSERT_STRUCT_OFFSET(cg_s, field_BD118, 0xBD118); + ASSERT_STRUCT_OFFSET(cg_s, field_BD11C, 0xBD11C); + ASSERT_STRUCT_OFFSET(cg_s, field_BD120, 0xBD120); + ASSERT_STRUCT_OFFSET(cg_s, holdBreathTime, 0xBD124); + ASSERT_STRUCT_OFFSET(cg_s, holdBreathInTime, 0xBD128); + ASSERT_STRUCT_OFFSET(cg_s, holdBreathDelay, 0xBD12C); + ASSERT_STRUCT_OFFSET(cg_s, holdBreathFrac, 0xBD130); + ASSERT_STRUCT_OFFSET(cg_s, waterBob, 0xBD134); + ASSERT_STRUCT_OFFSET(cg_s, bloodLastTime, 0xBD138); + ASSERT_STRUCT_OFFSET(cg_s, radarProgress, 0xBD13C); + ASSERT_STRUCT_OFFSET(cg_s, selectedLocation, 0xBD140); + ASSERT_STRUCT_OFFSET(cg_s, sprintStates, 0xBD148); + ASSERT_STRUCT_OFFSET(cg_s, adsViewErrorDone, 0xBD15C); + ASSERT_STRUCT_OFFSET(cg_s, inKillCam, 0xBD160); + ASSERT_STRUCT_OFFSET(cg_s, field_BD164, 0xBD164); + ASSERT_STRUCT_OFFSET(cg_s, bgs, 0xBD168); + ASSERT_STRUCT_OFFSET(cg_s, field_14ECE0, 0x14ECE0); + ASSERT_STRUCT_OFFSET(cg_s, vehReticleOffset, 0x159CE0); + ASSERT_STRUCT_OFFSET(cg_s, vehReticleVel, 0x159CE8); + ASSERT_STRUCT_OFFSET(cg_s, vehReticleLockOnStartTime, 0x159CF0); + ASSERT_STRUCT_OFFSET(cg_s, vehReticleLockOnDuration, 0x159CF4); + ASSERT_STRUCT_OFFSET(cg_s, vehReticleLockOnEntNum, 0x159CF8); + ASSERT_STRUCT_OFFSET(cg_s, viewModelPose, 0x159CFC); + ASSERT_STRUCT_OFFSET(cg_s, visionSetPreLoaded, 0x159DCC); + ASSERT_STRUCT_OFFSET(cg_s, visionSetPreLoadedName, 0x15A3AC); + ASSERT_STRUCT_OFFSET(cg_s, visionSetFrom, 0x15A5AC); + ASSERT_STRUCT_OFFSET(cg_s, visionSetTo, 0x15AA14); + ASSERT_STRUCT_OFFSET(cg_s, visionSetCurrent, 0x15AE7C); + ASSERT_STRUCT_OFFSET(cg_s, visionSetLerpData, 0x15B2E4); + ASSERT_STRUCT_OFFSET(cg_s, visionNameNaked, 0x15B32C); + ASSERT_STRUCT_OFFSET(cg_s, visionNameNight, 0x15B36C); + ASSERT_STRUCT_OFFSET(cg_s, visionNameVampire0, 0x15B3AC); + ASSERT_STRUCT_OFFSET(cg_s, visionNameVampire1, 0x15B3EC); + ASSERT_STRUCT_OFFSET(cg_s, visionNameBerserker0, 0x15B42C); + ASSERT_STRUCT_OFFSET(cg_s, visionNameBerserker1, 0x15B46C); + ASSERT_STRUCT_OFFSET(cg_s, visionNameLastStand, 0x15B4AC); + ASSERT_STRUCT_OFFSET(cg_s, visionNameDeath, 0x15B4EC); + ASSERT_STRUCT_OFFSET(cg_s, extraButtons, 0x15B52C); + ASSERT_STRUCT_OFFSET(cg_s, lastActionSlotTime, 0x15B530); + ASSERT_STRUCT_OFFSET(cg_s, playerTeleported, 0x15B534); + ASSERT_STRUCT_OFFSET(cg_s, stepViewStart, 0x15B538); + ASSERT_STRUCT_OFFSET(cg_s, stepViewChange, 0x15B53C); + ASSERT_STRUCT_OFFSET(cg_s, lastFrame, 0x15B540); + ASSERT_STRUCT_OFFSET(cg_s, nextRippleTime, 0x15B544); + ASSERT_STRUCT_OFFSET(cg_s, zNear, 0x15B548); + ASSERT_STRUCT_OFFSET(cg_s, prevLinkedInvQuat, 0x15B54C); + ASSERT_STRUCT_OFFSET(cg_s, linkAnglesFrac, 0x15B55C); + ASSERT_STRUCT_OFFSET(cg_s, prevLinkAnglesSet, 0x15B560); + ASSERT_STRUCT_OFFSET(cg_s, hudElemSound, 0x15B564); + ASSERT_STRUCT_OFFSET(cg_s, markers, 0x15B5E4); + ASSERT_STRUCT_OFFSET(cg_s, impactEffectsNext, 0x15D6A4); + ASSERT_STRUCT_OFFSET(cg_s, impactEffects, 0x15D6A8); + ASSERT_STRUCT_OFFSET(cg_s, visionsetVampireEnable, 0x15DAA8); + ASSERT_STRUCT_OFFSET(cg_s, visionsetBerserkerEnable, 0x15DAA9); + ASSERT_STRUCT_OFFSET(cg_s, visionsetDeathEnable, 0x15DAAA); + ASSERT_STRUCT_OFFSET(cg_s, generateClientSave, 0x15DAAC); + ASSERT_STRUCT_OFFSET(cg_s, commitClientSave, 0x15DAB0); + ASSERT_STRUCT_OFFSET(cg_s, zapperMenuActive, 0x15DAB4); + + struct SpawnVar + { + bool spawnVarsValid; //OFS: 0x0 SIZE: 0x1 + int numSpawnVars; //OFS: 0x4 SIZE: 0x4 + char * spawnVars[64][2]; //OFS: 0x8 SIZE: 0x200 + int numSpawnVarChars; //OFS: 0x208 SIZE: 0x4 + char spawnVarChars[2048]; //OFS: 0x20C SIZE: 0x800 + }; + ASSERT_STRUCT_SIZE(SpawnVar, 0xA0C); + ASSERT_STRUCT_OFFSET(SpawnVar, spawnVarsValid, 0x0); + ASSERT_STRUCT_OFFSET(SpawnVar, numSpawnVars, 0x4); + ASSERT_STRUCT_OFFSET(SpawnVar, spawnVars, 0x8); + ASSERT_STRUCT_OFFSET(SpawnVar, numSpawnVarChars, 0x208); + ASSERT_STRUCT_OFFSET(SpawnVar, spawnVarChars, 0x20C); + + struct cached_tag_mat_t + { + int time; //OFS: 0x0 SIZE: 0x4 + int entnum; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 name; //OFS: 0x8 SIZE: 0x2 + float tagMat[4][3]; //OFS: 0xC SIZE: 0x30 + }; + ASSERT_STRUCT_SIZE(cached_tag_mat_t, 0x3C); + ASSERT_STRUCT_OFFSET(cached_tag_mat_t, time, 0x0); + ASSERT_STRUCT_OFFSET(cached_tag_mat_t, entnum, 0x4); + ASSERT_STRUCT_OFFSET(cached_tag_mat_t, name, 0x8); + ASSERT_STRUCT_OFFSET(cached_tag_mat_t, tagMat, 0xC); + + struct trigger_info_t + { + unsigned __int16 entnum; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 otherEntnum; //OFS: 0x2 SIZE: 0x2 + int useCount; //OFS: 0x4 SIZE: 0x4 + int otherUseCount; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(trigger_info_t, 0xC); + ASSERT_STRUCT_OFFSET(trigger_info_t, entnum, 0x0); + ASSERT_STRUCT_OFFSET(trigger_info_t, otherEntnum, 0x2); + ASSERT_STRUCT_OFFSET(trigger_info_t, useCount, 0x4); + ASSERT_STRUCT_OFFSET(trigger_info_t, otherUseCount, 0x8); + + struct level_locals_s + { + gclient_s * clients; //OFS: 0x0 SIZE: 0x4 + gentity_s * gentities; //OFS: 0x4 SIZE: 0x4 + int unk1; //OFS: 0x8 SIZE: 0x4 + int num_entities; //OFS: 0xC SIZE: 0x4 + gentity_s * firstFreeEnt; //OFS: 0x10 SIZE: 0x4 + gentity_s * lastFreeEnt; //OFS: 0x14 SIZE: 0x4 + sentient_s * sentients; //OFS: 0x18 SIZE: 0x4 + actor_s * actors; //OFS: 0x1C SIZE: 0x4 + scr_vehicle_s * vehicles; //OFS: 0x20 SIZE: 0x4 + TurretInfo * turrets; //OFS: 0x24 SIZE: 0x4 + animCmdState_s * animCmds; //OFS: 0x28 SIZE: 0x4 + int gap_2C[1024]; //OFS: 0x2C SIZE: 0x1000 + int logFile; //OFS: 0x102C SIZE: 0x4 + int initializing; //OFS: 0x1030 SIZE: 0x4 + int clientIsSpawning; //OFS: 0x1034 SIZE: 0x4 + int maxclients; //OFS: 0x1038 SIZE: 0x4 + int framenum; //OFS: 0x103C SIZE: 0x4 + int time; //OFS: 0x1040 SIZE: 0x4 + int previousTime; //OFS: 0x1044 SIZE: 0x4 + int startTime; //OFS: 0x1048 SIZE: 0x4 + int newSession; //OFS: 0x104C SIZE: 0x4 + int actorCorpseCount; //OFS: 0x1050 SIZE: 0x4 + SpawnVar spawnVar; //OFS: 0x1054 SIZE: 0xA0C + int reloadDelayTime; //OFS: 0x1A60 SIZE: 0x4 + int absoluteReloadDelayTime; //OFS: 0x1A64 SIZE: 0x4 + EntHandle droppedWeaponCue[32]; //OFS: 0x1A68 SIZE: 0x80 + int changelevel; //OFS: 0x1AE8 SIZE: 0x4 + int bMissionSuccess; //OFS: 0x1AEC SIZE: 0x4 + int bMissionFailed; //OFS: 0x1AF0 SIZE: 0x4 + int exitTime; //OFS: 0x1AF4 SIZE: 0x4 + int savepersist; //OFS: 0x1AF8 SIZE: 0x4 + char cinematic[64]; //OFS: 0x1AFC SIZE: 0x40 + float fFogOpaqueDist; //OFS: 0x1B3C SIZE: 0x4 + float fFogOpaqueDistSqrd; //OFS: 0x1B40 SIZE: 0x4 + unsigned int grenadeHintCount; //OFS: 0x1B44 SIZE: 0x4 + int remapCount; //OFS: 0x1B48 SIZE: 0x4 + int iSearchFrame; //OFS: 0x1B4C SIZE: 0x4 + loading_t loading; //OFS: 0x1B50 SIZE: 0x4 + int actorPredictDepth; //OFS: 0x1B54 SIZE: 0x4 + int bDrawCompassFriendlies; //OFS: 0x1B58 SIZE: 0x4 + int bPlayerIgnoreRadiusDamage; //OFS: 0x1B5C SIZE: 0x4 + int bPlayerIgnoreRadiusDamageLatched; //OFS: 0x1B60 SIZE: 0x4 + int triggerIndex; //OFS: 0x1B64 SIZE: 0x4 + int padd; //OFS: 0x1B68 SIZE: 0x4 + int currentEntityThink; //OFS: 0x1B6C SIZE: 0x4 + int currentIndex; //OFS: 0x1B70 SIZE: 0x4 + bool checkAnimChange; //OFS: 0x1B74 SIZE: 0x1 + int registerWeapons; //OFS: 0x1B78 SIZE: 0x4 + int bRegisterItems; //OFS: 0x1B7C SIZE: 0x4 + int framePos; //OFS: 0x1B80 SIZE: 0x4 + cached_tag_mat_t cachedTagMat; //OFS: 0x1B84 SIZE: 0x3C + cached_tag_mat_t cachedEntTargetTagMat; //OFS: 0x1BC0 SIZE: 0x3C + __int16 soundAliasFirst; //OFS: 0x1BFC SIZE: 0x2 + __int16 soundAliasLast; //OFS: 0x1BFE SIZE: 0x2 + trigger_info_t pendingTriggerList[256]; //OFS: 0x1C00 SIZE: 0xC00 + trigger_info_t currentTriggerList[256]; //OFS: 0x2800 SIZE: 0xC00 + int pendingTriggerListSize; //OFS: 0x3400 SIZE: 0x4 + int currentTriggerListSize; //OFS: 0x3404 SIZE: 0x4 + int entTriggerIndex[1024]; //OFS: 0x3408 SIZE: 0x1000 + unsigned __int8 specialIndex[1024]; //OFS: 0x4408 SIZE: 0x400 + _BYTE gap4808[2628]; //OFS: 0x4808 SIZE: 0xA44 + int scriptPrintChannel; //OFS: 0x524C SIZE: 0x4 + float compassMapUpperLeft[2]; //OFS: 0x5250 SIZE: 0x8 + float compassMapWorldSize[2]; //OFS: 0x5258 SIZE: 0x8 + float compassNorth[2]; //OFS: 0x5260 SIZE: 0x8 + float mapSunColor[3]; //OFS: 0x5268 SIZE: 0xC + float mapSunDirection[3]; //OFS: 0x5274 SIZE: 0xC + int script_ai_limit; //OFS: 0x5280 SIZE: 0x4 + int disable_grenade_suicide; //OFS: 0x5284 SIZE: 0x4 + _BYTE gap5288[4]; //OFS: 0x5288 SIZE: 0x4 + int manualNameChange; //OFS: 0x528C SIZE: 0x4 + objective_t objectives[16]; //OFS: 0x5290 SIZE: 0x200 + int frameTime; //OFS: 0x5490 SIZE: 0x4 + int finished; //OFS: 0x5494 SIZE: 0x4 + int levelWasForceEnded; //OFS: 0x5498 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(level_locals_s, 0x549C); + ASSERT_STRUCT_OFFSET(level_locals_s, clients, 0x0); + ASSERT_STRUCT_OFFSET(level_locals_s, gentities, 0x4); + ASSERT_STRUCT_OFFSET(level_locals_s, unk1, 0x8); + ASSERT_STRUCT_OFFSET(level_locals_s, num_entities, 0xC); + ASSERT_STRUCT_OFFSET(level_locals_s, firstFreeEnt, 0x10); + ASSERT_STRUCT_OFFSET(level_locals_s, lastFreeEnt, 0x14); + ASSERT_STRUCT_OFFSET(level_locals_s, sentients, 0x18); + ASSERT_STRUCT_OFFSET(level_locals_s, actors, 0x1C); + ASSERT_STRUCT_OFFSET(level_locals_s, vehicles, 0x20); + ASSERT_STRUCT_OFFSET(level_locals_s, turrets, 0x24); + ASSERT_STRUCT_OFFSET(level_locals_s, animCmds, 0x28); + ASSERT_STRUCT_OFFSET(level_locals_s, gap_2C, 0x2C); + ASSERT_STRUCT_OFFSET(level_locals_s, logFile, 0x102C); + ASSERT_STRUCT_OFFSET(level_locals_s, initializing, 0x1030); + ASSERT_STRUCT_OFFSET(level_locals_s, clientIsSpawning, 0x1034); + ASSERT_STRUCT_OFFSET(level_locals_s, maxclients, 0x1038); + ASSERT_STRUCT_OFFSET(level_locals_s, framenum, 0x103C); + ASSERT_STRUCT_OFFSET(level_locals_s, time, 0x1040); + ASSERT_STRUCT_OFFSET(level_locals_s, previousTime, 0x1044); + ASSERT_STRUCT_OFFSET(level_locals_s, startTime, 0x1048); + ASSERT_STRUCT_OFFSET(level_locals_s, newSession, 0x104C); + ASSERT_STRUCT_OFFSET(level_locals_s, actorCorpseCount, 0x1050); + ASSERT_STRUCT_OFFSET(level_locals_s, spawnVar, 0x1054); + ASSERT_STRUCT_OFFSET(level_locals_s, reloadDelayTime, 0x1A60); + ASSERT_STRUCT_OFFSET(level_locals_s, absoluteReloadDelayTime, 0x1A64); + ASSERT_STRUCT_OFFSET(level_locals_s, droppedWeaponCue, 0x1A68); + ASSERT_STRUCT_OFFSET(level_locals_s, changelevel, 0x1AE8); + ASSERT_STRUCT_OFFSET(level_locals_s, bMissionSuccess, 0x1AEC); + ASSERT_STRUCT_OFFSET(level_locals_s, bMissionFailed, 0x1AF0); + ASSERT_STRUCT_OFFSET(level_locals_s, exitTime, 0x1AF4); + ASSERT_STRUCT_OFFSET(level_locals_s, savepersist, 0x1AF8); + ASSERT_STRUCT_OFFSET(level_locals_s, cinematic, 0x1AFC); + ASSERT_STRUCT_OFFSET(level_locals_s, fFogOpaqueDist, 0x1B3C); + ASSERT_STRUCT_OFFSET(level_locals_s, fFogOpaqueDistSqrd, 0x1B40); + ASSERT_STRUCT_OFFSET(level_locals_s, grenadeHintCount, 0x1B44); + ASSERT_STRUCT_OFFSET(level_locals_s, remapCount, 0x1B48); + ASSERT_STRUCT_OFFSET(level_locals_s, iSearchFrame, 0x1B4C); + ASSERT_STRUCT_OFFSET(level_locals_s, loading, 0x1B50); + ASSERT_STRUCT_OFFSET(level_locals_s, actorPredictDepth, 0x1B54); + ASSERT_STRUCT_OFFSET(level_locals_s, bDrawCompassFriendlies, 0x1B58); + ASSERT_STRUCT_OFFSET(level_locals_s, bPlayerIgnoreRadiusDamage, 0x1B5C); + ASSERT_STRUCT_OFFSET(level_locals_s, bPlayerIgnoreRadiusDamageLatched, 0x1B60); + ASSERT_STRUCT_OFFSET(level_locals_s, triggerIndex, 0x1B64); + ASSERT_STRUCT_OFFSET(level_locals_s, padd, 0x1B68); + ASSERT_STRUCT_OFFSET(level_locals_s, currentEntityThink, 0x1B6C); + ASSERT_STRUCT_OFFSET(level_locals_s, currentIndex, 0x1B70); + ASSERT_STRUCT_OFFSET(level_locals_s, checkAnimChange, 0x1B74); + ASSERT_STRUCT_OFFSET(level_locals_s, registerWeapons, 0x1B78); + ASSERT_STRUCT_OFFSET(level_locals_s, bRegisterItems, 0x1B7C); + ASSERT_STRUCT_OFFSET(level_locals_s, framePos, 0x1B80); + ASSERT_STRUCT_OFFSET(level_locals_s, cachedTagMat, 0x1B84); + ASSERT_STRUCT_OFFSET(level_locals_s, cachedEntTargetTagMat, 0x1BC0); + ASSERT_STRUCT_OFFSET(level_locals_s, soundAliasFirst, 0x1BFC); + ASSERT_STRUCT_OFFSET(level_locals_s, soundAliasLast, 0x1BFE); + ASSERT_STRUCT_OFFSET(level_locals_s, pendingTriggerList, 0x1C00); + ASSERT_STRUCT_OFFSET(level_locals_s, currentTriggerList, 0x2800); + ASSERT_STRUCT_OFFSET(level_locals_s, pendingTriggerListSize, 0x3400); + ASSERT_STRUCT_OFFSET(level_locals_s, currentTriggerListSize, 0x3404); + ASSERT_STRUCT_OFFSET(level_locals_s, entTriggerIndex, 0x3408); + ASSERT_STRUCT_OFFSET(level_locals_s, specialIndex, 0x4408); + ASSERT_STRUCT_OFFSET(level_locals_s, gap4808, 0x4808); + ASSERT_STRUCT_OFFSET(level_locals_s, scriptPrintChannel, 0x524C); + ASSERT_STRUCT_OFFSET(level_locals_s, compassMapUpperLeft, 0x5250); + ASSERT_STRUCT_OFFSET(level_locals_s, compassMapWorldSize, 0x5258); + ASSERT_STRUCT_OFFSET(level_locals_s, compassNorth, 0x5260); + ASSERT_STRUCT_OFFSET(level_locals_s, mapSunColor, 0x5268); + ASSERT_STRUCT_OFFSET(level_locals_s, mapSunDirection, 0x5274); + ASSERT_STRUCT_OFFSET(level_locals_s, script_ai_limit, 0x5280); + ASSERT_STRUCT_OFFSET(level_locals_s, disable_grenade_suicide, 0x5284); + ASSERT_STRUCT_OFFSET(level_locals_s, gap5288, 0x5288); + ASSERT_STRUCT_OFFSET(level_locals_s, manualNameChange, 0x528C); + ASSERT_STRUCT_OFFSET(level_locals_s, objectives, 0x5290); + ASSERT_STRUCT_OFFSET(level_locals_s, frameTime, 0x5490); + ASSERT_STRUCT_OFFSET(level_locals_s, finished, 0x5494); + ASSERT_STRUCT_OFFSET(level_locals_s, levelWasForceEnded, 0x5498); + + struct FxBoltAndSortOrder_s1 + { + __int32 _bf_0; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxBoltAndSortOrder_s1, 0x4); + ASSERT_STRUCT_OFFSET(FxBoltAndSortOrder_s1, _bf_0, 0x0); + + struct FxBoltAndSortOrder_s2 + { + __int32 _bf_0; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxBoltAndSortOrder_s2, 0x4); + ASSERT_STRUCT_OFFSET(FxBoltAndSortOrder_s2, _bf_0, 0x0); + + union FxBoltAndSortOrder + { + FxBoltAndSortOrder_s1 s0; //OFS: 0x0 SIZE: 0x4 + FxBoltAndSortOrder_s2 s1; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxBoltAndSortOrder, 0x4); + + struct FxSpatialFrame + { + float quat[4]; //OFS: 0x0 SIZE: 0x10 + float origin[3]; //OFS: 0x10 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(FxSpatialFrame, 0x1C); + ASSERT_STRUCT_OFFSET(FxSpatialFrame, quat, 0x0); + ASSERT_STRUCT_OFFSET(FxSpatialFrame, origin, 0x10); + + struct orientation_t + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float axis[3][3]; //OFS: 0xC SIZE: 0x24 + }; + ASSERT_STRUCT_SIZE(orientation_t, 0x30); + ASSERT_STRUCT_OFFSET(orientation_t, origin, 0x0); + ASSERT_STRUCT_OFFSET(orientation_t, axis, 0xC); + + struct FxEffect + { + FxEffectDef * def; //OFS: 0x0 SIZE: 0x4 + int status; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 firstElemHandle[3]; //OFS: 0x8 SIZE: 0x6 + unsigned __int16 firstSortedElemHandle; //OFS: 0xE SIZE: 0x2 + unsigned __int16 firstTrailHandle; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 randomSeed; //OFS: 0x12 SIZE: 0x2 + unsigned __int16 owner; //OFS: 0x14 SIZE: 0x2 + unsigned __int16 packedLighting; //OFS: 0x16 SIZE: 0x2 + FxBoltAndSortOrder boltAndSortOrder; //OFS: 0x18 SIZE: 0x4 + int frameCount; //OFS: 0x1C SIZE: 0x4 + int msecBegin; //OFS: 0x20 SIZE: 0x4 + int msecLastUpdate; //OFS: 0x24 SIZE: 0x4 + FxSpatialFrame frameAtSpawn; //OFS: 0x28 SIZE: 0x1C + FxSpatialFrame frameNow; //OFS: 0x44 SIZE: 0x1C + FxSpatialFrame framePrev; //OFS: 0x60 SIZE: 0x1C + float distanceTraveled; //OFS: 0x7C SIZE: 0x4 + orientation_t boneOffset; //OFS: 0x80 SIZE: 0x30 + unsigned int uniqueHandle; //OFS: 0xB0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxEffect, 0xB4); + ASSERT_STRUCT_OFFSET(FxEffect, def, 0x0); + ASSERT_STRUCT_OFFSET(FxEffect, status, 0x4); + ASSERT_STRUCT_OFFSET(FxEffect, firstElemHandle, 0x8); + ASSERT_STRUCT_OFFSET(FxEffect, firstSortedElemHandle, 0xE); + ASSERT_STRUCT_OFFSET(FxEffect, firstTrailHandle, 0x10); + ASSERT_STRUCT_OFFSET(FxEffect, randomSeed, 0x12); + ASSERT_STRUCT_OFFSET(FxEffect, owner, 0x14); + ASSERT_STRUCT_OFFSET(FxEffect, packedLighting, 0x16); + ASSERT_STRUCT_OFFSET(FxEffect, boltAndSortOrder, 0x18); + ASSERT_STRUCT_OFFSET(FxEffect, frameCount, 0x1C); + ASSERT_STRUCT_OFFSET(FxEffect, msecBegin, 0x20); + ASSERT_STRUCT_OFFSET(FxEffect, msecLastUpdate, 0x24); + ASSERT_STRUCT_OFFSET(FxEffect, frameAtSpawn, 0x28); + ASSERT_STRUCT_OFFSET(FxEffect, frameNow, 0x44); + ASSERT_STRUCT_OFFSET(FxEffect, framePrev, 0x60); + ASSERT_STRUCT_OFFSET(FxEffect, distanceTraveled, 0x7C); + ASSERT_STRUCT_OFFSET(FxEffect, boneOffset, 0x80); + ASSERT_STRUCT_OFFSET(FxEffect, uniqueHandle, 0xB0); + + struct __declspec(align(1)) FxElem_u_s_fade + { + char fadeAlpha; //OFS: 0x0 SIZE: 0x1 + char fadeAlphaPerSec; //OFS: 0x1 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(FxElem_u_s_fade, 0x2); + ASSERT_STRUCT_OFFSET(FxElem_u_s_fade, fadeAlpha, 0x0); + ASSERT_STRUCT_OFFSET(FxElem_u_s_fade, fadeAlphaPerSec, 0x1); + + struct __declspec(align(2)) FxElem_u_s + { + unsigned __int16 lightingHandle; //OFS: 0x0 SIZE: 0x2 + FxElem_u_s_fade fade; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(FxElem_u_s, 0x4); + ASSERT_STRUCT_OFFSET(FxElem_u_s, lightingHandle, 0x0); + ASSERT_STRUCT_OFFSET(FxElem_u_s, fade, 0x2); + + union FxElem_u + { + float trailTexCoord; //OFS: 0x0 SIZE: 0x4 + FxElem_u_s s; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxElem_u, 0x4); + + struct FxElem + { + unsigned __int8 defIndex; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 sequence; //OFS: 0x1 SIZE: 0x1 + unsigned __int8 atRestFraction; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 emitResidual; //OFS: 0x3 SIZE: 0x1 + unsigned __int16 nextElemHandleInEffect; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 prevElemHandleInEffect; //OFS: 0x6 SIZE: 0x2 + int msecBegin; //OFS: 0x8 SIZE: 0x4 + float baseVel[3]; //OFS: 0xC SIZE: 0xC + float origin[3]; //OFS: 0x18 SIZE: 0xC + FxElem_u u; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxElem, 0x28); + ASSERT_STRUCT_OFFSET(FxElem, defIndex, 0x0); + ASSERT_STRUCT_OFFSET(FxElem, sequence, 0x1); + ASSERT_STRUCT_OFFSET(FxElem, atRestFraction, 0x2); + ASSERT_STRUCT_OFFSET(FxElem, emitResidual, 0x3); + ASSERT_STRUCT_OFFSET(FxElem, nextElemHandleInEffect, 0x4); + ASSERT_STRUCT_OFFSET(FxElem, prevElemHandleInEffect, 0x6); + ASSERT_STRUCT_OFFSET(FxElem, msecBegin, 0x8); + ASSERT_STRUCT_OFFSET(FxElem, baseVel, 0xC); + ASSERT_STRUCT_OFFSET(FxElem, origin, 0x18); + ASSERT_STRUCT_OFFSET(FxElem, u, 0x24); + + union FxPool_FxElem + { + int nextFree; //OFS: 0x0 SIZE: 0x4 + FxElem item; //OFS: 0x1 SIZE: 0x28 + }; + ASSERT_STRUCT_SIZE(FxPool_FxElem, 0x28); + + struct __declspec(align(2)) FxTrail + { + unsigned __int16 nextTrailHandle; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 firstElemHandle; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 lastElemHandle; //OFS: 0x4 SIZE: 0x2 + char defIndex; //OFS: 0x6 SIZE: 0x1 + char sequence; //OFS: 0x7 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(FxTrail, 0x8); + ASSERT_STRUCT_OFFSET(FxTrail, nextTrailHandle, 0x0); + ASSERT_STRUCT_OFFSET(FxTrail, firstElemHandle, 0x2); + ASSERT_STRUCT_OFFSET(FxTrail, lastElemHandle, 0x4); + ASSERT_STRUCT_OFFSET(FxTrail, defIndex, 0x6); + ASSERT_STRUCT_OFFSET(FxTrail, sequence, 0x7); + + union FxPool_FxTrail + { + int nextFree; //OFS: 0x0 SIZE: 0x4 + FxTrail item; //OFS: 0x1 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(FxPool_FxTrail, 0x8); + + struct FxTrailElem + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float spawnDist; //OFS: 0xC SIZE: 0x4 + int msecBegin; //OFS: 0x10 SIZE: 0x4 + unsigned __int16 nextTrailElemHandle; //OFS: 0x14 SIZE: 0x2 + __int16 baseVelZ; //OFS: 0x16 SIZE: 0x2 + char basis[2][3]; //OFS: 0x18 SIZE: 0x6 + unsigned __int8 sequence; //OFS: 0x1E SIZE: 0x1 + unsigned __int8 unused; //OFS: 0x1F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(FxTrailElem, 0x20); + ASSERT_STRUCT_OFFSET(FxTrailElem, origin, 0x0); + ASSERT_STRUCT_OFFSET(FxTrailElem, spawnDist, 0xC); + ASSERT_STRUCT_OFFSET(FxTrailElem, msecBegin, 0x10); + ASSERT_STRUCT_OFFSET(FxTrailElem, nextTrailElemHandle, 0x14); + ASSERT_STRUCT_OFFSET(FxTrailElem, baseVelZ, 0x16); + ASSERT_STRUCT_OFFSET(FxTrailElem, basis, 0x18); + ASSERT_STRUCT_OFFSET(FxTrailElem, sequence, 0x1E); + ASSERT_STRUCT_OFFSET(FxTrailElem, unused, 0x1F); + + union FxPool_FxTrailElem + { + int nextFree; //OFS: 0x0 SIZE: 0x4 + FxTrailElem item; //OFS: 0x1 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(FxPool_FxTrailElem, 0x20); + + struct FxVisBlocker + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + unsigned __int16 radius; //OFS: 0xC SIZE: 0x2 + unsigned __int16 visibility; //OFS: 0xE SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(FxVisBlocker, 0x10); + ASSERT_STRUCT_OFFSET(FxVisBlocker, origin, 0x0); + ASSERT_STRUCT_OFFSET(FxVisBlocker, radius, 0xC); + ASSERT_STRUCT_OFFSET(FxVisBlocker, visibility, 0xE); + + struct FxVisState + { + FxVisBlocker blocker[256]; //OFS: 0x0 SIZE: 0x1000 + int blockerCount; //OFS: 0x1000 SIZE: 0x4 + unsigned int pad[3]; //OFS: 0x1004 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(FxVisState, 0x1010); + ASSERT_STRUCT_OFFSET(FxVisState, blocker, 0x0); + ASSERT_STRUCT_OFFSET(FxVisState, blockerCount, 0x1000); + ASSERT_STRUCT_OFFSET(FxVisState, pad, 0x1004); + + struct FxSystemBuffers + { + FxEffect effects[1024]; //OFS: 0x0 SIZE: 0x2D000 + FxPool_FxElem elems[2048]; //OFS: 0x2D000 SIZE: 0x14000 + FxPool_FxTrail trails[128]; //OFS: 0x41000 SIZE: 0x400 + FxPool_FxTrailElem trailElems[2048]; //OFS: 0x41400 SIZE: 0x10000 + FxVisState visState[2]; //OFS: 0x51400 SIZE: 0x2020 + unsigned __int16 deferredElems[2048]; //OFS: 0x53420 SIZE: 0x1000 + unsigned __int8 padBuffer[96]; //OFS: 0x54420 SIZE: 0x60 + }; + ASSERT_STRUCT_SIZE(FxSystemBuffers, 0x54480); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, effects, 0x0); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, elems, 0x2D000); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, trails, 0x41000); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, trailElems, 0x41400); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, visState, 0x51400); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, deferredElems, 0x53420); + ASSERT_STRUCT_OFFSET(FxSystemBuffers, padBuffer, 0x54420); + + struct FxCamera + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + int isValid; //OFS: 0xC SIZE: 0x4 + float frustum[6][4]; //OFS: 0x10 SIZE: 0x60 + float axis[3][3]; //OFS: 0x70 SIZE: 0x24 + unsigned int frustumPlaneCount; //OFS: 0x94 SIZE: 0x4 + float viewOffset[3]; //OFS: 0x98 SIZE: 0xC + unsigned int pad[3]; //OFS: 0xA4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(FxCamera, 0xB0); + ASSERT_STRUCT_OFFSET(FxCamera, origin, 0x0); + ASSERT_STRUCT_OFFSET(FxCamera, isValid, 0xC); + ASSERT_STRUCT_OFFSET(FxCamera, frustum, 0x10); + ASSERT_STRUCT_OFFSET(FxCamera, axis, 0x70); + ASSERT_STRUCT_OFFSET(FxCamera, frustumPlaneCount, 0x94); + ASSERT_STRUCT_OFFSET(FxCamera, viewOffset, 0x98); + ASSERT_STRUCT_OFFSET(FxCamera, pad, 0xA4); + + struct __declspec(align(2)) r_double_index_t + { + unsigned __int16 value[2]; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(r_double_index_t, 0x4); + ASSERT_STRUCT_OFFSET(r_double_index_t, value, 0x0); + + struct FxSpriteInfo + { + r_double_index_t * indices; //OFS: 0x0 SIZE: 0x4 + unsigned int indexCount; //OFS: 0x4 SIZE: 0x4 + Material * material; //OFS: 0x8 SIZE: 0x4 + const char * name; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxSpriteInfo, 0x10); + ASSERT_STRUCT_OFFSET(FxSpriteInfo, indices, 0x0); + ASSERT_STRUCT_OFFSET(FxSpriteInfo, indexCount, 0x4); + ASSERT_STRUCT_OFFSET(FxSpriteInfo, material, 0x8); + ASSERT_STRUCT_OFFSET(FxSpriteInfo, name, 0xC); + + struct FxEffectPriorityList + { + unsigned __int16 list[1024]; //OFS: 0x0 SIZE: 0x800 + int endOfSorted; //OFS: 0x800 SIZE: 0x4 + int firstUnsorted; //OFS: 0x804 SIZE: 0x4 + unsigned __int8 haveUnsorted; //OFS: 0x808 SIZE: 0x1 + unsigned __int8 pad[7]; //OFS: 0x809 SIZE: 0x7 + }; + ASSERT_STRUCT_SIZE(FxEffectPriorityList, 0x810); + ASSERT_STRUCT_OFFSET(FxEffectPriorityList, list, 0x0); + ASSERT_STRUCT_OFFSET(FxEffectPriorityList, endOfSorted, 0x800); + ASSERT_STRUCT_OFFSET(FxEffectPriorityList, firstUnsorted, 0x804); + ASSERT_STRUCT_OFFSET(FxEffectPriorityList, haveUnsorted, 0x808); + ASSERT_STRUCT_OFFSET(FxEffectPriorityList, pad, 0x809); + + struct FxSystem + { + FxCamera camera; //OFS: 0x0 SIZE: 0xB0 + FxCamera cameraPrev; //OFS: 0xB0 SIZE: 0xB0 + FxSpriteInfo sprite; //OFS: 0x160 SIZE: 0x10 + FxEffect * effects; //OFS: 0x170 SIZE: 0x4 + FxPool_FxElem * elems; //OFS: 0x174 SIZE: 0x4 + FxPool_FxTrail * trails; //OFS: 0x178 SIZE: 0x4 + FxPool_FxTrailElem * trailElems; //OFS: 0x17C SIZE: 0x4 + unsigned __int16 * deferredElems; //OFS: 0x180 SIZE: 0x4 + int firstFreeElem; //OFS: 0x184 SIZE: 0x4 + int firstFreeTrailElem; //OFS: 0x188 SIZE: 0x4 + int firstFreeTrail; //OFS: 0x18C SIZE: 0x4 + int deferredElemCount; //OFS: 0x190 SIZE: 0x4 + int activeElemCount; //OFS: 0x194 SIZE: 0x4 + int activeTrailElemCount; //OFS: 0x198 SIZE: 0x4 + int activeTrailCount; //OFS: 0x19C SIZE: 0x4 + int gfxCloudCount; //OFS: 0x1A0 SIZE: 0x4 + FxVisState * visState; //OFS: 0x1A4 SIZE: 0x4 + FxVisState * visStateBufferRead; //OFS: 0x1A8 SIZE: 0x4 + FxVisState * visStateBufferWrite; //OFS: 0x1AC SIZE: 0x4 + int firstActiveEffect; //OFS: 0x1B0 SIZE: 0x4 + int firstNewEffect; //OFS: 0x1B4 SIZE: 0x4 + int firstFreeEffect; //OFS: 0x1B8 SIZE: 0x4 + unsigned __int16 allEffectHandles[1024]; //OFS: 0x1BC SIZE: 0x800 + int activeSpotLightEffectCount; //OFS: 0x9BC SIZE: 0x4 + int activeSpotLightElemCount; //OFS: 0x9C0 SIZE: 0x4 + unsigned __int16 activeSpotLightEffectHandle; //OFS: 0x9C4 SIZE: 0x2 + unsigned __int16 activeSpotLightElemHandle; //OFS: 0x9C6 SIZE: 0x2 + __int16 activeSpotLightBoltDobj; //OFS: 0x9C8 SIZE: 0x2 + int iteratorCount; //OFS: 0x9CC SIZE: 0x4 + int msecNow; //OFS: 0x9D0 SIZE: 0x4 + int msecDraw; //OFS: 0x9D4 SIZE: 0x4 + int frameCount; //OFS: 0x9D8 SIZE: 0x4 + char isInitialized; //OFS: 0x9DC SIZE: 0x1 + bool needsGarbageCollection; //OFS: 0x9DD SIZE: 0x1 + bool isArchiving; //OFS: 0x9DE SIZE: 0x1 + char localClientNum; //OFS: 0x9DF SIZE: 0x1 + unsigned int restartList[32]; //OFS: 0x9E0 SIZE: 0x80 + FxEffectPriorityList priorityList; //OFS: 0xA60 SIZE: 0x810 + }; + ASSERT_STRUCT_SIZE(FxSystem, 0x1270); + ASSERT_STRUCT_OFFSET(FxSystem, camera, 0x0); + ASSERT_STRUCT_OFFSET(FxSystem, cameraPrev, 0xB0); + ASSERT_STRUCT_OFFSET(FxSystem, sprite, 0x160); + ASSERT_STRUCT_OFFSET(FxSystem, effects, 0x170); + ASSERT_STRUCT_OFFSET(FxSystem, elems, 0x174); + ASSERT_STRUCT_OFFSET(FxSystem, trails, 0x178); + ASSERT_STRUCT_OFFSET(FxSystem, trailElems, 0x17C); + ASSERT_STRUCT_OFFSET(FxSystem, deferredElems, 0x180); + ASSERT_STRUCT_OFFSET(FxSystem, firstFreeElem, 0x184); + ASSERT_STRUCT_OFFSET(FxSystem, firstFreeTrailElem, 0x188); + ASSERT_STRUCT_OFFSET(FxSystem, firstFreeTrail, 0x18C); + ASSERT_STRUCT_OFFSET(FxSystem, deferredElemCount, 0x190); + ASSERT_STRUCT_OFFSET(FxSystem, activeElemCount, 0x194); + ASSERT_STRUCT_OFFSET(FxSystem, activeTrailElemCount, 0x198); + ASSERT_STRUCT_OFFSET(FxSystem, activeTrailCount, 0x19C); + ASSERT_STRUCT_OFFSET(FxSystem, gfxCloudCount, 0x1A0); + ASSERT_STRUCT_OFFSET(FxSystem, visState, 0x1A4); + ASSERT_STRUCT_OFFSET(FxSystem, visStateBufferRead, 0x1A8); + ASSERT_STRUCT_OFFSET(FxSystem, visStateBufferWrite, 0x1AC); + ASSERT_STRUCT_OFFSET(FxSystem, firstActiveEffect, 0x1B0); + ASSERT_STRUCT_OFFSET(FxSystem, firstNewEffect, 0x1B4); + ASSERT_STRUCT_OFFSET(FxSystem, firstFreeEffect, 0x1B8); + ASSERT_STRUCT_OFFSET(FxSystem, allEffectHandles, 0x1BC); + ASSERT_STRUCT_OFFSET(FxSystem, activeSpotLightEffectCount, 0x9BC); + ASSERT_STRUCT_OFFSET(FxSystem, activeSpotLightElemCount, 0x9C0); + ASSERT_STRUCT_OFFSET(FxSystem, activeSpotLightEffectHandle, 0x9C4); + ASSERT_STRUCT_OFFSET(FxSystem, activeSpotLightElemHandle, 0x9C6); + ASSERT_STRUCT_OFFSET(FxSystem, activeSpotLightBoltDobj, 0x9C8); + ASSERT_STRUCT_OFFSET(FxSystem, iteratorCount, 0x9CC); + ASSERT_STRUCT_OFFSET(FxSystem, msecNow, 0x9D0); + ASSERT_STRUCT_OFFSET(FxSystem, msecDraw, 0x9D4); + ASSERT_STRUCT_OFFSET(FxSystem, frameCount, 0x9D8); + ASSERT_STRUCT_OFFSET(FxSystem, isInitialized, 0x9DC); + ASSERT_STRUCT_OFFSET(FxSystem, needsGarbageCollection, 0x9DD); + ASSERT_STRUCT_OFFSET(FxSystem, isArchiving, 0x9DE); + ASSERT_STRUCT_OFFSET(FxSystem, localClientNum, 0x9DF); + ASSERT_STRUCT_OFFSET(FxSystem, restartList, 0x9E0); + ASSERT_STRUCT_OFFSET(FxSystem, priorityList, 0xA60); + + struct server_s + { + serverState_t state; //OFS: 0x0 SIZE: 0x4 + int timeResidual; //OFS: 0x4 SIZE: 0x4 + bool inFrame; //OFS: 0x8 SIZE: 0x1 + int restarting; //OFS: 0xC SIZE: 0x4 + int num_restarts; //OFS: 0x10 SIZE: 0x4 + int start_frameTime; //OFS: 0x14 SIZE: 0x4 + int checksumFeed; //OFS: 0x18 SIZE: 0x4 + cmodel_t * models[512]; //OFS: 0x1C SIZE: 0x800 + __int16 emptyConfigString; //OFS: 0x81C SIZE: 0x2 + __int16 configstrings[3056]; //OFS: 0x81E SIZE: 0x17E0 + svEntity_t svEntities[1024]; //OFS: 0x2000 SIZE: 0x6B000 + entityState_s savedEntities[350]; //OFS: 0x6D000 SIZE: 0x17ED0 + gentity_s * gentities; //OFS: 0x84ED0 SIZE: 0x4 + int entitiySize; //OFS: 0x84ED4 SIZE: 0x4 + int max_clients; //OFS: 0x84ED8 SIZE: 0x4 + int num_saved_ents; //OFS: 0x84EDC SIZE: 0x4 + gclient_s * gameClients; //OFS: 0x84EE0 SIZE: 0x4 + int gameClientSize; //OFS: 0x84EE4 SIZE: 0x4 + actor_s * actors; //OFS: 0x84EE8 SIZE: 0x4 + int actorSize; //OFS: 0x84EEC SIZE: 0x4 + animCmdState_s * animCmds; //OFS: 0x84EF0 SIZE: 0x4 + int animCmdSize; //OFS: 0x84EF4 SIZE: 0x4 + int checksum; //OFS: 0x84EF8 SIZE: 0x4 + int skelTimeStamp; //OFS: 0x84EFC SIZE: 0x4 + int skelMemPos; //OFS: 0x84F00 SIZE: 0x4 + _BYTE gap_84F04[84]; //OFS: 0x84F04 SIZE: 0x54 + int bpsTotalBytes; //OFS: 0x84F58 SIZE: 0x4 + _BYTE gap_84F5C[84]; //OFS: 0x84F5C SIZE: 0x54 + int ubpsTotalBytes; //OFS: 0x84FB0 SIZE: 0x4 + _BYTE gap_84FB4[24]; //OFS: 0x84FB4 SIZE: 0x18 + char gametype[64]; //OFS: 0x84FCC SIZE: 0x40 + bool killServer; //OFS: 0x8500C SIZE: 0x1 + _BYTE gap_8500D[3]; //OFS: 0x8500D SIZE: 0x3 + char * killReason; //OFS: 0x85010 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(server_s, 0x85014); + ASSERT_STRUCT_OFFSET(server_s, state, 0x0); + ASSERT_STRUCT_OFFSET(server_s, timeResidual, 0x4); + ASSERT_STRUCT_OFFSET(server_s, inFrame, 0x8); + ASSERT_STRUCT_OFFSET(server_s, restarting, 0xC); + ASSERT_STRUCT_OFFSET(server_s, num_restarts, 0x10); + ASSERT_STRUCT_OFFSET(server_s, start_frameTime, 0x14); + ASSERT_STRUCT_OFFSET(server_s, checksumFeed, 0x18); + ASSERT_STRUCT_OFFSET(server_s, models, 0x1C); + ASSERT_STRUCT_OFFSET(server_s, emptyConfigString, 0x81C); + ASSERT_STRUCT_OFFSET(server_s, configstrings, 0x81E); + ASSERT_STRUCT_OFFSET(server_s, svEntities, 0x2000); + ASSERT_STRUCT_OFFSET(server_s, savedEntities, 0x6D000); + ASSERT_STRUCT_OFFSET(server_s, gentities, 0x84ED0); + ASSERT_STRUCT_OFFSET(server_s, entitiySize, 0x84ED4); + ASSERT_STRUCT_OFFSET(server_s, max_clients, 0x84ED8); + ASSERT_STRUCT_OFFSET(server_s, num_saved_ents, 0x84EDC); + ASSERT_STRUCT_OFFSET(server_s, gameClients, 0x84EE0); + ASSERT_STRUCT_OFFSET(server_s, gameClientSize, 0x84EE4); + ASSERT_STRUCT_OFFSET(server_s, actors, 0x84EE8); + ASSERT_STRUCT_OFFSET(server_s, actorSize, 0x84EEC); + ASSERT_STRUCT_OFFSET(server_s, animCmds, 0x84EF0); + ASSERT_STRUCT_OFFSET(server_s, animCmdSize, 0x84EF4); + ASSERT_STRUCT_OFFSET(server_s, checksum, 0x84EF8); + ASSERT_STRUCT_OFFSET(server_s, skelTimeStamp, 0x84EFC); + ASSERT_STRUCT_OFFSET(server_s, skelMemPos, 0x84F00); + ASSERT_STRUCT_OFFSET(server_s, gap_84F04, 0x84F04); + ASSERT_STRUCT_OFFSET(server_s, bpsTotalBytes, 0x84F58); + ASSERT_STRUCT_OFFSET(server_s, gap_84F5C, 0x84F5C); + ASSERT_STRUCT_OFFSET(server_s, ubpsTotalBytes, 0x84FB0); + ASSERT_STRUCT_OFFSET(server_s, gap_84FB4, 0x84FB4); + ASSERT_STRUCT_OFFSET(server_s, gametype, 0x84FCC); + ASSERT_STRUCT_OFFSET(server_s, killServer, 0x8500C); + ASSERT_STRUCT_OFFSET(server_s, gap_8500D, 0x8500D); + ASSERT_STRUCT_OFFSET(server_s, killReason, 0x85010); + + struct challenge_s + { + netadr_s adr; //OFS: 0x0 SIZE: 0x18 + int challenge; //OFS: 0x18 SIZE: 0x4 + int time; //OFS: 0x1C SIZE: 0x4 + int pingTime; //OFS: 0x20 SIZE: 0x4 + int firstTime; //OFS: 0x24 SIZE: 0x4 + int firstPing; //OFS: 0x28 SIZE: 0x4 + int connected; //OFS: 0x2C SIZE: 0x4 + int guid; //OFS: 0x30 SIZE: 0x4 + char PBguid[33]; //OFS: 0x34 SIZE: 0x21 + char clientPBguid[33]; //OFS: 0x55 SIZE: 0x21 + }; + ASSERT_STRUCT_SIZE(challenge_s, 0x78); + ASSERT_STRUCT_OFFSET(challenge_s, adr, 0x0); + ASSERT_STRUCT_OFFSET(challenge_s, challenge, 0x18); + ASSERT_STRUCT_OFFSET(challenge_s, time, 0x1C); + ASSERT_STRUCT_OFFSET(challenge_s, pingTime, 0x20); + ASSERT_STRUCT_OFFSET(challenge_s, firstTime, 0x24); + ASSERT_STRUCT_OFFSET(challenge_s, firstPing, 0x28); + ASSERT_STRUCT_OFFSET(challenge_s, connected, 0x2C); + ASSERT_STRUCT_OFFSET(challenge_s, guid, 0x30); + ASSERT_STRUCT_OFFSET(challenge_s, PBguid, 0x34); + ASSERT_STRUCT_OFFSET(challenge_s, clientPBguid, 0x55); + + struct tempBanSlot_t + { + int guid; //OFS: 0x0 SIZE: 0x4 + int banTime; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(tempBanSlot_t, 0x8); + ASSERT_STRUCT_OFFSET(tempBanSlot_t, guid, 0x0); + ASSERT_STRUCT_OFFSET(tempBanSlot_t, banTime, 0x4); + + struct __declspec(align(16)) serverStatic_s + { + char cachedSnapshot[22528]; //OFS: 0x0 SIZE: 0x5800 + char cachedSnapshot_[1294336]; //OFS: 0x5800 SIZE: 0x13C000 + char cachedSnapshot__[15360]; //OFS: 0x141800 SIZE: 0x3C00 + char cachedSnapshot___[180224]; //OFS: 0x145400 SIZE: 0x2C000 + int initialized; //OFS: 0x171400 SIZE: 0x4 + int time; //OFS: 0x171404 SIZE: 0x4 + int snapFlagServerBit; //OFS: 0x171408 SIZE: 0x4 + int field_17140C; //OFS: 0x17140C SIZE: 0x4 + client_s clients[4]; //OFS: 0x171410 SIZE: 0x1634C0 + int numSnapshotEntities; //OFS: 0x2D48D0 SIZE: 0x4 + int numSnapshotClients; //OFS: 0x2D48D4 SIZE: 0x4 + int numSnapshotActors; //OFS: 0x2D48D8 SIZE: 0x4 + int nextSnapshotEntities[4]; //OFS: 0x2D48DC SIZE: 0x10 + int nextSnapshotClients[4]; //OFS: 0x2D48EC SIZE: 0x10 + int nextSnapshotActors[4]; //OFS: 0x2D48FC SIZE: 0x10 + entityState_s snapshotEntities[4][5376]; //OFS: 0x2D490C SIZE: 0x5BE000 + clientState_s snapshotClients[4][64]; //OFS: 0x89290C SIZE: 0x9400 + actorState_s snapshotActors[4][512]; //OFS: 0x89BD0C SIZE: 0x3C000 + int nextCachedSnapshotEntities; //OFS: 0x8D7D0C SIZE: 0x4 + int nextCachedSnapshotClients; //OFS: 0x8D7D10 SIZE: 0x4 + int awdd; //OFS: 0x8D7D14 SIZE: 0x4 + int nextCachedSnapshotFrames; //OFS: 0x8D7D18 SIZE: 0x4 + char cachedSnapshot____[136256]; //OFS: 0x8D7D1C SIZE: 0x21440 + int nextHeartbeatTime; //OFS: 0x8F915C SIZE: 0x4 + int nextStatusResponseTime; //OFS: 0x8F9160 SIZE: 0x4 + challenge_s challenges[1024]; //OFS: 0x8F9164 SIZE: 0x1E000 + int numSnapshotAnimCmds; //OFS: 0x917164 SIZE: 0x4 + int nextSnapshotAnimCmds[4]; //OFS: 0x917168 SIZE: 0x10 + animCmdState_s snapshotAnimCmds[4][16384]; //OFS: 0x917178 SIZE: 0x2C0000 + int acaw; //OFS: 0xBD7178 SIZE: 0x4 + netProfileInfo_t OOBProf; //OFS: 0xBD717C SIZE: 0x5E0 + tempBanSlot_t tempBans[16]; //OFS: 0xBD775C SIZE: 0x80 + int field_BD77DC; //OFS: 0xBD77DC SIZE: 0x4 + int field_BD77E0[2][4]; //OFS: 0xBD77E0 SIZE: 0x20 + float mapCenter[3]; //OFS: 0xBD7800 SIZE: 0xC + int playerDeaths[4]; //OFS: 0xBD780C SIZE: 0x10 + int playerScore[4]; //OFS: 0xBD781C SIZE: 0x10 + _BYTE gapBD782C[83]; //OFS: 0xBD782C SIZE: 0x53 + char field_BD787F; //OFS: 0xBD787F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(serverStatic_s, 0xBD7880); + ASSERT_STRUCT_OFFSET(serverStatic_s, cachedSnapshot, 0x0); + ASSERT_STRUCT_OFFSET(serverStatic_s, cachedSnapshot_, 0x5800); + ASSERT_STRUCT_OFFSET(serverStatic_s, cachedSnapshot__, 0x141800); + ASSERT_STRUCT_OFFSET(serverStatic_s, cachedSnapshot___, 0x145400); + ASSERT_STRUCT_OFFSET(serverStatic_s, initialized, 0x171400); + ASSERT_STRUCT_OFFSET(serverStatic_s, time, 0x171404); + ASSERT_STRUCT_OFFSET(serverStatic_s, snapFlagServerBit, 0x171408); + ASSERT_STRUCT_OFFSET(serverStatic_s, field_17140C, 0x17140C); + ASSERT_STRUCT_OFFSET(serverStatic_s, clients, 0x171410); + ASSERT_STRUCT_OFFSET(serverStatic_s, numSnapshotEntities, 0x2D48D0); + ASSERT_STRUCT_OFFSET(serverStatic_s, numSnapshotClients, 0x2D48D4); + ASSERT_STRUCT_OFFSET(serverStatic_s, numSnapshotActors, 0x2D48D8); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextSnapshotEntities, 0x2D48DC); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextSnapshotClients, 0x2D48EC); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextSnapshotActors, 0x2D48FC); + ASSERT_STRUCT_OFFSET(serverStatic_s, snapshotEntities, 0x2D490C); + ASSERT_STRUCT_OFFSET(serverStatic_s, snapshotClients, 0x89290C); + ASSERT_STRUCT_OFFSET(serverStatic_s, snapshotActors, 0x89BD0C); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextCachedSnapshotEntities, 0x8D7D0C); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextCachedSnapshotClients, 0x8D7D10); + ASSERT_STRUCT_OFFSET(serverStatic_s, awdd, 0x8D7D14); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextCachedSnapshotFrames, 0x8D7D18); + ASSERT_STRUCT_OFFSET(serverStatic_s, cachedSnapshot____, 0x8D7D1C); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextHeartbeatTime, 0x8F915C); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextStatusResponseTime, 0x8F9160); + ASSERT_STRUCT_OFFSET(serverStatic_s, challenges, 0x8F9164); + ASSERT_STRUCT_OFFSET(serverStatic_s, numSnapshotAnimCmds, 0x917164); + ASSERT_STRUCT_OFFSET(serverStatic_s, nextSnapshotAnimCmds, 0x917168); + ASSERT_STRUCT_OFFSET(serverStatic_s, snapshotAnimCmds, 0x917178); + ASSERT_STRUCT_OFFSET(serverStatic_s, acaw, 0xBD7178); + ASSERT_STRUCT_OFFSET(serverStatic_s, OOBProf, 0xBD717C); + ASSERT_STRUCT_OFFSET(serverStatic_s, tempBans, 0xBD775C); + ASSERT_STRUCT_OFFSET(serverStatic_s, field_BD77DC, 0xBD77DC); + ASSERT_STRUCT_OFFSET(serverStatic_s, field_BD77E0, 0xBD77E0); + ASSERT_STRUCT_OFFSET(serverStatic_s, mapCenter, 0xBD7800); + ASSERT_STRUCT_OFFSET(serverStatic_s, playerDeaths, 0xBD780C); + ASSERT_STRUCT_OFFSET(serverStatic_s, playerScore, 0xBD781C); + ASSERT_STRUCT_OFFSET(serverStatic_s, gapBD782C, 0xBD782C); + ASSERT_STRUCT_OFFSET(serverStatic_s, field_BD787F, 0xBD787F); + + struct serverStaticHeader_s + { + client_s * clients; //OFS: 0x0 SIZE: 0x4 + actor_s * actors; //OFS: 0x4 SIZE: 0x4 + animCmdState_s * animCmds; //OFS: 0x8 SIZE: 0x4 + int time; //OFS: 0xC SIZE: 0x4 + int snapFlagServerBit; //OFS: 0x10 SIZE: 0x4 + int numSnapshotEntities; //OFS: 0x14 SIZE: 0x4 + int numSnapshotClients; //OFS: 0x18 SIZE: 0x4 + int numSnapshotActors; //OFS: 0x1C SIZE: 0x4 + int nextSnapshotEntities[4]; //OFS: 0x20 SIZE: 0x10 + entityState_s * snapshotEntities[4]; //OFS: 0x30 SIZE: 0x10 + clientState_s * snapshotClients[4]; //OFS: 0x40 SIZE: 0x10 + actorState_s * snapshotActors[4]; //OFS: 0x50 SIZE: 0x10 + svEntity_t * svEntities; //OFS: 0x60 SIZE: 0x4 + _BYTE gap_64[32]; //OFS: 0x64 SIZE: 0x20 + int numSnapshotAnimCmds; //OFS: 0x84 SIZE: 0x4 + animCmdState_s * snapshotAnimCmds[4]; //OFS: 0x88 SIZE: 0x10 + _BYTE gap_98[4]; //OFS: 0x98 SIZE: 0x4 + int awdawdd; //OFS: 0x9C SIZE: 0x4 + int nextCachedSnapshotFrames; //OFS: 0xA0 SIZE: 0x4 + _BYTE gap_A4[4]; //OFS: 0xA4 SIZE: 0x4 + int nextCachedSnapshotEntities; //OFS: 0xA8 SIZE: 0x4 + int nextCachedSnapshotClients; //OFS: 0xAC SIZE: 0x4 + int awdawd; //OFS: 0xB0 SIZE: 0x4 + int max_clients; //OFS: 0xB4 SIZE: 0x4 + char gap_B8[44]; //OFS: 0xB8 SIZE: 0x2C + int snapshotPeek; //OFS: 0xE4 SIZE: 0x4 + vehicle_info_t * bg_vehicleInfos; //OFS: 0xE8 SIZE: 0x4 + entityState_s * savedEntities; //OFS: 0xEC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(serverStaticHeader_s, 0xF0); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, clients, 0x0); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, actors, 0x4); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, animCmds, 0x8); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, time, 0xC); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapFlagServerBit, 0x10); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, numSnapshotEntities, 0x14); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, numSnapshotClients, 0x18); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, numSnapshotActors, 0x1C); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, nextSnapshotEntities, 0x20); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapshotEntities, 0x30); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapshotClients, 0x40); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapshotActors, 0x50); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, svEntities, 0x60); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, gap_64, 0x64); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, numSnapshotAnimCmds, 0x84); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapshotAnimCmds, 0x88); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, gap_98, 0x98); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, awdawdd, 0x9C); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, nextCachedSnapshotFrames, 0xA0); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, gap_A4, 0xA4); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, nextCachedSnapshotEntities, 0xA8); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, nextCachedSnapshotClients, 0xAC); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, awdawd, 0xB0); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, max_clients, 0xB4); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, gap_B8, 0xB8); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, snapshotPeek, 0xE4); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, bg_vehicleInfos, 0xE8); + ASSERT_STRUCT_OFFSET(serverStaticHeader_s, savedEntities, 0xEC); + + struct CmdArgs + { + int nesting; //OFS: 0x0 SIZE: 0x4 + int localClientNum[8]; //OFS: 0x4 SIZE: 0x20 + int controllerIndex[8]; //OFS: 0x24 SIZE: 0x20 + int argc[8]; //OFS: 0x44 SIZE: 0x20 + char ** argv[8]; //OFS: 0x64 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(CmdArgs, 0x84); + ASSERT_STRUCT_OFFSET(CmdArgs, nesting, 0x0); + ASSERT_STRUCT_OFFSET(CmdArgs, localClientNum, 0x4); + ASSERT_STRUCT_OFFSET(CmdArgs, controllerIndex, 0x24); + ASSERT_STRUCT_OFFSET(CmdArgs, argc, 0x44); + ASSERT_STRUCT_OFFSET(CmdArgs, argv, 0x64); + + struct pmove_s + { + playerState_s * ps; //OFS: 0x0 SIZE: 0x4 + usercmd_s cmd; //OFS: 0x4 SIZE: 0x38 + usercmd_s oldcmd; //OFS: 0x3C SIZE: 0x38 + int tracemask; //OFS: 0x74 SIZE: 0x4 + int numtouch; //OFS: 0x78 SIZE: 0x4 + int touchents[32]; //OFS: 0x7C SIZE: 0x80 + float mins[3]; //OFS: 0xFC SIZE: 0xC + float maxs[3]; //OFS: 0x108 SIZE: 0xC + float xyspeed; //OFS: 0x114 SIZE: 0x4 + int proneChange; //OFS: 0x118 SIZE: 0x4 + float maxSprintTimeMultiplier; //OFS: 0x11C SIZE: 0x4 + bool mantleStarted; //OFS: 0x120 SIZE: 0x1 + float mantleEndPos[3]; //OFS: 0x124 SIZE: 0xC + int mantleDuration; //OFS: 0x130 SIZE: 0x4 + int viewChangeTime; //OFS: 0x134 SIZE: 0x4 + float viewChange; //OFS: 0x138 SIZE: 0x4 + float vehicleAngles[3]; //OFS: 0x13C SIZE: 0xC + pmoveVehAnimState_t vehAnimState; //OFS: 0x148 SIZE: 0x4 + unsigned __int8 handler; //OFS: 0x14C SIZE: 0x1 + int localClientNum; //OFS: 0x150 SIZE: 0x4 + colgeom_visitor_inlined_t proximity_data; //OFS: 0x154 SIZE: 0x6B4 + }; + ASSERT_STRUCT_SIZE(pmove_s, 0x808); + ASSERT_STRUCT_OFFSET(pmove_s, ps, 0x0); + ASSERT_STRUCT_OFFSET(pmove_s, cmd, 0x4); + ASSERT_STRUCT_OFFSET(pmove_s, oldcmd, 0x3C); + ASSERT_STRUCT_OFFSET(pmove_s, tracemask, 0x74); + ASSERT_STRUCT_OFFSET(pmove_s, numtouch, 0x78); + ASSERT_STRUCT_OFFSET(pmove_s, touchents, 0x7C); + ASSERT_STRUCT_OFFSET(pmove_s, mins, 0xFC); + ASSERT_STRUCT_OFFSET(pmove_s, maxs, 0x108); + ASSERT_STRUCT_OFFSET(pmove_s, xyspeed, 0x114); + ASSERT_STRUCT_OFFSET(pmove_s, proneChange, 0x118); + ASSERT_STRUCT_OFFSET(pmove_s, maxSprintTimeMultiplier, 0x11C); + ASSERT_STRUCT_OFFSET(pmove_s, mantleStarted, 0x120); + ASSERT_STRUCT_OFFSET(pmove_s, mantleEndPos, 0x124); + ASSERT_STRUCT_OFFSET(pmove_s, mantleDuration, 0x130); + ASSERT_STRUCT_OFFSET(pmove_s, viewChangeTime, 0x134); + ASSERT_STRUCT_OFFSET(pmove_s, viewChange, 0x138); + ASSERT_STRUCT_OFFSET(pmove_s, vehicleAngles, 0x13C); + ASSERT_STRUCT_OFFSET(pmove_s, vehAnimState, 0x148); + ASSERT_STRUCT_OFFSET(pmove_s, handler, 0x14C); + ASSERT_STRUCT_OFFSET(pmove_s, localClientNum, 0x150); + ASSERT_STRUCT_OFFSET(pmove_s, proximity_data, 0x154); + + struct clientLogo_t + { + int startTime; //OFS: 0x0 SIZE: 0x4 + int duration; //OFS: 0x4 SIZE: 0x4 + int fadein; //OFS: 0x8 SIZE: 0x4 + int fadeout; //OFS: 0xC SIZE: 0x4 + Material * material[2]; //OFS: 0x10 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(clientLogo_t, 0x18); + ASSERT_STRUCT_OFFSET(clientLogo_t, startTime, 0x0); + ASSERT_STRUCT_OFFSET(clientLogo_t, duration, 0x4); + ASSERT_STRUCT_OFFSET(clientLogo_t, fadein, 0x8); + ASSERT_STRUCT_OFFSET(clientLogo_t, fadeout, 0xC); + ASSERT_STRUCT_OFFSET(clientLogo_t, material, 0x10); + + struct serverInfo_t + { + netadr_s hostAddr; //OFS: 0x0 SIZE: 0x18 + int secShit[7]; + int playerSlots; //OFS: 0x34 SIZE: 0x4 + int playerSlotsUsed; //OFS: 0x38 SIZE: 0x4 + int playerReservedSlots; //OFS: 0x3C SIZE: 0x4 + int playerReservedSlotsUsed; //OFS: 0x40 SIZE: 0x4 + int field_44; //OFS: 0x44 SIZE: 0x4 + int field_48; //OFS: 0x48 SIZE: 0x4 + int field_4C; //OFS: 0x4C SIZE: 0x4 + netadr_s adr; //OFS: 0x50 SIZE: 0x18 + char allowAnonymouse; //OFS: 0x68 SIZE: 0x1 + char bPassword; //OFS: 0x69 SIZE: 0x1 + char pure; //OFS: 0x6A SIZE: 0x1 + char consoleDisabled; //OFS: 0x6B SIZE: 0x1 + char arcademode; //OFS: 0x6C SIZE: 0x1 + char nettype; //OFS: 0x6D SIZE: 0x1 + char clients; //OFS: 0x6E SIZE: 0x1 + char maxClients; //OFS: 0x6F SIZE: 0x1 + char dirty; //OFS: 0x70 SIZE: 0x1 + char friendlyfire; //OFS: 0x71 SIZE: 0x1 + char killcam; //OFS: 0x72 SIZE: 0x1 + char hardware; //OFS: 0x73 SIZE: 0x1 + char mod; //OFS: 0x74 SIZE: 0x1 + char requestCount; //OFS: 0x75 SIZE: 0x1 + char punkBuster; //OFS: 0x76 SIZE: 0x1 + __int16 minping; //OFS: 0x78 SIZE: 0x2 + __int16 maxping; //OFS: 0x7A SIZE: 0x2 + __int16 ping; //OFS: 0x7C SIZE: 0x2 + char hostname[32]; //OFS: 0x7E SIZE: 0x20 + char mapname[32]; //OFS: 0x9E SIZE: 0x20 + char game[36]; //OFS: 0xBE SIZE: 0x24 + char gametype[16]; //OFS: 0xE2 SIZE: 0x10 + int field_F4; //OFS: 0xF4 SIZE: 0x4 + int field_F8; //OFS: 0xF8 SIZE: 0x4 + int field_FC; //OFS: 0xFC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(serverInfo_t, 0x100); + ASSERT_STRUCT_OFFSET(serverInfo_t, hostAddr, 0x0); + ASSERT_STRUCT_OFFSET(serverInfo_t, playerSlots, 0x34); + ASSERT_STRUCT_OFFSET(serverInfo_t, playerSlotsUsed, 0x38); + ASSERT_STRUCT_OFFSET(serverInfo_t, playerReservedSlots, 0x3C); + ASSERT_STRUCT_OFFSET(serverInfo_t, playerReservedSlotsUsed, 0x40); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_44, 0x44); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_48, 0x48); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_4C, 0x4C); + ASSERT_STRUCT_OFFSET(serverInfo_t, adr, 0x50); + ASSERT_STRUCT_OFFSET(serverInfo_t, allowAnonymouse, 0x68); + ASSERT_STRUCT_OFFSET(serverInfo_t, bPassword, 0x69); + ASSERT_STRUCT_OFFSET(serverInfo_t, pure, 0x6A); + ASSERT_STRUCT_OFFSET(serverInfo_t, consoleDisabled, 0x6B); + ASSERT_STRUCT_OFFSET(serverInfo_t, arcademode, 0x6C); + ASSERT_STRUCT_OFFSET(serverInfo_t, nettype, 0x6D); + ASSERT_STRUCT_OFFSET(serverInfo_t, clients, 0x6E); + ASSERT_STRUCT_OFFSET(serverInfo_t, maxClients, 0x6F); + ASSERT_STRUCT_OFFSET(serverInfo_t, dirty, 0x70); + ASSERT_STRUCT_OFFSET(serverInfo_t, friendlyfire, 0x71); + ASSERT_STRUCT_OFFSET(serverInfo_t, killcam, 0x72); + ASSERT_STRUCT_OFFSET(serverInfo_t, hardware, 0x73); + ASSERT_STRUCT_OFFSET(serverInfo_t, mod, 0x74); + ASSERT_STRUCT_OFFSET(serverInfo_t, requestCount, 0x75); + ASSERT_STRUCT_OFFSET(serverInfo_t, punkBuster, 0x76); + ASSERT_STRUCT_OFFSET(serverInfo_t, minping, 0x78); + ASSERT_STRUCT_OFFSET(serverInfo_t, maxping, 0x7A); + ASSERT_STRUCT_OFFSET(serverInfo_t, ping, 0x7C); + ASSERT_STRUCT_OFFSET(serverInfo_t, hostname, 0x7E); + ASSERT_STRUCT_OFFSET(serverInfo_t, mapname, 0x9E); + ASSERT_STRUCT_OFFSET(serverInfo_t, game, 0xBE); + ASSERT_STRUCT_OFFSET(serverInfo_t, gametype, 0xE2); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_F4, 0xF4); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_F8, 0xF8); + ASSERT_STRUCT_OFFSET(serverInfo_t, field_FC, 0xFC); + + struct trDebugString_t + { + float xyz[3]; //OFS: 0x0 SIZE: 0xC + float color[4]; //OFS: 0xC SIZE: 0x10 + float scale; //OFS: 0x1C SIZE: 0x4 + char text[96]; //OFS: 0x20 SIZE: 0x60 + }; + ASSERT_STRUCT_SIZE(trDebugString_t, 0x80); + ASSERT_STRUCT_OFFSET(trDebugString_t, xyz, 0x0); + ASSERT_STRUCT_OFFSET(trDebugString_t, color, 0xC); + ASSERT_STRUCT_OFFSET(trDebugString_t, scale, 0x1C); + ASSERT_STRUCT_OFFSET(trDebugString_t, text, 0x20); + + struct clientDebugStringInfo_t + { + int max; //OFS: 0x0 SIZE: 0x4 + int num; //OFS: 0x4 SIZE: 0x4 + trDebugString_t * strings; //OFS: 0x8 SIZE: 0x4 + int * durations; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientDebugStringInfo_t, 0x10); + ASSERT_STRUCT_OFFSET(clientDebugStringInfo_t, max, 0x0); + ASSERT_STRUCT_OFFSET(clientDebugStringInfo_t, num, 0x4); + ASSERT_STRUCT_OFFSET(clientDebugStringInfo_t, strings, 0x8); + ASSERT_STRUCT_OFFSET(clientDebugStringInfo_t, durations, 0xC); + + struct trDebugLine_t + { + float start[3]; //OFS: 0x0 SIZE: 0xC + float end[3]; //OFS: 0xC SIZE: 0xC + float color[4]; //OFS: 0x18 SIZE: 0x10 + int depthTest; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(trDebugLine_t, 0x2C); + ASSERT_STRUCT_OFFSET(trDebugLine_t, start, 0x0); + ASSERT_STRUCT_OFFSET(trDebugLine_t, end, 0xC); + ASSERT_STRUCT_OFFSET(trDebugLine_t, color, 0x18); + ASSERT_STRUCT_OFFSET(trDebugLine_t, depthTest, 0x28); + + struct clientDebugLineInfo_t + { + int max; //OFS: 0x0 SIZE: 0x4 + int num; //OFS: 0x4 SIZE: 0x4 + trDebugLine_t * lines; //OFS: 0x8 SIZE: 0x4 + int * durations; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientDebugLineInfo_t, 0x10); + ASSERT_STRUCT_OFFSET(clientDebugLineInfo_t, max, 0x0); + ASSERT_STRUCT_OFFSET(clientDebugLineInfo_t, num, 0x4); + ASSERT_STRUCT_OFFSET(clientDebugLineInfo_t, lines, 0x8); + ASSERT_STRUCT_OFFSET(clientDebugLineInfo_t, durations, 0xC); + + struct clientDebug_t + { + int prevFromServer; //OFS: 0x0 SIZE: 0x4 + int fromServer; //OFS: 0x4 SIZE: 0x4 + clientDebugStringInfo_t clStrings; //OFS: 0x8 SIZE: 0x10 + clientDebugStringInfo_t svStringsBuffer; //OFS: 0x18 SIZE: 0x10 + clientDebugStringInfo_t svStrings; //OFS: 0x28 SIZE: 0x10 + clientDebugLineInfo_t clLines; //OFS: 0x38 SIZE: 0x10 + clientDebugLineInfo_t svLinesBuffer; //OFS: 0x48 SIZE: 0x10 + clientDebugLineInfo_t svLines; //OFS: 0x58 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(clientDebug_t, 0x68); + ASSERT_STRUCT_OFFSET(clientDebug_t, prevFromServer, 0x0); + ASSERT_STRUCT_OFFSET(clientDebug_t, fromServer, 0x4); + ASSERT_STRUCT_OFFSET(clientDebug_t, clStrings, 0x8); + ASSERT_STRUCT_OFFSET(clientDebug_t, svStringsBuffer, 0x18); + ASSERT_STRUCT_OFFSET(clientDebug_t, svStrings, 0x28); + ASSERT_STRUCT_OFFSET(clientDebug_t, clLines, 0x38); + ASSERT_STRUCT_OFFSET(clientDebug_t, svLinesBuffer, 0x48); + ASSERT_STRUCT_OFFSET(clientDebug_t, svLines, 0x58); + + struct clientStatic_s + { + int quit; //OFS: 0x0 SIZE: 0x4 + int hunkUsersStarted; //OFS: 0x4 SIZE: 0x4 + char serverName[256]; //OFS: 0x8 SIZE: 0x100 + char field_108[32]; //OFS: 0x108 SIZE: 0x20 + int field_128; //OFS: 0x128 SIZE: 0x4 + _BYTE gap12C[16]; //OFS: 0x12C SIZE: 0x10 + int rendererStarted; //OFS: 0x13C SIZE: 0x4 + int soundStarted; //OFS: 0x140 SIZE: 0x4 + int uiStarted; //OFS: 0x144 SIZE: 0x4 + int frametime; //OFS: 0x148 SIZE: 0x4 + int realtimepause; //OFS: 0x14C SIZE: 0x4 + int realtime; //OFS: 0x150 SIZE: 0x4 + int realFrameTime; //OFS: 0x154 SIZE: 0x4 + clientLogo_t logo; //OFS: 0x158 SIZE: 0x18 + float mapCenter[3]; //OFS: 0x170 SIZE: 0xC + int numlocalservers; //OFS: 0x17C SIZE: 0x4 + serverInfo_t localServers[128]; //OFS: 0x180 SIZE: 0x8000 + _BYTE gap_8180[4]; //OFS: 0x8180 SIZE: 0x4 + int numglobalservers; //OFS: 0x8184 SIZE: 0x4 + serverInfo_t globalServers[20000]; //OFS: 0x8188 SIZE: 0x4E2000 + int numfriendsservers; //OFS: 0x4EA188 SIZE: 0x4 + int pad; //OFS: 0x4EA18C SIZE: 0x4 + serverInfo_t friendServers[128]; //OFS: 0x4EA190 SIZE: 0x8000 + int numfavoriteservers; //OFS: 0x4F2190 SIZE: 0x4 + int pad2; //OFS: 0x4F2194 SIZE: 0x4 + serverInfo_t favoriteServers[128]; //OFS: 0x4F2198 SIZE: 0x8000 + int pingUpdateSource; //OFS: 0x4FA198 SIZE: 0x4 + _BYTE gap_4FA19C[2916]; //OFS: 0x4FA19C SIZE: 0xB64 + netadr_s dNet; //OFS: 0x4FAD00 SIZE: 0x18 + _BYTE gap4FAD18[52]; //OFS: 0x4FAD18 SIZE: 0x34 + clientDebug_t debug; //OFS: 0x4FAD4C SIZE: 0x68 + float renderForward[3]; //OFS: 0x4FADB4 SIZE: 0xC + float renderPos[3]; //OFS: 0x4FADC0 SIZE: 0xC + int download; //OFS: 0x4FADCC SIZE: 0x4 + char downloadTempName[256]; //OFS: 0x4FADD0 SIZE: 0x100 + char downloadName[256]; //OFS: 0x4FAED0 SIZE: 0x100 + int downloadNumber; //OFS: 0x4FAFD0 SIZE: 0x4 + int downloadBlock; //OFS: 0x4FAFD4 SIZE: 0x4 + int downloadCount; //OFS: 0x4FAFD8 SIZE: 0x4 + int downloadSize; //OFS: 0x4FAFDC SIZE: 0x4 + char downloadList[1536]; //OFS: 0x4FAFE0 SIZE: 0x600 + int downloadRestart; //OFS: 0x4FB5E0 SIZE: 0x4 + int gameDirChanged; //OFS: 0x4FB5E4 SIZE: 0x4 + _BYTE gap_4FB5E8[119]; //OFS: 0x4FB5E8 SIZE: 0x77 + char field_4FB65F; //OFS: 0x4FB65F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(clientStatic_s, 0x4FB660); + ASSERT_STRUCT_OFFSET(clientStatic_s, quit, 0x0); + ASSERT_STRUCT_OFFSET(clientStatic_s, hunkUsersStarted, 0x4); + ASSERT_STRUCT_OFFSET(clientStatic_s, serverName, 0x8); + ASSERT_STRUCT_OFFSET(clientStatic_s, field_108, 0x108); + ASSERT_STRUCT_OFFSET(clientStatic_s, field_128, 0x128); + ASSERT_STRUCT_OFFSET(clientStatic_s, gap12C, 0x12C); + ASSERT_STRUCT_OFFSET(clientStatic_s, rendererStarted, 0x13C); + ASSERT_STRUCT_OFFSET(clientStatic_s, soundStarted, 0x140); + ASSERT_STRUCT_OFFSET(clientStatic_s, uiStarted, 0x144); + ASSERT_STRUCT_OFFSET(clientStatic_s, frametime, 0x148); + ASSERT_STRUCT_OFFSET(clientStatic_s, realtimepause, 0x14C); + ASSERT_STRUCT_OFFSET(clientStatic_s, realtime, 0x150); + ASSERT_STRUCT_OFFSET(clientStatic_s, realFrameTime, 0x154); + ASSERT_STRUCT_OFFSET(clientStatic_s, logo, 0x158); + ASSERT_STRUCT_OFFSET(clientStatic_s, mapCenter, 0x170); + ASSERT_STRUCT_OFFSET(clientStatic_s, numlocalservers, 0x17C); + ASSERT_STRUCT_OFFSET(clientStatic_s, localServers, 0x180); + ASSERT_STRUCT_OFFSET(clientStatic_s, gap_8180, 0x8180); + ASSERT_STRUCT_OFFSET(clientStatic_s, numglobalservers, 0x8184); + ASSERT_STRUCT_OFFSET(clientStatic_s, globalServers, 0x8188); + ASSERT_STRUCT_OFFSET(clientStatic_s, numfriendsservers, 0x4EA188); + ASSERT_STRUCT_OFFSET(clientStatic_s, pad, 0x4EA18C); + ASSERT_STRUCT_OFFSET(clientStatic_s, friendServers, 0x4EA190); + ASSERT_STRUCT_OFFSET(clientStatic_s, numfavoriteservers, 0x4F2190); + ASSERT_STRUCT_OFFSET(clientStatic_s, pad2, 0x4F2194); + ASSERT_STRUCT_OFFSET(clientStatic_s, favoriteServers, 0x4F2198); + ASSERT_STRUCT_OFFSET(clientStatic_s, pingUpdateSource, 0x4FA198); + ASSERT_STRUCT_OFFSET(clientStatic_s, gap_4FA19C, 0x4FA19C); + ASSERT_STRUCT_OFFSET(clientStatic_s, dNet, 0x4FAD00); + ASSERT_STRUCT_OFFSET(clientStatic_s, gap4FAD18, 0x4FAD18); + ASSERT_STRUCT_OFFSET(clientStatic_s, debug, 0x4FAD4C); + ASSERT_STRUCT_OFFSET(clientStatic_s, renderForward, 0x4FADB4); + ASSERT_STRUCT_OFFSET(clientStatic_s, renderPos, 0x4FADC0); + ASSERT_STRUCT_OFFSET(clientStatic_s, download, 0x4FADCC); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadTempName, 0x4FADD0); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadName, 0x4FAED0); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadNumber, 0x4FAFD0); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadBlock, 0x4FAFD4); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadCount, 0x4FAFD8); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadSize, 0x4FAFDC); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadList, 0x4FAFE0); + ASSERT_STRUCT_OFFSET(clientStatic_s, downloadRestart, 0x4FB5E0); + ASSERT_STRUCT_OFFSET(clientStatic_s, gameDirChanged, 0x4FB5E4); + ASSERT_STRUCT_OFFSET(clientStatic_s, gap_4FB5E8, 0x4FB5E8); + ASSERT_STRUCT_OFFSET(clientStatic_s, field_4FB65F, 0x4FB65F); + + struct clientUIActive_s + { + char active; //OFS: 0x0 SIZE: 0x1 + char isRunning; //OFS: 0x1 SIZE: 0x1 + char cgameInitialized; //OFS: 0x2 SIZE: 0x1 + char cgameInitCalled; //OFS: 0x3 SIZE: 0x1 + int mapPreloaded; //OFS: 0x4 SIZE: 0x4 + int keyCatchers; //OFS: 0x8 SIZE: 0x4 + int displayHUDWithKeycatchUI; //OFS: 0xC SIZE: 0x4 + connstate_t connectionState[1]; //OFS: 0x10 SIZE: 0x4 + int nextScrollTime; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientUIActive_s, 0x18); + ASSERT_STRUCT_OFFSET(clientUIActive_s, active, 0x0); + ASSERT_STRUCT_OFFSET(clientUIActive_s, isRunning, 0x1); + ASSERT_STRUCT_OFFSET(clientUIActive_s, cgameInitialized, 0x2); + ASSERT_STRUCT_OFFSET(clientUIActive_s, cgameInitCalled, 0x3); + ASSERT_STRUCT_OFFSET(clientUIActive_s, mapPreloaded, 0x4); + ASSERT_STRUCT_OFFSET(clientUIActive_s, keyCatchers, 0x8); + ASSERT_STRUCT_OFFSET(clientUIActive_s, displayHUDWithKeycatchUI, 0xC); + ASSERT_STRUCT_OFFSET(clientUIActive_s, connectionState, 0x10); + ASSERT_STRUCT_OFFSET(clientUIActive_s, nextScrollTime, 0x14); + + struct TraceExtents + { + float start[4]; //OFS: 0x0 SIZE: 0x10 + float end[4]; //OFS: 0x10 SIZE: 0x10 + float invDelta[4]; //OFS: 0x20 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(TraceExtents, 0x30); + ASSERT_STRUCT_OFFSET(TraceExtents, start, 0x0); + ASSERT_STRUCT_OFFSET(TraceExtents, end, 0x10); + ASSERT_STRUCT_OFFSET(TraceExtents, invDelta, 0x20); + + struct moveclip_t + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + float outerSize[3]; //OFS: 0x18 SIZE: 0xC + TraceExtents extents; //OFS: 0x24 SIZE: 0x30 + int passEntityNum; //OFS: 0x54 SIZE: 0x4 + int passOwnerNum; //OFS: 0x58 SIZE: 0x4 + int contentmask; //OFS: 0x5C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(moveclip_t, 0x60); + ASSERT_STRUCT_OFFSET(moveclip_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(moveclip_t, maxs, 0xC); + ASSERT_STRUCT_OFFSET(moveclip_t, outerSize, 0x18); + ASSERT_STRUCT_OFFSET(moveclip_t, extents, 0x24); + ASSERT_STRUCT_OFFSET(moveclip_t, passEntityNum, 0x54); + ASSERT_STRUCT_OFFSET(moveclip_t, passOwnerNum, 0x58); + ASSERT_STRUCT_OFFSET(moveclip_t, contentmask, 0x5C); + + struct IgnoreEntParams + { + int baseEntity; //OFS: 0x0 SIZE: 0x4 + int parentEntity; //OFS: 0x4 SIZE: 0x4 + char ignoreSelf; //OFS: 0x8 SIZE: 0x1 + char ignoreParent; //OFS: 0x9 SIZE: 0x1 + char ignoreSiblings; //OFS: 0xA SIZE: 0x1 + char ignoreChildren; //OFS: 0xB SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(IgnoreEntParams, 0xC); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, baseEntity, 0x0); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, parentEntity, 0x4); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, ignoreSelf, 0x8); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, ignoreParent, 0x9); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, ignoreSiblings, 0xA); + ASSERT_STRUCT_OFFSET(IgnoreEntParams, ignoreChildren, 0xB); + + struct pointtrace_t + { + TraceExtents extents; //OFS: 0x0 SIZE: 0x30 + IgnoreEntParams * ignoreEntParams; //OFS: 0x30 SIZE: 0x4 + int contentmask; //OFS: 0x34 SIZE: 0x4 + int bLocational; //OFS: 0x38 SIZE: 0x4 + int priorityMap; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pointtrace_t, 0x40); + ASSERT_STRUCT_OFFSET(pointtrace_t, extents, 0x0); + ASSERT_STRUCT_OFFSET(pointtrace_t, ignoreEntParams, 0x30); + ASSERT_STRUCT_OFFSET(pointtrace_t, contentmask, 0x34); + ASSERT_STRUCT_OFFSET(pointtrace_t, bLocational, 0x38); + ASSERT_STRUCT_OFFSET(pointtrace_t, priorityMap, 0x3C); + + struct field_t + { + int cursor; //OFS: 0x0 SIZE: 0x4 + int scroll; //OFS: 0x4 SIZE: 0x4 + int drawWidth; //OFS: 0x8 SIZE: 0x4 + int widthInPixels; //OFS: 0xC SIZE: 0x4 + float charHeight; //OFS: 0x10 SIZE: 0x4 + int fixedSize; //OFS: 0x14 SIZE: 0x4 + char buffer[256]; //OFS: 0x18 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(field_t, 0x118); + ASSERT_STRUCT_OFFSET(field_t, cursor, 0x0); + ASSERT_STRUCT_OFFSET(field_t, scroll, 0x4); + ASSERT_STRUCT_OFFSET(field_t, drawWidth, 0x8); + ASSERT_STRUCT_OFFSET(field_t, widthInPixels, 0xC); + ASSERT_STRUCT_OFFSET(field_t, charHeight, 0x10); + ASSERT_STRUCT_OFFSET(field_t, fixedSize, 0x14); + ASSERT_STRUCT_OFFSET(field_t, buffer, 0x18); + + struct entityHandler_t + { + void (__cdecl *think)(gentity_s *); //OFS: 0x0 SIZE: 0x4 + void (__cdecl *reached)(gentity_s *); //OFS: 0x4 SIZE: 0x4 + void (__cdecl *blocked)(gentity_s *, gentity_s *); //OFS: 0x8 SIZE: 0x4 + void (__cdecl *touch)(gentity_s *, gentity_s *, int); //OFS: 0xC SIZE: 0x4 + void (__cdecl *use)(gentity_s *, gentity_s *, gentity_s *); //OFS: 0x10 SIZE: 0x4 + void (__cdecl *pain)(gentity_s *, gentity_s *, int, const float *, const int, const float *, const int, const int); //OFS: 0x14 SIZE: 0x4 + void (__cdecl *die)(gentity_s *, gentity_s *, gentity_s *, const int, const int, const int, const float *, const int); //OFS: 0x18 SIZE: 0x4 + void (__cdecl *entinfo)(gentity_s *, float *); //OFS: 0x1C SIZE: 0x4 + void (__cdecl *controller)(const gentity_s *, int *); //OFS: 0x20 SIZE: 0x4 + meansOfDeath_t methodOfDeath; //OFS: 0x24 SIZE: 0x4 + int splashMethodOfDeath; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(entityHandler_t, 0x2C); + ASSERT_STRUCT_OFFSET(entityHandler_t, think, 0x0); + ASSERT_STRUCT_OFFSET(entityHandler_t, reached, 0x4); + ASSERT_STRUCT_OFFSET(entityHandler_t, blocked, 0x8); + ASSERT_STRUCT_OFFSET(entityHandler_t, touch, 0xC); + ASSERT_STRUCT_OFFSET(entityHandler_t, use, 0x10); + ASSERT_STRUCT_OFFSET(entityHandler_t, pain, 0x14); + ASSERT_STRUCT_OFFSET(entityHandler_t, die, 0x18); + ASSERT_STRUCT_OFFSET(entityHandler_t, entinfo, 0x1C); + ASSERT_STRUCT_OFFSET(entityHandler_t, controller, 0x20); + ASSERT_STRUCT_OFFSET(entityHandler_t, methodOfDeath, 0x24); + ASSERT_STRUCT_OFFSET(entityHandler_t, splashMethodOfDeath, 0x28); + + struct yy_buffer_state + { + _iobuf * yy_input_file; //OFS: 0x0 SIZE: 0x4 + char * yy_ch_buf; //OFS: 0x4 SIZE: 0x4 + char * yy_buf_pos; //OFS: 0x8 SIZE: 0x4 + unsigned int yy_buf_size; //OFS: 0xC SIZE: 0x4 + int yy_n_chars; //OFS: 0x10 SIZE: 0x4 + int yy_is_our_buffer; //OFS: 0x14 SIZE: 0x4 + int yy_is_interactive; //OFS: 0x18 SIZE: 0x4 + int yy_at_bol; //OFS: 0x1C SIZE: 0x4 + int yy_fill_buffer; //OFS: 0x20 SIZE: 0x4 + int yy_buffer_status; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(yy_buffer_state, 0x28); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_input_file, 0x0); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_ch_buf, 0x4); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_buf_pos, 0x8); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_buf_size, 0xC); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_n_chars, 0x10); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_is_our_buffer, 0x14); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_is_interactive, 0x18); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_at_bol, 0x1C); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_fill_buffer, 0x20); + ASSERT_STRUCT_OFFSET(yy_buffer_state, yy_buffer_status, 0x24); + + struct CmdArgsPrivate + { + char textPool[8192]; //OFS: 0x0 SIZE: 0x2000 + char * argvPool[512]; //OFS: 0x2000 SIZE: 0x800 + int usedTextPool[8]; //OFS: 0x2800 SIZE: 0x20 + int totalUsedArgvPool; //OFS: 0x2820 SIZE: 0x4 + int totalUsedTextPool; //OFS: 0x2824 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CmdArgsPrivate, 0x2828); + ASSERT_STRUCT_OFFSET(CmdArgsPrivate, textPool, 0x0); + ASSERT_STRUCT_OFFSET(CmdArgsPrivate, argvPool, 0x2000); + ASSERT_STRUCT_OFFSET(CmdArgsPrivate, usedTextPool, 0x2800); + ASSERT_STRUCT_OFFSET(CmdArgsPrivate, totalUsedArgvPool, 0x2820); + ASSERT_STRUCT_OFFSET(CmdArgsPrivate, totalUsedTextPool, 0x2824); + + struct ConDrawInputGlob + { + char autoCompleteChoice[64]; //OFS: 0x0 SIZE: 0x40 + int matchIndex; //OFS: 0x40 SIZE: 0x4 + int matchCount; //OFS: 0x44 SIZE: 0x4 + const char * inputText; //OFS: 0x48 SIZE: 0x4 + int inputTextLen; //OFS: 0x4C SIZE: 0x4 + bool hasExactMatch; //OFS: 0x50 SIZE: 0x1 + bool mayAutoComplete; //OFS: 0x51 SIZE: 0x1 + float x; //OFS: 0x54 SIZE: 0x4 + float y; //OFS: 0x58 SIZE: 0x4 + float leftX; //OFS: 0x5C SIZE: 0x4 + float fontHeight; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ConDrawInputGlob, 0x64); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, autoCompleteChoice, 0x0); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, matchIndex, 0x40); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, matchCount, 0x44); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, inputText, 0x48); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, inputTextLen, 0x4C); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, hasExactMatch, 0x50); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, mayAutoComplete, 0x51); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, x, 0x54); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, y, 0x58); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, leftX, 0x5C); + ASSERT_STRUCT_OFFSET(ConDrawInputGlob, fontHeight, 0x60); + + struct clientConnection_t + { + int qport; //OFS: 0x0 SIZE: 0x4 + int clientNum; //OFS: 0x4 SIZE: 0x4 + int lastPacketSentTime; //OFS: 0x8 SIZE: 0x4 + int lastPacketTime; //OFS: 0xC SIZE: 0x4 + netadr_s serverAddress; //OFS: 0x10 SIZE: 0x18 + int connectTime; //OFS: 0x28 SIZE: 0x4 + int connectPacketCount; //OFS: 0x2C SIZE: 0x4 + char serverMessage[256]; //OFS: 0x30 SIZE: 0x100 + int challenge; //OFS: 0x130 SIZE: 0x4 + int checksumFeed; //OFS: 0x134 SIZE: 0x4 + int reliableSequence; //OFS: 0x138 SIZE: 0x4 + int reliableAcknowledge; //OFS: 0x13C SIZE: 0x4 + char reliableCommands[128][512]; //OFS: 0x140 SIZE: 0x10000 + int serverMessageSequence; //OFS: 0x10140 SIZE: 0x4 + int serverCommandSequence; //OFS: 0x10144 SIZE: 0x4 + int lastExecutedServerCommand; //OFS: 0x10148 SIZE: 0x4 + char serverCommands[128][512]; //OFS: 0x1014C SIZE: 0x10000 + char isServerRestarting; //OFS: 0x2014C SIZE: 0x1 + int timeDemoBaseTime; //OFS: 0x20150 SIZE: 0x4 + netchan_s netchan; //OFS: 0x20154 SIZE: 0x6C8 + char netchanOutgoingBuffer[2048]; //OFS: 0x2081C SIZE: 0x800 + char netchanIncomingBuffer[131072]; //OFS: 0x2101C SIZE: 0x20000 + netProfileInfo_t OOBProf; //OFS: 0x4101C SIZE: 0x5E0 + char statPacketsToSend; //OFS: 0x415FC SIZE: 0x1 + int statPacketSendTime[7]; //OFS: 0x41600 SIZE: 0x1C + int serverChallenge; //OFS: 0x4161C SIZE: 0x4 + int clientChallenge; //OFS: 0x41620 SIZE: 0x4 + int nonce; //OFS: 0x41624 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clientConnection_t, 0x41628); + ASSERT_STRUCT_OFFSET(clientConnection_t, qport, 0x0); + ASSERT_STRUCT_OFFSET(clientConnection_t, clientNum, 0x4); + ASSERT_STRUCT_OFFSET(clientConnection_t, lastPacketSentTime, 0x8); + ASSERT_STRUCT_OFFSET(clientConnection_t, lastPacketTime, 0xC); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverAddress, 0x10); + ASSERT_STRUCT_OFFSET(clientConnection_t, connectTime, 0x28); + ASSERT_STRUCT_OFFSET(clientConnection_t, connectPacketCount, 0x2C); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverMessage, 0x30); + ASSERT_STRUCT_OFFSET(clientConnection_t, challenge, 0x130); + ASSERT_STRUCT_OFFSET(clientConnection_t, checksumFeed, 0x134); + ASSERT_STRUCT_OFFSET(clientConnection_t, reliableSequence, 0x138); + ASSERT_STRUCT_OFFSET(clientConnection_t, reliableAcknowledge, 0x13C); + ASSERT_STRUCT_OFFSET(clientConnection_t, reliableCommands, 0x140); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverMessageSequence, 0x10140); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverCommandSequence, 0x10144); + ASSERT_STRUCT_OFFSET(clientConnection_t, lastExecutedServerCommand, 0x10148); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverCommands, 0x1014C); + ASSERT_STRUCT_OFFSET(clientConnection_t, isServerRestarting, 0x2014C); + ASSERT_STRUCT_OFFSET(clientConnection_t, timeDemoBaseTime, 0x20150); + ASSERT_STRUCT_OFFSET(clientConnection_t, netchan, 0x20154); + ASSERT_STRUCT_OFFSET(clientConnection_t, netchanOutgoingBuffer, 0x2081C); + ASSERT_STRUCT_OFFSET(clientConnection_t, netchanIncomingBuffer, 0x2101C); + ASSERT_STRUCT_OFFSET(clientConnection_t, OOBProf, 0x4101C); + ASSERT_STRUCT_OFFSET(clientConnection_t, statPacketsToSend, 0x415FC); + ASSERT_STRUCT_OFFSET(clientConnection_t, statPacketSendTime, 0x41600); + ASSERT_STRUCT_OFFSET(clientConnection_t, serverChallenge, 0x4161C); + ASSERT_STRUCT_OFFSET(clientConnection_t, clientChallenge, 0x41620); + ASSERT_STRUCT_OFFSET(clientConnection_t, nonce, 0x41624); + + struct aifields + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *setter)(actor_s *, const aifields *); //OFS: 0xC SIZE: 0x4 + void (__cdecl *getter)(actor_s *, const aifields *); //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(aifields, 0x14); + ASSERT_STRUCT_OFFSET(aifields, name, 0x0); + ASSERT_STRUCT_OFFSET(aifields, ofs, 0x4); + ASSERT_STRUCT_OFFSET(aifields, type, 0x8); + ASSERT_STRUCT_OFFSET(aifields, setter, 0xC); + ASSERT_STRUCT_OFFSET(aifields, getter, 0x10); + + struct ent_field_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *callback)(gentity_s *, int); //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ent_field_t, 0x10); + ASSERT_STRUCT_OFFSET(ent_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(ent_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(ent_field_t, type, 0x8); + ASSERT_STRUCT_OFFSET(ent_field_t, callback, 0xC); + + struct sentient_fields_s + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *setter)(sentient_s *, const sentient_fields_s *); //OFS: 0xC SIZE: 0x4 + void (__cdecl *getter)(sentient_s *, const sentient_fields_s *); //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sentient_fields_s, 0x14); + ASSERT_STRUCT_OFFSET(sentient_fields_s, name, 0x0); + ASSERT_STRUCT_OFFSET(sentient_fields_s, ofs, 0x4); + ASSERT_STRUCT_OFFSET(sentient_fields_s, type, 0x8); + ASSERT_STRUCT_OFFSET(sentient_fields_s, setter, 0xC); + ASSERT_STRUCT_OFFSET(sentient_fields_s, getter, 0x10); + + struct client_fields_s + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + int type2; //OFS: 0xC SIZE: 0x4 + void (__cdecl *setter)(gclient_s *, client_fields_s *); //OFS: 0x10 SIZE: 0x4 + void (__cdecl *getter)(gclient_s *, client_fields_s *); //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(client_fields_s, 0x18); + ASSERT_STRUCT_OFFSET(client_fields_s, name, 0x0); + ASSERT_STRUCT_OFFSET(client_fields_s, ofs, 0x4); + ASSERT_STRUCT_OFFSET(client_fields_s, type, 0x8); + ASSERT_STRUCT_OFFSET(client_fields_s, type2, 0xC); + ASSERT_STRUCT_OFFSET(client_fields_s, setter, 0x10); + ASSERT_STRUCT_OFFSET(client_fields_s, getter, 0x14); + + struct game_hudelem_field_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + int mask; //OFS: 0xC SIZE: 0x4 + int shift; //OFS: 0x10 SIZE: 0x4 + void (__cdecl *setter)(game_hudelem_s *, int); //OFS: 0x14 SIZE: 0x4 + void (__cdecl *getter)(game_hudelem_s *, int); //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(game_hudelem_field_t, 0x1C); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, type, 0x8); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, mask, 0xC); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, shift, 0x10); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, setter, 0x14); + ASSERT_STRUCT_OFFSET(game_hudelem_field_t, getter, 0x18); + + struct node_field_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *getter)(void *, int) ; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(node_field_t, 0x10); + ASSERT_STRUCT_OFFSET(node_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(node_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(node_field_t, type, 0x8); + ASSERT_STRUCT_OFFSET(node_field_t, getter, 0xC); + + struct CmdText + { + char * data; //OFS: 0x0 SIZE: 0x4 + int maxsize; //OFS: 0x4 SIZE: 0x4 + int cmdsize; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CmdText, 0xC); + ASSERT_STRUCT_OFFSET(CmdText, data, 0x0); + ASSERT_STRUCT_OFFSET(CmdText, maxsize, 0x4); + ASSERT_STRUCT_OFFSET(CmdText, cmdsize, 0x8); + + struct Console + { + _BYTE gap_0[66120]; //OFS: 0x0 SIZE: 0x10248 + char outputVisible; //OFS: 0x10248 SIZE: 0x1 + _BYTE gap_10249[18563]; //OFS: 0x10249 SIZE: 0x4883 + int field_14ACC; //OFS: 0x14ACC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Console, 0x14AD0); + ASSERT_STRUCT_OFFSET(Console, gap_0, 0x0); + ASSERT_STRUCT_OFFSET(Console, outputVisible, 0x10248); + ASSERT_STRUCT_OFFSET(Console, gap_10249, 0x10249); + ASSERT_STRUCT_OFFSET(Console, field_14ACC, 0x14ACC); + + struct vehicle_field_s + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + int type; //OFS: 0x8 SIZE: 0x4 + int mask; //OFS: 0xC SIZE: 0x4 + void (__cdecl *setter)(void *, int); //OFS: 0x10 SIZE: 0x4 + void (__cdecl *getter)(void *, int); //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vehicle_field_s, 0x18); + ASSERT_STRUCT_OFFSET(vehicle_field_s, name, 0x0); + ASSERT_STRUCT_OFFSET(vehicle_field_s, ofs, 0x4); + ASSERT_STRUCT_OFFSET(vehicle_field_s, type, 0x8); + ASSERT_STRUCT_OFFSET(vehicle_field_s, mask, 0xC); + ASSERT_STRUCT_OFFSET(vehicle_field_s, setter, 0x10); + ASSERT_STRUCT_OFFSET(vehicle_field_s, getter, 0x14); + + struct menuParse_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + void (__cdecl *func)(void *, int); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(menuParse_t, 0x8); + ASSERT_STRUCT_OFFSET(menuParse_t, name, 0x0); + ASSERT_STRUCT_OFFSET(menuParse_t, func, 0x4); + + struct itemParse_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + void (__cdecl *func)(void *, int); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(itemParse_t, 0x8); + ASSERT_STRUCT_OFFSET(itemParse_t, name, 0x0); + ASSERT_STRUCT_OFFSET(itemParse_t, func, 0x4); + + struct commandDef_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + void (__cdecl *func)(UiContext *, itemDef_s *, char **); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(commandDef_t, 0x8); + ASSERT_STRUCT_OFFSET(commandDef_t, name, 0x0); + ASSERT_STRUCT_OFFSET(commandDef_t, func, 0x4); + + struct KeyState + { + int down; //OFS: 0x0 SIZE: 0x4 + int repeats; //OFS: 0x4 SIZE: 0x4 + char * binding; //OFS: 0x8 SIZE: 0x4 + char * binding_2; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(KeyState, 0x10); + ASSERT_STRUCT_OFFSET(KeyState, down, 0x0); + ASSERT_STRUCT_OFFSET(KeyState, repeats, 0x4); + ASSERT_STRUCT_OFFSET(KeyState, binding, 0x8); + ASSERT_STRUCT_OFFSET(KeyState, binding_2, 0xC); + + struct PlayerKeyState + { + int chat_team; //OFS: 0x0 SIZE: 0x4 + _BYTE gap_4[4]; //OFS: 0x4 SIZE: 0x4 + int anyKeyDown; //OFS: 0x8 SIZE: 0x4 + KeyState keys[256]; //OFS: 0xC SIZE: 0x1000 + LocSelInputState locSelInputState; //OFS: 0x100C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PlayerKeyState, 0x1010); + ASSERT_STRUCT_OFFSET(PlayerKeyState, chat_team, 0x0); + ASSERT_STRUCT_OFFSET(PlayerKeyState, gap_4, 0x4); + ASSERT_STRUCT_OFFSET(PlayerKeyState, anyKeyDown, 0x8); + ASSERT_STRUCT_OFFSET(PlayerKeyState, keys, 0xC); + ASSERT_STRUCT_OFFSET(PlayerKeyState, locSelInputState, 0x100C); + + union qfile_gus + { + _iobuf * o; //OFS: 0x0 SIZE: 0x4 + char * z; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(qfile_gus, 0x4); + + struct qfile_us + { + qfile_gus file; //OFS: 0x0 SIZE: 0x4 + int iwdIsClone; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(qfile_us, 0x8); + ASSERT_STRUCT_OFFSET(qfile_us, file, 0x0); + ASSERT_STRUCT_OFFSET(qfile_us, iwdIsClone, 0x4); + + struct fileHandleData_t + { + qfile_us handleFiles; //OFS: 0x0 SIZE: 0x8 + int handleSync; //OFS: 0x8 SIZE: 0x4 + int fileSize; //OFS: 0xC SIZE: 0x4 + int zipFilePos; //OFS: 0x10 SIZE: 0x4 + void * zipFile; //OFS: 0x14 SIZE: 0x4 + int streamed; //OFS: 0x18 SIZE: 0x4 + char name[256]; //OFS: 0x1C SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(fileHandleData_t, 0x11C); + ASSERT_STRUCT_OFFSET(fileHandleData_t, handleFiles, 0x0); + ASSERT_STRUCT_OFFSET(fileHandleData_t, handleSync, 0x8); + ASSERT_STRUCT_OFFSET(fileHandleData_t, fileSize, 0xC); + ASSERT_STRUCT_OFFSET(fileHandleData_t, zipFilePos, 0x10); + ASSERT_STRUCT_OFFSET(fileHandleData_t, zipFile, 0x14); + ASSERT_STRUCT_OFFSET(fileHandleData_t, streamed, 0x18); + ASSERT_STRUCT_OFFSET(fileHandleData_t, name, 0x1C); + + struct game_hudelem_s + { + hudelem_s elem; //OFS: 0x0 SIZE: 0xAC + int clientNum; //OFS: 0xAC SIZE: 0x4 + int team; //OFS: 0xB0 SIZE: 0x4 + int archived; //OFS: 0xB4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(game_hudelem_s, 0xB8); + ASSERT_STRUCT_OFFSET(game_hudelem_s, elem, 0x0); + ASSERT_STRUCT_OFFSET(game_hudelem_s, clientNum, 0xAC); + ASSERT_STRUCT_OFFSET(game_hudelem_s, team, 0xB0); + ASSERT_STRUCT_OFFSET(game_hudelem_s, archived, 0xB4); + + struct PartyData_s + { + _BYTE gap_0[5996]; //OFS: 0x0 SIZE: 0x176C + _DWORD areWeHost; //OFS: 0x176C SIZE: 0x4 + _DWORD joiningAnotherParty; //OFS: 0x1770 SIZE: 0x4 + _DWORD inParty; //OFS: 0x1774 SIZE: 0x4 + _DWORD party_systemActive; //OFS: 0x1778 SIZE: 0x4 + _BYTE gap_177C[2739]; //OFS: 0x177C SIZE: 0xAB3 + char field_222F; //OFS: 0x222F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(PartyData_s, 0x2230); + ASSERT_STRUCT_OFFSET(PartyData_s, gap_0, 0x0); + ASSERT_STRUCT_OFFSET(PartyData_s, areWeHost, 0x176C); + ASSERT_STRUCT_OFFSET(PartyData_s, joiningAnotherParty, 0x1770); + ASSERT_STRUCT_OFFSET(PartyData_s, inParty, 0x1774); + ASSERT_STRUCT_OFFSET(PartyData_s, party_systemActive, 0x1778); + ASSERT_STRUCT_OFFSET(PartyData_s, gap_177C, 0x177C); + ASSERT_STRUCT_OFFSET(PartyData_s, field_222F, 0x222F); + + struct __declspec(align(1)) SessionData + { + _BYTE gap0[375]; //OFS: 0x0 SIZE: 0x177 + char field_177; //OFS: 0x177 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SessionData, 0x178); + ASSERT_STRUCT_OFFSET(SessionData, gap0, 0x0); + ASSERT_STRUCT_OFFSET(SessionData, field_177, 0x177); + + struct __declspec(align(1)) playerDetails_s + { + _BYTE gap0[103]; //OFS: 0x0 SIZE: 0x67 + char field_67; //OFS: 0x67 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(playerDetails_s, 0x68); + ASSERT_STRUCT_OFFSET(playerDetails_s, gap0, 0x0); + ASSERT_STRUCT_OFFSET(playerDetails_s, field_67, 0x67); + + struct cspField_t + { + const char * szName; //OFS: 0x0 SIZE: 0x4 + int iOffset; //OFS: 0x4 SIZE: 0x4 + int iFieldType; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cspField_t, 0xC); + ASSERT_STRUCT_OFFSET(cspField_t, szName, 0x0); + ASSERT_STRUCT_OFFSET(cspField_t, iOffset, 0x4); + ASSERT_STRUCT_OFFSET(cspField_t, iFieldType, 0x8); + + struct NetField + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int offset; //OFS: 0x4 SIZE: 0x4 + int bits; //OFS: 0x8 SIZE: 0x4 + int type; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(NetField, 0x10); + ASSERT_STRUCT_OFFSET(NetField, name, 0x0); + ASSERT_STRUCT_OFFSET(NetField, offset, 0x4); + ASSERT_STRUCT_OFFSET(NetField, bits, 0x8); + ASSERT_STRUCT_OFFSET(NetField, type, 0xC); + + struct constantConfigString + { + int configStringNum; //OFS: 0x0 SIZE: 0x4 + char * configString; //OFS: 0x4 SIZE: 0x4 + int configStringHash; //OFS: 0x8 SIZE: 0x4 + int lowercaseConfigStringHash; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(constantConfigString, 0x10); + ASSERT_STRUCT_OFFSET(constantConfigString, configStringNum, 0x0); + ASSERT_STRUCT_OFFSET(constantConfigString, configString, 0x4); + ASSERT_STRUCT_OFFSET(constantConfigString, configStringHash, 0x8); + ASSERT_STRUCT_OFFSET(constantConfigString, lowercaseConfigStringHash, 0xC); + + struct __declspec(align(2)) _XINPUT_VIBRATION + { + unsigned __int16 wLeftMotorSpeed; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 wRightMotorSpeed; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(_XINPUT_VIBRATION, 0x4); + ASSERT_STRUCT_OFFSET(_XINPUT_VIBRATION, wLeftMotorSpeed, 0x0); + ASSERT_STRUCT_OFFSET(_XINPUT_VIBRATION, wRightMotorSpeed, 0x2); + + struct __declspec(align(2)) _XINPUT_GAMEPAD + { + WORD wButtons; //OFS: 0x0 SIZE: 0x2 + BYTE bLeftTrigger; //OFS: 0x2 SIZE: 0x1 + BYTE bRightTrigger; //OFS: 0x3 SIZE: 0x1 + SHORT sThumbLX; //OFS: 0x4 SIZE: 0x2 + SHORT sThumbLY; //OFS: 0x6 SIZE: 0x2 + SHORT sThumbRX; //OFS: 0x8 SIZE: 0x2 + SHORT sThumbRY; //OFS: 0xA SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(_XINPUT_GAMEPAD, 0xC); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, wButtons, 0x0); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, bLeftTrigger, 0x2); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, bRightTrigger, 0x3); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, sThumbLX, 0x4); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, sThumbLY, 0x6); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, sThumbRX, 0x8); + ASSERT_STRUCT_OFFSET(_XINPUT_GAMEPAD, sThumbRY, 0xA); + + struct _XINPUT_STATE + { + DWORD dwPacketNumber; //OFS: 0x0 SIZE: 0x4 + _XINPUT_GAMEPAD Gamepad; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(_XINPUT_STATE, 0x10); + ASSERT_STRUCT_OFFSET(_XINPUT_STATE, dwPacketNumber, 0x0); + ASSERT_STRUCT_OFFSET(_XINPUT_STATE, Gamepad, 0x4); + + struct PhysicalMemoryAllocation + { + char * name; //OFS: 0x0 SIZE: 0x4 + unsigned int pos; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysicalMemoryAllocation, 0x8); + ASSERT_STRUCT_OFFSET(PhysicalMemoryAllocation, name, 0x0); + ASSERT_STRUCT_OFFSET(PhysicalMemoryAllocation, pos, 0x4); + + struct PhysicalMemoryPrim + { + char * allocName; //OFS: 0x0 SIZE: 0x4 + unsigned int allocListCount; //OFS: 0x4 SIZE: 0x4 + unsigned int pos; //OFS: 0x8 SIZE: 0x4 + PhysicalMemoryAllocation allocList[32]; //OFS: 0xC SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(PhysicalMemoryPrim, 0x10C); + ASSERT_STRUCT_OFFSET(PhysicalMemoryPrim, allocName, 0x0); + ASSERT_STRUCT_OFFSET(PhysicalMemoryPrim, allocListCount, 0x4); + ASSERT_STRUCT_OFFSET(PhysicalMemoryPrim, pos, 0x8); + ASSERT_STRUCT_OFFSET(PhysicalMemoryPrim, allocList, 0xC); + + struct PhysicalMemory + { + char * name; //OFS: 0x0 SIZE: 0x4 + unsigned __int8 * buf; //OFS: 0x4 SIZE: 0x4 + PhysicalMemoryPrim prim[2]; //OFS: 0x8 SIZE: 0x218 + unsigned int size; //OFS: 0x220 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysicalMemory, 0x224); + ASSERT_STRUCT_OFFSET(PhysicalMemory, name, 0x0); + ASSERT_STRUCT_OFFSET(PhysicalMemory, buf, 0x4); + ASSERT_STRUCT_OFFSET(PhysicalMemory, prim, 0x8); + ASSERT_STRUCT_OFFSET(PhysicalMemory, size, 0x220); + + struct fileInIwd_s + { + unsigned int pos; //OFS: 0x0 SIZE: 0x4 + char * name; //OFS: 0x4 SIZE: 0x4 + fileInIwd_s * next; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(fileInIwd_s, 0xC); + ASSERT_STRUCT_OFFSET(fileInIwd_s, pos, 0x0); + ASSERT_STRUCT_OFFSET(fileInIwd_s, name, 0x4); + ASSERT_STRUCT_OFFSET(fileInIwd_s, next, 0x8); + + struct iwd_t + { + char iwdFilename[256]; //OFS: 0x0 SIZE: 0x100 + char iwdBasename[256]; //OFS: 0x100 SIZE: 0x100 + char iwdGamename[256]; //OFS: 0x200 SIZE: 0x100 + char * handle; //OFS: 0x300 SIZE: 0x4 + int checksum; //OFS: 0x304 SIZE: 0x4 + int pure_checksum; //OFS: 0x308 SIZE: 0x4 + volatile int hasOpenFile; //OFS: 0x30C SIZE: 0x4 + int numfiles; //OFS: 0x310 SIZE: 0x4 + char referenced; //OFS: 0x314 SIZE: 0x1 + unsigned int hashSize; //OFS: 0x318 SIZE: 0x4 + fileInIwd_s ** hashTable; //OFS: 0x31C SIZE: 0x4 + fileInIwd_s * buildBuffer; //OFS: 0x320 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(iwd_t, 0x324); + ASSERT_STRUCT_OFFSET(iwd_t, iwdFilename, 0x0); + ASSERT_STRUCT_OFFSET(iwd_t, iwdBasename, 0x100); + ASSERT_STRUCT_OFFSET(iwd_t, iwdGamename, 0x200); + ASSERT_STRUCT_OFFSET(iwd_t, handle, 0x300); + ASSERT_STRUCT_OFFSET(iwd_t, checksum, 0x304); + ASSERT_STRUCT_OFFSET(iwd_t, pure_checksum, 0x308); + ASSERT_STRUCT_OFFSET(iwd_t, hasOpenFile, 0x30C); + ASSERT_STRUCT_OFFSET(iwd_t, numfiles, 0x310); + ASSERT_STRUCT_OFFSET(iwd_t, referenced, 0x314); + ASSERT_STRUCT_OFFSET(iwd_t, hashSize, 0x318); + ASSERT_STRUCT_OFFSET(iwd_t, hashTable, 0x31C); + ASSERT_STRUCT_OFFSET(iwd_t, buildBuffer, 0x320); + + struct __declspec(align(1)) directory_t + { + char path[256]; //OFS: 0x0 SIZE: 0x100 + char gamedir[256]; //OFS: 0x100 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(directory_t, 0x200); + ASSERT_STRUCT_OFFSET(directory_t, path, 0x0); + ASSERT_STRUCT_OFFSET(directory_t, gamedir, 0x100); + + struct searchpath_s + { + searchpath_s * next; //OFS: 0x0 SIZE: 0x4 + iwd_t * iwd; //OFS: 0x4 SIZE: 0x4 + directory_t * dir; //OFS: 0x8 SIZE: 0x4 + int bLocalized; //OFS: 0xC SIZE: 0x4 + int ignore; //OFS: 0x10 SIZE: 0x4 + int ignorePureCheck; //OFS: 0x14 SIZE: 0x4 + int language; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(searchpath_s, 0x1C); + ASSERT_STRUCT_OFFSET(searchpath_s, next, 0x0); + ASSERT_STRUCT_OFFSET(searchpath_s, iwd, 0x4); + ASSERT_STRUCT_OFFSET(searchpath_s, dir, 0x8); + ASSERT_STRUCT_OFFSET(searchpath_s, bLocalized, 0xC); + ASSERT_STRUCT_OFFSET(searchpath_s, ignore, 0x10); + ASSERT_STRUCT_OFFSET(searchpath_s, ignorePureCheck, 0x14); + ASSERT_STRUCT_OFFSET(searchpath_s, language, 0x18); + + struct __declspec(align(1)) PrintChannel + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + bool allowScript; //OFS: 0x20 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(PrintChannel, 0x21); + ASSERT_STRUCT_OFFSET(PrintChannel, name, 0x0); + ASSERT_STRUCT_OFFSET(PrintChannel, allowScript, 0x20); + + struct PrintChannelGlob + { + PrintChannel openChannels[256]; //OFS: 0x0 SIZE: 0x2100 + unsigned int filters[7][8]; //OFS: 0x2100 SIZE: 0xE0 + }; + ASSERT_STRUCT_SIZE(PrintChannelGlob, 0x21E0); + ASSERT_STRUCT_OFFSET(PrintChannelGlob, openChannels, 0x0); + ASSERT_STRUCT_OFFSET(PrintChannelGlob, filters, 0x2100); + + struct weaponParms + { + float forward[3]; //OFS: 0x0 SIZE: 0xC + float right[3]; //OFS: 0xC SIZE: 0xC + float up[3]; //OFS: 0x18 SIZE: 0xC + float muzzleTrace[3]; //OFS: 0x24 SIZE: 0xC + float gunForward[3]; //OFS: 0x30 SIZE: 0xC + const WeaponDef * weapDef; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(weaponParms, 0x40); + ASSERT_STRUCT_OFFSET(weaponParms, forward, 0x0); + ASSERT_STRUCT_OFFSET(weaponParms, right, 0xC); + ASSERT_STRUCT_OFFSET(weaponParms, up, 0x18); + ASSERT_STRUCT_OFFSET(weaponParms, muzzleTrace, 0x24); + ASSERT_STRUCT_OFFSET(weaponParms, gunForward, 0x30); + ASSERT_STRUCT_OFFSET(weaponParms, weapDef, 0x3C); + + struct AntilagClientStore + { + float realClientPositions[4][3]; //OFS: 0x0 SIZE: 0x30 + bool clientMoved[4]; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AntilagClientStore, 0x34); + ASSERT_STRUCT_OFFSET(AntilagClientStore, realClientPositions, 0x0); + ASSERT_STRUCT_OFFSET(AntilagClientStore, clientMoved, 0x30); + + struct loadAssets_t + { + float fadeClamp; //OFS: 0x0 SIZE: 0x4 + int fadeCycle; //OFS: 0x4 SIZE: 0x4 + float fadeAmount; //OFS: 0x8 SIZE: 0x4 + float fadeInAmount; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(loadAssets_t, 0x10); + ASSERT_STRUCT_OFFSET(loadAssets_t, fadeClamp, 0x0); + ASSERT_STRUCT_OFFSET(loadAssets_t, fadeCycle, 0x4); + ASSERT_STRUCT_OFFSET(loadAssets_t, fadeAmount, 0x8); + ASSERT_STRUCT_OFFSET(loadAssets_t, fadeInAmount, 0xC); + + struct menu_stuffs + { + loadAssets_t loadAssets; //OFS: 0x0 SIZE: 0x10 + MenuList menuList; //OFS: 0x10 SIZE: 0xC + itemDef_s * items[256]; //OFS: 0x1C SIZE: 0x400 + menuDef_t * menus[512]; //OFS: 0x41C SIZE: 0x800 + }; + ASSERT_STRUCT_SIZE(menu_stuffs, 0xC1C); + ASSERT_STRUCT_OFFSET(menu_stuffs, loadAssets, 0x0); + ASSERT_STRUCT_OFFSET(menu_stuffs, menuList, 0x10); + ASSERT_STRUCT_OFFSET(menu_stuffs, items, 0x1C); + ASSERT_STRUCT_OFFSET(menu_stuffs, menus, 0x41C); + + struct punctuation_s + { + char * p; //OFS: 0x0 SIZE: 0x4 + int n; //OFS: 0x4 SIZE: 0x4 + punctuation_s * next; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(punctuation_s, 0xC); + ASSERT_STRUCT_OFFSET(punctuation_s, p, 0x0); + ASSERT_STRUCT_OFFSET(punctuation_s, n, 0x4); + ASSERT_STRUCT_OFFSET(punctuation_s, next, 0x8); + + struct __declspec(align(8)) token_s + { + char string[1024]; //OFS: 0x0 SIZE: 0x400 + int type; //OFS: 0x400 SIZE: 0x4 + int subtype; //OFS: 0x404 SIZE: 0x4 + unsigned int intvalue; //OFS: 0x408 SIZE: 0x4 + long double floatvalue; //OFS: 0x410 SIZE: 0x8 + char * whitespace_p; //OFS: 0x418 SIZE: 0x4 + char * endwhitespace_p; //OFS: 0x41C SIZE: 0x4 + int line; //OFS: 0x420 SIZE: 0x4 + int linescrossed; //OFS: 0x424 SIZE: 0x4 + token_s * next; //OFS: 0x428 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(token_s, 0x430); + ASSERT_STRUCT_OFFSET(token_s, string, 0x0); + ASSERT_STRUCT_OFFSET(token_s, type, 0x400); + ASSERT_STRUCT_OFFSET(token_s, subtype, 0x404); + ASSERT_STRUCT_OFFSET(token_s, intvalue, 0x408); + ASSERT_STRUCT_OFFSET(token_s, floatvalue, 0x410); + ASSERT_STRUCT_OFFSET(token_s, whitespace_p, 0x418); + ASSERT_STRUCT_OFFSET(token_s, endwhitespace_p, 0x41C); + ASSERT_STRUCT_OFFSET(token_s, line, 0x420); + ASSERT_STRUCT_OFFSET(token_s, linescrossed, 0x424); + ASSERT_STRUCT_OFFSET(token_s, next, 0x428); + + struct __declspec(align(8)) script_s + { + char filename[64]; //OFS: 0x0 SIZE: 0x40 + char * buffer; //OFS: 0x40 SIZE: 0x4 + char * script_p; //OFS: 0x44 SIZE: 0x4 + char * end_p; //OFS: 0x48 SIZE: 0x4 + char * lastscript_p; //OFS: 0x4C SIZE: 0x4 + char * whitespace_p; //OFS: 0x50 SIZE: 0x4 + char * endwhitespace_p; //OFS: 0x54 SIZE: 0x4 + int length; //OFS: 0x58 SIZE: 0x4 + int line; //OFS: 0x5C SIZE: 0x4 + int lastline; //OFS: 0x60 SIZE: 0x4 + int tokenavailable; //OFS: 0x64 SIZE: 0x4 + int flags; //OFS: 0x68 SIZE: 0x4 + punctuation_s * punctuations; //OFS: 0x6C SIZE: 0x4 + punctuation_s ** punctuationtable; //OFS: 0x70 SIZE: 0x4 + token_s token; //OFS: 0x78 SIZE: 0x430 + script_s * next; //OFS: 0x4A8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(script_s, 0x4B0); + ASSERT_STRUCT_OFFSET(script_s, filename, 0x0); + ASSERT_STRUCT_OFFSET(script_s, buffer, 0x40); + ASSERT_STRUCT_OFFSET(script_s, script_p, 0x44); + ASSERT_STRUCT_OFFSET(script_s, end_p, 0x48); + ASSERT_STRUCT_OFFSET(script_s, lastscript_p, 0x4C); + ASSERT_STRUCT_OFFSET(script_s, whitespace_p, 0x50); + ASSERT_STRUCT_OFFSET(script_s, endwhitespace_p, 0x54); + ASSERT_STRUCT_OFFSET(script_s, length, 0x58); + ASSERT_STRUCT_OFFSET(script_s, line, 0x5C); + ASSERT_STRUCT_OFFSET(script_s, lastline, 0x60); + ASSERT_STRUCT_OFFSET(script_s, tokenavailable, 0x64); + ASSERT_STRUCT_OFFSET(script_s, flags, 0x68); + ASSERT_STRUCT_OFFSET(script_s, punctuations, 0x6C); + ASSERT_STRUCT_OFFSET(script_s, punctuationtable, 0x70); + ASSERT_STRUCT_OFFSET(script_s, token, 0x78); + ASSERT_STRUCT_OFFSET(script_s, next, 0x4A8); + + struct define_s + { + char * name; //OFS: 0x0 SIZE: 0x4 + int flags; //OFS: 0x4 SIZE: 0x4 + int builtin; //OFS: 0x8 SIZE: 0x4 + int numparms; //OFS: 0xC SIZE: 0x4 + token_s * parms; //OFS: 0x10 SIZE: 0x4 + token_s * tokens; //OFS: 0x14 SIZE: 0x4 + define_s * next; //OFS: 0x18 SIZE: 0x4 + define_s * hashnext; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(define_s, 0x20); + ASSERT_STRUCT_OFFSET(define_s, name, 0x0); + ASSERT_STRUCT_OFFSET(define_s, flags, 0x4); + ASSERT_STRUCT_OFFSET(define_s, builtin, 0x8); + ASSERT_STRUCT_OFFSET(define_s, numparms, 0xC); + ASSERT_STRUCT_OFFSET(define_s, parms, 0x10); + ASSERT_STRUCT_OFFSET(define_s, tokens, 0x14); + ASSERT_STRUCT_OFFSET(define_s, next, 0x18); + ASSERT_STRUCT_OFFSET(define_s, hashnext, 0x1C); + + struct indent_s + { + int type; //OFS: 0x0 SIZE: 0x4 + parseSkip_t skip; //OFS: 0x4 SIZE: 0x4 + script_s * script; //OFS: 0x8 SIZE: 0x4 + indent_s * next; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(indent_s, 0x10); + ASSERT_STRUCT_OFFSET(indent_s, type, 0x0); + ASSERT_STRUCT_OFFSET(indent_s, skip, 0x4); + ASSERT_STRUCT_OFFSET(indent_s, script, 0x8); + ASSERT_STRUCT_OFFSET(indent_s, next, 0xC); + + struct __declspec(align(8)) source_s + { + char filename[64]; //OFS: 0x0 SIZE: 0x40 + char includepath[64]; //OFS: 0x40 SIZE: 0x40 + punctuation_s * punctuations; //OFS: 0x80 SIZE: 0x4 + script_s * scriptstack; //OFS: 0x84 SIZE: 0x4 + token_s * tokens; //OFS: 0x88 SIZE: 0x4 + define_s * defines; //OFS: 0x8C SIZE: 0x4 + define_s ** definehash; //OFS: 0x90 SIZE: 0x4 + indent_s * indentstack; //OFS: 0x94 SIZE: 0x4 + int skip; //OFS: 0x98 SIZE: 0x4 + token_s token; //OFS: 0xA0 SIZE: 0x430 + }; + ASSERT_STRUCT_SIZE(source_s, 0x4D0); + ASSERT_STRUCT_OFFSET(source_s, filename, 0x0); + ASSERT_STRUCT_OFFSET(source_s, includepath, 0x40); + ASSERT_STRUCT_OFFSET(source_s, punctuations, 0x80); + ASSERT_STRUCT_OFFSET(source_s, scriptstack, 0x84); + ASSERT_STRUCT_OFFSET(source_s, tokens, 0x88); + ASSERT_STRUCT_OFFSET(source_s, defines, 0x8C); + ASSERT_STRUCT_OFFSET(source_s, definehash, 0x90); + ASSERT_STRUCT_OFFSET(source_s, indentstack, 0x94); + ASSERT_STRUCT_OFFSET(source_s, skip, 0x98); + ASSERT_STRUCT_OFFSET(source_s, token, 0xA0); + + struct pc_token_s + { + int type; //OFS: 0x0 SIZE: 0x4 + int subtype; //OFS: 0x4 SIZE: 0x4 + int intvalue; //OFS: 0x8 SIZE: 0x4 + float floatvalue; //OFS: 0xC SIZE: 0x4 + char string[1024]; //OFS: 0x10 SIZE: 0x400 + }; + ASSERT_STRUCT_SIZE(pc_token_s, 0x410); + ASSERT_STRUCT_OFFSET(pc_token_s, type, 0x0); + ASSERT_STRUCT_OFFSET(pc_token_s, subtype, 0x4); + ASSERT_STRUCT_OFFSET(pc_token_s, intvalue, 0x8); + ASSERT_STRUCT_OFFSET(pc_token_s, floatvalue, 0xC); + ASSERT_STRUCT_OFFSET(pc_token_s, string, 0x10); + + // uiInfo_s + + struct AimTweakables + { + float slowdownRegionWidth; //OFS: 0x0 SIZE: 0x4 + float slowdownRegionHeight; //OFS: 0x4 SIZE: 0x4 + float autoAimRegionWidth; //OFS: 0x8 SIZE: 0x4 + float autoAimRegionHeight; //OFS: 0xC SIZE: 0x4 + float autoMeleeRegionWidth; //OFS: 0x10 SIZE: 0x4 + float autoMeleeRegionHeight; //OFS: 0x14 SIZE: 0x4 + float lockOnRegionWidth; //OFS: 0x18 SIZE: 0x4 + float lockOnRegionHeight; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimTweakables, 0x20); + ASSERT_STRUCT_OFFSET(AimTweakables, slowdownRegionWidth, 0x0); + ASSERT_STRUCT_OFFSET(AimTweakables, slowdownRegionHeight, 0x4); + ASSERT_STRUCT_OFFSET(AimTweakables, autoAimRegionWidth, 0x8); + ASSERT_STRUCT_OFFSET(AimTweakables, autoAimRegionHeight, 0xC); + ASSERT_STRUCT_OFFSET(AimTweakables, autoMeleeRegionWidth, 0x10); + ASSERT_STRUCT_OFFSET(AimTweakables, autoMeleeRegionHeight, 0x14); + ASSERT_STRUCT_OFFSET(AimTweakables, lockOnRegionWidth, 0x18); + ASSERT_STRUCT_OFFSET(AimTweakables, lockOnRegionHeight, 0x1C); + + struct AimScreenTarget + { + int entIndex; //OFS: 0x0 SIZE: 0x4 + float clipMins[2]; //OFS: 0x4 SIZE: 0x8 + float clipMaxs[2]; //OFS: 0xC SIZE: 0x8 + float aimPos[3]; //OFS: 0x14 SIZE: 0xC + float velocity[3]; //OFS: 0x20 SIZE: 0xC + float distSqr; //OFS: 0x2C SIZE: 0x4 + float crosshairDistSqr; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimScreenTarget, 0x34); + ASSERT_STRUCT_OFFSET(AimScreenTarget, entIndex, 0x0); + ASSERT_STRUCT_OFFSET(AimScreenTarget, clipMins, 0x4); + ASSERT_STRUCT_OFFSET(AimScreenTarget, clipMaxs, 0xC); + ASSERT_STRUCT_OFFSET(AimScreenTarget, aimPos, 0x14); + ASSERT_STRUCT_OFFSET(AimScreenTarget, velocity, 0x20); + ASSERT_STRUCT_OFFSET(AimScreenTarget, distSqr, 0x2C); + ASSERT_STRUCT_OFFSET(AimScreenTarget, crosshairDistSqr, 0x30); + + struct AimAssistGlobals + { + bool initialized; //OFS: 0x0 SIZE: 0x1 + AimTweakables tweakables; //OFS: 0x4 SIZE: 0x20 + float viewOrigin[3]; //OFS: 0x24 SIZE: 0xC + float viewAngles[3]; //OFS: 0x30 SIZE: 0xC + float viewAxis[3][3]; //OFS: 0x3C SIZE: 0x24 + float fovTurnRateScale; //OFS: 0x60 SIZE: 0x4 + float fovScaleInv; //OFS: 0x64 SIZE: 0x4 + float adsLerp; //OFS: 0x68 SIZE: 0x4 + float pitchDelta; //OFS: 0x6C SIZE: 0x4 + float yawDelta; //OFS: 0x70 SIZE: 0x4 + float screenWidth; //OFS: 0x74 SIZE: 0x4 + float screenHeight; //OFS: 0x78 SIZE: 0x4 + float screenMtx[4][4]; //OFS: 0x7C SIZE: 0x40 + float invScreenMtx[4][4]; //OFS: 0xBC SIZE: 0x40 + AimScreenTarget screenTargets[64]; //OFS: 0xFC SIZE: 0xD00 + int screenTargetCount; //OFS: 0xDFC SIZE: 0x4 + int autoAimTargetEnt; //OFS: 0xE00 SIZE: 0x4 + bool autoAimPressed; //OFS: 0xE04 SIZE: 0x1 + bool autoAimActive; //OFS: 0xE05 SIZE: 0x1 + float autoAimPitch; //OFS: 0xE08 SIZE: 0x4 + float autoAimPitchTarget; //OFS: 0xE0C SIZE: 0x4 + float autoAimYaw; //OFS: 0xE10 SIZE: 0x4 + float autoAimYawTarget; //OFS: 0xE14 SIZE: 0x4 + bool autoAimJustGotTarget; //OFS: 0xE18 SIZE: 0x1 + bool autoAimHasRealTarget; //OFS: 0xE19 SIZE: 0x1 + bool aimSlowdownActive; //OFS: 0xE1A SIZE: 0x1 + int aimSlowdownTargetEnt; //OFS: 0xE1C SIZE: 0x4 + int autoMeleeTargetEnt; //OFS: 0xE20 SIZE: 0x4 + eAutoMeleeState autoMeleeState; //OFS: 0xE24 SIZE: 0x4 + float autoMeleePitch; //OFS: 0xE28 SIZE: 0x4 + float autoMeleePitchTarget; //OFS: 0xE2C SIZE: 0x4 + float autoMeleeYaw; //OFS: 0xE30 SIZE: 0x4 + float autoMeleeYawTarget; //OFS: 0xE34 SIZE: 0x4 + int lockOnTargetEnt; //OFS: 0xE38 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimAssistGlobals, 0xE3C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, initialized, 0x0); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, tweakables, 0x4); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, viewOrigin, 0x24); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, viewAngles, 0x30); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, viewAxis, 0x3C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, fovTurnRateScale, 0x60); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, fovScaleInv, 0x64); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, adsLerp, 0x68); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, pitchDelta, 0x6C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, yawDelta, 0x70); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, screenWidth, 0x74); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, screenHeight, 0x78); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, screenMtx, 0x7C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, invScreenMtx, 0xBC); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, screenTargets, 0xFC); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, screenTargetCount, 0xDFC); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimTargetEnt, 0xE00); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimPressed, 0xE04); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimActive, 0xE05); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimPitch, 0xE08); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimPitchTarget, 0xE0C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimYaw, 0xE10); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimYawTarget, 0xE14); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimJustGotTarget, 0xE18); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoAimHasRealTarget, 0xE19); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, aimSlowdownActive, 0xE1A); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, aimSlowdownTargetEnt, 0xE1C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleeTargetEnt, 0xE20); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleeState, 0xE24); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleePitch, 0xE28); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleePitchTarget, 0xE2C); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleeYaw, 0xE30); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, autoMeleeYawTarget, 0xE34); + ASSERT_STRUCT_OFFSET(AimAssistGlobals, lockOnTargetEnt, 0xE38); + + struct AimInput + { + int deltaTime; //OFS: 0x0 SIZE: 0x4 + float pitch; //OFS: 0x4 SIZE: 0x4 + float pitchAxis; //OFS: 0x8 SIZE: 0x4 + float pitchMax; //OFS: 0xC SIZE: 0x4 + float yaw; //OFS: 0x10 SIZE: 0x4 + float yawAxis; //OFS: 0x14 SIZE: 0x4 + float yawMax; //OFS: 0x18 SIZE: 0x4 + int forwardAxis; //OFS: 0x1C SIZE: 0x4 + int rightAxis; //OFS: 0x20 SIZE: 0x4 + int buttons; //OFS: 0x24 SIZE: 0x4 + int localClientNum; //OFS: 0x28 SIZE: 0x4 + playerState_s * ps; //OFS: 0x2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimInput, 0x30); + ASSERT_STRUCT_OFFSET(AimInput, deltaTime, 0x0); + ASSERT_STRUCT_OFFSET(AimInput, pitch, 0x4); + ASSERT_STRUCT_OFFSET(AimInput, pitchAxis, 0x8); + ASSERT_STRUCT_OFFSET(AimInput, pitchMax, 0xC); + ASSERT_STRUCT_OFFSET(AimInput, yaw, 0x10); + ASSERT_STRUCT_OFFSET(AimInput, yawAxis, 0x14); + ASSERT_STRUCT_OFFSET(AimInput, yawMax, 0x18); + ASSERT_STRUCT_OFFSET(AimInput, forwardAxis, 0x1C); + ASSERT_STRUCT_OFFSET(AimInput, rightAxis, 0x20); + ASSERT_STRUCT_OFFSET(AimInput, buttons, 0x24); + ASSERT_STRUCT_OFFSET(AimInput, localClientNum, 0x28); + ASSERT_STRUCT_OFFSET(AimInput, ps, 0x2C); + + struct AimOutput + { + float pitch; //OFS: 0x0 SIZE: 0x4 + float yaw; //OFS: 0x4 SIZE: 0x4 + int meleeChargeYaw; //OFS: 0x8 SIZE: 0x4 + int meleeChargeDist; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimOutput, 0x10); + ASSERT_STRUCT_OFFSET(AimOutput, pitch, 0x0); + ASSERT_STRUCT_OFFSET(AimOutput, yaw, 0x4); + ASSERT_STRUCT_OFFSET(AimOutput, meleeChargeYaw, 0x8); + ASSERT_STRUCT_OFFSET(AimOutput, meleeChargeDist, 0xC); + + struct struc_16A3BA0 + { + int field_0; //OFS: 0x0 SIZE: 0x4 + int field_4[512]; //OFS: 0x4 SIZE: 0x800 + char field_804[512]; //OFS: 0x804 SIZE: 0x200 + void * field_A04; //OFS: 0xA04 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(struc_16A3BA0, 0xA08); + ASSERT_STRUCT_OFFSET(struc_16A3BA0, field_0, 0x0); + ASSERT_STRUCT_OFFSET(struc_16A3BA0, field_4, 0x4); + ASSERT_STRUCT_OFFSET(struc_16A3BA0, field_804, 0x804); + ASSERT_STRUCT_OFFSET(struc_16A3BA0, field_A04, 0xA04); + + struct SpawnFuncEntry + { + const char * classname; //OFS: 0x0 SIZE: 0x4 + void (__cdecl *callback)(gentity_s *); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SpawnFuncEntry, 0x8); + ASSERT_STRUCT_OFFSET(SpawnFuncEntry, classname, 0x0); + ASSERT_STRUCT_OFFSET(SpawnFuncEntry, callback, 0x4); + + struct ScriptFunctions + { + int maxSize; //OFS: 0x0 SIZE: 0x4 + int count; //OFS: 0x4 SIZE: 0x4 + int * address; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ScriptFunctions, 0xC); + ASSERT_STRUCT_OFFSET(ScriptFunctions, maxSize, 0x0); + ASSERT_STRUCT_OFFSET(ScriptFunctions, count, 0x4); + ASSERT_STRUCT_OFFSET(ScriptFunctions, address, 0x8); + + struct StreamDelayInfo + { + const void * ptr; //OFS: 0x0 SIZE: 0x4 + int size; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StreamDelayInfo, 0x8); + ASSERT_STRUCT_OFFSET(StreamDelayInfo, ptr, 0x0); + ASSERT_STRUCT_OFFSET(StreamDelayInfo, size, 0x4); + + union ct_data_s_fc + { + unsigned __int16 freq; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 code; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ct_data_s_fc, 0x2); + + union ct_data_s_dl + { + unsigned __int16 dad; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 len; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ct_data_s_dl, 0x2); + + struct __declspec(align(2)) ct_data_s + { + ct_data_s_fc fc; //OFS: 0x0 SIZE: 0x2 + ct_data_s_dl _dl; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(ct_data_s, 0x4); + ASSERT_STRUCT_OFFSET(ct_data_s, fc, 0x0); + ASSERT_STRUCT_OFFSET(ct_data_s, _dl, 0x2); + + struct static_tree_desc_s + { + const ct_data_s * static_tree; //OFS: 0x0 SIZE: 0x4 + const int * extra_bits; //OFS: 0x4 SIZE: 0x4 + int extra_base; //OFS: 0x8 SIZE: 0x4 + int elems; //OFS: 0xC SIZE: 0x4 + int max_length; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(static_tree_desc_s, 0x14); + ASSERT_STRUCT_OFFSET(static_tree_desc_s, static_tree, 0x0); + ASSERT_STRUCT_OFFSET(static_tree_desc_s, extra_bits, 0x4); + ASSERT_STRUCT_OFFSET(static_tree_desc_s, extra_base, 0x8); + ASSERT_STRUCT_OFFSET(static_tree_desc_s, elems, 0xC); + ASSERT_STRUCT_OFFSET(static_tree_desc_s, max_length, 0x10); + + struct tree_desc_s + { + ct_data_s * dyn_tree; //OFS: 0x0 SIZE: 0x4 + int max_code; //OFS: 0x4 SIZE: 0x4 + static_tree_desc_s * stat_desc; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(tree_desc_s, 0xC); + ASSERT_STRUCT_OFFSET(tree_desc_s, dyn_tree, 0x0); + ASSERT_STRUCT_OFFSET(tree_desc_s, max_code, 0x4); + ASSERT_STRUCT_OFFSET(tree_desc_s, stat_desc, 0x8); + + struct deflate_state + { + z_stream_s * strm; //OFS: 0x0 SIZE: 0x4 + int status; //OFS: 0x4 SIZE: 0x4 + unsigned __int8 * pending_buf; //OFS: 0x8 SIZE: 0x4 + unsigned int pending_buf_size; //OFS: 0xC SIZE: 0x4 + unsigned __int8 * pending_out; //OFS: 0x10 SIZE: 0x4 + int pending; //OFS: 0x14 SIZE: 0x4 + int noheader; //OFS: 0x18 SIZE: 0x4 + unsigned __int8 data_type; //OFS: 0x1C SIZE: 0x1 + unsigned __int8 method; //OFS: 0x1D SIZE: 0x1 + int last_flush; //OFS: 0x20 SIZE: 0x4 + unsigned int w_size; //OFS: 0x24 SIZE: 0x4 + unsigned int w_bits; //OFS: 0x28 SIZE: 0x4 + unsigned int w_mask; //OFS: 0x2C SIZE: 0x4 + unsigned __int8 * window; //OFS: 0x30 SIZE: 0x4 + unsigned int window_size; //OFS: 0x34 SIZE: 0x4 + unsigned __int16 * prev; //OFS: 0x38 SIZE: 0x4 + unsigned __int16 * head; //OFS: 0x3C SIZE: 0x4 + unsigned int ins_h; //OFS: 0x40 SIZE: 0x4 + unsigned int hash_size; //OFS: 0x44 SIZE: 0x4 + unsigned int hash_bits; //OFS: 0x48 SIZE: 0x4 + unsigned int hash_mask; //OFS: 0x4C SIZE: 0x4 + unsigned int hash_shift; //OFS: 0x50 SIZE: 0x4 + int block_start; //OFS: 0x54 SIZE: 0x4 + unsigned int match_length; //OFS: 0x58 SIZE: 0x4 + unsigned int prev_match; //OFS: 0x5C SIZE: 0x4 + int match_available; //OFS: 0x60 SIZE: 0x4 + unsigned int strstart; //OFS: 0x64 SIZE: 0x4 + unsigned int match_start; //OFS: 0x68 SIZE: 0x4 + unsigned int lookahead; //OFS: 0x6C SIZE: 0x4 + unsigned int prev_length; //OFS: 0x70 SIZE: 0x4 + unsigned int max_chain_length; //OFS: 0x74 SIZE: 0x4 + unsigned int max_lazy_match; //OFS: 0x78 SIZE: 0x4 + int level; //OFS: 0x7C SIZE: 0x4 + int strategy; //OFS: 0x80 SIZE: 0x4 + unsigned int good_match; //OFS: 0x84 SIZE: 0x4 + int nice_match; //OFS: 0x88 SIZE: 0x4 + ct_data_s dyn_ltree[573]; //OFS: 0x8C SIZE: 0x8F4 + ct_data_s dyn_dtree[61]; //OFS: 0x980 SIZE: 0xF4 + ct_data_s bl_tree[39]; //OFS: 0xA74 SIZE: 0x9C + tree_desc_s l_desc; //OFS: 0xB10 SIZE: 0xC + tree_desc_s d_desc; //OFS: 0xB1C SIZE: 0xC + tree_desc_s bl_desc; //OFS: 0xB28 SIZE: 0xC + unsigned __int16 bl_count[16]; //OFS: 0xB34 SIZE: 0x20 + int heap[573]; //OFS: 0xB54 SIZE: 0x8F4 + int heap_len; //OFS: 0x1448 SIZE: 0x4 + int heap_max; //OFS: 0x144C SIZE: 0x4 + unsigned __int8 depth[573]; //OFS: 0x1450 SIZE: 0x23D + unsigned __int8 * l_buf; //OFS: 0x1690 SIZE: 0x4 + unsigned int lit_bufsize; //OFS: 0x1694 SIZE: 0x4 + unsigned int last_lit; //OFS: 0x1698 SIZE: 0x4 + unsigned __int16 * d_buf; //OFS: 0x169C SIZE: 0x4 + unsigned int opt_len; //OFS: 0x16A0 SIZE: 0x4 + unsigned int static_len; //OFS: 0x16A4 SIZE: 0x4 + unsigned int matches; //OFS: 0x16A8 SIZE: 0x4 + int last_eob_len; //OFS: 0x16AC SIZE: 0x4 + unsigned __int16 bi_buf; //OFS: 0x16B0 SIZE: 0x2 + int bi_valid; //OFS: 0x16B4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(deflate_state, 0x16B8); + ASSERT_STRUCT_OFFSET(deflate_state, strm, 0x0); + ASSERT_STRUCT_OFFSET(deflate_state, status, 0x4); + ASSERT_STRUCT_OFFSET(deflate_state, pending_buf, 0x8); + ASSERT_STRUCT_OFFSET(deflate_state, pending_buf_size, 0xC); + ASSERT_STRUCT_OFFSET(deflate_state, pending_out, 0x10); + ASSERT_STRUCT_OFFSET(deflate_state, pending, 0x14); + ASSERT_STRUCT_OFFSET(deflate_state, noheader, 0x18); + ASSERT_STRUCT_OFFSET(deflate_state, data_type, 0x1C); + ASSERT_STRUCT_OFFSET(deflate_state, method, 0x1D); + ASSERT_STRUCT_OFFSET(deflate_state, last_flush, 0x20); + ASSERT_STRUCT_OFFSET(deflate_state, w_size, 0x24); + ASSERT_STRUCT_OFFSET(deflate_state, w_bits, 0x28); + ASSERT_STRUCT_OFFSET(deflate_state, w_mask, 0x2C); + ASSERT_STRUCT_OFFSET(deflate_state, window, 0x30); + ASSERT_STRUCT_OFFSET(deflate_state, window_size, 0x34); + ASSERT_STRUCT_OFFSET(deflate_state, prev, 0x38); + ASSERT_STRUCT_OFFSET(deflate_state, head, 0x3C); + ASSERT_STRUCT_OFFSET(deflate_state, ins_h, 0x40); + ASSERT_STRUCT_OFFSET(deflate_state, hash_size, 0x44); + ASSERT_STRUCT_OFFSET(deflate_state, hash_bits, 0x48); + ASSERT_STRUCT_OFFSET(deflate_state, hash_mask, 0x4C); + ASSERT_STRUCT_OFFSET(deflate_state, hash_shift, 0x50); + ASSERT_STRUCT_OFFSET(deflate_state, block_start, 0x54); + ASSERT_STRUCT_OFFSET(deflate_state, match_length, 0x58); + ASSERT_STRUCT_OFFSET(deflate_state, prev_match, 0x5C); + ASSERT_STRUCT_OFFSET(deflate_state, match_available, 0x60); + ASSERT_STRUCT_OFFSET(deflate_state, strstart, 0x64); + ASSERT_STRUCT_OFFSET(deflate_state, match_start, 0x68); + ASSERT_STRUCT_OFFSET(deflate_state, lookahead, 0x6C); + ASSERT_STRUCT_OFFSET(deflate_state, prev_length, 0x70); + ASSERT_STRUCT_OFFSET(deflate_state, max_chain_length, 0x74); + ASSERT_STRUCT_OFFSET(deflate_state, max_lazy_match, 0x78); + ASSERT_STRUCT_OFFSET(deflate_state, level, 0x7C); + ASSERT_STRUCT_OFFSET(deflate_state, strategy, 0x80); + ASSERT_STRUCT_OFFSET(deflate_state, good_match, 0x84); + ASSERT_STRUCT_OFFSET(deflate_state, nice_match, 0x88); + ASSERT_STRUCT_OFFSET(deflate_state, dyn_ltree, 0x8C); + ASSERT_STRUCT_OFFSET(deflate_state, dyn_dtree, 0x980); + ASSERT_STRUCT_OFFSET(deflate_state, bl_tree, 0xA74); + ASSERT_STRUCT_OFFSET(deflate_state, l_desc, 0xB10); + ASSERT_STRUCT_OFFSET(deflate_state, d_desc, 0xB1C); + ASSERT_STRUCT_OFFSET(deflate_state, bl_desc, 0xB28); + ASSERT_STRUCT_OFFSET(deflate_state, bl_count, 0xB34); + ASSERT_STRUCT_OFFSET(deflate_state, heap, 0xB54); + ASSERT_STRUCT_OFFSET(deflate_state, heap_len, 0x1448); + ASSERT_STRUCT_OFFSET(deflate_state, heap_max, 0x144C); + ASSERT_STRUCT_OFFSET(deflate_state, depth, 0x1450); + ASSERT_STRUCT_OFFSET(deflate_state, l_buf, 0x1690); + ASSERT_STRUCT_OFFSET(deflate_state, lit_bufsize, 0x1694); + ASSERT_STRUCT_OFFSET(deflate_state, last_lit, 0x1698); + ASSERT_STRUCT_OFFSET(deflate_state, d_buf, 0x169C); + ASSERT_STRUCT_OFFSET(deflate_state, opt_len, 0x16A0); + ASSERT_STRUCT_OFFSET(deflate_state, static_len, 0x16A4); + ASSERT_STRUCT_OFFSET(deflate_state, matches, 0x16A8); + ASSERT_STRUCT_OFFSET(deflate_state, last_eob_len, 0x16AC); + ASSERT_STRUCT_OFFSET(deflate_state, bi_buf, 0x16B0); + ASSERT_STRUCT_OFFSET(deflate_state, bi_valid, 0x16B4); + + struct internal_state_sub_check + { + unsigned int was; //OFS: 0x0 SIZE: 0x4 + unsigned int need; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(internal_state_sub_check, 0x8); + ASSERT_STRUCT_OFFSET(internal_state_sub_check, was, 0x0); + ASSERT_STRUCT_OFFSET(internal_state_sub_check, need, 0x4); + + union internal_state_sub + { + unsigned int method; //OFS: 0x0 SIZE: 0x4 + internal_state_sub_check check; //OFS: 0x1 SIZE: 0x8 + unsigned int marker; //OFS: 0x2 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(internal_state_sub, 0x8); + + struct __declspec(align(1)) inflate_huft_s_word_what + { + unsigned __int8 Exop; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 Bits; //OFS: 0x1 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(inflate_huft_s_word_what, 0x2); + ASSERT_STRUCT_OFFSET(inflate_huft_s_word_what, Exop, 0x0); + ASSERT_STRUCT_OFFSET(inflate_huft_s_word_what, Bits, 0x1); + + union inflate_huft_s_word + { + inflate_huft_s_word_what what; //OFS: 0x0 SIZE: 0x2 + unsigned int pad; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_huft_s_word, 0x4); + + struct inflate_huft_s + { + inflate_huft_s_word word; //OFS: 0x0 SIZE: 0x4 + unsigned int base; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_huft_s, 0x8); + ASSERT_STRUCT_OFFSET(inflate_huft_s, word, 0x0); + ASSERT_STRUCT_OFFSET(inflate_huft_s, base, 0x4); + + struct inflate_blocks_state_sub_trees + { + unsigned int table; //OFS: 0x0 SIZE: 0x4 + unsigned int index; //OFS: 0x4 SIZE: 0x4 + unsigned int * blens; //OFS: 0x8 SIZE: 0x4 + unsigned int bb; //OFS: 0xC SIZE: 0x4 + inflate_huft_s * tb; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_blocks_state_sub_trees, 0x14); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_trees, table, 0x0); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_trees, index, 0x4); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_trees, blens, 0x8); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_trees, bb, 0xC); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_trees, tb, 0x10); + + struct inflate_codes_state_sub_code + { + inflate_huft_s * tree; //OFS: 0x0 SIZE: 0x4 + unsigned int need; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_codes_state_sub_code, 0x8); + ASSERT_STRUCT_OFFSET(inflate_codes_state_sub_code, tree, 0x0); + ASSERT_STRUCT_OFFSET(inflate_codes_state_sub_code, need, 0x4); + + struct inflate_codes_state_sub_copy + { + unsigned int get; //OFS: 0x0 SIZE: 0x4 + unsigned int dist; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_codes_state_sub_copy, 0x8); + ASSERT_STRUCT_OFFSET(inflate_codes_state_sub_copy, get, 0x0); + ASSERT_STRUCT_OFFSET(inflate_codes_state_sub_copy, dist, 0x4); + + union inflate_codes_state_sub + { + struct inflate_codes_state_sub_code code; //OFS: 0x0 SIZE: 0x8 + struct inflate_codes_state_sub_copy copy; //OFS: 0x1 SIZE: 0x8 + unsigned int lit; //OFS: 0x2 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_codes_state_sub, 0x8); + + struct inflate_codes_state + { + int mode; //OFS: 0x0 SIZE: 0x4 + int len; //OFS: 0x4 SIZE: 0x4 + inflate_codes_state_sub sub; //OFS: 0x8 SIZE: 0x8 + char lbits; //OFS: 0x10 SIZE: 0x1 + char dbits; //OFS: 0x11 SIZE: 0x1 + inflate_huft_s * ltree; //OFS: 0x14 SIZE: 0x4 + inflate_huft_s * dtree; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_codes_state, 0x1C); + ASSERT_STRUCT_OFFSET(inflate_codes_state, mode, 0x0); + ASSERT_STRUCT_OFFSET(inflate_codes_state, len, 0x4); + ASSERT_STRUCT_OFFSET(inflate_codes_state, sub, 0x8); + ASSERT_STRUCT_OFFSET(inflate_codes_state, lbits, 0x10); + ASSERT_STRUCT_OFFSET(inflate_codes_state, dbits, 0x11); + ASSERT_STRUCT_OFFSET(inflate_codes_state, ltree, 0x14); + ASSERT_STRUCT_OFFSET(inflate_codes_state, dtree, 0x18); + + struct inflate_blocks_state_sub_decode + { + inflate_codes_state * codes; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_blocks_state_sub_decode, 0x4); + ASSERT_STRUCT_OFFSET(inflate_blocks_state_sub_decode, codes, 0x0); + + union inflate_blocks_state_sub + { + unsigned int left; //OFS: 0x0 SIZE: 0x4 + inflate_blocks_state_sub_trees trees; //OFS: 0x1 SIZE: 0x14 + inflate_blocks_state_sub_decode decode; //OFS: 0x2 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_blocks_state_sub, 0x14); + + struct inflate_blocks_state + { + inflate_block_mode mode; //OFS: 0x0 SIZE: 0x4 + inflate_blocks_state_sub sub; //OFS: 0x4 SIZE: 0x14 + unsigned int last; //OFS: 0x18 SIZE: 0x4 + unsigned int bitk; //OFS: 0x1C SIZE: 0x4 + unsigned int bitb; //OFS: 0x20 SIZE: 0x4 + inflate_huft_s * hufts; //OFS: 0x24 SIZE: 0x4 + unsigned __int8 * window; //OFS: 0x28 SIZE: 0x4 + unsigned __int8 * end; //OFS: 0x2C SIZE: 0x4 + unsigned __int8 * read; //OFS: 0x30 SIZE: 0x4 + unsigned __int8 * write; //OFS: 0x34 SIZE: 0x4 + unsigned int (__cdecl *checkfn)(unsigned int, const unsigned __int8 *, unsigned int); //OFS: 0x38 SIZE: 0x4 + int check; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(inflate_blocks_state, 0x40); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, mode, 0x0); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, sub, 0x4); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, last, 0x18); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, bitk, 0x1C); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, bitb, 0x20); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, hufts, 0x24); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, window, 0x28); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, end, 0x2C); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, read, 0x30); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, write, 0x34); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, checkfn, 0x38); + ASSERT_STRUCT_OFFSET(inflate_blocks_state, check, 0x3C); + + typedef inflate_block_mode inflate_mode; + + struct internal_state + { + inflate_mode mode; //OFS: 0x0 SIZE: 0x4 + internal_state_sub sub; //OFS: 0x4 SIZE: 0x8 + int nowrap; //OFS: 0xC SIZE: 0x4 + unsigned int wbits; //OFS: 0x10 SIZE: 0x4 + inflate_blocks_state * blocks; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(internal_state, 0x18); + ASSERT_STRUCT_OFFSET(internal_state, mode, 0x0); + ASSERT_STRUCT_OFFSET(internal_state, sub, 0x4); + ASSERT_STRUCT_OFFSET(internal_state, nowrap, 0xC); + ASSERT_STRUCT_OFFSET(internal_state, wbits, 0x10); + ASSERT_STRUCT_OFFSET(internal_state, blocks, 0x14); + + union deflate_or_inflate_state + { + deflate_state * deflate_state; //OFS: 0x0 SIZE: 0x4 + internal_state * inflate_state; //OFS: 0x1 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(deflate_or_inflate_state, 0x4); + + struct z_stream_s + { + unsigned __int8 * next_in; //OFS: 0x0 SIZE: 0x4 + unsigned int avail_in; //OFS: 0x4 SIZE: 0x4 + unsigned int total_in; //OFS: 0x8 SIZE: 0x4 + unsigned __int8 * next_out; //OFS: 0xC SIZE: 0x4 + unsigned int avail_out; //OFS: 0x10 SIZE: 0x4 + unsigned int total_out; //OFS: 0x14 SIZE: 0x4 + char * msg; //OFS: 0x18 SIZE: 0x4 + deflate_or_inflate_state state; //OFS: 0x1C SIZE: 0x4 + unsigned __int8 *(__cdecl *zalloc)(unsigned __int8 *opaque, unsigned int items, unsigned int size); //OFS: 0x20 SIZE: 0x4 + void (__cdecl *zfree)(unsigned __int8 *opaque, unsigned __int8 *address); //OFS: 0x24 SIZE: 0x4 + unsigned __int8 * opaque; //OFS: 0x28 SIZE: 0x4 + int data_type; //OFS: 0x2C SIZE: 0x4 + int adler; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(z_stream_s, 0x34); + ASSERT_STRUCT_OFFSET(z_stream_s, next_in, 0x0); + ASSERT_STRUCT_OFFSET(z_stream_s, avail_in, 0x4); + ASSERT_STRUCT_OFFSET(z_stream_s, total_in, 0x8); + ASSERT_STRUCT_OFFSET(z_stream_s, next_out, 0xC); + ASSERT_STRUCT_OFFSET(z_stream_s, avail_out, 0x10); + ASSERT_STRUCT_OFFSET(z_stream_s, total_out, 0x14); + ASSERT_STRUCT_OFFSET(z_stream_s, msg, 0x18); + ASSERT_STRUCT_OFFSET(z_stream_s, state, 0x1C); + ASSERT_STRUCT_OFFSET(z_stream_s, zalloc, 0x20); + ASSERT_STRUCT_OFFSET(z_stream_s, zfree, 0x24); + ASSERT_STRUCT_OFFSET(z_stream_s, opaque, 0x28); + ASSERT_STRUCT_OFFSET(z_stream_s, data_type, 0x2C); + ASSERT_STRUCT_OFFSET(z_stream_s, adler, 0x30); + + struct DB_LoadData + { + void * f; //OFS: 0x0 SIZE: 0x4 + char * filename; //OFS: 0x4 SIZE: 0x4 + XBlock * blocks; //OFS: 0x8 SIZE: 0x4 + int outstandingReads; //OFS: 0xC SIZE: 0x4 + _OVERLAPPED overlapped; //OFS: 0x10 SIZE: 0x14 + z_stream_s stream; //OFS: 0x24 SIZE: 0x34 + char * compressBufferStart; //OFS: 0x58 SIZE: 0x4 + void * compressBufferEnd; //OFS: 0x5C SIZE: 0x4 + void (__cdecl *interrupt)(); //OFS: 0x60 SIZE: 0x4 + int allocType; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DB_LoadData, 0x68); + ASSERT_STRUCT_OFFSET(DB_LoadData, f, 0x0); + ASSERT_STRUCT_OFFSET(DB_LoadData, filename, 0x4); + ASSERT_STRUCT_OFFSET(DB_LoadData, blocks, 0x8); + ASSERT_STRUCT_OFFSET(DB_LoadData, outstandingReads, 0xC); + ASSERT_STRUCT_OFFSET(DB_LoadData, overlapped, 0x10); + ASSERT_STRUCT_OFFSET(DB_LoadData, stream, 0x24); + ASSERT_STRUCT_OFFSET(DB_LoadData, compressBufferStart, 0x58); + ASSERT_STRUCT_OFFSET(DB_LoadData, compressBufferEnd, 0x5C); + ASSERT_STRUCT_OFFSET(DB_LoadData, interrupt, 0x60); + ASSERT_STRUCT_OFFSET(DB_LoadData, allocType, 0x64); + + struct areaParms_t + { + const float * mins; //OFS: 0x0 SIZE: 0x4 + const float * maxs; //OFS: 0x4 SIZE: 0x4 + int * list; //OFS: 0x8 SIZE: 0x4 + int count; //OFS: 0xC SIZE: 0x4 + int maxcount; //OFS: 0x10 SIZE: 0x4 + int contentmask; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(areaParms_t, 0x18); + ASSERT_STRUCT_OFFSET(areaParms_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(areaParms_t, maxs, 0x4); + ASSERT_STRUCT_OFFSET(areaParms_t, list, 0x8); + ASSERT_STRUCT_OFFSET(areaParms_t, count, 0xC); + ASSERT_STRUCT_OFFSET(areaParms_t, maxcount, 0x10); + ASSERT_STRUCT_OFFSET(areaParms_t, contentmask, 0x14); + + struct useList_t + { + gentity_s * ent; //OFS: 0x0 SIZE: 0x4 + float score; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(useList_t, 0x8); + ASSERT_STRUCT_OFFSET(useList_t, ent, 0x0); + ASSERT_STRUCT_OFFSET(useList_t, score, 0x4); + + struct NodeTypeToName + { + nodeType type; //OFS: 0x0 SIZE: 0x4 + const char * name; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(NodeTypeToName, 0x8); + ASSERT_STRUCT_OFFSET(NodeTypeToName, type, 0x0); + ASSERT_STRUCT_OFFSET(NodeTypeToName, name, 0x4); + + struct pathnode_field_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathnode_field_t, 0xC); + ASSERT_STRUCT_OFFSET(pathnode_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(pathnode_field_t, type, 0x8); + + struct badplace_arc_t + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float radius; //OFS: 0xC SIZE: 0x4 + float halfheight; //OFS: 0x10 SIZE: 0x4 + float angle0; //OFS: 0x14 SIZE: 0x4 + float angle1; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(badplace_arc_t, 0x1C); + ASSERT_STRUCT_OFFSET(badplace_arc_t, origin, 0x0); + ASSERT_STRUCT_OFFSET(badplace_arc_t, radius, 0xC); + ASSERT_STRUCT_OFFSET(badplace_arc_t, halfheight, 0x10); + ASSERT_STRUCT_OFFSET(badplace_arc_t, angle0, 0x14); + ASSERT_STRUCT_OFFSET(badplace_arc_t, angle1, 0x18); + + struct badplace_brush_t + { + gentity_s * volume; //OFS: 0x0 SIZE: 0x4 + float radius; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(badplace_brush_t, 0x8); + ASSERT_STRUCT_OFFSET(badplace_brush_t, volume, 0x0); + ASSERT_STRUCT_OFFSET(badplace_brush_t, radius, 0x4); + + union badplace_parms_t + { + badplace_arc_t arc; //OFS: 0x0 SIZE: 0x1C + badplace_brush_t brush; //OFS: 0x1 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(badplace_parms_t, 0x1C); + + struct badplace_t + { + int endtime; //OFS: 0x0 SIZE: 0x4 + int pingTime; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 name; //OFS: 0x8 SIZE: 0x2 + unsigned __int8 type; //OFS: 0xA SIZE: 0x1 + unsigned __int8 teamflags; //OFS: 0xB SIZE: 0x1 + int depth; //OFS: 0xC SIZE: 0x4 + badplace_parms_t parms; //OFS: 0x10 SIZE: 0x1C + }; + ASSERT_STRUCT_SIZE(badplace_t, 0x2C); + ASSERT_STRUCT_OFFSET(badplace_t, endtime, 0x0); + ASSERT_STRUCT_OFFSET(badplace_t, pingTime, 0x4); + ASSERT_STRUCT_OFFSET(badplace_t, name, 0x8); + ASSERT_STRUCT_OFFSET(badplace_t, type, 0xA); + ASSERT_STRUCT_OFFSET(badplace_t, teamflags, 0xB); + ASSERT_STRUCT_OFFSET(badplace_t, depth, 0xC); + ASSERT_STRUCT_OFFSET(badplace_t, parms, 0x10); + + struct __declspec(align(2)) PathLinkInfo + { + unsigned __int16 from; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 to; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 prev; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 next; //OFS: 0x6 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(PathLinkInfo, 0x8); + ASSERT_STRUCT_OFFSET(PathLinkInfo, from, 0x0); + ASSERT_STRUCT_OFFSET(PathLinkInfo, to, 0x2); + ASSERT_STRUCT_OFFSET(PathLinkInfo, prev, 0x4); + ASSERT_STRUCT_OFFSET(PathLinkInfo, next, 0x6); + + struct pathsort_t + { + pathnode_t * node; //OFS: 0x0 SIZE: 0x4 + float metric; //OFS: 0x4 SIZE: 0x4 + float distMetric; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathsort_t, 0xC); + ASSERT_STRUCT_OFFSET(pathsort_t, node, 0x0); + ASSERT_STRUCT_OFFSET(pathsort_t, metric, 0x4); + ASSERT_STRUCT_OFFSET(pathsort_t, distMetric, 0x8); + + struct pathlocal_t_circle + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float maxDist; //OFS: 0xC SIZE: 0x4 + float maxDistSq; //OFS: 0x10 SIZE: 0x4 + float maxHeightSq; //OFS: 0x14 SIZE: 0x4 + int typeFlags; //OFS: 0x18 SIZE: 0x4 + pathsort_t * nodes; //OFS: 0x1C SIZE: 0x4 + int maxNodes; //OFS: 0x20 SIZE: 0x4 + int nodeCount; //OFS: 0x24 SIZE: 0x4 + float maxHeight; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathlocal_t_circle, 0x2C); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, origin, 0x0); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, maxDist, 0xC); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, maxDistSq, 0x10); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, maxHeightSq, 0x14); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, typeFlags, 0x18); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, nodes, 0x1C); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, maxNodes, 0x20); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, nodeCount, 0x24); + ASSERT_STRUCT_OFFSET(pathlocal_t_circle, maxHeight, 0x28); + + struct __declspec(align(128)) pathlocal_t + { + PathLinkInfo pathLinkInfoArray[2048]; //OFS: 0x0 SIZE: 0x4000 + int pathLinkInfoArrayInited; //OFS: 0x4000 SIZE: 0x4 + unsigned int actualNodeCount; //OFS: 0x4004 SIZE: 0x4 + pathlocal_t_circle circle; //OFS: 0x4008 SIZE: 0x2C + unsigned int extraNodes; //OFS: 0x4034 SIZE: 0x4 + unsigned int originErrors; //OFS: 0x4038 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathlocal_t, 0x4080); + ASSERT_STRUCT_OFFSET(pathlocal_t, pathLinkInfoArray, 0x0); + ASSERT_STRUCT_OFFSET(pathlocal_t, pathLinkInfoArrayInited, 0x4000); + ASSERT_STRUCT_OFFSET(pathlocal_t, actualNodeCount, 0x4004); + ASSERT_STRUCT_OFFSET(pathlocal_t, circle, 0x4008); + ASSERT_STRUCT_OFFSET(pathlocal_t, extraNodes, 0x4034); + ASSERT_STRUCT_OFFSET(pathlocal_t, originErrors, 0x4038); + + struct AIEventListener + { + int entIndex; //OFS: 0x0 SIZE: 0x4 + unsigned int events; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AIEventListener, 0x8); + ASSERT_STRUCT_OFFSET(AIEventListener, entIndex, 0x0); + ASSERT_STRUCT_OFFSET(AIEventListener, events, 0x4); + + struct vnode_field_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vnode_field_t, 0xC); + ASSERT_STRUCT_OFFSET(vnode_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(vnode_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(vnode_field_t, type, 0x8); + + struct StreamFileNameRaw + { + const char * dir; //OFS: 0x0 SIZE: 0x4 + const char * name; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StreamFileNameRaw, 0x8); + ASSERT_STRUCT_OFFSET(StreamFileNameRaw, dir, 0x0); + ASSERT_STRUCT_OFFSET(StreamFileNameRaw, name, 0x4); + + union StreamFileInfo + { + StreamFileNameRaw raw[32]; //OFS: 0x0 SIZE: 0x100 + }; + ASSERT_STRUCT_SIZE(StreamFileInfo, 0x100); + + struct GfxStreamingAabbTree + { + unsigned __int16 firstItem; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 itemCount; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 firstChild; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 childCount; //OFS: 0x6 SIZE: 0x2 + float mins[3]; //OFS: 0x8 SIZE: 0xC + float maxs[3]; //OFS: 0x14 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(GfxStreamingAabbTree, 0x20); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, firstItem, 0x0); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, itemCount, 0x2); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, firstChild, 0x4); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, childCount, 0x6); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, mins, 0x8); + ASSERT_STRUCT_OFFSET(GfxStreamingAabbTree, maxs, 0x14); + + struct GfxWorldStreamInfo + { + int aabbTreeCount; //OFS: 0x0 SIZE: 0x4 + GfxStreamingAabbTree * aabbTrees; //OFS: 0x4 SIZE: 0x4 + int leafRefCount; //OFS: 0x8 SIZE: 0x4 + int * leafRefs; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldStreamInfo, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldStreamInfo, aabbTreeCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldStreamInfo, aabbTrees, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldStreamInfo, leafRefCount, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldStreamInfo, leafRefs, 0xC); + + struct GfxWorldGeomStreamGroup + { + float roughCenter[3]; //OFS: 0x0 SIZE: 0xC + float streamDist; //OFS: 0xC SIZE: 0x4 + unsigned __int16 firstVolume; //OFS: 0x10 SIZE: 0x2 + unsigned __int16 numVolumes; //OFS: 0x12 SIZE: 0x2 + unsigned __int16 * surfs; //OFS: 0x14 SIZE: 0x4 + char * name; //OFS: 0x18 SIZE: 0x4 + unsigned int fileSize; //OFS: 0x1C SIZE: 0x4 + unsigned __int16 surfCount; //OFS: 0x20 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxWorldGeomStreamGroup, 0x24); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, roughCenter, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, streamDist, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, firstVolume, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, numVolumes, 0x12); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, surfs, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, name, 0x18); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, fileSize, 0x1C); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamGroup, surfCount, 0x20); + + struct GfxWorldGeomStreamVolume + { + float matrix[3][3]; //OFS: 0x0 SIZE: 0x24 + float translate[3]; //OFS: 0x24 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(GfxWorldGeomStreamVolume, 0x30); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamVolume, matrix, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamVolume, translate, 0x24); + + struct GfxWorldGeomStreamInfo + { + int aabbTreeCount; //OFS: 0x0 SIZE: 0x4 + GfxStreamingAabbTree * aabbTrees; //OFS: 0x4 SIZE: 0x4 + int groupIndexCount; //OFS: 0x8 SIZE: 0x4 + unsigned __int16 * groupIndices; //OFS: 0xC SIZE: 0x4 + int groupCount; //OFS: 0x10 SIZE: 0x4 + GfxWorldGeomStreamGroup * groups; //OFS: 0x14 SIZE: 0x4 + int volumeCount; //OFS: 0x18 SIZE: 0x4 + GfxWorldGeomStreamVolume * volumes; //OFS: 0x1C SIZE: 0x4 + int streamBufSize; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldGeomStreamInfo, 0x24); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, aabbTreeCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, aabbTrees, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, groupIndexCount, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, groupIndices, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, groupCount, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, groups, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, volumeCount, 0x18); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, volumes, 0x1C); + ASSERT_STRUCT_OFFSET(GfxWorldGeomStreamInfo, streamBufSize, 0x20); + + struct GfxWorldXModelStreamInfo + { + int aabbTreeCount; //OFS: 0x0 SIZE: 0x4 + GfxStreamingAabbTree * aabbTrees; //OFS: 0x4 SIZE: 0x4 + int smodelIndexCount; //OFS: 0x8 SIZE: 0x4 + unsigned __int16 * smodelIndices; //OFS: 0xC SIZE: 0x4 + int streamBufSize; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldXModelStreamInfo, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorldXModelStreamInfo, aabbTreeCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldXModelStreamInfo, aabbTrees, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldXModelStreamInfo, smodelIndexCount, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldXModelStreamInfo, smodelIndices, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldXModelStreamInfo, streamBufSize, 0x10); + + struct GfxSimpleWaterCell + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + float underSurfaceHeight[169]; //OFS: 0x18 SIZE: 0x2A4 + }; + ASSERT_STRUCT_SIZE(GfxSimpleWaterCell, 0x2BC); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterCell, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterCell, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterCell, underSurfaceHeight, 0x18); + + struct GfxSimpleWaterWaveGen + { + float pos[3]; //OFS: 0x0 SIZE: 0xC + float amplitude; //OFS: 0xC SIZE: 0x4 + float waveLength; //OFS: 0x10 SIZE: 0x4 + float frequency; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxSimpleWaterWaveGen, 0x18); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterWaveGen, pos, 0x0); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterWaveGen, amplitude, 0xC); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterWaveGen, waveLength, 0x10); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterWaveGen, frequency, 0x14); + + struct GfxSimpleWaterData + { + int minx; //OFS: 0x0 SIZE: 0x4 + int miny; //OFS: 0x4 SIZE: 0x4 + int maxx; //OFS: 0x8 SIZE: 0x4 + int maxy; //OFS: 0xC SIZE: 0x4 + float seaLevel; //OFS: 0x10 SIZE: 0x4 + float minAlpha; //OFS: 0x14 SIZE: 0x4 + float maxAlpha; //OFS: 0x18 SIZE: 0x4 + float minAlphaDepth; //OFS: 0x1C SIZE: 0x4 + float maxAlphaDepth; //OFS: 0x20 SIZE: 0x4 + float animFadeBegin; //OFS: 0x24 SIZE: 0x4 + float animFadeEnd; //OFS: 0x28 SIZE: 0x4 + float cullDist; //OFS: 0x2C SIZE: 0x4 + float minColor[3]; //OFS: 0x30 SIZE: 0xC + float maxColor[3]; //OFS: 0x3C SIZE: 0xC + float depthAmpReduceSlope; //OFS: 0x48 SIZE: 0x4 + float depthAmpReduceIntercept; //OFS: 0x4C SIZE: 0x4 + Material * waterMaterial; //OFS: 0x50 SIZE: 0x4 + unsigned int numCells; //OFS: 0x54 SIZE: 0x4 + GfxSimpleWaterCell * cells; //OFS: 0x58 SIZE: 0x4 + unsigned __int8 * cellVisData; //OFS: 0x5C SIZE: 0x4 + unsigned int numWaveGens; //OFS: 0x60 SIZE: 0x4 + GfxSimpleWaterWaveGen * waveGens; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxSimpleWaterData, 0x68); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, minx, 0x0); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, miny, 0x4); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, maxx, 0x8); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, maxy, 0xC); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, seaLevel, 0x10); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, minAlpha, 0x14); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, maxAlpha, 0x18); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, minAlphaDepth, 0x1C); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, maxAlphaDepth, 0x20); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, animFadeBegin, 0x24); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, animFadeEnd, 0x28); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, cullDist, 0x2C); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, minColor, 0x30); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, maxColor, 0x3C); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, depthAmpReduceSlope, 0x48); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, depthAmpReduceIntercept, 0x4C); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, waterMaterial, 0x50); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, numCells, 0x54); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, cells, 0x58); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, cellVisData, 0x5C); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, numWaveGens, 0x60); + ASSERT_STRUCT_OFFSET(GfxSimpleWaterData, waveGens, 0x64); + + struct worldContents_s + { + int contentsStaticModels; //OFS: 0x0 SIZE: 0x4 + int contentsEntities; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 entities; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 staticModels; //OFS: 0xA SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(worldContents_s, 0xC); + ASSERT_STRUCT_OFFSET(worldContents_s, contentsStaticModels, 0x0); + ASSERT_STRUCT_OFFSET(worldContents_s, contentsEntities, 0x4); + ASSERT_STRUCT_OFFSET(worldContents_s, entities, 0x8); + ASSERT_STRUCT_OFFSET(worldContents_s, staticModels, 0xA); + + union worldTree_s_u + { + unsigned __int16 parent; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 nextFree; //OFS: 0x1 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(worldTree_s_u, 0x2); + + struct worldTree_s + { + float dist; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 axis; //OFS: 0x4 SIZE: 0x2 + worldTree_s_u u; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 child[2]; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(worldTree_s, 0xC); + ASSERT_STRUCT_OFFSET(worldTree_s, dist, 0x0); + ASSERT_STRUCT_OFFSET(worldTree_s, axis, 0x4); + ASSERT_STRUCT_OFFSET(worldTree_s, u, 0x6); + ASSERT_STRUCT_OFFSET(worldTree_s, child, 0x8); + + struct worldSector_s + { + worldContents_s contents; //OFS: 0x0 SIZE: 0xC + worldTree_s tree; //OFS: 0xC SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(worldSector_s, 0x18); + ASSERT_STRUCT_OFFSET(worldSector_s, contents, 0x0); + ASSERT_STRUCT_OFFSET(worldSector_s, tree, 0xC); + + struct cm_world_t + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + unsigned __int16 freeHead; //OFS: 0x18 SIZE: 0x2 + worldSector_s sectors[1024]; //OFS: 0x1C SIZE: 0x6000 + }; + ASSERT_STRUCT_SIZE(cm_world_t, 0x601C); + ASSERT_STRUCT_OFFSET(cm_world_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(cm_world_t, maxs, 0xC); + ASSERT_STRUCT_OFFSET(cm_world_t, freeHead, 0x18); + ASSERT_STRUCT_OFFSET(cm_world_t, sectors, 0x1C); + + struct SnapshotInfo_s + { + int clientNum; //OFS: 0x0 SIZE: 0x4 + clientHeader_s * client; //OFS: 0x4 SIZE: 0x4 + int snapshotDeltaTime; //OFS: 0x8 SIZE: 0x4 + BaseLineState fromBaseline; //OFS: 0xC SIZE: 0x4 + bool archived; //OFS: 0x10 SIZE: 0x1 + float field_14[3]; //OFS: 0x14 SIZE: 0xC + float field_20[2]; //OFS: 0x20 SIZE: 0x8 + char field_28; //OFS: 0x28 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SnapshotInfo_s, 0x2C); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, clientNum, 0x0); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, client, 0x4); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, snapshotDeltaTime, 0x8); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, fromBaseline, 0xC); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, archived, 0x10); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, field_14, 0x14); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, field_20, 0x20); + ASSERT_STRUCT_OFFSET(SnapshotInfo_s, field_28, 0x28); + + struct NetFieldList + { + const NetField * array; //OFS: 0x0 SIZE: 0x4 + unsigned int count; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(NetFieldList, 0x8); + ASSERT_STRUCT_OFFSET(NetFieldList, array, 0x0); + ASSERT_STRUCT_OFFSET(NetFieldList, count, 0x4); + + struct kbutton_t + { + int down[2]; //OFS: 0x0 SIZE: 0x8 + unsigned int downtime; //OFS: 0x8 SIZE: 0x4 + unsigned int msec; //OFS: 0xC SIZE: 0x4 + bool active; //OFS: 0x10 SIZE: 0x1 + bool wasPressed; //OFS: 0x11 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(kbutton_t, 0x14); + ASSERT_STRUCT_OFFSET(kbutton_t, down, 0x0); + ASSERT_STRUCT_OFFSET(kbutton_t, downtime, 0x8); + ASSERT_STRUCT_OFFSET(kbutton_t, msec, 0xC); + ASSERT_STRUCT_OFFSET(kbutton_t, active, 0x10); + ASSERT_STRUCT_OFFSET(kbutton_t, wasPressed, 0x11); + + struct GamepadVirtualAxisMapping + { + GamepadPhysicalAxis physicalAxis; //OFS: 0x0 SIZE: 0x4 + GamepadMapping mapType; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GamepadVirtualAxisMapping, 0x8); + ASSERT_STRUCT_OFFSET(GamepadVirtualAxisMapping, physicalAxis, 0x0); + ASSERT_STRUCT_OFFSET(GamepadVirtualAxisMapping, mapType, 0x4); + + struct ScreenPlacement + { + float scaleVirtualToReal[2]; //OFS: 0x0 SIZE: 0x8 + float scaleVirtualToFull[2]; //OFS: 0x8 SIZE: 0x8 + float scaleRealToVirtual[2]; //OFS: 0x10 SIZE: 0x8 + float virtualViewableMin[2]; //OFS: 0x18 SIZE: 0x8 + float virtualViewableMax[2]; //OFS: 0x20 SIZE: 0x8 + float realViewportSize[2]; //OFS: 0x28 SIZE: 0x8 + float realViewableMin[2]; //OFS: 0x30 SIZE: 0x8 + float realViewableMax[2]; //OFS: 0x38 SIZE: 0x8 + float subScreen[2]; //OFS: 0x40 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(ScreenPlacement, 0x48); + ASSERT_STRUCT_OFFSET(ScreenPlacement, scaleVirtualToReal, 0x0); + ASSERT_STRUCT_OFFSET(ScreenPlacement, scaleVirtualToFull, 0x8); + ASSERT_STRUCT_OFFSET(ScreenPlacement, scaleRealToVirtual, 0x10); + ASSERT_STRUCT_OFFSET(ScreenPlacement, virtualViewableMin, 0x18); + ASSERT_STRUCT_OFFSET(ScreenPlacement, virtualViewableMax, 0x20); + ASSERT_STRUCT_OFFSET(ScreenPlacement, realViewportSize, 0x28); + ASSERT_STRUCT_OFFSET(ScreenPlacement, realViewableMin, 0x30); + ASSERT_STRUCT_OFFSET(ScreenPlacement, realViewableMax, 0x38); + ASSERT_STRUCT_OFFSET(ScreenPlacement, subScreen, 0x40); + + struct GraphFloat + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + float knots[32][2]; //OFS: 0x40 SIZE: 0x100 + int knotCount; //OFS: 0x140 SIZE: 0x4 + float scale; //OFS: 0x144 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GraphFloat, 0x148); + ASSERT_STRUCT_OFFSET(GraphFloat, name, 0x0); + ASSERT_STRUCT_OFFSET(GraphFloat, knots, 0x40); + ASSERT_STRUCT_OFFSET(GraphFloat, knotCount, 0x140); + ASSERT_STRUCT_OFFSET(GraphFloat, scale, 0x144); + + struct dsound_sample_t + { + void * DSCB; //OFS: 0x0 SIZE: 0x4 + void * DSB; //OFS: 0x4 SIZE: 0x4 + unsigned int dwBufferSize; //OFS: 0x8 SIZE: 0x4 + unsigned int dwCaptureOffset; //OFS: 0xC SIZE: 0x4 + unsigned int currentOffset; //OFS: 0x10 SIZE: 0x4 + unsigned int lastOffset; //OFS: 0x14 SIZE: 0x4 + unsigned int currentBufferLength; //OFS: 0x18 SIZE: 0x4 + int stopPosition; //OFS: 0x1C SIZE: 0x4 + unsigned int lastPlayPos; //OFS: 0x20 SIZE: 0x4 + int bytesBuffered; //OFS: 0x24 SIZE: 0x4 + int mode; //OFS: 0x28 SIZE: 0x4 + int frequency; //OFS: 0x2C SIZE: 0x4 + int volume; //OFS: 0x30 SIZE: 0x4 + int pan; //OFS: 0x34 SIZE: 0x4 + int channels; //OFS: 0x38 SIZE: 0x4 + bool playing; //OFS: 0x3C SIZE: 0x1 + int channel; //OFS: 0x40 SIZE: 0x4 + char playMode; //OFS: 0x44 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(dsound_sample_t, 0x48); + ASSERT_STRUCT_OFFSET(dsound_sample_t, DSCB, 0x0); + ASSERT_STRUCT_OFFSET(dsound_sample_t, DSB, 0x4); + ASSERT_STRUCT_OFFSET(dsound_sample_t, dwBufferSize, 0x8); + ASSERT_STRUCT_OFFSET(dsound_sample_t, dwCaptureOffset, 0xC); + ASSERT_STRUCT_OFFSET(dsound_sample_t, currentOffset, 0x10); + ASSERT_STRUCT_OFFSET(dsound_sample_t, lastOffset, 0x14); + ASSERT_STRUCT_OFFSET(dsound_sample_t, currentBufferLength, 0x18); + ASSERT_STRUCT_OFFSET(dsound_sample_t, stopPosition, 0x1C); + ASSERT_STRUCT_OFFSET(dsound_sample_t, lastPlayPos, 0x20); + ASSERT_STRUCT_OFFSET(dsound_sample_t, bytesBuffered, 0x24); + ASSERT_STRUCT_OFFSET(dsound_sample_t, mode, 0x28); + ASSERT_STRUCT_OFFSET(dsound_sample_t, frequency, 0x2C); + ASSERT_STRUCT_OFFSET(dsound_sample_t, volume, 0x30); + ASSERT_STRUCT_OFFSET(dsound_sample_t, pan, 0x34); + ASSERT_STRUCT_OFFSET(dsound_sample_t, channels, 0x38); + ASSERT_STRUCT_OFFSET(dsound_sample_t, playing, 0x3C); + ASSERT_STRUCT_OFFSET(dsound_sample_t, channel, 0x40); + ASSERT_STRUCT_OFFSET(dsound_sample_t, playMode, 0x44); + + struct audioSample_t + { + char * buffer; //OFS: 0x0 SIZE: 0x4 + int lengthInBytes; //OFS: 0x4 SIZE: 0x4 + int lengthInSamples; //OFS: 0x8 SIZE: 0x4 + int bytesPerSample; //OFS: 0xC SIZE: 0x4 + int frequency; //OFS: 0x10 SIZE: 0x4 + bool stereo; //OFS: 0x14 SIZE: 0x1 + int channels; //OFS: 0x18 SIZE: 0x4 + int sampleOffset; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(audioSample_t, 0x20); + ASSERT_STRUCT_OFFSET(audioSample_t, buffer, 0x0); + ASSERT_STRUCT_OFFSET(audioSample_t, lengthInBytes, 0x4); + ASSERT_STRUCT_OFFSET(audioSample_t, lengthInSamples, 0x8); + ASSERT_STRUCT_OFFSET(audioSample_t, bytesPerSample, 0xC); + ASSERT_STRUCT_OFFSET(audioSample_t, frequency, 0x10); + ASSERT_STRUCT_OFFSET(audioSample_t, stereo, 0x14); + ASSERT_STRUCT_OFFSET(audioSample_t, channels, 0x18); + ASSERT_STRUCT_OFFSET(audioSample_t, sampleOffset, 0x1C); + + struct sysEvent_t + { + int evTime; //OFS: 0x0 SIZE: 0x4 + sysEventType_t evType; //OFS: 0x4 SIZE: 0x4 + int evValue; //OFS: 0x8 SIZE: 0x4 + int evValue2; //OFS: 0xC SIZE: 0x4 + int evPtrLength; //OFS: 0x10 SIZE: 0x4 + void * evPtr; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sysEvent_t, 0x18); + ASSERT_STRUCT_OFFSET(sysEvent_t, evTime, 0x0); + ASSERT_STRUCT_OFFSET(sysEvent_t, evType, 0x4); + ASSERT_STRUCT_OFFSET(sysEvent_t, evValue, 0x8); + ASSERT_STRUCT_OFFSET(sysEvent_t, evValue2, 0xC); + ASSERT_STRUCT_OFFSET(sysEvent_t, evPtrLength, 0x10); + ASSERT_STRUCT_OFFSET(sysEvent_t, evPtr, 0x14); + + struct traceWork_t + { + float delta[4]; //OFS: 0x0 SIZE: 0x10 + float midpoint[4]; //OFS: 0x10 SIZE: 0x10 + float halfDelta[4]; //OFS: 0x20 SIZE: 0x10 + float halfDeltaAbs[4]; //OFS: 0x30 SIZE: 0x10 + float size[4]; //OFS: 0x40 SIZE: 0x10 + float bounds[2][4]; //OFS: 0x50 SIZE: 0x20 + float radiusOffset[4]; //OFS: 0x70 SIZE: 0x10 + TraceExtents extents; //OFS: 0x80 SIZE: 0x30 + float deltaLen; //OFS: 0xB0 SIZE: 0x4 + float deltaLenSq; //OFS: 0xB4 SIZE: 0x4 + int contents; //OFS: 0xB8 SIZE: 0x4 + bool isPoint; //OFS: 0xBC SIZE: 0x1 + bool axialCullOnly; //OFS: 0xBD SIZE: 0x1 + bool doublesided; //OFS: 0xBE SIZE: 0x1 + float radius; //OFS: 0xC0 SIZE: 0x4 + float offsetZ; //OFS: 0xC4 SIZE: 0x4 + float boundingRadius; //OFS: 0xC8 SIZE: 0x4 + TraceThreadInfo threadInfo; //OFS: 0xCC SIZE: 0x14 + }; + ASSERT_STRUCT_SIZE(traceWork_t, 0xE0); + ASSERT_STRUCT_OFFSET(traceWork_t, delta, 0x0); + ASSERT_STRUCT_OFFSET(traceWork_t, midpoint, 0x10); + ASSERT_STRUCT_OFFSET(traceWork_t, halfDelta, 0x20); + ASSERT_STRUCT_OFFSET(traceWork_t, halfDeltaAbs, 0x30); + ASSERT_STRUCT_OFFSET(traceWork_t, size, 0x40); + ASSERT_STRUCT_OFFSET(traceWork_t, bounds, 0x50); + ASSERT_STRUCT_OFFSET(traceWork_t, radiusOffset, 0x70); + ASSERT_STRUCT_OFFSET(traceWork_t, extents, 0x80); + ASSERT_STRUCT_OFFSET(traceWork_t, deltaLen, 0xB0); + ASSERT_STRUCT_OFFSET(traceWork_t, deltaLenSq, 0xB4); + ASSERT_STRUCT_OFFSET(traceWork_t, contents, 0xB8); + ASSERT_STRUCT_OFFSET(traceWork_t, isPoint, 0xBC); + ASSERT_STRUCT_OFFSET(traceWork_t, axialCullOnly, 0xBD); + ASSERT_STRUCT_OFFSET(traceWork_t, doublesided, 0xBE); + ASSERT_STRUCT_OFFSET(traceWork_t, radius, 0xC0); + ASSERT_STRUCT_OFFSET(traceWork_t, offsetZ, 0xC4); + ASSERT_STRUCT_OFFSET(traceWork_t, boundingRadius, 0xC8); + ASSERT_STRUCT_OFFSET(traceWork_t, threadInfo, 0xCC); + + struct __declspec(align(1)) defVtxDef + { + char gap0[1]; //OFS: 0x0 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(defVtxDef, 0x1); + ASSERT_STRUCT_OFFSET(defVtxDef, gap0, 0x0); + + struct __declspec(align(2)) GfxCachedLightEffect + { + unsigned __int16 lightIndex; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 atten; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxCachedLightEffect, 0x4); + ASSERT_STRUCT_OFFSET(GfxCachedLightEffect, lightIndex, 0x0); + ASSERT_STRUCT_OFFSET(GfxCachedLightEffect, atten, 0x2); + + struct GfxCachedLightSetting + { + __int16 firstIndex; //OFS: 0x0 SIZE: 0x2 + __int16 count; //OFS: 0x2 SIZE: 0x2 + GfxColor ambient; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCachedLightSetting, 0x8); + ASSERT_STRUCT_OFFSET(GfxCachedLightSetting, firstIndex, 0x0); + ASSERT_STRUCT_OFFSET(GfxCachedLightSetting, count, 0x2); + ASSERT_STRUCT_OFFSET(GfxCachedLightSetting, ambient, 0x4); + + struct GfxLightGrid2dLight + { + float pos[4]; //OFS: 0x0 SIZE: 0x10 + float color[3]; //OFS: 0x10 SIZE: 0xC + float pad; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2dLight, 0x20); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dLight, pos, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dLight, color, 0x10); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dLight, pad, 0x1C); + + struct GfxLightGrid2dIndex + { + unsigned int index; //OFS: 0x0 SIZE: 0x4 + float atten; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2dIndex, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dIndex, index, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dIndex, atten, 0x4); + + struct GfxLightGrid2dRow + { + float minColumnCoord; //OFS: 0x0 SIZE: 0x4 + unsigned int firstGridPoint; //OFS: 0x4 SIZE: 0x4 + unsigned int numGridPoints; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2dRow, 0xC); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dRow, minColumnCoord, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dRow, firstGridPoint, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dRow, numGridPoints, 0x8); + + struct __declspec(align(2)) GfxLightGrid2dPoint + { + unsigned __int16 first; //OFS: 0x0 SIZE: 0x2 + unsigned __int8 count; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 ambientIndex; //OFS: 0x3 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2dPoint, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dPoint, first, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dPoint, count, 0x2); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dPoint, ambientIndex, 0x3); + + struct GfxLightGrid2dCell + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + float rowDelta; //OFS: 0x18 SIZE: 0x4 + float columnDelta; //OFS: 0x1C SIZE: 0x4 + float minRowCoord; //OFS: 0x20 SIZE: 0x4 + unsigned __int16 firstRow; //OFS: 0x24 SIZE: 0x2 + unsigned __int16 numRows; //OFS: 0x26 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2dCell, 0x28); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, rowDelta, 0x18); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, columnDelta, 0x1C); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, minRowCoord, 0x20); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, firstRow, 0x24); + ASSERT_STRUCT_OFFSET(GfxLightGrid2dCell, numRows, 0x26); + + struct GfxLightGrid2d + { + unsigned int numLights; //OFS: 0x0 SIZE: 0x4 + GfxLightGrid2dLight * lights; //OFS: 0x4 SIZE: 0x4 + unsigned int numIndices; //OFS: 0x8 SIZE: 0x4 + GfxLightGrid2dIndex * indices; //OFS: 0xC SIZE: 0x4 + unsigned int numRows; //OFS: 0x10 SIZE: 0x4 + GfxLightGrid2dRow * rows; //OFS: 0x14 SIZE: 0x4 + unsigned int numPoints; //OFS: 0x18 SIZE: 0x4 + GfxLightGrid2dPoint * points; //OFS: 0x1C SIZE: 0x4 + unsigned int numCells; //OFS: 0x20 SIZE: 0x4 + GfxLightGrid2dCell * cells; //OFS: 0x24 SIZE: 0x4 + unsigned int numAmbients; //OFS: 0x28 SIZE: 0x4 + GfxColor * ambients; //OFS: 0x2C SIZE: 0x4 + unsigned int numPointHeights; //OFS: 0x30 SIZE: 0x4 + __int16 * pointHeights; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid2d, 0x38); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numLights, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, lights, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numIndices, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, indices, 0xC); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numRows, 0x10); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, rows, 0x14); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numPoints, 0x18); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, points, 0x1C); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numCells, 0x20); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, cells, 0x24); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numAmbients, 0x28); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, ambients, 0x2C); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, numPointHeights, 0x30); + ASSERT_STRUCT_OFFSET(GfxLightGrid2d, pointHeights, 0x34); + + struct GfxLightmapArray + { + GfxImage * primary; //OFS: 0x0 SIZE: 0x4 + GfxImage * secondary; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightmapArray, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightmapArray, primary, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightmapArray, secondary, 0x4); + + struct GpadAxesGlob + { + int axesValues[6]; //OFS: 0x0 SIZE: 0x18 + GamepadVirtualAxisMapping virtualAxes[6]; //OFS: 0x18 SIZE: 0x30 + }; + ASSERT_STRUCT_SIZE(GpadAxesGlob, 0x48); + ASSERT_STRUCT_OFFSET(GpadAxesGlob, axesValues, 0x0); + ASSERT_STRUCT_OFFSET(GpadAxesGlob, virtualAxes, 0x18); + + struct __declspec(align(2)) _XINPUT_CAPABILITIES + { + char Type; //OFS: 0x0 SIZE: 0x1 + char SubType; //OFS: 0x1 SIZE: 0x1 + unsigned __int16 Flags; //OFS: 0x2 SIZE: 0x2 + _XINPUT_GAMEPAD Gamepad; //OFS: 0x4 SIZE: 0xC + _XINPUT_VIBRATION Vibration; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(_XINPUT_CAPABILITIES, 0x14); + ASSERT_STRUCT_OFFSET(_XINPUT_CAPABILITIES, Type, 0x0); + ASSERT_STRUCT_OFFSET(_XINPUT_CAPABILITIES, SubType, 0x1); + ASSERT_STRUCT_OFFSET(_XINPUT_CAPABILITIES, Flags, 0x2); + ASSERT_STRUCT_OFFSET(_XINPUT_CAPABILITIES, Gamepad, 0x4); + ASSERT_STRUCT_OFFSET(_XINPUT_CAPABILITIES, Vibration, 0x10); + + struct GamePad + { + bool enabled; //OFS: 0x0 SIZE: 0x1 + bool keyboardEnabled; //OFS: 0x1 SIZE: 0x1 + __int16 digitals; //OFS: 0x2 SIZE: 0x2 + __int16 lastDigitals; //OFS: 0x4 SIZE: 0x2 + float analogs[2]; //OFS: 0x8 SIZE: 0x8 + float lastAnalogs[2]; //OFS: 0x10 SIZE: 0x8 + float sticks[4]; //OFS: 0x18 SIZE: 0x10 + float lastSticks[4]; //OFS: 0x28 SIZE: 0x10 + bool stickDown[4][2]; //OFS: 0x38 SIZE: 0x8 + bool stickDownLast[4][2]; //OFS: 0x40 SIZE: 0x8 + float lowRumble; //OFS: 0x48 SIZE: 0x4 + float highRumble; //OFS: 0x4C SIZE: 0x4 + _XINPUT_VIBRATION feedback[6]; //OFS: 0x50 SIZE: 0x18 + _XINPUT_CAPABILITIES keyboardCaps; //OFS: 0x68 SIZE: 0x14 + }; + ASSERT_STRUCT_SIZE(GamePad, 0x7C); + ASSERT_STRUCT_OFFSET(GamePad, enabled, 0x0); + ASSERT_STRUCT_OFFSET(GamePad, keyboardEnabled, 0x1); + ASSERT_STRUCT_OFFSET(GamePad, digitals, 0x2); + ASSERT_STRUCT_OFFSET(GamePad, lastDigitals, 0x4); + ASSERT_STRUCT_OFFSET(GamePad, analogs, 0x8); + ASSERT_STRUCT_OFFSET(GamePad, lastAnalogs, 0x10); + ASSERT_STRUCT_OFFSET(GamePad, sticks, 0x18); + ASSERT_STRUCT_OFFSET(GamePad, lastSticks, 0x28); + ASSERT_STRUCT_OFFSET(GamePad, stickDown, 0x38); + ASSERT_STRUCT_OFFSET(GamePad, stickDownLast, 0x40); + ASSERT_STRUCT_OFFSET(GamePad, lowRumble, 0x48); + ASSERT_STRUCT_OFFSET(GamePad, highRumble, 0x4C); + ASSERT_STRUCT_OFFSET(GamePad, feedback, 0x50); + ASSERT_STRUCT_OFFSET(GamePad, keyboardCaps, 0x68); + + struct BulletFireParams + { + int weaponEntIndex; //OFS: 0x0 SIZE: 0x4 + int ignoreEntIndex; //OFS: 0x4 SIZE: 0x4 + float damageMultiplier; //OFS: 0x8 SIZE: 0x4 + int methodOfDeath; //OFS: 0xC SIZE: 0x4 + float origStart[3]; //OFS: 0x10 SIZE: 0xC + float start[3]; //OFS: 0x1C SIZE: 0xC + float end[3]; //OFS: 0x28 SIZE: 0xC + float dir[3]; //OFS: 0x34 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(BulletFireParams, 0x40); + ASSERT_STRUCT_OFFSET(BulletFireParams, weaponEntIndex, 0x0); + ASSERT_STRUCT_OFFSET(BulletFireParams, ignoreEntIndex, 0x4); + ASSERT_STRUCT_OFFSET(BulletFireParams, damageMultiplier, 0x8); + ASSERT_STRUCT_OFFSET(BulletFireParams, methodOfDeath, 0xC); + ASSERT_STRUCT_OFFSET(BulletFireParams, origStart, 0x10); + ASSERT_STRUCT_OFFSET(BulletFireParams, start, 0x1C); + ASSERT_STRUCT_OFFSET(BulletFireParams, end, 0x28); + ASSERT_STRUCT_OFFSET(BulletFireParams, dir, 0x34); + + struct locTraceWork_t + { + int contents; //OFS: 0x0 SIZE: 0x4 + TraceExtents extents; //OFS: 0x4 SIZE: 0x30 + }; + ASSERT_STRUCT_SIZE(locTraceWork_t, 0x34); + ASSERT_STRUCT_OFFSET(locTraceWork_t, contents, 0x0); + ASSERT_STRUCT_OFFSET(locTraceWork_t, extents, 0x4); + + struct cg_level_locals_t + { + con_channel_e scriptPrintChannel; //OFS: 0x0 SIZE: 0x4 + SpawnVar spawnVar; //OFS: 0x4 SIZE: 0xA0C + }; + ASSERT_STRUCT_SIZE(cg_level_locals_t, 0xA10); + ASSERT_STRUCT_OFFSET(cg_level_locals_t, scriptPrintChannel, 0x0); + ASSERT_STRUCT_OFFSET(cg_level_locals_t, spawnVar, 0x4); + + struct cent_field_t + { + char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cent_field_t, 0xC); + ASSERT_STRUCT_OFFSET(cent_field_t, name, 0x0); + ASSERT_STRUCT_OFFSET(cent_field_t, ofs, 0x4); + ASSERT_STRUCT_OFFSET(cent_field_t, type, 0x8); + + struct Bone + { + int parentBone; //OFS: 0x0 SIZE: 0x4 + unsigned __int8 animBones[2]; //OFS: 0x4 SIZE: 0x2 + int rigidBody; //OFS: 0x8 SIZE: 0x4 + float length; //OFS: 0xC SIZE: 0x4 + float center[3]; //OFS: 0x10 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(Bone, 0x1C); + ASSERT_STRUCT_OFFSET(Bone, parentBone, 0x0); + ASSERT_STRUCT_OFFSET(Bone, animBones, 0x4); + ASSERT_STRUCT_OFFSET(Bone, rigidBody, 0x8); + ASSERT_STRUCT_OFFSET(Bone, length, 0xC); + ASSERT_STRUCT_OFFSET(Bone, center, 0x10); + + struct LerpBone + { + int parentBone; //OFS: 0x0 SIZE: 0x4 + unsigned __int8 animBone; //OFS: 0x4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(LerpBone, 0x8); + ASSERT_STRUCT_OFFSET(LerpBone, parentBone, 0x0); + ASSERT_STRUCT_OFFSET(LerpBone, animBone, 0x4); + + struct Joint + { + int joint; //OFS: 0x0 SIZE: 0x4 + int joint2; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Joint, 0x8); + ASSERT_STRUCT_OFFSET(Joint, joint, 0x0); + ASSERT_STRUCT_OFFSET(Joint, joint2, 0x4); + + struct BoneOrientation + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + int boneFlags; //OFS: 0xC SIZE: 0x4 + float orientation[4]; //OFS: 0x10 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(BoneOrientation, 0x20); + ASSERT_STRUCT_OFFSET(BoneOrientation, origin, 0x0); + ASSERT_STRUCT_OFFSET(BoneOrientation, boneFlags, 0xC); + ASSERT_STRUCT_OFFSET(BoneOrientation, orientation, 0x10); + + struct RagdollBody + { + int references; //OFS: 0x0 SIZE: 0x4 + int ragdollDef; //OFS: 0x4 SIZE: 0x4 + int dobj; //OFS: 0x8 SIZE: 0x4 + DObj_s * obj; //OFS: 0xC SIZE: 0x4 + cpose_t * pose; //OFS: 0x10 SIZE: 0x4 + float poseOffset[3]; //OFS: 0x14 SIZE: 0xC + int localClientNum; //OFS: 0x20 SIZE: 0x4 + RagdollBodyState state; //OFS: 0x24 SIZE: 0x4 + int stateMsec; //OFS: 0x28 SIZE: 0x4 + int stateFrames; //OFS: 0x2C SIZE: 0x4 + int velCaptureMsec; //OFS: 0x30 SIZE: 0x4 + int stableTime; //OFS: 0x34 SIZE: 0x4 + int numBones; //OFS: 0x38 SIZE: 0x4 + Bone bones[14]; //OFS: 0x3C SIZE: 0x188 + int numLerpBones; //OFS: 0x1C4 SIZE: 0x4 + LerpBone lerpBones[9]; //OFS: 0x1C8 SIZE: 0x48 + int numJoints; //OFS: 0x210 SIZE: 0x4 + Joint joints[28]; //OFS: 0x214 SIZE: 0xE0 + int curOrientationBuffer; //OFS: 0x2F4 SIZE: 0x4 + BoneOrientation boneOrientations[2][23]; //OFS: 0x2F8 SIZE: 0x5C0 + BoneOrientation lerpBoneOffsets[9]; //OFS: 0x8B8 SIZE: 0x120 + int flags; //OFS: 0x9D8 SIZE: 0x4 + int storedLaunchCount; //OFS: 0x9DC SIZE: 0x4 + hitLocation_t storedLaunchHitLoc[2]; //OFS: 0x9E0 SIZE: 0x8 + float storedLaunchForce[2][3]; //OFS: 0x9E8 SIZE: 0x18 + void * m_bpg; //OFS: 0xA00 SIZE: 0x4 + void * m_list_bpcp; //OFS: 0xA04 SIZE: 0x4 + int rope_id; //OFS: 0xA08 SIZE: 0x4 + void * rbc_dist; //OFS: 0xA0C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(RagdollBody, 0xA10); + ASSERT_STRUCT_OFFSET(RagdollBody, references, 0x0); + ASSERT_STRUCT_OFFSET(RagdollBody, ragdollDef, 0x4); + ASSERT_STRUCT_OFFSET(RagdollBody, dobj, 0x8); + ASSERT_STRUCT_OFFSET(RagdollBody, obj, 0xC); + ASSERT_STRUCT_OFFSET(RagdollBody, pose, 0x10); + ASSERT_STRUCT_OFFSET(RagdollBody, poseOffset, 0x14); + ASSERT_STRUCT_OFFSET(RagdollBody, localClientNum, 0x20); + ASSERT_STRUCT_OFFSET(RagdollBody, state, 0x24); + ASSERT_STRUCT_OFFSET(RagdollBody, stateMsec, 0x28); + ASSERT_STRUCT_OFFSET(RagdollBody, stateFrames, 0x2C); + ASSERT_STRUCT_OFFSET(RagdollBody, velCaptureMsec, 0x30); + ASSERT_STRUCT_OFFSET(RagdollBody, stableTime, 0x34); + ASSERT_STRUCT_OFFSET(RagdollBody, numBones, 0x38); + ASSERT_STRUCT_OFFSET(RagdollBody, bones, 0x3C); + ASSERT_STRUCT_OFFSET(RagdollBody, numLerpBones, 0x1C4); + ASSERT_STRUCT_OFFSET(RagdollBody, lerpBones, 0x1C8); + ASSERT_STRUCT_OFFSET(RagdollBody, numJoints, 0x210); + ASSERT_STRUCT_OFFSET(RagdollBody, joints, 0x214); + ASSERT_STRUCT_OFFSET(RagdollBody, curOrientationBuffer, 0x2F4); + ASSERT_STRUCT_OFFSET(RagdollBody, boneOrientations, 0x2F8); + ASSERT_STRUCT_OFFSET(RagdollBody, lerpBoneOffsets, 0x8B8); + ASSERT_STRUCT_OFFSET(RagdollBody, flags, 0x9D8); + ASSERT_STRUCT_OFFSET(RagdollBody, storedLaunchCount, 0x9DC); + ASSERT_STRUCT_OFFSET(RagdollBody, storedLaunchHitLoc, 0x9E0); + ASSERT_STRUCT_OFFSET(RagdollBody, storedLaunchForce, 0x9E8); + ASSERT_STRUCT_OFFSET(RagdollBody, m_bpg, 0xA00); + ASSERT_STRUCT_OFFSET(RagdollBody, m_list_bpcp, 0xA04); + ASSERT_STRUCT_OFFSET(RagdollBody, rope_id, 0xA08); + ASSERT_STRUCT_OFFSET(RagdollBody, rbc_dist, 0xA0C); + + struct BoneDef + { + char animBoneTextNames[2][20]; //OFS: 0x0 SIZE: 0x28 + unsigned int animBoneNames[2]; //OFS: 0x28 SIZE: 0x8 + float radius; //OFS: 0x30 SIZE: 0x4 + bool mirror; //OFS: 0x34 SIZE: 0x1 + float percent; //OFS: 0x38 SIZE: 0x4 + float mass; //OFS: 0x3C SIZE: 0x4 + float friction; //OFS: 0x40 SIZE: 0x4 + float buoyancy; //OFS: 0x44 SIZE: 0x4 + int parentBone; //OFS: 0x48 SIZE: 0x4 + PhysicsGeomType geomType; //OFS: 0x4C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BoneDef, 0x50); + ASSERT_STRUCT_OFFSET(BoneDef, animBoneTextNames, 0x0); + ASSERT_STRUCT_OFFSET(BoneDef, animBoneNames, 0x28); + ASSERT_STRUCT_OFFSET(BoneDef, radius, 0x30); + ASSERT_STRUCT_OFFSET(BoneDef, mirror, 0x34); + ASSERT_STRUCT_OFFSET(BoneDef, percent, 0x38); + ASSERT_STRUCT_OFFSET(BoneDef, mass, 0x3C); + ASSERT_STRUCT_OFFSET(BoneDef, friction, 0x40); + ASSERT_STRUCT_OFFSET(BoneDef, buoyancy, 0x44); + ASSERT_STRUCT_OFFSET(BoneDef, parentBone, 0x48); + ASSERT_STRUCT_OFFSET(BoneDef, geomType, 0x4C); + + struct BaseLerpBoneDef + { + char animBoneTextName[20]; //OFS: 0x0 SIZE: 0x14 + unsigned int animBoneName; //OFS: 0x14 SIZE: 0x4 + unsigned int parentBoneIndex; //OFS: 0x18 SIZE: 0x4 + int lerpTime; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BaseLerpBoneDef, 0x20); + ASSERT_STRUCT_OFFSET(BaseLerpBoneDef, animBoneTextName, 0x0); + ASSERT_STRUCT_OFFSET(BaseLerpBoneDef, animBoneName, 0x14); + ASSERT_STRUCT_OFFSET(BaseLerpBoneDef, parentBoneIndex, 0x18); + ASSERT_STRUCT_OFFSET(BaseLerpBoneDef, lerpTime, 0x1C); + + struct JointDef + { + unsigned __int8 bone; //OFS: 0x0 SIZE: 0x1 + JointType type; //OFS: 0x4 SIZE: 0x4 + int numLimitAxes; //OFS: 0x8 SIZE: 0x4 + float limitAxes[3][3]; //OFS: 0xC SIZE: 0x24 + float minAngles[3]; //OFS: 0x30 SIZE: 0xC + float maxAngles[3]; //OFS: 0x3C SIZE: 0xC + float axisFriction[3]; //OFS: 0x48 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(JointDef, 0x54); + ASSERT_STRUCT_OFFSET(JointDef, bone, 0x0); + ASSERT_STRUCT_OFFSET(JointDef, type, 0x4); + ASSERT_STRUCT_OFFSET(JointDef, numLimitAxes, 0x8); + ASSERT_STRUCT_OFFSET(JointDef, limitAxes, 0xC); + ASSERT_STRUCT_OFFSET(JointDef, minAngles, 0x30); + ASSERT_STRUCT_OFFSET(JointDef, maxAngles, 0x3C); + ASSERT_STRUCT_OFFSET(JointDef, axisFriction, 0x48); + + struct __declspec(align(1)) SelfPairDef + { + unsigned __int8 bones[2]; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(SelfPairDef, 0x2); + ASSERT_STRUCT_OFFSET(SelfPairDef, bones, 0x0); + + struct RagdollDef + { + bool inUse; //OFS: 0x0 SIZE: 0x1 + bool bound; //OFS: 0x1 SIZE: 0x1 + int numBones; //OFS: 0x4 SIZE: 0x4 + BoneDef boneDefs[14]; //OFS: 0x8 SIZE: 0x460 + int numBaseLerpBones; //OFS: 0x468 SIZE: 0x4 + BaseLerpBoneDef baseLerpBoneDefs[9]; //OFS: 0x46C SIZE: 0x120 + int numJoints; //OFS: 0x58C SIZE: 0x4 + JointDef jointDefs[28]; //OFS: 0x590 SIZE: 0x930 + int numSelfPairs; //OFS: 0xEC0 SIZE: 0x4 + SelfPairDef selfPairDefs[33]; //OFS: 0xEC4 SIZE: 0x42 + }; + ASSERT_STRUCT_SIZE(RagdollDef, 0xF08); + ASSERT_STRUCT_OFFSET(RagdollDef, inUse, 0x0); + ASSERT_STRUCT_OFFSET(RagdollDef, bound, 0x1); + ASSERT_STRUCT_OFFSET(RagdollDef, numBones, 0x4); + ASSERT_STRUCT_OFFSET(RagdollDef, boneDefs, 0x8); + ASSERT_STRUCT_OFFSET(RagdollDef, numBaseLerpBones, 0x468); + ASSERT_STRUCT_OFFSET(RagdollDef, baseLerpBoneDefs, 0x46C); + ASSERT_STRUCT_OFFSET(RagdollDef, numJoints, 0x58C); + ASSERT_STRUCT_OFFSET(RagdollDef, jointDefs, 0x590); + ASSERT_STRUCT_OFFSET(RagdollDef, numSelfPairs, 0xEC0); + ASSERT_STRUCT_OFFSET(RagdollDef, selfPairDefs, 0xEC4); + + struct CameraShake + { + int time; //OFS: 0x0 SIZE: 0x4 + float scale; //OFS: 0x4 SIZE: 0x4 + float length; //OFS: 0x8 SIZE: 0x4 + float radius; //OFS: 0xC SIZE: 0x4 + float src[3]; //OFS: 0x10 SIZE: 0xC + float size; //OFS: 0x1C SIZE: 0x4 + float rumbleScale; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CameraShake, 0x24); + ASSERT_STRUCT_OFFSET(CameraShake, time, 0x0); + ASSERT_STRUCT_OFFSET(CameraShake, scale, 0x4); + ASSERT_STRUCT_OFFSET(CameraShake, length, 0x8); + ASSERT_STRUCT_OFFSET(CameraShake, radius, 0xC); + ASSERT_STRUCT_OFFSET(CameraShake, src, 0x10); + ASSERT_STRUCT_OFFSET(CameraShake, size, 0x1C); + ASSERT_STRUCT_OFFSET(CameraShake, rumbleScale, 0x20); + + struct CameraShakeSet + { + CameraShake shakes[4]; //OFS: 0x0 SIZE: 0x90 + float phase; //OFS: 0x90 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CameraShakeSet, 0x94); + ASSERT_STRUCT_OFFSET(CameraShakeSet, shakes, 0x0); + ASSERT_STRUCT_OFFSET(CameraShakeSet, phase, 0x90); + + struct DynEntityCollTree + { + float dist; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 axis; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 nextFree; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 child[2]; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEntityCollTree, 0xC); + ASSERT_STRUCT_OFFSET(DynEntityCollTree, dist, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityCollTree, axis, 0x4); + ASSERT_STRUCT_OFFSET(DynEntityCollTree, nextFree, 0x6); + ASSERT_STRUCT_OFFSET(DynEntityCollTree, child, 0x8); + + struct DynEntityCollSector + { + DynEntityCollTree tree; //OFS: 0x0 SIZE: 0xC + int contents; //OFS: 0xC SIZE: 0x4 + unsigned __int16 entListHead; //OFS: 0x10 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(DynEntityCollSector, 0x14); + ASSERT_STRUCT_OFFSET(DynEntityCollSector, tree, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityCollSector, contents, 0xC); + ASSERT_STRUCT_OFFSET(DynEntityCollSector, entListHead, 0x10); + + struct DynEntityCollWorld + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + unsigned __int16 freeHead; //OFS: 0x18 SIZE: 0x2 + DynEntityCollSector sectors[1024]; //OFS: 0x1C SIZE: 0x5000 + }; + ASSERT_STRUCT_SIZE(DynEntityCollWorld, 0x501C); + ASSERT_STRUCT_OFFSET(DynEntityCollWorld, mins, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityCollWorld, maxs, 0xC); + ASSERT_STRUCT_OFFSET(DynEntityCollWorld, freeHead, 0x18); + ASSERT_STRUCT_OFFSET(DynEntityCollWorld, sectors, 0x1C); + + struct CgEntCollTree + { + float dist; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 axis; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 nextFree; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 child[2]; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CgEntCollTree, 0xC); + ASSERT_STRUCT_OFFSET(CgEntCollTree, dist, 0x0); + ASSERT_STRUCT_OFFSET(CgEntCollTree, axis, 0x4); + ASSERT_STRUCT_OFFSET(CgEntCollTree, nextFree, 0x6); + ASSERT_STRUCT_OFFSET(CgEntCollTree, child, 0x8); + + struct CgEntCollSector + { + CgEntCollTree tree; //OFS: 0x0 SIZE: 0xC + unsigned __int16 entListHead; //OFS: 0xC SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(CgEntCollSector, 0x10); + ASSERT_STRUCT_OFFSET(CgEntCollSector, tree, 0x0); + ASSERT_STRUCT_OFFSET(CgEntCollSector, entListHead, 0xC); + + struct CgEntCollWorld + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + unsigned __int16 freeHead; //OFS: 0x18 SIZE: 0x2 + CgEntCollSector sectors[1024]; //OFS: 0x1C SIZE: 0x4000 + }; + ASSERT_STRUCT_SIZE(CgEntCollWorld, 0x401C); + ASSERT_STRUCT_OFFSET(CgEntCollWorld, mins, 0x0); + ASSERT_STRUCT_OFFSET(CgEntCollWorld, maxs, 0xC); + ASSERT_STRUCT_OFFSET(CgEntCollWorld, freeHead, 0x18); + ASSERT_STRUCT_OFFSET(CgEntCollWorld, sectors, 0x1C); + + struct CgEntCollNode + { + unsigned __int16 sector; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 nextEntInSector; //OFS: 0x2 SIZE: 0x2 + float linkMins[2]; //OFS: 0x4 SIZE: 0x8 + float linkMaxs[2]; //OFS: 0xC SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(CgEntCollNode, 0x14); + ASSERT_STRUCT_OFFSET(CgEntCollNode, sector, 0x0); + ASSERT_STRUCT_OFFSET(CgEntCollNode, nextEntInSector, 0x2); + ASSERT_STRUCT_OFFSET(CgEntCollNode, linkMins, 0x4); + ASSERT_STRUCT_OFFSET(CgEntCollNode, linkMaxs, 0xC); + + struct pathstatic_t + { + pathlink_s * pathLinks; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 * indirectNodes; //OFS: 0x4 SIZE: 0x4 + char * pathbuf; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathstatic_t, 0xC); + ASSERT_STRUCT_OFFSET(pathstatic_t, pathLinks, 0x0); + ASSERT_STRUCT_OFFSET(pathstatic_t, indirectNodes, 0x4); + ASSERT_STRUCT_OFFSET(pathstatic_t, pathbuf, 0x8); + + struct MemoryFile + { + unsigned __int8 * buffer; //OFS: 0x0 SIZE: 0x4 + int bufferSize; //OFS: 0x4 SIZE: 0x4 + int bytesUsed; //OFS: 0x8 SIZE: 0x4 + int cacheBufferUsed; //OFS: 0xC SIZE: 0x4 + int segmentIndex; //OFS: 0x10 SIZE: 0x4 + int segmentStart; //OFS: 0x14 SIZE: 0x4 + int nonZeroCount; //OFS: 0x18 SIZE: 0x4 + int zeroCount; //OFS: 0x1C SIZE: 0x4 + bool errorOnOverflow; //OFS: 0x20 SIZE: 0x1 + bool memoryOverflow; //OFS: 0x21 SIZE: 0x1 + bool compress_enabled; //OFS: 0x22 SIZE: 0x1 + bool rle_enabled; //OFS: 0x23 SIZE: 0x1 + bool is_writing; //OFS: 0x24 SIZE: 0x1 + z_stream_s stream; //OFS: 0x28 SIZE: 0x34 + unsigned __int8 cacheBuffer[32760]; //OFS: 0x5C SIZE: 0x7FF8 + }; + ASSERT_STRUCT_SIZE(MemoryFile, 0x8054); + ASSERT_STRUCT_OFFSET(MemoryFile, buffer, 0x0); + ASSERT_STRUCT_OFFSET(MemoryFile, bufferSize, 0x4); + ASSERT_STRUCT_OFFSET(MemoryFile, bytesUsed, 0x8); + ASSERT_STRUCT_OFFSET(MemoryFile, cacheBufferUsed, 0xC); + ASSERT_STRUCT_OFFSET(MemoryFile, segmentIndex, 0x10); + ASSERT_STRUCT_OFFSET(MemoryFile, segmentStart, 0x14); + ASSERT_STRUCT_OFFSET(MemoryFile, nonZeroCount, 0x18); + ASSERT_STRUCT_OFFSET(MemoryFile, zeroCount, 0x1C); + ASSERT_STRUCT_OFFSET(MemoryFile, errorOnOverflow, 0x20); + ASSERT_STRUCT_OFFSET(MemoryFile, memoryOverflow, 0x21); + ASSERT_STRUCT_OFFSET(MemoryFile, compress_enabled, 0x22); + ASSERT_STRUCT_OFFSET(MemoryFile, rle_enabled, 0x23); + ASSERT_STRUCT_OFFSET(MemoryFile, is_writing, 0x24); + ASSERT_STRUCT_OFFSET(MemoryFile, stream, 0x28); + ASSERT_STRUCT_OFFSET(MemoryFile, cacheBuffer, 0x5C); + + struct qtime_s + { + int tm_sec; //OFS: 0x0 SIZE: 0x4 + int tm_min; //OFS: 0x4 SIZE: 0x4 + int tm_hour; //OFS: 0x8 SIZE: 0x4 + int tm_mday; //OFS: 0xC SIZE: 0x4 + int tm_mon; //OFS: 0x10 SIZE: 0x4 + int tm_year; //OFS: 0x14 SIZE: 0x4 + int tm_wday; //OFS: 0x18 SIZE: 0x4 + int tm_yday; //OFS: 0x1C SIZE: 0x4 + int tm_isdst; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(qtime_s, 0x24); + ASSERT_STRUCT_OFFSET(qtime_s, tm_sec, 0x0); + ASSERT_STRUCT_OFFSET(qtime_s, tm_min, 0x4); + ASSERT_STRUCT_OFFSET(qtime_s, tm_hour, 0x8); + ASSERT_STRUCT_OFFSET(qtime_s, tm_mday, 0xC); + ASSERT_STRUCT_OFFSET(qtime_s, tm_mon, 0x10); + ASSERT_STRUCT_OFFSET(qtime_s, tm_year, 0x14); + ASSERT_STRUCT_OFFSET(qtime_s, tm_wday, 0x18); + ASSERT_STRUCT_OFFSET(qtime_s, tm_yday, 0x1C); + ASSERT_STRUCT_OFFSET(qtime_s, tm_isdst, 0x20); + + struct SaveHeader + { + int saveVersion; //OFS: 0x0 SIZE: 0x4 + int gameCheckSum; //OFS: 0x4 SIZE: 0x4 + int saveCheckSum; //OFS: 0x8 SIZE: 0x4 + int saveId; //OFS: 0xC SIZE: 0x4 + bool isUsingScriptChecksum; //OFS: 0x10 SIZE: 0x1 + int scrCheckSum[3]; //OFS: 0x14 SIZE: 0xC + char mapName[256]; //OFS: 0x20 SIZE: 0x100 + char buildNumber[128]; //OFS: 0x120 SIZE: 0x80 + char campaign[256]; //OFS: 0x1A0 SIZE: 0x100 + char screenShotName[64]; //OFS: 0x2A0 SIZE: 0x40 + char description[256]; //OFS: 0x2E0 SIZE: 0x100 + char filename[64]; //OFS: 0x3E0 SIZE: 0x40 + int health; //OFS: 0x420 SIZE: 0x4 + int skill; //OFS: 0x424 SIZE: 0x4 + bool internalSave; //OFS: 0x428 SIZE: 0x1 + qtime_s time; //OFS: 0x42C SIZE: 0x24 + int server_bodySize; //OFS: 0x450 SIZE: 0x4 + int client_bodySize; //OFS: 0x454 SIZE: 0x4 + int pad[16]; //OFS: 0x458 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(SaveHeader, 0x498); + ASSERT_STRUCT_OFFSET(SaveHeader, saveVersion, 0x0); + ASSERT_STRUCT_OFFSET(SaveHeader, gameCheckSum, 0x4); + ASSERT_STRUCT_OFFSET(SaveHeader, saveCheckSum, 0x8); + ASSERT_STRUCT_OFFSET(SaveHeader, saveId, 0xC); + ASSERT_STRUCT_OFFSET(SaveHeader, isUsingScriptChecksum, 0x10); + ASSERT_STRUCT_OFFSET(SaveHeader, scrCheckSum, 0x14); + ASSERT_STRUCT_OFFSET(SaveHeader, mapName, 0x20); + ASSERT_STRUCT_OFFSET(SaveHeader, buildNumber, 0x120); + ASSERT_STRUCT_OFFSET(SaveHeader, campaign, 0x1A0); + ASSERT_STRUCT_OFFSET(SaveHeader, screenShotName, 0x2A0); + ASSERT_STRUCT_OFFSET(SaveHeader, description, 0x2E0); + ASSERT_STRUCT_OFFSET(SaveHeader, filename, 0x3E0); + ASSERT_STRUCT_OFFSET(SaveHeader, health, 0x420); + ASSERT_STRUCT_OFFSET(SaveHeader, skill, 0x424); + ASSERT_STRUCT_OFFSET(SaveHeader, internalSave, 0x428); + ASSERT_STRUCT_OFFSET(SaveHeader, time, 0x42C); + ASSERT_STRUCT_OFFSET(SaveHeader, server_bodySize, 0x450); + ASSERT_STRUCT_OFFSET(SaveHeader, client_bodySize, 0x454); + ASSERT_STRUCT_OFFSET(SaveHeader, pad, 0x458); + + struct SaveGame + { + MemoryFile server_memFile; //OFS: 0x0 SIZE: 0x8054 + MemoryFile client_memFile; //OFS: 0x8054 SIZE: 0x8054 + SaveBufferState saveState; //OFS: 0x100A8 SIZE: 0x4 + SaveHeader header; //OFS: 0x100AC SIZE: 0x498 + bool isUsingGlobalBuffer; //OFS: 0x10544 SIZE: 0x1 + bool isDirectWriteActive; //OFS: 0x10545 SIZE: 0x1 + bool isWrittenToDevice; //OFS: 0x10546 SIZE: 0x1 + bool suppressPlayerNotify; //OFS: 0x10547 SIZE: 0x1 + bool isClientDoneSaving; //OFS: 0x10548 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SaveGame, 0x1054C); + ASSERT_STRUCT_OFFSET(SaveGame, server_memFile, 0x0); + ASSERT_STRUCT_OFFSET(SaveGame, client_memFile, 0x8054); + ASSERT_STRUCT_OFFSET(SaveGame, saveState, 0x100A8); + ASSERT_STRUCT_OFFSET(SaveGame, header, 0x100AC); + ASSERT_STRUCT_OFFSET(SaveGame, isUsingGlobalBuffer, 0x10544); + ASSERT_STRUCT_OFFSET(SaveGame, isDirectWriteActive, 0x10545); + ASSERT_STRUCT_OFFSET(SaveGame, isWrittenToDevice, 0x10546); + ASSERT_STRUCT_OFFSET(SaveGame, suppressPlayerNotify, 0x10547); + ASSERT_STRUCT_OFFSET(SaveGame, isClientDoneSaving, 0x10548); + + struct parseInfo_t + { + char token[1024]; //OFS: 0x0 SIZE: 0x400 + int lines; //OFS: 0x400 SIZE: 0x4 + bool ungetToken; //OFS: 0x404 SIZE: 0x1 + bool spaceDelimited; //OFS: 0x405 SIZE: 0x1 + bool keepStringQuotes; //OFS: 0x406 SIZE: 0x1 + bool csv; //OFS: 0x407 SIZE: 0x1 + bool negativeNumbers; //OFS: 0x408 SIZE: 0x1 + char * errorPrefix; //OFS: 0x40C SIZE: 0x4 + char * warningPrefix; //OFS: 0x410 SIZE: 0x4 + int backup_lines; //OFS: 0x414 SIZE: 0x4 + char * backup_text; //OFS: 0x418 SIZE: 0x4 + char * parseFile; //OFS: 0x41C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(parseInfo_t, 0x420); + ASSERT_STRUCT_OFFSET(parseInfo_t, token, 0x0); + ASSERT_STRUCT_OFFSET(parseInfo_t, lines, 0x400); + ASSERT_STRUCT_OFFSET(parseInfo_t, ungetToken, 0x404); + ASSERT_STRUCT_OFFSET(parseInfo_t, spaceDelimited, 0x405); + ASSERT_STRUCT_OFFSET(parseInfo_t, keepStringQuotes, 0x406); + ASSERT_STRUCT_OFFSET(parseInfo_t, csv, 0x407); + ASSERT_STRUCT_OFFSET(parseInfo_t, negativeNumbers, 0x408); + ASSERT_STRUCT_OFFSET(parseInfo_t, errorPrefix, 0x40C); + ASSERT_STRUCT_OFFSET(parseInfo_t, warningPrefix, 0x410); + ASSERT_STRUCT_OFFSET(parseInfo_t, backup_lines, 0x414); + ASSERT_STRUCT_OFFSET(parseInfo_t, backup_text, 0x418); + ASSERT_STRUCT_OFFSET(parseInfo_t, parseFile, 0x41C); + + struct pml_t + { + float forward[3]; //OFS: 0x0 SIZE: 0xC + float right[3]; //OFS: 0xC SIZE: 0xC + float up[3]; //OFS: 0x18 SIZE: 0xC + float frametime; //OFS: 0x24 SIZE: 0x4 + int msec; //OFS: 0x28 SIZE: 0x4 + int walking; //OFS: 0x2C SIZE: 0x4 + int groundPlane; //OFS: 0x30 SIZE: 0x4 + int almostGroundPlane; //OFS: 0x34 SIZE: 0x4 + trace_t groundTrace; //OFS: 0x38 SIZE: 0x34 + float impactSpeed; //OFS: 0x6C SIZE: 0x4 + float previous_origin[3]; //OFS: 0x70 SIZE: 0xC + float previous_velocity[3]; //OFS: 0x7C SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(pml_t, 0x88); + ASSERT_STRUCT_OFFSET(pml_t, forward, 0x0); + ASSERT_STRUCT_OFFSET(pml_t, right, 0xC); + ASSERT_STRUCT_OFFSET(pml_t, up, 0x18); + ASSERT_STRUCT_OFFSET(pml_t, frametime, 0x24); + ASSERT_STRUCT_OFFSET(pml_t, msec, 0x28); + ASSERT_STRUCT_OFFSET(pml_t, walking, 0x2C); + ASSERT_STRUCT_OFFSET(pml_t, groundPlane, 0x30); + ASSERT_STRUCT_OFFSET(pml_t, almostGroundPlane, 0x34); + ASSERT_STRUCT_OFFSET(pml_t, groundTrace, 0x38); + ASSERT_STRUCT_OFFSET(pml_t, impactSpeed, 0x6C); + ASSERT_STRUCT_OFFSET(pml_t, previous_origin, 0x70); + ASSERT_STRUCT_OFFSET(pml_t, previous_velocity, 0x7C); + + struct saveField_t + { + int ofs; //OFS: 0x0 SIZE: 0x4 + saveFieldtype_t type; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(saveField_t, 0x8); + ASSERT_STRUCT_OFFSET(saveField_t, ofs, 0x0); + ASSERT_STRUCT_OFFSET(saveField_t, type, 0x4); + + struct SavedScreenParams + { + float s0; //OFS: 0x0 SIZE: 0x4 + float t0; //OFS: 0x4 SIZE: 0x4 + float _ds; //OFS: 0x8 SIZE: 0x4 + float dt; //OFS: 0xC SIZE: 0x4 + int isSet; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SavedScreenParams, 0x14); + ASSERT_STRUCT_OFFSET(SavedScreenParams, s0, 0x0); + ASSERT_STRUCT_OFFSET(SavedScreenParams, t0, 0x4); + ASSERT_STRUCT_OFFSET(SavedScreenParams, _ds, 0x8); + ASSERT_STRUCT_OFFSET(SavedScreenParams, dt, 0xC); + ASSERT_STRUCT_OFFSET(SavedScreenParams, isSet, 0x10); + + struct r_global_permanent_t + { + Material * sortedMaterials[2048]; //OFS: 0x0 SIZE: 0x2000 + int needSortMaterials; //OFS: 0x2000 SIZE: 0x4 + int materialCount; //OFS: 0x2004 SIZE: 0x4 + int needMaterialPreload; //OFS: 0x2008 SIZE: 0x4 + GfxImage * whiteImage; //OFS: 0x200C SIZE: 0x4 + GfxImage * blackImage; //OFS: 0x2010 SIZE: 0x4 + GfxImage * blankImage; //OFS: 0x2014 SIZE: 0x4 + GfxImage * grayImage; //OFS: 0x2018 SIZE: 0x4 + GfxImage * identityNormalMapImage; //OFS: 0x201C SIZE: 0x4 + GfxImage * specularityImage; //OFS: 0x2020 SIZE: 0x4 + GfxImage * outdoorImage; //OFS: 0x2024 SIZE: 0x4 + GfxImage * pixelCostColorCode; //OFS: 0x2028 SIZE: 0x4 + GfxLightDef * dlightDef; //OFS: 0x202C SIZE: 0x4 + Material * defaultMaterial; //OFS: 0x2030 SIZE: 0x4 + Material * whiteMaterial; //OFS: 0x2034 SIZE: 0x4 + Material * additiveMaterial; //OFS: 0x2038 SIZE: 0x4 + Material * additiveMaterialNoDepth; //OFS: 0x203C SIZE: 0x4 + Material * pointMaterial; //OFS: 0x2040 SIZE: 0x4 + Material * lineMaterial; //OFS: 0x2044 SIZE: 0x4 + Material * lineMaterialNoDepth; //OFS: 0x2048 SIZE: 0x4 + Material * clearAlphaMaterial; //OFS: 0x204C SIZE: 0x4 + Material * clearAlphaStencilMaterial; //OFS: 0x2050 SIZE: 0x4 + Material * shadowClearMaterial; //OFS: 0x2054 SIZE: 0x4 + Material * shadowCookieOverlayMaterial; //OFS: 0x2058 SIZE: 0x4 + Material * shadowCookieBlurMaterial; //OFS: 0x205C SIZE: 0x4 + Material * shadowCasterMaterial; //OFS: 0x2060 SIZE: 0x4 + Material * shadowOverlayMaterial; //OFS: 0x2064 SIZE: 0x4 + Material * depthPrepassMaterial; //OFS: 0x2068 SIZE: 0x4 + Material * glareBlindMaterial; //OFS: 0x206C SIZE: 0x4 + Material * lightCoronaMaterial; //OFS: 0x2070 SIZE: 0x4 + Material * pixelCostAddDepthAlwaysMaterial; //OFS: 0x2074 SIZE: 0x4 + Material * pixelCostAddDepthDisableMaterial; //OFS: 0x2078 SIZE: 0x4 + Material * pixelCostAddDepthEqualMaterial; //OFS: 0x207C SIZE: 0x4 + Material * pixelCostAddDepthLessMaterial; //OFS: 0x2080 SIZE: 0x4 + Material * pixelCostAddDepthWriteMaterial; //OFS: 0x2084 SIZE: 0x4 + Material * pixelCostAddNoDepthWriteMaterial; //OFS: 0x2088 SIZE: 0x4 + Material * pixelCostColorCodeMaterial; //OFS: 0x208C SIZE: 0x4 + Material * stencilShadowMaterial; //OFS: 0x2090 SIZE: 0x4 + Material * stencilDisplayMaterial; //OFS: 0x2094 SIZE: 0x4 + Material * floatZDisplayMaterial; //OFS: 0x2098 SIZE: 0x4 + Material * colorChannelMixerMaterial; //OFS: 0x209C SIZE: 0x4 + Material * frameColorDebugMaterial; //OFS: 0x20A0 SIZE: 0x4 + Material * frameAlphaDebugMaterial; //OFS: 0x20A4 SIZE: 0x4 + GfxImage * rawImage; //OFS: 0x20A8 SIZE: 0x4 + GfxWorld * world; //OFS: 0x20AC SIZE: 0x4 + Material * feedbackReplaceMaterial; //OFS: 0x20B0 SIZE: 0x4 + Material * feedbackBlendMaterial; //OFS: 0x20B4 SIZE: 0x4 + Material * feedbackFilmBlendMaterial; //OFS: 0x20B8 SIZE: 0x4 + Material * cinematicMaterial; //OFS: 0x20BC SIZE: 0x4 + Material * flameThrowerFXMaterial; //OFS: 0x20C0 SIZE: 0x4 + Material * waterSheetingFXMaterial; //OFS: 0x20C4 SIZE: 0x4 + Material * waterDropletMaterial; //OFS: 0x20C8 SIZE: 0x4 + Material * reviveFXMaterial; //OFS: 0x20CC SIZE: 0x4 + Material * postFxColorMaterial; //OFS: 0x20D0 SIZE: 0x4 + Material * postFxMaterial; //OFS: 0x20D4 SIZE: 0x4 + Material * poisonFXMaterial; //OFS: 0x20D8 SIZE: 0x4 + Material * symmetricFilterMaterial[8]; //OFS: 0x20DC SIZE: 0x20 + Material * godRaysFilterMaterial; //OFS: 0x20FC SIZE: 0x4 + Material * shellShockBlurredMaterial; //OFS: 0x2100 SIZE: 0x4 + Material * shellShockFlashedMaterial; //OFS: 0x2104 SIZE: 0x4 + Material * glowConsistentSetupMaterial; //OFS: 0x2108 SIZE: 0x4 + Material * glowApplyBloomMaterial; //OFS: 0x210C SIZE: 0x4 + Material * ropeMaterial; //OFS: 0x2110 SIZE: 0x4 + int savedScreenTimes[4]; //OFS: 0x2114 SIZE: 0x10 + SavedScreenParams savedScreenParams[4]; //OFS: 0x2124 SIZE: 0x50 + GfxImage * terrain_scorch_images[31]; //OFS: 0x2174 SIZE: 0x7C + GfxImage * splitscreen_sidebars; //OFS: 0x21F0 SIZE: 0x4 + char pad[140]; //OFS: 0x21F4 SIZE: 0x8C + }; + ASSERT_STRUCT_SIZE(r_global_permanent_t, 0x2280); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, sortedMaterials, 0x0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, needSortMaterials, 0x2000); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, materialCount, 0x2004); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, needMaterialPreload, 0x2008); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, whiteImage, 0x200C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, blackImage, 0x2010); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, blankImage, 0x2014); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, grayImage, 0x2018); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, identityNormalMapImage, 0x201C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, specularityImage, 0x2020); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, outdoorImage, 0x2024); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostColorCode, 0x2028); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, dlightDef, 0x202C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, defaultMaterial, 0x2030); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, whiteMaterial, 0x2034); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, additiveMaterial, 0x2038); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, additiveMaterialNoDepth, 0x203C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pointMaterial, 0x2040); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, lineMaterial, 0x2044); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, lineMaterialNoDepth, 0x2048); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, clearAlphaMaterial, 0x204C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, clearAlphaStencilMaterial, 0x2050); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shadowClearMaterial, 0x2054); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shadowCookieOverlayMaterial, 0x2058); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shadowCookieBlurMaterial, 0x205C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shadowCasterMaterial, 0x2060); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shadowOverlayMaterial, 0x2064); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, depthPrepassMaterial, 0x2068); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, glareBlindMaterial, 0x206C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, lightCoronaMaterial, 0x2070); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddDepthAlwaysMaterial, 0x2074); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddDepthDisableMaterial, 0x2078); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddDepthEqualMaterial, 0x207C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddDepthLessMaterial, 0x2080); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddDepthWriteMaterial, 0x2084); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostAddNoDepthWriteMaterial, 0x2088); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pixelCostColorCodeMaterial, 0x208C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, stencilShadowMaterial, 0x2090); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, stencilDisplayMaterial, 0x2094); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, floatZDisplayMaterial, 0x2098); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, colorChannelMixerMaterial, 0x209C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, frameColorDebugMaterial, 0x20A0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, frameAlphaDebugMaterial, 0x20A4); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, rawImage, 0x20A8); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, world, 0x20AC); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, feedbackReplaceMaterial, 0x20B0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, feedbackBlendMaterial, 0x20B4); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, feedbackFilmBlendMaterial, 0x20B8); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, cinematicMaterial, 0x20BC); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, flameThrowerFXMaterial, 0x20C0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, waterSheetingFXMaterial, 0x20C4); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, waterDropletMaterial, 0x20C8); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, reviveFXMaterial, 0x20CC); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, postFxColorMaterial, 0x20D0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, postFxMaterial, 0x20D4); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, poisonFXMaterial, 0x20D8); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, symmetricFilterMaterial, 0x20DC); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, godRaysFilterMaterial, 0x20FC); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shellShockBlurredMaterial, 0x2100); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, shellShockFlashedMaterial, 0x2104); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, glowConsistentSetupMaterial, 0x2108); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, glowApplyBloomMaterial, 0x210C); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, ropeMaterial, 0x2110); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, savedScreenTimes, 0x2114); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, savedScreenParams, 0x2124); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, terrain_scorch_images, 0x2174); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, splitscreen_sidebars, 0x21F0); + ASSERT_STRUCT_OFFSET(r_global_permanent_t, pad, 0x21F4); + + // r_globals_t + + struct BspLumpData_t + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + void * header; //OFS: 0x40 SIZE: 0x4 + unsigned int fileSize; //OFS: 0x44 SIZE: 0x4 + unsigned int checksum; //OFS: 0x48 SIZE: 0x4 + LumpType loadedLumpType; //OFS: 0x4C SIZE: 0x4 + const void * loadedLumpData; //OFS: 0x50 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BspLumpData_t, 0x54); + ASSERT_STRUCT_OFFSET(BspLumpData_t, name, 0x0); + ASSERT_STRUCT_OFFSET(BspLumpData_t, header, 0x40); + ASSERT_STRUCT_OFFSET(BspLumpData_t, fileSize, 0x44); + ASSERT_STRUCT_OFFSET(BspLumpData_t, checksum, 0x48); + ASSERT_STRUCT_OFFSET(BspLumpData_t, loadedLumpType, 0x4C); + ASSERT_STRUCT_OFFSET(BspLumpData_t, loadedLumpData, 0x50); + + struct nodespawn_t + { + char * name; //OFS: 0x0 SIZE: 0x4 + nodeType type; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(nodespawn_t, 0x8); + ASSERT_STRUCT_OFFSET(nodespawn_t, name, 0x0); + ASSERT_STRUCT_OFFSET(nodespawn_t, type, 0x4); + + struct keyname_t + { + char * name; //OFS: 0x0 SIZE: 0x4 + int keynum; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(keyname_t, 0x8); + ASSERT_STRUCT_OFFSET(keyname_t, name, 0x0); + ASSERT_STRUCT_OFFSET(keyname_t, keynum, 0x4); + + struct visField_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int offset; //OFS: 0x4 SIZE: 0x4 + int fieldType; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(visField_t, 0xC); + ASSERT_STRUCT_OFFSET(visField_t, name, 0x0); + ASSERT_STRUCT_OFFSET(visField_t, offset, 0x4); + ASSERT_STRUCT_OFFSET(visField_t, fieldType, 0x8); + + struct directive_s + { + char * name; //OFS: 0x0 SIZE: 0x4 + int (__cdecl *func)(source_s *); //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(directive_s, 0x8); + ASSERT_STRUCT_OFFSET(directive_s, name, 0x0); + ASSERT_STRUCT_OFFSET(directive_s, func, 0x4); + + struct viewLerpWaypoint_s + { + int iFrac; //OFS: 0x0 SIZE: 0x4 + float fViewHeight; //OFS: 0x4 SIZE: 0x4 + int iOffset; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(viewLerpWaypoint_s, 0xC); + ASSERT_STRUCT_OFFSET(viewLerpWaypoint_s, iFrac, 0x0); + ASSERT_STRUCT_OFFSET(viewLerpWaypoint_s, fViewHeight, 0x4); + ASSERT_STRUCT_OFFSET(viewLerpWaypoint_s, iOffset, 0x8); + + struct pmoveHandler_t + { + void (__cdecl *trace)(trace_t *, const float *, const float *, const float *, const float *, int, int, void *); //OFS: 0x0 SIZE: 0x4 + void * water; //OFS: 0x4 SIZE: 0x4 + void (__cdecl *playerEvent)(int, int); //OFS: 0x8 SIZE: 0x4 + bool (__cdecl *getEntityOriginAngles)(int, int, float *, float *); //OFS: 0xC SIZE: 0x4 + unsigned __int16 (__cdecl *getVehicleTypeString)(int, int); //OFS: 0x10 SIZE: 0x4 + void (__cdecl *entityLinkFromPMove)(int, int, const int); //OFS: 0x14 SIZE: 0x4 + int (__cdecl *getPlayerWeapon)(const playerState_s *, const int); //OFS: 0x18 SIZE: 0x4 + void (__cdecl *setVehDriverInputs)(const int, const int, usercmd_s *); //OFS: 0x1C SIZE: 0x4 + int (__cdecl *isEntWalkable)(const int, const int); //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pmoveHandler_t, 0x24); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, trace, 0x0); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, water, 0x4); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, playerEvent, 0x8); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, getEntityOriginAngles, 0xC); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, getVehicleTypeString, 0x10); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, entityLinkFromPMove, 0x14); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, getPlayerWeapon, 0x18); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, setVehDriverInputs, 0x1C); + ASSERT_STRUCT_OFFSET(pmoveHandler_t, isEntWalkable, 0x20); + + struct CustomSearchInfo_FindPath + { + pathnode_t * m_pNodeTo; //OFS: 0x0 SIZE: 0x4 + float startPos[3]; //OFS: 0x4 SIZE: 0xC + float negotiationOverlapCost; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CustomSearchInfo_FindPath, 0x14); + ASSERT_STRUCT_OFFSET(CustomSearchInfo_FindPath, m_pNodeTo, 0x0); + ASSERT_STRUCT_OFFSET(CustomSearchInfo_FindPath, startPos, 0x4); + ASSERT_STRUCT_OFFSET(CustomSearchInfo_FindPath, negotiationOverlapCost, 0x10); + + struct threat_bias_t + { + unsigned __int16 groupName[16]; //OFS: 0x0 SIZE: 0x20 + int threatTable[16][16]; //OFS: 0x20 SIZE: 0x400 + int threatGroupCount; //OFS: 0x420 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(threat_bias_t, 0x424); + ASSERT_STRUCT_OFFSET(threat_bias_t, groupName, 0x0); + ASSERT_STRUCT_OFFSET(threat_bias_t, threatTable, 0x20); + ASSERT_STRUCT_OFFSET(threat_bias_t, threatGroupCount, 0x420); + + struct nodetype + { + nodetype * left; //OFS: 0x0 SIZE: 0x4 + nodetype * right; //OFS: 0x4 SIZE: 0x4 + nodetype * parent; //OFS: 0x8 SIZE: 0x4 + int weight; //OFS: 0xC SIZE: 0x4 + int symbol; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(nodetype, 0x14); + ASSERT_STRUCT_OFFSET(nodetype, left, 0x0); + ASSERT_STRUCT_OFFSET(nodetype, right, 0x4); + ASSERT_STRUCT_OFFSET(nodetype, parent, 0x8); + ASSERT_STRUCT_OFFSET(nodetype, weight, 0xC); + ASSERT_STRUCT_OFFSET(nodetype, symbol, 0x10); + + struct huff_t + { + int blocNode; //OFS: 0x0 SIZE: 0x4 + int blocPtrs; //OFS: 0x4 SIZE: 0x4 + nodetype * tree; //OFS: 0x8 SIZE: 0x4 + nodetype * loc[257]; //OFS: 0xC SIZE: 0x404 + nodetype ** freelist; //OFS: 0x410 SIZE: 0x4 + nodetype nodeList[768]; //OFS: 0x414 SIZE: 0x3C00 + nodetype * nodePtrs[768]; //OFS: 0x4014 SIZE: 0xC00 + }; + ASSERT_STRUCT_SIZE(huff_t, 0x4C14); + ASSERT_STRUCT_OFFSET(huff_t, blocNode, 0x0); + ASSERT_STRUCT_OFFSET(huff_t, blocPtrs, 0x4); + ASSERT_STRUCT_OFFSET(huff_t, tree, 0x8); + ASSERT_STRUCT_OFFSET(huff_t, loc, 0xC); + ASSERT_STRUCT_OFFSET(huff_t, freelist, 0x410); + ASSERT_STRUCT_OFFSET(huff_t, nodeList, 0x414); + ASSERT_STRUCT_OFFSET(huff_t, nodePtrs, 0x4014); + + struct huffman_t + { + huff_t compressDecompress; //OFS: 0x0 SIZE: 0x4C14 + }; + ASSERT_STRUCT_SIZE(huffman_t, 0x4C14); + ASSERT_STRUCT_OFFSET(huffman_t, compressDecompress, 0x0); + + struct snapshotEntityNumbers_t + { + int numSnapshotEntities; //OFS: 0x0 SIZE: 0x4 + int snapshotEntities[1024]; //OFS: 0x4 SIZE: 0x1000 + }; + ASSERT_STRUCT_SIZE(snapshotEntityNumbers_t, 0x1004); + ASSERT_STRUCT_OFFSET(snapshotEntityNumbers_t, numSnapshotEntities, 0x0); + ASSERT_STRUCT_OFFSET(snapshotEntityNumbers_t, snapshotEntities, 0x4); + + struct AttractorRepulsor_t + { + bool inUse; //OFS: 0x0 SIZE: 0x1 + bool isAttractor; //OFS: 0x1 SIZE: 0x1 + int entnum; //OFS: 0x4 SIZE: 0x4 + float origin[3]; //OFS: 0x8 SIZE: 0xC + float strength; //OFS: 0x14 SIZE: 0x4 + float maxDist; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AttractorRepulsor_t, 0x1C); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, inUse, 0x0); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, isAttractor, 0x1); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, entnum, 0x4); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, origin, 0x8); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, strength, 0x14); + ASSERT_STRUCT_OFFSET(AttractorRepulsor_t, maxDist, 0x18); + + struct attrGlob_t + { + AttractorRepulsor_t attractors[32]; //OFS: 0x0 SIZE: 0x380 + }; + ASSERT_STRUCT_SIZE(attrGlob_t, 0x380); + ASSERT_STRUCT_OFFSET(attrGlob_t, attractors, 0x0); + + struct actor_physics_local_t + { + float fFrameTime; //OFS: 0x0 SIZE: 0x4 + int bIsWalking; //OFS: 0x4 SIZE: 0x4 + int bGroundPlane; //OFS: 0x8 SIZE: 0x4 + trace_t groundTrace; //OFS: 0xC SIZE: 0x34 + float fImpactSpeed; //OFS: 0x40 SIZE: 0x4 + float vPrevOrigin[3]; //OFS: 0x44 SIZE: 0xC + float vPrevVelocity[3]; //OFS: 0x50 SIZE: 0xC + int iTraceMask; //OFS: 0x5C SIZE: 0x4 + float stepheight; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(actor_physics_local_t, 0x64); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, fFrameTime, 0x0); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, bIsWalking, 0x4); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, bGroundPlane, 0x8); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, groundTrace, 0xC); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, fImpactSpeed, 0x40); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, vPrevOrigin, 0x44); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, vPrevVelocity, 0x50); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, iTraceMask, 0x5C); + ASSERT_STRUCT_OFFSET(actor_physics_local_t, stepheight, 0x60); + + struct ai_funcs_t + { + bool (__cdecl *pfnStart)(actor_s *pSelf, ai_state_t ePrevState); //OFS: 0x0 SIZE: 0x4 + void (__cdecl *pfnFinish)(actor_s *pSelf, ai_state_t eNextState); //OFS: 0x4 SIZE: 0x4 + void (__cdecl *pfnSuspend)(actor_s *pSelf, ai_state_t eNextState); //OFS: 0x8 SIZE: 0x4 + bool (__cdecl *pfnResume)(actor_s *pSelf, ai_state_t ePrevState); //OFS: 0xC SIZE: 0x4 + actor_think_result_t (__cdecl *pfnThink)(actor_s *pSelf); //OFS: 0x10 SIZE: 0x4 + void (__cdecl *pfnTouch)(actor_s *pSelf, gentity_s *pOther); //OFS: 0x14 SIZE: 0x4 + void (__cdecl *pfnPain)(actor_s *pSelf, gentity_s *pAttacker, int iDamage, float *vPoint, int iMod, float *vDir, hitLocation_t hitLoc); //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ai_funcs_t, 0x1C); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnStart, 0x0); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnFinish, 0x4); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnSuspend, 0x8); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnResume, 0xC); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnThink, 0x10); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnTouch, 0x14); + ASSERT_STRUCT_OFFSET(ai_funcs_t, pfnPain, 0x18); + + struct AimTarget + { + int entIndex; //OFS: 0x0 SIZE: 0x4 + float worldDistSqr; //OFS: 0x4 SIZE: 0x4 + float mins[3]; //OFS: 0x8 SIZE: 0xC + float maxs[3]; //OFS: 0x14 SIZE: 0xC + float velocity[3]; //OFS: 0x20 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(AimTarget, 0x2C); + ASSERT_STRUCT_OFFSET(AimTarget, entIndex, 0x0); + ASSERT_STRUCT_OFFSET(AimTarget, worldDistSqr, 0x4); + ASSERT_STRUCT_OFFSET(AimTarget, mins, 0x8); + ASSERT_STRUCT_OFFSET(AimTarget, maxs, 0x14); + ASSERT_STRUCT_OFFSET(AimTarget, velocity, 0x20); + + struct AimTargetGlob + { + AimTarget targets[64]; //OFS: 0x0 SIZE: 0xB00 + int targetCount; //OFS: 0xB00 SIZE: 0x4 + AimTarget clientTargets[64]; //OFS: 0xB04 SIZE: 0xB00 + int clientTargetCount; //OFS: 0x1604 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(AimTargetGlob, 0x1608); + ASSERT_STRUCT_OFFSET(AimTargetGlob, targets, 0x0); + ASSERT_STRUCT_OFFSET(AimTargetGlob, targetCount, 0xB00); + ASSERT_STRUCT_OFFSET(AimTargetGlob, clientTargets, 0xB04); + ASSERT_STRUCT_OFFSET(AimTargetGlob, clientTargetCount, 0x1604); + + struct cent_field_s + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int ofs; //OFS: 0x4 SIZE: 0x4 + fieldtype_t type; //OFS: 0x8 SIZE: 0x4 + void (__cdecl *setter)(centity_s *, const cent_field_s *); //OFS: 0xC SIZE: 0x4 + void (__cdecl *getter)(centity_s *, const cent_field_s *); //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cent_field_s, 0x14); + ASSERT_STRUCT_OFFSET(cent_field_s, name, 0x0); + ASSERT_STRUCT_OFFSET(cent_field_s, ofs, 0x4); + ASSERT_STRUCT_OFFSET(cent_field_s, type, 0x8); + ASSERT_STRUCT_OFFSET(cent_field_s, setter, 0xC); + ASSERT_STRUCT_OFFSET(cent_field_s, getter, 0x10); + + struct ThreadDebugInfo + { + const char * pos[32]; //OFS: 0x0 SIZE: 0x80 + int posSize; //OFS: 0x80 SIZE: 0x4 + float varUsage; //OFS: 0x84 SIZE: 0x4 + float endonUsage; //OFS: 0x88 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ThreadDebugInfo, 0x8C); + ASSERT_STRUCT_OFFSET(ThreadDebugInfo, pos, 0x0); + ASSERT_STRUCT_OFFSET(ThreadDebugInfo, posSize, 0x80); + ASSERT_STRUCT_OFFSET(ThreadDebugInfo, varUsage, 0x84); + ASSERT_STRUCT_OFFSET(ThreadDebugInfo, endonUsage, 0x88); + + struct configstringBundle + { + int index; //OFS: 0x0 SIZE: 0x4 + char * val; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(configstringBundle, 0x8); + ASSERT_STRUCT_OFFSET(configstringBundle, index, 0x0); + ASSERT_STRUCT_OFFSET(configstringBundle, val, 0x4); + + struct fake_centity_s + { + unsigned int flags; //OFS: 0x0 SIZE: 0x4 + snd_alias_t * soundAliasPtr; //OFS: 0x4 SIZE: 0x4 + centity_s cent; //OFS: 0x8 SIZE: 0x2D4 + char soundAlias[64]; //OFS: 0x2DC SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(fake_centity_s, 0x31C); + ASSERT_STRUCT_OFFSET(fake_centity_s, flags, 0x0); + ASSERT_STRUCT_OFFSET(fake_centity_s, soundAliasPtr, 0x4); + ASSERT_STRUCT_OFFSET(fake_centity_s, cent, 0x8); + ASSERT_STRUCT_OFFSET(fake_centity_s, soundAlias, 0x2DC); + + struct LayeredTechniqueSetName + { + const char * inputName; //OFS: 0x0 SIZE: 0x4 + const char * namePrefixRegister; //OFS: 0x4 SIZE: 0x4 + const char * namePrefixGenerate; //OFS: 0x8 SIZE: 0x4 + const char * nameChunk; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LayeredTechniqueSetName, 0x10); + ASSERT_STRUCT_OFFSET(LayeredTechniqueSetName, inputName, 0x0); + ASSERT_STRUCT_OFFSET(LayeredTechniqueSetName, namePrefixRegister, 0x4); + ASSERT_STRUCT_OFFSET(LayeredTechniqueSetName, namePrefixGenerate, 0x8); + ASSERT_STRUCT_OFFSET(LayeredTechniqueSetName, nameChunk, 0xC); + + struct cgMedia_t + { + Material * whiteMaterial; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + int field_8; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + int field_10; //OFS: 0x10 SIZE: 0x4 + int field_14; //OFS: 0x14 SIZE: 0x4 + int field_18; //OFS: 0x18 SIZE: 0x4 + int field_1C; //OFS: 0x1C SIZE: 0x4 + int field_20; //OFS: 0x20 SIZE: 0x4 + int field_24; //OFS: 0x24 SIZE: 0x4 + int field_28; //OFS: 0x28 SIZE: 0x4 + int field_2C; //OFS: 0x2C SIZE: 0x4 + int field_30[3]; //OFS: 0x30 SIZE: 0xC + int field_3C; //OFS: 0x3C SIZE: 0x4 + int field_40; //OFS: 0x40 SIZE: 0x4 + int field_44; //OFS: 0x44 SIZE: 0x4 + int field_48[129]; //OFS: 0x48 SIZE: 0x204 + int field_24C; //OFS: 0x24C SIZE: 0x4 + int field_250; //OFS: 0x250 SIZE: 0x4 + int field_254; //OFS: 0x254 SIZE: 0x4 + int field_258; //OFS: 0x258 SIZE: 0x4 + int field_25C; //OFS: 0x25C SIZE: 0x4 + int field_260[1]; //OFS: 0x260 SIZE: 0x4 + int field_264; //OFS: 0x264 SIZE: 0x4 + int field_268; //OFS: 0x268 SIZE: 0x4 + int field_26C; //OFS: 0x26C SIZE: 0x4 + int field_270; //OFS: 0x270 SIZE: 0x4 + int field_274; //OFS: 0x274 SIZE: 0x4 + int field_278; //OFS: 0x278 SIZE: 0x4 + int field_27C; //OFS: 0x27C SIZE: 0x4 + int field_280; //OFS: 0x280 SIZE: 0x4 + int cgMedia_smallDevFont; //OFS: 0x284 SIZE: 0x4 + int field_288; //OFS: 0x288 SIZE: 0x4 + int field_28C; //OFS: 0x28C SIZE: 0x4 + int field_290; //OFS: 0x290 SIZE: 0x4 + int field_294[31]; //OFS: 0x294 SIZE: 0x7C + int field_310[31]; //OFS: 0x310 SIZE: 0x7C + int field_38C[31]; //OFS: 0x38C SIZE: 0x7C + int field_408[31]; //OFS: 0x408 SIZE: 0x7C + int field_484[1]; //OFS: 0x484 SIZE: 0x4 + char field_488[120]; //OFS: 0x488 SIZE: 0x78 + int field_500[31]; //OFS: 0x500 SIZE: 0x7C + int field_57C[31]; //OFS: 0x57C SIZE: 0x7C + int field_5F8[31]; //OFS: 0x5F8 SIZE: 0x7C + int field_674[31]; //OFS: 0x674 SIZE: 0x7C + int field_6F0[31]; //OFS: 0x6F0 SIZE: 0x7C + int field_76C[31]; //OFS: 0x76C SIZE: 0x7C + int field_7E8[31]; //OFS: 0x7E8 SIZE: 0x7C + int field_864[31]; //OFS: 0x864 SIZE: 0x7C + int field_8E0[31]; //OFS: 0x8E0 SIZE: 0x7C + _DWORD field_95C[31]; //OFS: 0x95C SIZE: 0x7C + int field_9D8[31]; //OFS: 0x9D8 SIZE: 0x7C + _DWORD field_A54[31]; //OFS: 0xA54 SIZE: 0x7C + int field_AD0[31]; //OFS: 0xAD0 SIZE: 0x7C + _DWORD field_B4C[31]; //OFS: 0xB4C SIZE: 0x7C + int field_BC8[31]; //OFS: 0xBC8 SIZE: 0x7C + _DWORD field_C44[31]; //OFS: 0xC44 SIZE: 0x7C + int field_CC0[31]; //OFS: 0xCC0 SIZE: 0x7C + _DWORD field_D3C[31]; //OFS: 0xD3C SIZE: 0x7C + int field_DB8[31]; //OFS: 0xDB8 SIZE: 0x7C + _DWORD field_E34[24]; //OFS: 0xE34 SIZE: 0x60 + int field_E94[7]; //OFS: 0xE94 SIZE: 0x1C + int field_EB0[24]; //OFS: 0xEB0 SIZE: 0x60 + int field_F10[7]; //OFS: 0xF10 SIZE: 0x1C + _DWORD field_F2C[24]; //OFS: 0xF2C SIZE: 0x60 + int field_F8C[7]; //OFS: 0xF8C SIZE: 0x1C + int field_FA8[24]; //OFS: 0xFA8 SIZE: 0x60 + int field_1008[7]; //OFS: 0x1008 SIZE: 0x1C + _DWORD field_1024[31]; //OFS: 0x1024 SIZE: 0x7C + _DWORD field_10A0[31]; //OFS: 0x10A0 SIZE: 0x7C + _DWORD field_111C[31]; //OFS: 0x111C SIZE: 0x7C + _DWORD field_1198[31]; //OFS: 0x1198 SIZE: 0x7C + _DWORD field_1214[31]; //OFS: 0x1214 SIZE: 0x7C + int field_1290; //OFS: 0x1290 SIZE: 0x4 + int field_1294; //OFS: 0x1294 SIZE: 0x4 + int field_1298; //OFS: 0x1298 SIZE: 0x4 + int field_129C; //OFS: 0x129C SIZE: 0x4 + int field_12A0; //OFS: 0x12A0 SIZE: 0x4 + int field_12A4; //OFS: 0x12A4 SIZE: 0x4 + int field_12A8; //OFS: 0x12A8 SIZE: 0x4 + int field_12AC; //OFS: 0x12AC SIZE: 0x4 + int field_12B0; //OFS: 0x12B0 SIZE: 0x4 + int field_12B4; //OFS: 0x12B4 SIZE: 0x4 + int field_12B8; //OFS: 0x12B8 SIZE: 0x4 + int field_12BC; //OFS: 0x12BC SIZE: 0x4 + int field_12C0; //OFS: 0x12C0 SIZE: 0x4 + int field_12C4; //OFS: 0x12C4 SIZE: 0x4 + int field_12C8; //OFS: 0x12C8 SIZE: 0x4 + int field_12CC; //OFS: 0x12CC SIZE: 0x4 + int field_12D0; //OFS: 0x12D0 SIZE: 0x4 + int field_12D4; //OFS: 0x12D4 SIZE: 0x4 + int field_12D8; //OFS: 0x12D8 SIZE: 0x4 + int field_12DC; //OFS: 0x12DC SIZE: 0x4 + int field_12E0; //OFS: 0x12E0 SIZE: 0x4 + int field_12E4; //OFS: 0x12E4 SIZE: 0x4 + int field_12E8; //OFS: 0x12E8 SIZE: 0x4 + int field_12EC; //OFS: 0x12EC SIZE: 0x4 + int field_12F0; //OFS: 0x12F0 SIZE: 0x4 + int field_12F4; //OFS: 0x12F4 SIZE: 0x4 + int field_12F8; //OFS: 0x12F8 SIZE: 0x4 + int field_12FC; //OFS: 0x12FC SIZE: 0x4 + int field_1300; //OFS: 0x1300 SIZE: 0x4 + int field_1304; //OFS: 0x1304 SIZE: 0x4 + _DWORD field_1308[1550]; //OFS: 0x1308 SIZE: 0x1838 + int field_2B40; //OFS: 0x2B40 SIZE: 0x4 + int field_2B44; //OFS: 0x2B44 SIZE: 0x4 + int field_2B48; //OFS: 0x2B48 SIZE: 0x4 + int field_2B4C; //OFS: 0x2B4C SIZE: 0x4 + int field_2B50; //OFS: 0x2B50 SIZE: 0x4 + int field_2B54; //OFS: 0x2B54 SIZE: 0x4 + int field_2B58; //OFS: 0x2B58 SIZE: 0x4 + int field_2B5C; //OFS: 0x2B5C SIZE: 0x4 + int field_2B60; //OFS: 0x2B60 SIZE: 0x4 + int field_2B64; //OFS: 0x2B64 SIZE: 0x4 + int field_2B68; //OFS: 0x2B68 SIZE: 0x4 + int field_2B6C; //OFS: 0x2B6C SIZE: 0x4 + int field_2B70; //OFS: 0x2B70 SIZE: 0x4 + int field_2B74; //OFS: 0x2B74 SIZE: 0x4 + int field_2B78; //OFS: 0x2B78 SIZE: 0x4 + int field_2B7C; //OFS: 0x2B7C SIZE: 0x4 + _BYTE gap2B80[8]; //OFS: 0x2B80 SIZE: 0x8 + int field_2B88; //OFS: 0x2B88 SIZE: 0x4 + int field_2B8C; //OFS: 0x2B8C SIZE: 0x4 + int field_2B90; //OFS: 0x2B90 SIZE: 0x4 + Material * hud_grenadeicon; //OFS: 0x2B94 SIZE: 0x4 + Material * hud_flashbangicon; //OFS: 0x2B98 SIZE: 0x4 + Material * hud_grenadethrowback; //OFS: 0x2B9C SIZE: 0x4 + int hud_grenadepointer; //OFS: 0x2BA0 SIZE: 0x4 + int field_2BA4; //OFS: 0x2BA4 SIZE: 0x4 + int field_2BA8; //OFS: 0x2BA8 SIZE: 0x4 + Material * offscreenObjectivePointer; //OFS: 0x2BAC SIZE: 0x4 + int field_2BB0; //OFS: 0x2BB0 SIZE: 0x4 + char field_2BB4[4]; //OFS: 0x2BB4 SIZE: 0x4 + int field_2BB8; //OFS: 0x2BB8 SIZE: 0x4 + int field_2BBC; //OFS: 0x2BBC SIZE: 0x4 + int field_2BC0; //OFS: 0x2BC0 SIZE: 0x4 + int field_2BC4; //OFS: 0x2BC4 SIZE: 0x4 + int field_2BC8; //OFS: 0x2BC8 SIZE: 0x4 + int field_2BCC; //OFS: 0x2BCC SIZE: 0x4 + int field_2BD0; //OFS: 0x2BD0 SIZE: 0x4 + int field_2BD4; //OFS: 0x2BD4 SIZE: 0x4 + int field_2BD8; //OFS: 0x2BD8 SIZE: 0x4 + int field_2BDC; //OFS: 0x2BDC SIZE: 0x4 + int field_2BE0; //OFS: 0x2BE0 SIZE: 0x4 + int field_2BE4; //OFS: 0x2BE4 SIZE: 0x4 + int field_2BE8; //OFS: 0x2BE8 SIZE: 0x4 + int field_2BEC; //OFS: 0x2BEC SIZE: 0x4 + int field_2BF0; //OFS: 0x2BF0 SIZE: 0x4 + int field_2BF4; //OFS: 0x2BF4 SIZE: 0x4 + int field_2BF8; //OFS: 0x2BF8 SIZE: 0x4 + int nightVisionOverlay; //OFS: 0x2BFC SIZE: 0x4 + _BYTE gap2C00[4]; //OFS: 0x2C00 SIZE: 0x4 + int field_2C04; //OFS: 0x2C04 SIZE: 0x4 + int field_2C08; //OFS: 0x2C08 SIZE: 0x4 + int field_2C0C; //OFS: 0x2C0C SIZE: 0x4 + int field_2C10; //OFS: 0x2C10 SIZE: 0x4 + int field_2C14; //OFS: 0x2C14 SIZE: 0x4 + int field_2C18; //OFS: 0x2C18 SIZE: 0x4 + int field_2C1C; //OFS: 0x2C1C SIZE: 0x4 + Material * textDecodeCharacters; //OFS: 0x2C20 SIZE: 0x4 + Material * textDecodeCharactersGlow; //OFS: 0x2C24 SIZE: 0x4 + _BYTE gap2C28[32]; //OFS: 0x2C28 SIZE: 0x20 + int field_2C48[1]; //OFS: 0x2C48 SIZE: 0x4 + int field_2C4C; //OFS: 0x2C4C SIZE: 0x4 + int field_2C50; //OFS: 0x2C50 SIZE: 0x4 + int field_2C54; //OFS: 0x2C54 SIZE: 0x4 + int field_2C58; //OFS: 0x2C58 SIZE: 0x4 + int field_2C5C; //OFS: 0x2C5C SIZE: 0x4 + int field_2C60; //OFS: 0x2C60 SIZE: 0x4 + int field_2C64; //OFS: 0x2C64 SIZE: 0x4 + int field_2C68; //OFS: 0x2C68 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cgMedia_t, 0x2C6C); + ASSERT_STRUCT_OFFSET(cgMedia_t, whiteMaterial, 0x0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_4, 0x4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_8, 0x8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_C, 0xC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_10, 0x10); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_14, 0x14); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_18, 0x18); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1C, 0x1C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_20, 0x20); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_24, 0x24); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_28, 0x28); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C, 0x2C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_30, 0x30); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_3C, 0x3C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_40, 0x40); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_44, 0x44); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_48, 0x48); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_24C, 0x24C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_250, 0x250); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_254, 0x254); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_258, 0x258); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_25C, 0x25C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_260, 0x260); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_264, 0x264); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_268, 0x268); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_26C, 0x26C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_270, 0x270); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_274, 0x274); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_278, 0x278); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_27C, 0x27C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_280, 0x280); + ASSERT_STRUCT_OFFSET(cgMedia_t, cgMedia_smallDevFont, 0x284); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_288, 0x288); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_28C, 0x28C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_290, 0x290); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_294, 0x294); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_310, 0x310); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_38C, 0x38C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_408, 0x408); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_484, 0x484); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_488, 0x488); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_500, 0x500); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_57C, 0x57C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_5F8, 0x5F8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_674, 0x674); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_6F0, 0x6F0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_76C, 0x76C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_7E8, 0x7E8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_864, 0x864); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_8E0, 0x8E0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_95C, 0x95C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_9D8, 0x9D8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_A54, 0xA54); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_AD0, 0xAD0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_B4C, 0xB4C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_BC8, 0xBC8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_C44, 0xC44); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_CC0, 0xCC0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_D3C, 0xD3C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_DB8, 0xDB8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_E34, 0xE34); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_E94, 0xE94); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_EB0, 0xEB0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_F10, 0xF10); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_F2C, 0xF2C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_F8C, 0xF8C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_FA8, 0xFA8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1008, 0x1008); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1024, 0x1024); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_10A0, 0x10A0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_111C, 0x111C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1198, 0x1198); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1214, 0x1214); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1290, 0x1290); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1294, 0x1294); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1298, 0x1298); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_129C, 0x129C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12A0, 0x12A0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12A4, 0x12A4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12A8, 0x12A8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12AC, 0x12AC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12B0, 0x12B0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12B4, 0x12B4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12B8, 0x12B8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12BC, 0x12BC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12C0, 0x12C0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12C4, 0x12C4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12C8, 0x12C8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12CC, 0x12CC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12D0, 0x12D0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12D4, 0x12D4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12D8, 0x12D8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12DC, 0x12DC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12E0, 0x12E0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12E4, 0x12E4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12E8, 0x12E8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12EC, 0x12EC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12F0, 0x12F0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12F4, 0x12F4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12F8, 0x12F8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_12FC, 0x12FC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1300, 0x1300); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1304, 0x1304); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_1308, 0x1308); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B40, 0x2B40); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B44, 0x2B44); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B48, 0x2B48); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B4C, 0x2B4C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B50, 0x2B50); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B54, 0x2B54); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B58, 0x2B58); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B5C, 0x2B5C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B60, 0x2B60); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B64, 0x2B64); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B68, 0x2B68); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B6C, 0x2B6C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B70, 0x2B70); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B74, 0x2B74); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B78, 0x2B78); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B7C, 0x2B7C); + ASSERT_STRUCT_OFFSET(cgMedia_t, gap2B80, 0x2B80); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B88, 0x2B88); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B8C, 0x2B8C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2B90, 0x2B90); + ASSERT_STRUCT_OFFSET(cgMedia_t, hud_grenadeicon, 0x2B94); + ASSERT_STRUCT_OFFSET(cgMedia_t, hud_flashbangicon, 0x2B98); + ASSERT_STRUCT_OFFSET(cgMedia_t, hud_grenadethrowback, 0x2B9C); + ASSERT_STRUCT_OFFSET(cgMedia_t, hud_grenadepointer, 0x2BA0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BA4, 0x2BA4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BA8, 0x2BA8); + ASSERT_STRUCT_OFFSET(cgMedia_t, offscreenObjectivePointer, 0x2BAC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BB0, 0x2BB0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BB4, 0x2BB4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BB8, 0x2BB8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BBC, 0x2BBC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BC0, 0x2BC0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BC4, 0x2BC4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BC8, 0x2BC8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BCC, 0x2BCC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BD0, 0x2BD0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BD4, 0x2BD4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BD8, 0x2BD8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BDC, 0x2BDC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BE0, 0x2BE0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BE4, 0x2BE4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BE8, 0x2BE8); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BEC, 0x2BEC); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BF0, 0x2BF0); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BF4, 0x2BF4); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2BF8, 0x2BF8); + ASSERT_STRUCT_OFFSET(cgMedia_t, nightVisionOverlay, 0x2BFC); + ASSERT_STRUCT_OFFSET(cgMedia_t, gap2C00, 0x2C00); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C04, 0x2C04); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C08, 0x2C08); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C0C, 0x2C0C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C10, 0x2C10); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C14, 0x2C14); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C18, 0x2C18); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C1C, 0x2C1C); + ASSERT_STRUCT_OFFSET(cgMedia_t, textDecodeCharacters, 0x2C20); + ASSERT_STRUCT_OFFSET(cgMedia_t, textDecodeCharactersGlow, 0x2C24); + ASSERT_STRUCT_OFFSET(cgMedia_t, gap2C28, 0x2C28); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C48, 0x2C48); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C4C, 0x2C4C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C50, 0x2C50); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C54, 0x2C54); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C58, 0x2C58); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C5C, 0x2C5C); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C60, 0x2C60); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C64, 0x2C64); + ASSERT_STRUCT_OFFSET(cgMedia_t, field_2C68, 0x2C68); + + struct gitem_s + { + itemType_t giType; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(gitem_s, 0x4); + ASSERT_STRUCT_OFFSET(gitem_s, giType, 0x0); + + struct weaponInfo_s + { + DObj_s * viewModelDObj; //OFS: 0x0 SIZE: 0x4 + XModel * handModel; //OFS: 0x4 SIZE: 0x4 + XModel * gogglesModel; //OFS: 0x8 SIZE: 0x4 + XModel * rocketModel; //OFS: 0xC SIZE: 0x4 + XModel * knifeModel; //OFS: 0x10 SIZE: 0x4 + unsigned __int8 weapModelIdx; //OFS: 0x14 SIZE: 0x1 + unsigned int partBits[4]; //OFS: 0x18 SIZE: 0x10 + int iPrevAnim; //OFS: 0x28 SIZE: 0x4 + int hasAnimTree; //OFS: 0x2C SIZE: 0x4 + XAnimTree_s * tree; //OFS: 0x30 SIZE: 0x4 + int registered; //OFS: 0x34 SIZE: 0x4 + gitem_s * item; //OFS: 0x38 SIZE: 0x4 + char * translatedDisplayName; //OFS: 0x3C SIZE: 0x4 + char * translatedModename; //OFS: 0x40 SIZE: 0x4 + char * translatedAIOverlayDescription; //OFS: 0x44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(weaponInfo_s, 0x48); + ASSERT_STRUCT_OFFSET(weaponInfo_s, viewModelDObj, 0x0); + ASSERT_STRUCT_OFFSET(weaponInfo_s, handModel, 0x4); + ASSERT_STRUCT_OFFSET(weaponInfo_s, gogglesModel, 0x8); + ASSERT_STRUCT_OFFSET(weaponInfo_s, rocketModel, 0xC); + ASSERT_STRUCT_OFFSET(weaponInfo_s, knifeModel, 0x10); + ASSERT_STRUCT_OFFSET(weaponInfo_s, weapModelIdx, 0x14); + ASSERT_STRUCT_OFFSET(weaponInfo_s, partBits, 0x18); + ASSERT_STRUCT_OFFSET(weaponInfo_s, iPrevAnim, 0x28); + ASSERT_STRUCT_OFFSET(weaponInfo_s, hasAnimTree, 0x2C); + ASSERT_STRUCT_OFFSET(weaponInfo_s, tree, 0x30); + ASSERT_STRUCT_OFFSET(weaponInfo_s, registered, 0x34); + ASSERT_STRUCT_OFFSET(weaponInfo_s, item, 0x38); + ASSERT_STRUCT_OFFSET(weaponInfo_s, translatedDisplayName, 0x3C); + ASSERT_STRUCT_OFFSET(weaponInfo_s, translatedModename, 0x40); + ASSERT_STRUCT_OFFSET(weaponInfo_s, translatedAIOverlayDescription, 0x44); + + struct CompassVehicle + { + int entityNum; //OFS: 0x0 SIZE: 0x4 + int lastUpdate; //OFS: 0x4 SIZE: 0x4 + float lastPos[2]; //OFS: 0x8 SIZE: 0x8 + float lastYaw; //OFS: 0x10 SIZE: 0x4 + int drawOnCompass; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CompassVehicle, 0x18); + ASSERT_STRUCT_OFFSET(CompassVehicle, entityNum, 0x0); + ASSERT_STRUCT_OFFSET(CompassVehicle, lastUpdate, 0x4); + ASSERT_STRUCT_OFFSET(CompassVehicle, lastPos, 0x8); + ASSERT_STRUCT_OFFSET(CompassVehicle, lastYaw, 0x10); + ASSERT_STRUCT_OFFSET(CompassVehicle, drawOnCompass, 0x14); + + struct CompassActor + { + int lastUpdate; //OFS: 0x0 SIZE: 0x4 + float lastPos[2]; //OFS: 0x4 SIZE: 0x8 + float lastYaw; //OFS: 0xC SIZE: 0x4 + int beginFadeTime; //OFS: 0x10 SIZE: 0x4 + bool enemy; //OFS: 0x14 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(CompassActor, 0x18); + ASSERT_STRUCT_OFFSET(CompassActor, lastUpdate, 0x0); + ASSERT_STRUCT_OFFSET(CompassActor, lastPos, 0x4); + ASSERT_STRUCT_OFFSET(CompassActor, lastYaw, 0xC); + ASSERT_STRUCT_OFFSET(CompassActor, beginFadeTime, 0x10); + ASSERT_STRUCT_OFFSET(CompassActor, enemy, 0x14); + + struct DeferredMsg + { + unsigned __int8 data[1264]; //OFS: 0x0 SIZE: 0x4F0 + int datalen; //OFS: 0x4F0 SIZE: 0x4 + int j; //OFS: 0x4F4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DeferredMsg, 0x4F8); + ASSERT_STRUCT_OFFSET(DeferredMsg, data, 0x0); + ASSERT_STRUCT_OFFSET(DeferredMsg, datalen, 0x4F0); + ASSERT_STRUCT_OFFSET(DeferredMsg, j, 0x4F4); + + struct DeferredQueue + { + DeferredMsg msgs[16]; //OFS: 0x0 SIZE: 0x4F80 + int get; //OFS: 0x4F80 SIZE: 0x4 + int send; //OFS: 0x4F84 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DeferredQueue, 0x4F88); + ASSERT_STRUCT_OFFSET(DeferredQueue, msgs, 0x0); + ASSERT_STRUCT_OFFSET(DeferredQueue, get, 0x4F80); + ASSERT_STRUCT_OFFSET(DeferredQueue, send, 0x4F84); + + struct struc_838200 + { + int field_0; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + void * field_8; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(struc_838200, 0x10); + ASSERT_STRUCT_OFFSET(struc_838200, field_0, 0x0); + ASSERT_STRUCT_OFFSET(struc_838200, field_4, 0x4); + ASSERT_STRUCT_OFFSET(struc_838200, field_8, 0x8); + ASSERT_STRUCT_OFFSET(struc_838200, field_C, 0xC); + + struct ClientVoicePacket_t + { + char data[256]; //OFS: 0x0 SIZE: 0x100 + int dataSize; //OFS: 0x100 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ClientVoicePacket_t, 0x104); + ASSERT_STRUCT_OFFSET(ClientVoicePacket_t, data, 0x0); + ASSERT_STRUCT_OFFSET(ClientVoicePacket_t, dataSize, 0x100); + + struct voiceCommunication_t + { + ClientVoicePacket_t voicePackets[10]; //OFS: 0x0 SIZE: 0xA28 + int voicePacketCount; //OFS: 0xA28 SIZE: 0x4 + int voicePacketLastTransmit; //OFS: 0xA2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(voiceCommunication_t, 0xA30); + ASSERT_STRUCT_OFFSET(voiceCommunication_t, voicePackets, 0x0); + ASSERT_STRUCT_OFFSET(voiceCommunication_t, voicePacketCount, 0xA28); + ASSERT_STRUCT_OFFSET(voiceCommunication_t, voicePacketLastTransmit, 0xA2C); + + struct __declspec(align(2)) EntHandleList + { + unsigned __int16 infoIndex; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(EntHandleList, 0x2); + ASSERT_STRUCT_OFFSET(EntHandleList, infoIndex, 0x0); + + struct GfxEntity + { + unsigned int renderFxFlags; //OFS: 0x0 SIZE: 0x4 + float materialTime; //OFS: 0x4 SIZE: 0x4 + float destructibleBurnAmount; //OFS: 0x8 SIZE: 0x4 + float destructibleFadeAmount; //OFS: 0xC SIZE: 0x4 + float modelRadius; //OFS: 0x10 SIZE: 0x4 + float wetness; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxEntity, 0x18); + ASSERT_STRUCT_OFFSET(GfxEntity, renderFxFlags, 0x0); + ASSERT_STRUCT_OFFSET(GfxEntity, materialTime, 0x4); + ASSERT_STRUCT_OFFSET(GfxEntity, destructibleBurnAmount, 0x8); + ASSERT_STRUCT_OFFSET(GfxEntity, destructibleFadeAmount, 0xC); + ASSERT_STRUCT_OFFSET(GfxEntity, modelRadius, 0x10); + ASSERT_STRUCT_OFFSET(GfxEntity, wetness, 0x14); + + struct localEntity_s + { + localEntity_s * prev; //OFS: 0x0 SIZE: 0x4 + localEntity_s * next; //OFS: 0x4 SIZE: 0x4 + leType_t leType; //OFS: 0x8 SIZE: 0x4 + int endTime; //OFS: 0xC SIZE: 0x4 + trajectory_t pos; //OFS: 0x10 SIZE: 0x24 + float color[4]; //OFS: 0x34 SIZE: 0x10 + float tracerClipDist; //OFS: 0x44 SIZE: 0x4 + GfxEntity refEntity; //OFS: 0x48 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(localEntity_s, 0x60); + ASSERT_STRUCT_OFFSET(localEntity_s, prev, 0x0); + ASSERT_STRUCT_OFFSET(localEntity_s, next, 0x4); + ASSERT_STRUCT_OFFSET(localEntity_s, leType, 0x8); + ASSERT_STRUCT_OFFSET(localEntity_s, endTime, 0xC); + ASSERT_STRUCT_OFFSET(localEntity_s, pos, 0x10); + ASSERT_STRUCT_OFFSET(localEntity_s, color, 0x34); + ASSERT_STRUCT_OFFSET(localEntity_s, tracerClipDist, 0x44); + ASSERT_STRUCT_OFFSET(localEntity_s, refEntity, 0x48); + + struct lagometer_t + { + int frameSamples[128]; //OFS: 0x0 SIZE: 0x200 + int frameCount; //OFS: 0x200 SIZE: 0x4 + int snapshotFlags[128]; //OFS: 0x204 SIZE: 0x200 + int snapshotSamples[128]; //OFS: 0x404 SIZE: 0x200 + int snapshotCount; //OFS: 0x604 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(lagometer_t, 0x608); + ASSERT_STRUCT_OFFSET(lagometer_t, frameSamples, 0x0); + ASSERT_STRUCT_OFFSET(lagometer_t, frameCount, 0x200); + ASSERT_STRUCT_OFFSET(lagometer_t, snapshotFlags, 0x204); + ASSERT_STRUCT_OFFSET(lagometer_t, snapshotSamples, 0x404); + ASSERT_STRUCT_OFFSET(lagometer_t, snapshotCount, 0x604); + + struct serverStatus_s + { + char string[8192]; //OFS: 0x0 SIZE: 0x2000 + netadr_s address; //OFS: 0x2000 SIZE: 0x18 + int time; //OFS: 0x2018 SIZE: 0x4 + int startTime; //OFS: 0x201C SIZE: 0x4 + int pending; //OFS: 0x2020 SIZE: 0x4 + int print; //OFS: 0x2024 SIZE: 0x4 + int retrieved; //OFS: 0x2028 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(serverStatus_s, 0x202C); + ASSERT_STRUCT_OFFSET(serverStatus_s, string, 0x0); + ASSERT_STRUCT_OFFSET(serverStatus_s, address, 0x2000); + ASSERT_STRUCT_OFFSET(serverStatus_s, time, 0x2018); + ASSERT_STRUCT_OFFSET(serverStatus_s, startTime, 0x201C); + ASSERT_STRUCT_OFFSET(serverStatus_s, pending, 0x2020); + ASSERT_STRUCT_OFFSET(serverStatus_s, print, 0x2024); + ASSERT_STRUCT_OFFSET(serverStatus_s, retrieved, 0x2028); + + struct ClientSnapshotData + { + int snapshotSize[8]; //OFS: 0x0 SIZE: 0x20 + int compressedSize[8]; //OFS: 0x20 SIZE: 0x20 + int index; //OFS: 0x40 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ClientSnapshotData, 0x44); + ASSERT_STRUCT_OFFSET(ClientSnapshotData, snapshotSize, 0x0); + ASSERT_STRUCT_OFFSET(ClientSnapshotData, compressedSize, 0x20); + ASSERT_STRUCT_OFFSET(ClientSnapshotData, index, 0x40); + + struct hunkUsed_t + { + int permanent; //OFS: 0x0 SIZE: 0x4 + int temp; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(hunkUsed_t, 0x8); + ASSERT_STRUCT_OFFSET(hunkUsed_t, permanent, 0x0); + ASSERT_STRUCT_OFFSET(hunkUsed_t, temp, 0x4); + + struct struc_21AC318 + { + int com_list_cache; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + int field_8; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(struc_21AC318, 0xC); + ASSERT_STRUCT_OFFSET(struc_21AC318, com_list_cache, 0x0); + ASSERT_STRUCT_OFFSET(struc_21AC318, field_4, 0x4); + ASSERT_STRUCT_OFFSET(struc_21AC318, field_8, 0x8); + + struct fileData_s + { + void * data; //OFS: 0x0 SIZE: 0x4 + fileData_s * next; //OFS: 0x4 SIZE: 0x4 + unsigned __int8 type; //OFS: 0x8 SIZE: 0x1 + char name[1]; //OFS: 0x9 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(fileData_s, 0xC); + ASSERT_STRUCT_OFFSET(fileData_s, data, 0x0); + ASSERT_STRUCT_OFFSET(fileData_s, next, 0x4); + ASSERT_STRUCT_OFFSET(fileData_s, type, 0x8); + ASSERT_STRUCT_OFFSET(fileData_s, name, 0x9); + + struct WinVars_t + { + HINSTANCE__ * reflib_library; //OFS: 0x0 SIZE: 0x4 + int reflib_active; //OFS: 0x4 SIZE: 0x4 + HWND__ * hWnd; //OFS: 0x8 SIZE: 0x4 + HINSTANCE__ * hInstance; //OFS: 0xC SIZE: 0x4 + int activeApp; //OFS: 0x10 SIZE: 0x4 + int isMinimized; //OFS: 0x14 SIZE: 0x4 + int recenterMouse; //OFS: 0x18 SIZE: 0x4 + unsigned int sysMsgTime; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(WinVars_t, 0x20); + ASSERT_STRUCT_OFFSET(WinVars_t, reflib_library, 0x0); + ASSERT_STRUCT_OFFSET(WinVars_t, reflib_active, 0x4); + ASSERT_STRUCT_OFFSET(WinVars_t, hWnd, 0x8); + ASSERT_STRUCT_OFFSET(WinVars_t, hInstance, 0xC); + ASSERT_STRUCT_OFFSET(WinVars_t, activeApp, 0x10); + ASSERT_STRUCT_OFFSET(WinVars_t, isMinimized, 0x14); + ASSERT_STRUCT_OFFSET(WinVars_t, recenterMouse, 0x18); + ASSERT_STRUCT_OFFSET(WinVars_t, sysMsgTime, 0x1C); + + struct _pendedBadPlace + { + badplace_parms_t params; //OFS: 0x0 SIZE: 0x1C + unsigned int name; //OFS: 0x1C SIZE: 0x4 + int duration; //OFS: 0x20 SIZE: 0x4 + int teamflags; //OFS: 0x24 SIZE: 0x4 + int type; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(_pendedBadPlace, 0x2C); + ASSERT_STRUCT_OFFSET(_pendedBadPlace, params, 0x0); + ASSERT_STRUCT_OFFSET(_pendedBadPlace, name, 0x1C); + ASSERT_STRUCT_OFFSET(_pendedBadPlace, duration, 0x20); + ASSERT_STRUCT_OFFSET(_pendedBadPlace, teamflags, 0x24); + ASSERT_STRUCT_OFFSET(_pendedBadPlace, type, 0x28); + + struct EntHandleInfo + { + void * handle; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 next; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 prev; //OFS: 0x6 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(EntHandleInfo, 0x8); + ASSERT_STRUCT_OFFSET(EntHandleInfo, handle, 0x0); + ASSERT_STRUCT_OFFSET(EntHandleInfo, next, 0x4); + ASSERT_STRUCT_OFFSET(EntHandleInfo, prev, 0x6); + + struct StreamPosInfo + { + char * pos; //OFS: 0x0 SIZE: 0x4 + unsigned int index; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StreamPosInfo, 0x8); + ASSERT_STRUCT_OFFSET(StreamPosInfo, pos, 0x0); + ASSERT_STRUCT_OFFSET(StreamPosInfo, index, 0x4); + + struct pushed_t + { + gentity_s * ent; //OFS: 0x0 SIZE: 0x4 + float origin[3]; //OFS: 0x4 SIZE: 0xC + float angles[3]; //OFS: 0x10 SIZE: 0xC + float surfaceNormal[3]; //OFS: 0x1C SIZE: 0xC + float deltayaw; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pushed_t, 0x2C); + ASSERT_STRUCT_OFFSET(pushed_t, ent, 0x0); + ASSERT_STRUCT_OFFSET(pushed_t, origin, 0x4); + ASSERT_STRUCT_OFFSET(pushed_t, angles, 0x10); + ASSERT_STRUCT_OFFSET(pushed_t, surfaceNormal, 0x1C); + ASSERT_STRUCT_OFFSET(pushed_t, deltayaw, 0x28); + + struct target_t + { + gentity_s * ent; //OFS: 0x0 SIZE: 0x4 + float offset[3]; //OFS: 0x4 SIZE: 0xC + int materialIndex; //OFS: 0x10 SIZE: 0x4 + int offscreenMaterialIndex; //OFS: 0x14 SIZE: 0x4 + int flags; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(target_t, 0x1C); + ASSERT_STRUCT_OFFSET(target_t, ent, 0x0); + ASSERT_STRUCT_OFFSET(target_t, offset, 0x4); + ASSERT_STRUCT_OFFSET(target_t, materialIndex, 0x10); + ASSERT_STRUCT_OFFSET(target_t, offscreenMaterialIndex, 0x14); + ASSERT_STRUCT_OFFSET(target_t, flags, 0x18); + + struct node_params_t + { + char classname[64]; //OFS: 0x0 SIZE: 0x40 + char targetname[64]; //OFS: 0x40 SIZE: 0x40 + unsigned __int16 targetname_hash; //OFS: 0x80 SIZE: 0x2 + char target[64]; //OFS: 0x82 SIZE: 0x40 + char target2[64]; //OFS: 0xC2 SIZE: 0x40 + float origin[3]; //OFS: 0x104 SIZE: 0xC + float angles[3]; //OFS: 0x110 SIZE: 0xC + int used; //OFS: 0x11C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(node_params_t, 0x120); + ASSERT_STRUCT_OFFSET(node_params_t, classname, 0x0); + ASSERT_STRUCT_OFFSET(node_params_t, targetname, 0x40); + ASSERT_STRUCT_OFFSET(node_params_t, targetname_hash, 0x80); + ASSERT_STRUCT_OFFSET(node_params_t, target, 0x82); + ASSERT_STRUCT_OFFSET(node_params_t, target2, 0xC2); + ASSERT_STRUCT_OFFSET(node_params_t, origin, 0x104); + ASSERT_STRUCT_OFFSET(node_params_t, angles, 0x110); + ASSERT_STRUCT_OFFSET(node_params_t, used, 0x11C); + + struct BreakablePiece + { + XModel * model; //OFS: 0x0 SIZE: 0x4 + int physObjId; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 lightingHandle; //OFS: 0x8 SIZE: 0x2 + bool active; //OFS: 0xA SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(BreakablePiece, 0xC); + ASSERT_STRUCT_OFFSET(BreakablePiece, model, 0x0); + ASSERT_STRUCT_OFFSET(BreakablePiece, physObjId, 0x4); + ASSERT_STRUCT_OFFSET(BreakablePiece, lightingHandle, 0x8); + ASSERT_STRUCT_OFFSET(BreakablePiece, active, 0xA); + + struct DynEnt_BurnData + { + unsigned __int16 id; //OFS: 0x0 SIZE: 0x2 + unsigned int fx; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEnt_BurnData, 0x8); + ASSERT_STRUCT_OFFSET(DynEnt_BurnData, id, 0x0); + ASSERT_STRUCT_OFFSET(DynEnt_BurnData, fx, 0x4); + + struct __declspec(align(1)) unkLaserStruct + { + char pad1[72]; //OFS: 0x0 SIZE: 0x48 + }; + ASSERT_STRUCT_SIZE(unkLaserStruct, 0x48); + ASSERT_STRUCT_OFFSET(unkLaserStruct, pad1, 0x0); + + struct FxMarkPoint + { + float xyz[3]; //OFS: 0x0 SIZE: 0xC + float lmapCoord[2]; //OFS: 0xC SIZE: 0x8 + float normal[3]; //OFS: 0x14 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(FxMarkPoint, 0x20); + ASSERT_STRUCT_OFFSET(FxMarkPoint, xyz, 0x0); + ASSERT_STRUCT_OFFSET(FxMarkPoint, lmapCoord, 0xC); + ASSERT_STRUCT_OFFSET(FxMarkPoint, normal, 0x14); + + struct __declspec(align(2)) GfxMarkContext + { + unsigned __int8 lmapIndex; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 primaryLightIndex; //OFS: 0x1 SIZE: 0x1 + unsigned __int8 reflectionProbeIndex; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 modelTypeAndSurf; //OFS: 0x3 SIZE: 0x1 + unsigned __int16 modelIndex; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxMarkContext, 0x6); + ASSERT_STRUCT_OFFSET(GfxMarkContext, lmapIndex, 0x0); + ASSERT_STRUCT_OFFSET(GfxMarkContext, primaryLightIndex, 0x1); + ASSERT_STRUCT_OFFSET(GfxMarkContext, reflectionProbeIndex, 0x2); + ASSERT_STRUCT_OFFSET(GfxMarkContext, modelTypeAndSurf, 0x3); + ASSERT_STRUCT_OFFSET(GfxMarkContext, modelIndex, 0x4); + + struct FxMark + { + unsigned __int16 prevMark; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 nextMark; //OFS: 0x2 SIZE: 0x2 + int frameCountDrawn; //OFS: 0x4 SIZE: 0x4 + int frameCountAlloced; //OFS: 0x8 SIZE: 0x4 + float origin[3]; //OFS: 0xC SIZE: 0xC + float radius; //OFS: 0x18 SIZE: 0x4 + float texCoordAxis[3]; //OFS: 0x1C SIZE: 0xC + float hitNormal[3]; //OFS: 0x28 SIZE: 0xC + unsigned __int8 nativeColor[4]; //OFS: 0x34 SIZE: 0x4 + Material * material; //OFS: 0x38 SIZE: 0x4 + int tris; //OFS: 0x3C SIZE: 0x4 + int points; //OFS: 0x40 SIZE: 0x4 + GfxMarkContext context; //OFS: 0x44 SIZE: 0x6 + unsigned __int16 pointCount; //OFS: 0x4A SIZE: 0x2 + unsigned __int8 triCount; //OFS: 0x4C SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(FxMark, 0x50); + ASSERT_STRUCT_OFFSET(FxMark, prevMark, 0x0); + ASSERT_STRUCT_OFFSET(FxMark, nextMark, 0x2); + ASSERT_STRUCT_OFFSET(FxMark, frameCountDrawn, 0x4); + ASSERT_STRUCT_OFFSET(FxMark, frameCountAlloced, 0x8); + ASSERT_STRUCT_OFFSET(FxMark, origin, 0xC); + ASSERT_STRUCT_OFFSET(FxMark, radius, 0x18); + ASSERT_STRUCT_OFFSET(FxMark, texCoordAxis, 0x1C); + ASSERT_STRUCT_OFFSET(FxMark, hitNormal, 0x28); + ASSERT_STRUCT_OFFSET(FxMark, nativeColor, 0x34); + ASSERT_STRUCT_OFFSET(FxMark, material, 0x38); + ASSERT_STRUCT_OFFSET(FxMark, tris, 0x3C); + ASSERT_STRUCT_OFFSET(FxMark, points, 0x40); + ASSERT_STRUCT_OFFSET(FxMark, context, 0x44); + ASSERT_STRUCT_OFFSET(FxMark, pointCount, 0x4A); + ASSERT_STRUCT_OFFSET(FxMark, triCount, 0x4C); + + struct FxTriGroup + { + unsigned __int16 indices[2][3]; //OFS: 0x0 SIZE: 0xC + GfxMarkContext context; //OFS: 0xC SIZE: 0x6 + unsigned __int8 triCount; //OFS: 0x12 SIZE: 0x1 + unsigned __int8 unused[1]; //OFS: 0x13 SIZE: 0x1 + int next; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxTriGroup, 0x18); + ASSERT_STRUCT_OFFSET(FxTriGroup, indices, 0x0); + ASSERT_STRUCT_OFFSET(FxTriGroup, context, 0xC); + ASSERT_STRUCT_OFFSET(FxTriGroup, triCount, 0x12); + ASSERT_STRUCT_OFFSET(FxTriGroup, unused, 0x13); + ASSERT_STRUCT_OFFSET(FxTriGroup, next, 0x14); + + struct FxTriGroupPool + { + FxTriGroup triGroup; //OFS: 0x0 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(FxTriGroupPool, 0x18); + ASSERT_STRUCT_OFFSET(FxTriGroupPool, triGroup, 0x0); + + struct FxPointGroup + { + FxMarkPoint points[2]; //OFS: 0x0 SIZE: 0x40 + int next; //OFS: 0x40 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxPointGroup, 0x44); + ASSERT_STRUCT_OFFSET(FxPointGroup, points, 0x0); + ASSERT_STRUCT_OFFSET(FxPointGroup, next, 0x40); + + struct FxPointGroupPool + { + FxPointGroup pointGroup; //OFS: 0x0 SIZE: 0x44 + }; + ASSERT_STRUCT_SIZE(FxPointGroupPool, 0x44); + ASSERT_STRUCT_OFFSET(FxPointGroupPool, pointGroup, 0x0); + + struct FxMarksSystem + { + int frameCount; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 firstFreeMarkHandle; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 firstActiveWorldMarkHandle; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 entFirstMarkHandles[2048]; //OFS: 0x8 SIZE: 0x1000 + void * firstFreeTriGroup; //OFS: 0x1008 SIZE: 0x4 + void * firstFreePointGroup; //OFS: 0x100C SIZE: 0x4 + FxMark marks[256]; //OFS: 0x1010 SIZE: 0x5000 + FxTriGroupPool triGroups[1024]; //OFS: 0x6010 SIZE: 0x6000 + FxPointGroupPool pointGroups[1536]; //OFS: 0xC010 SIZE: 0x19800 + bool noMarks; //OFS: 0x25810 SIZE: 0x1 + bool hasCarryIndex; //OFS: 0x25811 SIZE: 0x1 + unsigned __int16 carryIndex; //OFS: 0x25812 SIZE: 0x2 + unsigned int allocedMarkCount; //OFS: 0x25814 SIZE: 0x4 + unsigned int freedMarkCount; //OFS: 0x25818 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxMarksSystem, 0x2581C); + ASSERT_STRUCT_OFFSET(FxMarksSystem, frameCount, 0x0); + ASSERT_STRUCT_OFFSET(FxMarksSystem, firstFreeMarkHandle, 0x4); + ASSERT_STRUCT_OFFSET(FxMarksSystem, firstActiveWorldMarkHandle, 0x6); + ASSERT_STRUCT_OFFSET(FxMarksSystem, entFirstMarkHandles, 0x8); + ASSERT_STRUCT_OFFSET(FxMarksSystem, firstFreeTriGroup, 0x1008); + ASSERT_STRUCT_OFFSET(FxMarksSystem, firstFreePointGroup, 0x100C); + ASSERT_STRUCT_OFFSET(FxMarksSystem, marks, 0x1010); + ASSERT_STRUCT_OFFSET(FxMarksSystem, triGroups, 0x6010); + ASSERT_STRUCT_OFFSET(FxMarksSystem, pointGroups, 0xC010); + ASSERT_STRUCT_OFFSET(FxMarksSystem, noMarks, 0x25810); + ASSERT_STRUCT_OFFSET(FxMarksSystem, hasCarryIndex, 0x25811); + ASSERT_STRUCT_OFFSET(FxMarksSystem, carryIndex, 0x25812); + ASSERT_STRUCT_OFFSET(FxMarksSystem, allocedMarkCount, 0x25814); + ASSERT_STRUCT_OFFSET(FxMarksSystem, freedMarkCount, 0x25818); + + struct rope_t + { + char field_0; //OFS: 0x0 SIZE: 0x1 + _BYTE gap1[3039]; //OFS: 0x1 SIZE: 0xBDF + int field_BE0; //OFS: 0xBE0 SIZE: 0x4 + _BYTE gapBE4[48]; //OFS: 0xBE4 SIZE: 0x30 + int field_C14; //OFS: 0xC14 SIZE: 0x4 + _BYTE gapC18[12]; //OFS: 0xC18 SIZE: 0xC + int field_C24; //OFS: 0xC24 SIZE: 0x4 + _BYTE gapC28[32]; //OFS: 0xC28 SIZE: 0x20 + int field_C48; //OFS: 0xC48 SIZE: 0x4 + _BYTE gapC4C[11]; //OFS: 0xC4C SIZE: 0xB + char field_C57; //OFS: 0xC57 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(rope_t, 0xC58); + ASSERT_STRUCT_OFFSET(rope_t, field_0, 0x0); + ASSERT_STRUCT_OFFSET(rope_t, gap1, 0x1); + ASSERT_STRUCT_OFFSET(rope_t, field_BE0, 0xBE0); + ASSERT_STRUCT_OFFSET(rope_t, gapBE4, 0xBE4); + ASSERT_STRUCT_OFFSET(rope_t, field_C14, 0xC14); + ASSERT_STRUCT_OFFSET(rope_t, gapC18, 0xC18); + ASSERT_STRUCT_OFFSET(rope_t, field_C24, 0xC24); + ASSERT_STRUCT_OFFSET(rope_t, gapC28, 0xC28); + ASSERT_STRUCT_OFFSET(rope_t, field_C48, 0xC48); + ASSERT_STRUCT_OFFSET(rope_t, gapC4C, 0xC4C); + ASSERT_STRUCT_OFFSET(rope_t, field_C57, 0xC57); + + struct unkServerListStruct + { + char field_0[1]; //OFS: 0x0 SIZE: 0x1 + _BYTE gap1[175]; //OFS: 0x1 SIZE: 0xAF + int field_B0[1]; //OFS: 0xB0 SIZE: 0x4 + int field_B4[1]; //OFS: 0xB4 SIZE: 0x4 + char field_B8[1]; //OFS: 0xB8 SIZE: 0x1 + char field_B9[1]; //OFS: 0xB9 SIZE: 0x1 + char field_BA[1]; //OFS: 0xBA SIZE: 0x1 + char field_BB[5]; //OFS: 0xBB SIZE: 0x5 + _BYTE field_C0[49]; //OFS: 0xC0 SIZE: 0x31 + char field_F1[1]; //OFS: 0xF1 SIZE: 0x1 + _BYTE gapF2; //OFS: 0xF2 SIZE: 0x1 + char field_F3[32]; //OFS: 0xF3 SIZE: 0x20 + char field_113[64]; //OFS: 0x113 SIZE: 0x40 + char field_153[128]; //OFS: 0x153 SIZE: 0x80 + char field_1D3[1]; //OFS: 0x1D3 SIZE: 0x1 + char field_1D4[4]; //OFS: 0x1D4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(unkServerListStruct, 0x1D8); + + struct dwUnifiedFriends + { + unkServerListStruct unkFriendsStruct; //OFS: 0x0 SIZE: 0x1D8 + _BYTE gap1D8[46727]; //OFS: 0x1D8 SIZE: 0xB687 + char field_B85F; //OFS: 0xB85F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(dwUnifiedFriends, 0xB860); + ASSERT_STRUCT_OFFSET(dwUnifiedFriends, unkFriendsStruct, 0x0); + ASSERT_STRUCT_OFFSET(dwUnifiedFriends, gap1D8, 0x1D8); + ASSERT_STRUCT_OFFSET(dwUnifiedFriends, field_B85F, 0xB85F); + + struct struc_1F3A280 + { + int field_0[1]; //OFS: 0x0 SIZE: 0x4 + int field_4[1]; //OFS: 0x4 SIZE: 0x4 + char field_8[64]; //OFS: 0x8 SIZE: 0x40 + int field_48[1]; //OFS: 0x48 SIZE: 0x4 + int field_4C[1]; //OFS: 0x4C SIZE: 0x4 + _BYTE gap50[7919]; //OFS: 0x50 SIZE: 0x1EEF + char field_1F3F; //OFS: 0x1F3F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(struc_1F3A280, 0x1F40); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_0, 0x0); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_4, 0x4); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_8, 0x8); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_48, 0x48); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_4C, 0x4C); + ASSERT_STRUCT_OFFSET(struc_1F3A280, gap50, 0x50); + ASSERT_STRUCT_OFFSET(struc_1F3A280, field_1F3F, 0x1F3F); + + struct struc_1F3DAC0 + { + int field_0[1]; //OFS: 0x0 SIZE: 0x4 + int field_4[1]; //OFS: 0x4 SIZE: 0x4 + char field_8[72]; //OFS: 0x8 SIZE: 0x48 + _BYTE gap50[7919]; //OFS: 0x50 SIZE: 0x1EEF + char field_1F3F; //OFS: 0x1F3F SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(struc_1F3DAC0, 0x1F40); + ASSERT_STRUCT_OFFSET(struc_1F3DAC0, field_0, 0x0); + ASSERT_STRUCT_OFFSET(struc_1F3DAC0, field_4, 0x4); + ASSERT_STRUCT_OFFSET(struc_1F3DAC0, field_8, 0x8); + ASSERT_STRUCT_OFFSET(struc_1F3DAC0, gap50, 0x50); + ASSERT_STRUCT_OFFSET(struc_1F3DAC0, field_1F3F, 0x1F3F); + + struct CachedAssets_t + { + Material * scrollBarArrowUp; //OFS: 0x0 SIZE: 0x4 + Material * scrollBarArrowDown; //OFS: 0x4 SIZE: 0x4 + Material * scrollBarArrowLeft; //OFS: 0x8 SIZE: 0x4 + Material * scrollBarArrowRight; //OFS: 0xC SIZE: 0x4 + Material * scrollBar; //OFS: 0x10 SIZE: 0x4 + Material * scrollBarThumb; //OFS: 0x14 SIZE: 0x4 + Material * sliderBar; //OFS: 0x18 SIZE: 0x4 + Material * sliderThumb; //OFS: 0x1C SIZE: 0x4 + Material * whiteMaterial; //OFS: 0x20 SIZE: 0x4 + Material * cursor; //OFS: 0x24 SIZE: 0x4 + Material * playlist_sp_recrMaterial; //OFS: 0x28 SIZE: 0x4 + Material * playlist_sp_regMaterial; //OFS: 0x2C SIZE: 0x4 + Material * playlist_sp_hardMaterial; //OFS: 0x30 SIZE: 0x4 + Material * playlist_sp_vetMaterial; //OFS: 0x34 SIZE: 0x4 + Font_s * bigFont; //OFS: 0x38 SIZE: 0x4 + Font_s * smallFont; //OFS: 0x3C SIZE: 0x4 + Font_s * consoleFont; //OFS: 0x40 SIZE: 0x4 + Font_s * boldFont; //OFS: 0x44 SIZE: 0x4 + Font_s * normalFont; //OFS: 0x48 SIZE: 0x4 + Font_s * extraBigFont; //OFS: 0x4C SIZE: 0x4 + Font_s * objectiveFont; //OFS: 0x50 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CachedAssets_t, 0x54); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBarArrowUp, 0x0); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBarArrowDown, 0x4); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBarArrowLeft, 0x8); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBarArrowRight, 0xC); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBar, 0x10); + ASSERT_STRUCT_OFFSET(CachedAssets_t, scrollBarThumb, 0x14); + ASSERT_STRUCT_OFFSET(CachedAssets_t, sliderBar, 0x18); + ASSERT_STRUCT_OFFSET(CachedAssets_t, sliderThumb, 0x1C); + ASSERT_STRUCT_OFFSET(CachedAssets_t, whiteMaterial, 0x20); + ASSERT_STRUCT_OFFSET(CachedAssets_t, cursor, 0x24); + ASSERT_STRUCT_OFFSET(CachedAssets_t, playlist_sp_recrMaterial, 0x28); + ASSERT_STRUCT_OFFSET(CachedAssets_t, playlist_sp_regMaterial, 0x2C); + ASSERT_STRUCT_OFFSET(CachedAssets_t, playlist_sp_hardMaterial, 0x30); + ASSERT_STRUCT_OFFSET(CachedAssets_t, playlist_sp_vetMaterial, 0x34); + ASSERT_STRUCT_OFFSET(CachedAssets_t, bigFont, 0x38); + ASSERT_STRUCT_OFFSET(CachedAssets_t, smallFont, 0x3C); + ASSERT_STRUCT_OFFSET(CachedAssets_t, consoleFont, 0x40); + ASSERT_STRUCT_OFFSET(CachedAssets_t, boldFont, 0x44); + ASSERT_STRUCT_OFFSET(CachedAssets_t, normalFont, 0x48); + ASSERT_STRUCT_OFFSET(CachedAssets_t, extraBigFont, 0x4C); + ASSERT_STRUCT_OFFSET(CachedAssets_t, objectiveFont, 0x50); + + struct pendingServer_t + { + char adrstr[64]; //OFS: 0x0 SIZE: 0x40 + char name[64]; //OFS: 0x40 SIZE: 0x40 + int startTime; //OFS: 0x80 SIZE: 0x4 + int serverNum; //OFS: 0x84 SIZE: 0x4 + int valid; //OFS: 0x88 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pendingServer_t, 0x8C); + ASSERT_STRUCT_OFFSET(pendingServer_t, adrstr, 0x0); + ASSERT_STRUCT_OFFSET(pendingServer_t, name, 0x40); + ASSERT_STRUCT_OFFSET(pendingServer_t, startTime, 0x80); + ASSERT_STRUCT_OFFSET(pendingServer_t, serverNum, 0x84); + ASSERT_STRUCT_OFFSET(pendingServer_t, valid, 0x88); + + struct pendingServerStatus_t + { + int num; //OFS: 0x0 SIZE: 0x4 + pendingServer_t server[8]; //OFS: 0x4 SIZE: 0x460 + }; + ASSERT_STRUCT_SIZE(pendingServerStatus_t, 0x464); + ASSERT_STRUCT_OFFSET(pendingServerStatus_t, num, 0x0); + ASSERT_STRUCT_OFFSET(pendingServerStatus_t, server, 0x4); + + struct serverStatusInfo_s + { + char gap1[787]; //OFS: 0x0 SIZE: 0x313 + int numLinesnot; //OFS: 0x314 SIZE: 0x4 + char gap2[2357]; //OFS: 0x318 SIZE: 0x935 + }; + ASSERT_STRUCT_SIZE(serverStatusInfo_s, 0xC50); + ASSERT_STRUCT_OFFSET(serverStatusInfo_s, gap1, 0x0); + ASSERT_STRUCT_OFFSET(serverStatusInfo_s, numLinesnot, 0x314); + ASSERT_STRUCT_OFFSET(serverStatusInfo_s, gap2, 0x318); + + struct XAnimNotify_s + { + char * name; //OFS: 0x0 SIZE: 0x4 + unsigned int type; //OFS: 0x4 SIZE: 0x4 + float timeFrac; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimNotify_s, 0xC); + ASSERT_STRUCT_OFFSET(XAnimNotify_s, name, 0x0); + ASSERT_STRUCT_OFFSET(XAnimNotify_s, type, 0x4); + ASSERT_STRUCT_OFFSET(XAnimNotify_s, timeFrac, 0x8); + + struct infoParm_t + { + const char * name; //OFS: 0x0 SIZE: 0x4 + int clearSolid; //OFS: 0x4 SIZE: 0x4 + int surfaceFlags; //OFS: 0x8 SIZE: 0x4 + int contents; //OFS: 0xC SIZE: 0x4 + int toolFlags; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(infoParm_t, 0x14); + ASSERT_STRUCT_OFFSET(infoParm_t, name, 0x0); + ASSERT_STRUCT_OFFSET(infoParm_t, clearSolid, 0x4); + ASSERT_STRUCT_OFFSET(infoParm_t, surfaceFlags, 0x8); + ASSERT_STRUCT_OFFSET(infoParm_t, contents, 0xC); + ASSERT_STRUCT_OFFSET(infoParm_t, toolFlags, 0x10); + + struct Destructible_BonePose + { + int boneid; //OFS: 0x0 SIZE: 0x4 + int pieceIndex; //OFS: 0x4 SIZE: 0x4 + float angles_original[3]; //OFS: 0x8 SIZE: 0xC + float angles_offset[3]; //OFS: 0x14 SIZE: 0xC + float angles_vel[3]; //OFS: 0x20 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(Destructible_BonePose, 0x2C); + ASSERT_STRUCT_OFFSET(Destructible_BonePose, boneid, 0x0); + ASSERT_STRUCT_OFFSET(Destructible_BonePose, pieceIndex, 0x4); + ASSERT_STRUCT_OFFSET(Destructible_BonePose, angles_original, 0x8); + ASSERT_STRUCT_OFFSET(Destructible_BonePose, angles_offset, 0x14); + ASSERT_STRUCT_OFFSET(Destructible_BonePose, angles_vel, 0x20); + + struct DestructiblePose + { + Destructible_BonePose bones[32]; //OFS: 0x0 SIZE: 0x580 + __int16 numBones; //OFS: 0x580 SIZE: 0x2 + __int16 destructibleID; //OFS: 0x582 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(DestructiblePose, 0x584); + ASSERT_STRUCT_OFFSET(DestructiblePose, bones, 0x0); + ASSERT_STRUCT_OFFSET(DestructiblePose, numBones, 0x580); + ASSERT_STRUCT_OFFSET(DestructiblePose, destructibleID, 0x582); + + struct struct_0 + { + int clientNum; //OFS: 0x0 SIZE: 0x4 + int var_44; //OFS: 0x4 SIZE: 0x4 + int var_40; //OFS: 0x8 SIZE: 0x4 + int var_3C; //OFS: 0xC SIZE: 0x4 + int var_38; //OFS: 0x10 SIZE: 0x4 + int var_34; //OFS: 0x14 SIZE: 0x4 + int var_30; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(struct_0, 0x1C); + ASSERT_STRUCT_OFFSET(struct_0, clientNum, 0x0); + ASSERT_STRUCT_OFFSET(struct_0, var_44, 0x4); + ASSERT_STRUCT_OFFSET(struct_0, var_40, 0x8); + ASSERT_STRUCT_OFFSET(struct_0, var_3C, 0xC); + ASSERT_STRUCT_OFFSET(struct_0, var_38, 0x10); + ASSERT_STRUCT_OFFSET(struct_0, var_34, 0x14); + ASSERT_STRUCT_OFFSET(struct_0, var_30, 0x18); + + struct stype_t + { + sval_u val; //OFS: 0x0 SIZE: 0x4 + unsigned int pos; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(stype_t, 0x8); + ASSERT_STRUCT_OFFSET(stype_t, val, 0x0); + ASSERT_STRUCT_OFFSET(stype_t, pos, 0x4); + + struct DObjModel_s + { + XModel * model; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 boneName; //OFS: 0x4 SIZE: 0x2 + bool ignoreCollision; //OFS: 0x6 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(DObjModel_s, 0x8); + ASSERT_STRUCT_OFFSET(DObjModel_s, model, 0x0); + ASSERT_STRUCT_OFFSET(DObjModel_s, boneName, 0x4); + ASSERT_STRUCT_OFFSET(DObjModel_s, ignoreCollision, 0x6); + + struct leafList_s + { + int count; //OFS: 0x0 SIZE: 0x4 + int maxcount; //OFS: 0x4 SIZE: 0x4 + int overflowed; //OFS: 0x8 SIZE: 0x4 + unsigned __int16 * list; //OFS: 0xC SIZE: 0x4 + float bounds[2][3]; //OFS: 0x10 SIZE: 0x18 + int lastLeaf; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(leafList_s, 0x2C); + ASSERT_STRUCT_OFFSET(leafList_s, count, 0x0); + ASSERT_STRUCT_OFFSET(leafList_s, maxcount, 0x4); + ASSERT_STRUCT_OFFSET(leafList_s, overflowed, 0x8); + ASSERT_STRUCT_OFFSET(leafList_s, list, 0xC); + ASSERT_STRUCT_OFFSET(leafList_s, bounds, 0x10); + ASSERT_STRUCT_OFFSET(leafList_s, lastLeaf, 0x28); + + struct FastCriticalSection + { + volatile int readCount; //OFS: 0x0 SIZE: 0x4 + volatile int writeCount; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FastCriticalSection, 0x8); + ASSERT_STRUCT_OFFSET(FastCriticalSection, readCount, 0x0); + ASSERT_STRUCT_OFFSET(FastCriticalSection, writeCount, 0x4); + + struct ParseThreadInfo + { + parseInfo_t parseInfo[16]; //OFS: 0x0 SIZE: 0x4200 + int parseInfoNum; //OFS: 0x4200 SIZE: 0x4 + char * tokenPos; //OFS: 0x4204 SIZE: 0x4 + char * prevTokenPos; //OFS: 0x4208 SIZE: 0x4 + char line[1024]; //OFS: 0x420C SIZE: 0x400 + }; + ASSERT_STRUCT_SIZE(ParseThreadInfo, 0x460C); + ASSERT_STRUCT_OFFSET(ParseThreadInfo, parseInfo, 0x0); + ASSERT_STRUCT_OFFSET(ParseThreadInfo, parseInfoNum, 0x4200); + ASSERT_STRUCT_OFFSET(ParseThreadInfo, tokenPos, 0x4204); + ASSERT_STRUCT_OFFSET(ParseThreadInfo, prevTokenPos, 0x4208); + ASSERT_STRUCT_OFFSET(ParseThreadInfo, line, 0x420C); + + struct LargeLocal + { + int startPos; //OFS: 0x0 SIZE: 0x4 + int size; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LargeLocal, 0x8); + ASSERT_STRUCT_OFFSET(LargeLocal, startPos, 0x0); + ASSERT_STRUCT_OFFSET(LargeLocal, size, 0x4); + + struct XFile + { + unsigned int size; //OFS: 0x0 SIZE: 0x4 + unsigned int externalSize; //OFS: 0x4 SIZE: 0x4 + unsigned int blockSize[8]; //OFS: 0x8 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(XFile, 0x28); + ASSERT_STRUCT_OFFSET(XFile, size, 0x0); + ASSERT_STRUCT_OFFSET(XFile, externalSize, 0x4); + ASSERT_STRUCT_OFFSET(XFile, blockSize, 0x8); + + union pointtrace_or_moveclip_u + { + pointtrace_t point; //OFS: 0x0 SIZE: 0x40 + moveclip_t move; //OFS: 0x1 SIZE: 0x60 + }; + ASSERT_STRUCT_SIZE(pointtrace_or_moveclip_u, 0x60); + + struct PhysGlob + { + int physGlob; //OFS: 0x0 SIZE: 0x4 + int field_4; //OFS: 0x4 SIZE: 0x4 + int field_8; //OFS: 0x8 SIZE: 0x4 + int field_C; //OFS: 0xC SIZE: 0x4 + int field_10[1]; //OFS: 0x10 SIZE: 0x4 + int field_14[1]; //OFS: 0x14 SIZE: 0x4 + int field_18[3]; //OFS: 0x18 SIZE: 0xC + int field_24; //OFS: 0x24 SIZE: 0x4 + _BYTE gap28[12]; //OFS: 0x28 SIZE: 0xC + float field_34[16]; //OFS: 0x34 SIZE: 0x40 + int physGlob__timeLastSnapshot; //OFS: 0x74 SIZE: 0x4 + int physGlob__timeLastUpdate; //OFS: 0x78 SIZE: 0x4 + float physGlob__timeNowLerpFrac; //OFS: 0x7C SIZE: 0x4 + int collisionCallback; //OFS: 0x80 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysGlob, 0x84); + ASSERT_STRUCT_OFFSET(PhysGlob, physGlob, 0x0); + ASSERT_STRUCT_OFFSET(PhysGlob, field_4, 0x4); + ASSERT_STRUCT_OFFSET(PhysGlob, field_8, 0x8); + ASSERT_STRUCT_OFFSET(PhysGlob, field_C, 0xC); + ASSERT_STRUCT_OFFSET(PhysGlob, field_10, 0x10); + ASSERT_STRUCT_OFFSET(PhysGlob, field_14, 0x14); + ASSERT_STRUCT_OFFSET(PhysGlob, field_18, 0x18); + ASSERT_STRUCT_OFFSET(PhysGlob, field_24, 0x24); + ASSERT_STRUCT_OFFSET(PhysGlob, gap28, 0x28); + ASSERT_STRUCT_OFFSET(PhysGlob, field_34, 0x34); + ASSERT_STRUCT_OFFSET(PhysGlob, physGlob__timeLastSnapshot, 0x74); + ASSERT_STRUCT_OFFSET(PhysGlob, physGlob__timeLastUpdate, 0x78); + ASSERT_STRUCT_OFFSET(PhysGlob, physGlob__timeNowLerpFrac, 0x7C); + ASSERT_STRUCT_OFFSET(PhysGlob, collisionCallback, 0x80); + + struct CinematicGlob + { + char currentCinematicName[256]; //OFS: 0x0 SIZE: 0x100 + char targetCinematicName[256]; //OFS: 0x100 SIZE: 0x100 + char nextCinematicName[256]; //OFS: 0x200 SIZE: 0x100 + unsigned int nextCinematicPlaybackFlags; //OFS: 0x300 SIZE: 0x4 + unsigned int playbackFlags; //OFS: 0x304 SIZE: 0x4 + bool targetCinematicChanged; //OFS: 0x308 SIZE: 0x1 + bool cinematicFinished; //OFS: 0x309 SIZE: 0x1 + char field_30A[2]; //OFS: 0x30A SIZE: 0x2 + int field_30C; //OFS: 0x30C SIZE: 0x4 + int field_310; //OFS: 0x310 SIZE: 0x4 + char field_314; //OFS: 0x314 SIZE: 0x1 + char field_315; //OFS: 0x315 SIZE: 0x1 + char field_316; //OFS: 0x316 SIZE: 0x1 + char field_317; //OFS: 0x317 SIZE: 0x1 + char field_318; //OFS: 0x318 SIZE: 0x1 + char field_319[3]; //OFS: 0x319 SIZE: 0x3 + int field_31C; //OFS: 0x31C SIZE: 0x4 + int field_320; //OFS: 0x320 SIZE: 0x4 + int field_324; //OFS: 0x324 SIZE: 0x4 + int field_328; //OFS: 0x328 SIZE: 0x4 + int field_32C; //OFS: 0x32C SIZE: 0x4 + int field_330; //OFS: 0x330 SIZE: 0x4 + int field_334; //OFS: 0x334 SIZE: 0x4 + _BYTE gap338[176]; //OFS: 0x338 SIZE: 0xB0 + int field_3E8; //OFS: 0x3E8 SIZE: 0x4 + int field_3EC; //OFS: 0x3EC SIZE: 0x4 + int field_3F0; //OFS: 0x3F0 SIZE: 0x4 + int field_3F4; //OFS: 0x3F4 SIZE: 0x4 + int field_3F8; //OFS: 0x3F8 SIZE: 0x4 + int field_3FC; //OFS: 0x3FC SIZE: 0x4 + int field_400; //OFS: 0x400 SIZE: 0x4 + int field_404; //OFS: 0x404 SIZE: 0x4 + int field_408; //OFS: 0x408 SIZE: 0x4 + int field_40C; //OFS: 0x40C SIZE: 0x4 + int field_410; //OFS: 0x410 SIZE: 0x4 + int field_414; //OFS: 0x414 SIZE: 0x4 + int field_418; //OFS: 0x418 SIZE: 0x4 + void * field_41C; //OFS: 0x41C SIZE: 0x4 + int field_420; //OFS: 0x420 SIZE: 0x4 + int field_424; //OFS: 0x424 SIZE: 0x4 + int field_428; //OFS: 0x428 SIZE: 0x4 + int field_42C; //OFS: 0x42C SIZE: 0x4 + int field_430; //OFS: 0x430 SIZE: 0x4 + int field_434; //OFS: 0x434 SIZE: 0x4 + _BYTE gap438[864]; //OFS: 0x438 SIZE: 0x360 + int activeTextureSet; //OFS: 0x798 SIZE: 0x4 + int activeImageFrameTextureSet; //OFS: 0x79C SIZE: 0x4 + void * memPool; //OFS: 0x7A0 SIZE: 0x4 + float playbackVolume; //OFS: 0x7A4 SIZE: 0x4 + bool underrun; //OFS: 0x7A8 SIZE: 0x1 + char field_7A9[3]; //OFS: 0x7A9 SIZE: 0x3 + int field_7AC; //OFS: 0x7AC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CinematicGlob, 0x7B0); + ASSERT_STRUCT_OFFSET(CinematicGlob, currentCinematicName, 0x0); + ASSERT_STRUCT_OFFSET(CinematicGlob, targetCinematicName, 0x100); + ASSERT_STRUCT_OFFSET(CinematicGlob, nextCinematicName, 0x200); + ASSERT_STRUCT_OFFSET(CinematicGlob, nextCinematicPlaybackFlags, 0x300); + ASSERT_STRUCT_OFFSET(CinematicGlob, playbackFlags, 0x304); + ASSERT_STRUCT_OFFSET(CinematicGlob, targetCinematicChanged, 0x308); + ASSERT_STRUCT_OFFSET(CinematicGlob, cinematicFinished, 0x309); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_30A, 0x30A); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_30C, 0x30C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_310, 0x310); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_314, 0x314); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_315, 0x315); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_316, 0x316); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_317, 0x317); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_318, 0x318); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_319, 0x319); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_31C, 0x31C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_320, 0x320); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_324, 0x324); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_328, 0x328); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_32C, 0x32C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_330, 0x330); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_334, 0x334); + ASSERT_STRUCT_OFFSET(CinematicGlob, gap338, 0x338); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3E8, 0x3E8); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3EC, 0x3EC); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3F0, 0x3F0); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3F4, 0x3F4); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3F8, 0x3F8); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_3FC, 0x3FC); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_400, 0x400); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_404, 0x404); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_408, 0x408); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_40C, 0x40C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_410, 0x410); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_414, 0x414); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_418, 0x418); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_41C, 0x41C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_420, 0x420); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_424, 0x424); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_428, 0x428); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_42C, 0x42C); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_430, 0x430); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_434, 0x434); + ASSERT_STRUCT_OFFSET(CinematicGlob, gap438, 0x438); + ASSERT_STRUCT_OFFSET(CinematicGlob, activeTextureSet, 0x798); + ASSERT_STRUCT_OFFSET(CinematicGlob, activeImageFrameTextureSet, 0x79C); + ASSERT_STRUCT_OFFSET(CinematicGlob, memPool, 0x7A0); + ASSERT_STRUCT_OFFSET(CinematicGlob, playbackVolume, 0x7A4); + ASSERT_STRUCT_OFFSET(CinematicGlob, underrun, 0x7A8); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_7A9, 0x7A9); + ASSERT_STRUCT_OFFSET(CinematicGlob, field_7AC, 0x7AC); + + struct sightclip_t + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + float outerSize[3]; //OFS: 0x18 SIZE: 0xC + float start[3]; //OFS: 0x24 SIZE: 0xC + float end[3]; //OFS: 0x30 SIZE: 0xC + int passEntityNum[2]; //OFS: 0x3C SIZE: 0x8 + int contentmask; //OFS: 0x44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sightclip_t, 0x48); + ASSERT_STRUCT_OFFSET(sightclip_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(sightclip_t, maxs, 0xC); + ASSERT_STRUCT_OFFSET(sightclip_t, outerSize, 0x18); + ASSERT_STRUCT_OFFSET(sightclip_t, start, 0x24); + ASSERT_STRUCT_OFFSET(sightclip_t, end, 0x30); + ASSERT_STRUCT_OFFSET(sightclip_t, passEntityNum, 0x3C); + ASSERT_STRUCT_OFFSET(sightclip_t, contentmask, 0x44); + + struct sightpointtrace_t + { + float start[3]; //OFS: 0x0 SIZE: 0xC + float end[3]; //OFS: 0xC SIZE: 0xC + int passEntityNum[2]; //OFS: 0x18 SIZE: 0x8 + int contentmask; //OFS: 0x20 SIZE: 0x4 + int locational; //OFS: 0x24 SIZE: 0x4 + unsigned __int8 * priorityMap; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sightpointtrace_t, 0x2C); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, start, 0x0); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, end, 0xC); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, passEntityNum, 0x18); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, contentmask, 0x20); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, locational, 0x24); + ASSERT_STRUCT_OFFSET(sightpointtrace_t, priorityMap, 0x28); + + union sightclip_or_sightpointtrace_u + { + sightclip_t sightclip; //OFS: 0x0 SIZE: 0x48 + sightpointtrace_t sightpointtrace; //OFS: 0x1 SIZE: 0x2C + }; + ASSERT_STRUCT_SIZE(sightclip_or_sightpointtrace_u, 0x48); + + struct targGlob_t + { + target_t targets[32]; //OFS: 0x0 SIZE: 0x380 + int targetCount; //OFS: 0x380 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(targGlob_t, 0x384); + ASSERT_STRUCT_OFFSET(targGlob_t, targets, 0x0); + ASSERT_STRUCT_OFFSET(targGlob_t, targetCount, 0x380); + + struct snd_fader + { + float value; //OFS: 0x0 SIZE: 0x4 + float goal; //OFS: 0x4 SIZE: 0x4 + float rate; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_fader, 0xC); + ASSERT_STRUCT_OFFSET(snd_fader, value, 0x0); + ASSERT_STRUCT_OFFSET(snd_fader, goal, 0x4); + ASSERT_STRUCT_OFFSET(snd_fader, rate, 0x8); + + struct SndEntHandle + { + int handle; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SndEntHandle, 0x4); + ASSERT_STRUCT_OFFSET(SndEntHandle, handle, 0x0); + + struct snd_player_water + { + float waterHeight; //OFS: 0x0 SIZE: 0x4 + float position[3]; //OFS: 0x4 SIZE: 0xC + float viewHeight; //OFS: 0x10 SIZE: 0x4 + unsigned int lastTransition; //OFS: 0x14 SIZE: 0x4 + unsigned int timeTillGulp; //OFS: 0x18 SIZE: 0x4 + SndEntHandle ent; //OFS: 0x1C SIZE: 0x4 + int startId; //OFS: 0x20 SIZE: 0x4 + int enterId; //OFS: 0x24 SIZE: 0x4 + int exitId; //OFS: 0x28 SIZE: 0x4 + int idleId; //OFS: 0x2C SIZE: 0x4 + int swimId; //OFS: 0x30 SIZE: 0x4 + int vxId; //OFS: 0x34 SIZE: 0x4 + bool in_use; //OFS: 0x38 SIZE: 0x1 + bool is_new; //OFS: 0x39 SIZE: 0x1 + snd_fader idleBlend; //OFS: 0x3C SIZE: 0xC + snd_fader swimBlend; //OFS: 0x48 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(snd_player_water, 0x54); + ASSERT_STRUCT_OFFSET(snd_player_water, waterHeight, 0x0); + ASSERT_STRUCT_OFFSET(snd_player_water, position, 0x4); + ASSERT_STRUCT_OFFSET(snd_player_water, viewHeight, 0x10); + ASSERT_STRUCT_OFFSET(snd_player_water, lastTransition, 0x14); + ASSERT_STRUCT_OFFSET(snd_player_water, timeTillGulp, 0x18); + ASSERT_STRUCT_OFFSET(snd_player_water, ent, 0x1C); + ASSERT_STRUCT_OFFSET(snd_player_water, startId, 0x20); + ASSERT_STRUCT_OFFSET(snd_player_water, enterId, 0x24); + ASSERT_STRUCT_OFFSET(snd_player_water, exitId, 0x28); + ASSERT_STRUCT_OFFSET(snd_player_water, idleId, 0x2C); + ASSERT_STRUCT_OFFSET(snd_player_water, swimId, 0x30); + ASSERT_STRUCT_OFFSET(snd_player_water, vxId, 0x34); + ASSERT_STRUCT_OFFSET(snd_player_water, in_use, 0x38); + ASSERT_STRUCT_OFFSET(snd_player_water, is_new, 0x39); + ASSERT_STRUCT_OFFSET(snd_player_water, idleBlend, 0x3C); + ASSERT_STRUCT_OFFSET(snd_player_water, swimBlend, 0x48); + + struct snd_volume_info_t + { + float volume; //OFS: 0x0 SIZE: 0x4 + float goalvolume; //OFS: 0x4 SIZE: 0x4 + float goalrate; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_volume_info_t, 0xC); + ASSERT_STRUCT_OFFSET(snd_volume_info_t, volume, 0x0); + ASSERT_STRUCT_OFFSET(snd_volume_info_t, goalvolume, 0x4); + ASSERT_STRUCT_OFFSET(snd_volume_info_t, goalrate, 0x8); + + struct SndBusVolGroup + { + snd_volume_info_t busVol[64]; //OFS: 0x0 SIZE: 0x300 + bool active; //OFS: 0x300 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SndBusVolGroup, 0x304); + ASSERT_STRUCT_OFFSET(SndBusVolGroup, busVol, 0x0); + ASSERT_STRUCT_OFFSET(SndBusVolGroup, active, 0x300); + + struct snd_enveffect + { + snd_reverb_patch_t * reverb; //OFS: 0x0 SIZE: 0x4 + float drylevel; //OFS: 0x4 SIZE: 0x4 + float drygoal; //OFS: 0x8 SIZE: 0x4 + float dryrate; //OFS: 0xC SIZE: 0x4 + float wetlevel; //OFS: 0x10 SIZE: 0x4 + float wetgoal; //OFS: 0x14 SIZE: 0x4 + float wetrate; //OFS: 0x18 SIZE: 0x4 + bool active; //OFS: 0x1C SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(snd_enveffect, 0x20); + ASSERT_STRUCT_OFFSET(snd_enveffect, reverb, 0x0); + ASSERT_STRUCT_OFFSET(snd_enveffect, drylevel, 0x4); + ASSERT_STRUCT_OFFSET(snd_enveffect, drygoal, 0x8); + ASSERT_STRUCT_OFFSET(snd_enveffect, dryrate, 0xC); + ASSERT_STRUCT_OFFSET(snd_enveffect, wetlevel, 0x10); + ASSERT_STRUCT_OFFSET(snd_enveffect, wetgoal, 0x14); + ASSERT_STRUCT_OFFSET(snd_enveffect, wetrate, 0x18); + ASSERT_STRUCT_OFFSET(snd_enveffect, active, 0x1C); + + struct snd_listener + { + orientation_t orient; //OFS: 0x0 SIZE: 0x30 + int clientNum; //OFS: 0x30 SIZE: 0x4 + bool active; //OFS: 0x34 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(snd_listener, 0x38); + ASSERT_STRUCT_OFFSET(snd_listener, orient, 0x0); + ASSERT_STRUCT_OFFSET(snd_listener, clientNum, 0x30); + ASSERT_STRUCT_OFFSET(snd_listener, active, 0x34); + + struct snd_amplifier + { + snd_listener * listener; //OFS: 0x0 SIZE: 0x4 + int minRadius; //OFS: 0x4 SIZE: 0x4 + int maxRadius; //OFS: 0x8 SIZE: 0x4 + float falloffExp; //OFS: 0xC SIZE: 0x4 + float minVol; //OFS: 0x10 SIZE: 0x4 + float maxVol; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_amplifier, 0x18); + ASSERT_STRUCT_OFFSET(snd_amplifier, listener, 0x0); + ASSERT_STRUCT_OFFSET(snd_amplifier, minRadius, 0x4); + ASSERT_STRUCT_OFFSET(snd_amplifier, maxRadius, 0x8); + ASSERT_STRUCT_OFFSET(snd_amplifier, falloffExp, 0xC); + ASSERT_STRUCT_OFFSET(snd_amplifier, minVol, 0x10); + ASSERT_STRUCT_OFFSET(snd_amplifier, maxVol, 0x14); + + struct snd_bus_t + { + snd_bus_info_t * info; //OFS: 0x0 SIZE: 0x4 + snd_fader scriptAttenuation; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(snd_bus_t, 0x10); + ASSERT_STRUCT_OFFSET(snd_bus_t, info, 0x0); + ASSERT_STRUCT_OFFSET(snd_bus_t, scriptAttenuation, 0x4); + + struct SndFileSpecificChannelInfo + { + SndFileLoadingState loadingState; //OFS: 0x0 SIZE: 0x4 + int srcChannelCount; //OFS: 0x4 SIZE: 0x4 + int baserate; //OFS: 0x8 SIZE: 0x4 + int endtime; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SndFileSpecificChannelInfo, 0x10); + ASSERT_STRUCT_OFFSET(SndFileSpecificChannelInfo, loadingState, 0x0); + ASSERT_STRUCT_OFFSET(SndFileSpecificChannelInfo, srcChannelCount, 0x4); + ASSERT_STRUCT_OFFSET(SndFileSpecificChannelInfo, baserate, 0x8); + ASSERT_STRUCT_OFFSET(SndFileSpecificChannelInfo, endtime, 0xC); + + struct sndLengthNotifyInfo + { + SndLengthId id[4]; //OFS: 0x0 SIZE: 0x10 + void * data[4]; //OFS: 0x10 SIZE: 0x10 + int count; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(sndLengthNotifyInfo, 0x24); + ASSERT_STRUCT_OFFSET(sndLengthNotifyInfo, id, 0x0); + ASSERT_STRUCT_OFFSET(sndLengthNotifyInfo, data, 0x10); + ASSERT_STRUCT_OFFSET(sndLengthNotifyInfo, count, 0x20); + + struct snd_channel_info_t + { + SndFileSpecificChannelInfo soundFileInfo; //OFS: 0x0 SIZE: 0x10 + SndEntHandle sndEnt; //OFS: 0x10 SIZE: 0x4 + snd_entity_update entity_update; //OFS: 0x14 SIZE: 0x4 + int bus; //OFS: 0x18 SIZE: 0x4 + int startDelay; //OFS: 0x1C SIZE: 0x4 + int timeshift; //OFS: 0x20 SIZE: 0x4 + float fraction; //OFS: 0x24 SIZE: 0x4 + int startTime; //OFS: 0x28 SIZE: 0x4 + int looptime; //OFS: 0x2C SIZE: 0x4 + int totalMsec; //OFS: 0x30 SIZE: 0x4 + int playbackId; //OFS: 0x34 SIZE: 0x4 + sndLengthNotifyInfo lengthNotifyInfo; //OFS: 0x38 SIZE: 0x24 + snd_alias_t * alias0; //OFS: 0x5C SIZE: 0x4 + snd_alias_t * alias1; //OFS: 0x60 SIZE: 0x4 + int saveIndex0; //OFS: 0x64 SIZE: 0x4 + int saveIndex1; //OFS: 0x68 SIZE: 0x4 + float lerp; //OFS: 0x6C SIZE: 0x4 + float offset[3]; //OFS: 0x70 SIZE: 0xC + float position[3]; //OFS: 0x7C SIZE: 0xC + float velocity[3]; //OFS: 0x88 SIZE: 0xC + float orientation[3][3]; //OFS: 0x94 SIZE: 0x24 + float direction[3]; //OFS: 0xB8 SIZE: 0xC + float fluxVelocity[3]; //OFS: 0xC4 SIZE: 0xC + float baseDistance; //OFS: 0xD0 SIZE: 0x4 + float distanceAttenuation; //OFS: 0xD4 SIZE: 0x4 + float reverbAttenuation; //OFS: 0xD8 SIZE: 0x4 + float cylinderAttenuation; //OFS: 0xDC SIZE: 0x4 + float volModSeed; //OFS: 0xE0 SIZE: 0x4 + float volModStart; //OFS: 0xE4 SIZE: 0x4 + float pitchModSeed; //OFS: 0xE8 SIZE: 0x4 + float globalPriority; //OFS: 0xEC SIZE: 0x4 + snd_fader doppler; //OFS: 0xF0 SIZE: 0xC + snd_fader fade; //OFS: 0xFC SIZE: 0xC + snd_fader script_fade; //OFS: 0x108 SIZE: 0xC + snd_fader script_pitch; //OFS: 0x114 SIZE: 0xC + snd_fader losOcclusion; //OFS: 0x120 SIZE: 0xC + int losHitCache; //OFS: 0x12C SIZE: 0x4 + int closestListenerIndex; //OFS: 0x130 SIZE: 0x4 + snd_alias_system_t system; //OFS: 0x134 SIZE: 0x4 + float dryLevel; //OFS: 0x138 SIZE: 0x4 + float wetLevel; //OFS: 0x13C SIZE: 0x4 + snd_speaker_map pan; //OFS: 0x140 SIZE: 0x48 + bool paused; //OFS: 0x188 SIZE: 0x1 + bool timescale; //OFS: 0x189 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(snd_channel_info_t, 0x18C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, soundFileInfo, 0x0); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, sndEnt, 0x10); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, entity_update, 0x14); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, bus, 0x18); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, startDelay, 0x1C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, timeshift, 0x20); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, fraction, 0x24); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, startTime, 0x28); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, looptime, 0x2C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, totalMsec, 0x30); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, playbackId, 0x34); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, lengthNotifyInfo, 0x38); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, alias0, 0x5C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, alias1, 0x60); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, saveIndex0, 0x64); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, saveIndex1, 0x68); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, lerp, 0x6C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, offset, 0x70); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, position, 0x7C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, velocity, 0x88); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, orientation, 0x94); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, direction, 0xB8); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, fluxVelocity, 0xC4); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, baseDistance, 0xD0); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, distanceAttenuation, 0xD4); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, reverbAttenuation, 0xD8); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, cylinderAttenuation, 0xDC); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, volModSeed, 0xE0); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, volModStart, 0xE4); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, pitchModSeed, 0xE8); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, globalPriority, 0xEC); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, doppler, 0xF0); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, fade, 0xFC); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, script_fade, 0x108); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, script_pitch, 0x114); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, losOcclusion, 0x120); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, losHitCache, 0x12C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, closestListenerIndex, 0x130); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, system, 0x134); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, dryLevel, 0x138); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, wetLevel, 0x13C); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, pan, 0x140); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, paused, 0x188); + ASSERT_STRUCT_OFFSET(snd_channel_info_t, timescale, 0x189); + + struct snd_reverb_fader_t + { + snd_fader room; //OFS: 0x0 SIZE: 0xC + snd_fader roomHF; //OFS: 0xC SIZE: 0xC + snd_fader roomRolloffFactor; //OFS: 0x18 SIZE: 0xC + snd_fader decayTime; //OFS: 0x24 SIZE: 0xC + snd_fader decayHFRatio; //OFS: 0x30 SIZE: 0xC + snd_fader reflections; //OFS: 0x3C SIZE: 0xC + snd_fader reflectionsDelay; //OFS: 0x48 SIZE: 0xC + snd_fader reverb; //OFS: 0x54 SIZE: 0xC + snd_fader reverbDelay; //OFS: 0x60 SIZE: 0xC + snd_fader diffusion; //OFS: 0x6C SIZE: 0xC + snd_fader density; //OFS: 0x78 SIZE: 0xC + snd_fader HFReference; //OFS: 0x84 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(snd_reverb_fader_t, 0x90); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, room, 0x0); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, roomHF, 0xC); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, roomRolloffFactor, 0x18); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, decayTime, 0x24); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, decayHFRatio, 0x30); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, reflections, 0x3C); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, reflectionsDelay, 0x48); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, reverb, 0x54); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, reverbDelay, 0x60); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, diffusion, 0x6C); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, density, 0x78); + ASSERT_STRUCT_OFFSET(snd_reverb_fader_t, HFReference, 0x84); + + struct snd_occlusion_trace_t + { + float listener[3]; //OFS: 0x0 SIZE: 0xC + float playback[3]; //OFS: 0xC SIZE: 0xC + int cache; //OFS: 0x18 SIZE: 0x4 + int id; //OFS: 0x1C SIZE: 0x4 + float occlusion; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_occlusion_trace_t, 0x24); + ASSERT_STRUCT_OFFSET(snd_occlusion_trace_t, listener, 0x0); + ASSERT_STRUCT_OFFSET(snd_occlusion_trace_t, playback, 0xC); + ASSERT_STRUCT_OFFSET(snd_occlusion_trace_t, cache, 0x18); + ASSERT_STRUCT_OFFSET(snd_occlusion_trace_t, id, 0x1C); + ASSERT_STRUCT_OFFSET(snd_occlusion_trace_t, occlusion, 0x20); + + struct snd_local_t + { + bool Initialized2d; //OFS: 0x0 SIZE: 0x1 + bool Initialized3d; //OFS: 0x1 SIZE: 0x1 + bool paused; //OFS: 0x2 SIZE: 0x1 + int playbackIdCounter; //OFS: 0x4 SIZE: 0x4 + int playback_channels; //OFS: 0x8 SIZE: 0x4 + int pausetime; //OFS: 0xC SIZE: 0x4 + int cpu; //OFS: 0x10 SIZE: 0x4 + snd_fader volume; //OFS: 0x14 SIZE: 0xC + SndBusVolGroup busVolGroups[5]; //OFS: 0x20 SIZE: 0xF14 + SndBusVolGroup * busVol; //OFS: 0xF34 SIZE: 0x4 + snd_fader slave; //OFS: 0xF38 SIZE: 0xC + snd_enveffect envEffects[3]; //OFS: 0xF44 SIZE: 0x60 + snd_enveffect * effect; //OFS: 0xFA4 SIZE: 0x4 + bool pauseSettings[64]; //OFS: 0xFA8 SIZE: 0x40 + snd_listener listeners[2]; //OFS: 0xFE8 SIZE: 0x70 + int time; //OFS: 0x1058 SIZE: 0x4 + int looptime; //OFS: 0x105C SIZE: 0x4 + snd_amplifier amplifier; //OFS: 0x1060 SIZE: 0x18 + snd_bus_t buses[64]; //OFS: 0x1078 SIZE: 0x400 + int voice_bus; //OFS: 0x1478 SIZE: 0x4 + snd_channel_info_t chaninfo[70]; //OFS: 0x147C SIZE: 0x6C48 + int channelAliasHash[70]; //OFS: 0x80C4 SIZE: 0x118 + _BYTE gap81DC[840]; //OFS: 0x81DC SIZE: 0x348 + int max_2D_channels; //OFS: 0x8524 SIZE: 0x4 + int max_3D_channels; //OFS: 0x8528 SIZE: 0x4 + int max_stream_channels; //OFS: 0x852C SIZE: 0x4 + snd_reverb_fader_t reverb_fader; //OFS: 0x8530 SIZE: 0x90 + snd_reverb_patch_t current_reverb_patch; //OFS: 0x85C0 SIZE: 0x50 + snd_master_effect_t * masterEffect; //OFS: 0x8610 SIZE: 0x4 + snd_master_effect_t visionsetMasterEffect; //OFS: 0x8614 SIZE: 0x38 + SndDriverGlobals * global_constants; //OFS: 0x864C SIZE: 0x4 + snd_occlusion_trace_t occlusionTraces[70]; //OFS: 0x8650 SIZE: 0x9D8 + int occlusionRunning; //OFS: 0x9028 SIZE: 0x4 + char framesSinceLastOcclusionUpdate[4]; //OFS: 0x902C SIZE: 0x4 + int traceSequence; //OFS: 0x9030 SIZE: 0x4 + int lastTraceSequence; //OFS: 0x9034 SIZE: 0x4 + int inCinematic; //OFS: 0x9038 SIZE: 0x4 + int cinematicTimestamp; //OFS: 0x903C SIZE: 0x4 + int cinematicUpdate; //OFS: 0x9040 SIZE: 0x4 + int forcePause; //OFS: 0x9044 SIZE: 0x4 + int globalAttenuation; //OFS: 0x9048 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_local_t, 0x904C); + ASSERT_STRUCT_OFFSET(snd_local_t, Initialized2d, 0x0); + ASSERT_STRUCT_OFFSET(snd_local_t, Initialized3d, 0x1); + ASSERT_STRUCT_OFFSET(snd_local_t, paused, 0x2); + ASSERT_STRUCT_OFFSET(snd_local_t, playbackIdCounter, 0x4); + ASSERT_STRUCT_OFFSET(snd_local_t, playback_channels, 0x8); + ASSERT_STRUCT_OFFSET(snd_local_t, pausetime, 0xC); + ASSERT_STRUCT_OFFSET(snd_local_t, cpu, 0x10); + ASSERT_STRUCT_OFFSET(snd_local_t, volume, 0x14); + ASSERT_STRUCT_OFFSET(snd_local_t, busVolGroups, 0x20); + ASSERT_STRUCT_OFFSET(snd_local_t, busVol, 0xF34); + ASSERT_STRUCT_OFFSET(snd_local_t, slave, 0xF38); + ASSERT_STRUCT_OFFSET(snd_local_t, envEffects, 0xF44); + ASSERT_STRUCT_OFFSET(snd_local_t, effect, 0xFA4); + ASSERT_STRUCT_OFFSET(snd_local_t, pauseSettings, 0xFA8); + ASSERT_STRUCT_OFFSET(snd_local_t, listeners, 0xFE8); + ASSERT_STRUCT_OFFSET(snd_local_t, time, 0x1058); + ASSERT_STRUCT_OFFSET(snd_local_t, looptime, 0x105C); + ASSERT_STRUCT_OFFSET(snd_local_t, amplifier, 0x1060); + ASSERT_STRUCT_OFFSET(snd_local_t, buses, 0x1078); + ASSERT_STRUCT_OFFSET(snd_local_t, voice_bus, 0x1478); + ASSERT_STRUCT_OFFSET(snd_local_t, chaninfo, 0x147C); + ASSERT_STRUCT_OFFSET(snd_local_t, channelAliasHash, 0x80C4); + ASSERT_STRUCT_OFFSET(snd_local_t, gap81DC, 0x81DC); + ASSERT_STRUCT_OFFSET(snd_local_t, max_2D_channels, 0x8524); + ASSERT_STRUCT_OFFSET(snd_local_t, max_3D_channels, 0x8528); + ASSERT_STRUCT_OFFSET(snd_local_t, max_stream_channels, 0x852C); + ASSERT_STRUCT_OFFSET(snd_local_t, reverb_fader, 0x8530); + ASSERT_STRUCT_OFFSET(snd_local_t, current_reverb_patch, 0x85C0); + ASSERT_STRUCT_OFFSET(snd_local_t, masterEffect, 0x8610); + ASSERT_STRUCT_OFFSET(snd_local_t, visionsetMasterEffect, 0x8614); + ASSERT_STRUCT_OFFSET(snd_local_t, global_constants, 0x864C); + ASSERT_STRUCT_OFFSET(snd_local_t, occlusionTraces, 0x8650); + ASSERT_STRUCT_OFFSET(snd_local_t, occlusionRunning, 0x9028); + ASSERT_STRUCT_OFFSET(snd_local_t, framesSinceLastOcclusionUpdate, 0x902C); + ASSERT_STRUCT_OFFSET(snd_local_t, traceSequence, 0x9030); + ASSERT_STRUCT_OFFSET(snd_local_t, lastTraceSequence, 0x9034); + ASSERT_STRUCT_OFFSET(snd_local_t, inCinematic, 0x9038); + ASSERT_STRUCT_OFFSET(snd_local_t, cinematicTimestamp, 0x903C); + ASSERT_STRUCT_OFFSET(snd_local_t, cinematicUpdate, 0x9040); + ASSERT_STRUCT_OFFSET(snd_local_t, forcePause, 0x9044); + ASSERT_STRUCT_OFFSET(snd_local_t, globalAttenuation, 0x9048); + + struct animStringItem_t + { + const char * string; //OFS: 0x0 SIZE: 0x4 + int hash; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animStringItem_t, 0x8); + ASSERT_STRUCT_OFFSET(animStringItem_t, string, 0x0); + ASSERT_STRUCT_OFFSET(animStringItem_t, hash, 0x4); + + struct animConditionTable_t + { + animScriptConditionTypes_t type; //OFS: 0x0 SIZE: 0x4 + animStringItem_t * values; //OFS: 0x4 SIZE: 0x4 + int minValue; //OFS: 0x8 SIZE: 0x4 + int maxValue; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animConditionTable_t, 0x10); + ASSERT_STRUCT_OFFSET(animConditionTable_t, type, 0x0); + ASSERT_STRUCT_OFFSET(animConditionTable_t, values, 0x4); + ASSERT_STRUCT_OFFSET(animConditionTable_t, minValue, 0x8); + ASSERT_STRUCT_OFFSET(animConditionTable_t, maxValue, 0xC); + + struct SurfaceTypeSoundList + { + char * surfaceSoundBase; //OFS: 0x0 SIZE: 0x4 + char ** soundAliasList; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SurfaceTypeSoundList, 0x8); + ASSERT_STRUCT_OFFSET(SurfaceTypeSoundList, surfaceSoundBase, 0x0); + ASSERT_STRUCT_OFFSET(SurfaceTypeSoundList, soundAliasList, 0x4); + + struct VariantWind + { + float wind_vector[3]; //OFS: 0x0 SIZE: 0xC + float rustle_angular_frequency[3]; //OFS: 0xC SIZE: 0xC + float rustle_amplitude[3]; //OFS: 0x18 SIZE: 0xC + float blade_acceleration; //OFS: 0x24 SIZE: 0x4 + float blade_velocity; //OFS: 0x28 SIZE: 0x4 + int reset_timer; //OFS: 0x2C SIZE: 0x4 + int gust_start; //OFS: 0x30 SIZE: 0x4 + int gust_dur; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VariantWind, 0x38); + ASSERT_STRUCT_OFFSET(VariantWind, wind_vector, 0x0); + ASSERT_STRUCT_OFFSET(VariantWind, rustle_angular_frequency, 0xC); + ASSERT_STRUCT_OFFSET(VariantWind, rustle_amplitude, 0x18); + ASSERT_STRUCT_OFFSET(VariantWind, blade_acceleration, 0x24); + ASSERT_STRUCT_OFFSET(VariantWind, blade_velocity, 0x28); + ASSERT_STRUCT_OFFSET(VariantWind, reset_timer, 0x2C); + ASSERT_STRUCT_OFFSET(VariantWind, gust_start, 0x30); + ASSERT_STRUCT_OFFSET(VariantWind, gust_dur, 0x34); + + struct GrassWind + { + float pos[2]; //OFS: 0x0 SIZE: 0x8 + float dir[2]; //OFS: 0x8 SIZE: 0x8 + float strength_skew; //OFS: 0x10 SIZE: 0x4 + int life_span; //OFS: 0x14 SIZE: 0x4 + int start_time; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GrassWind, 0x1C); + ASSERT_STRUCT_OFFSET(GrassWind, pos, 0x0); + ASSERT_STRUCT_OFFSET(GrassWind, dir, 0x8); + ASSERT_STRUCT_OFFSET(GrassWind, strength_skew, 0x10); + ASSERT_STRUCT_OFFSET(GrassWind, life_span, 0x14); + ASSERT_STRUCT_OFFSET(GrassWind, start_time, 0x18); + + struct vehAnimClient_t + { + bool initialized; //OFS: 0x0 SIZE: 0x1 + VehicleSeatPositions curSeat; //OFS: 0x4 SIZE: 0x4 + VehicleSeatPositions prevSeat; //OFS: 0x8 SIZE: 0x4 + bool moving; //OFS: 0xC SIZE: 0x1 + int animStage; //OFS: 0x10 SIZE: 0x4 + int animIndex; //OFS: 0x14 SIZE: 0x4 + int tagName; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(vehAnimClient_t, 0x1C); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, initialized, 0x0); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, curSeat, 0x4); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, prevSeat, 0x8); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, moving, 0xC); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, animStage, 0x10); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, animIndex, 0x14); + ASSERT_STRUCT_OFFSET(vehAnimClient_t, tagName, 0x18); + + struct FxUniqueHandleDb_Node + { + FxEffect * effect; //OFS: 0x0 SIZE: 0x4 + FxUniqueHandleDb_Node * next; //OFS: 0x4 SIZE: 0x4 + unsigned int handle; //OFS: 0x8 SIZE: 0x4 + int pad[1]; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxUniqueHandleDb_Node, 0x10); + ASSERT_STRUCT_OFFSET(FxUniqueHandleDb_Node, effect, 0x0); + ASSERT_STRUCT_OFFSET(FxUniqueHandleDb_Node, next, 0x4); + ASSERT_STRUCT_OFFSET(FxUniqueHandleDb_Node, handle, 0x8); + ASSERT_STRUCT_OFFSET(FxUniqueHandleDb_Node, pad, 0xC); + + struct FxUniqueHandleDb + { + FxUniqueHandleDb_Node nodes[1024]; //OFS: 0x0 SIZE: 0x4000 + }; + ASSERT_STRUCT_SIZE(FxUniqueHandleDb, 0x4000); + ASSERT_STRUCT_OFFSET(FxUniqueHandleDb, nodes, 0x0); + + struct snd_whizby + { + snd_alias_t * alias; //OFS: 0x0 SIZE: 0x4 + float start[3]; //OFS: 0x4 SIZE: 0xC + float end[3]; //OFS: 0x10 SIZE: 0xC + float t; //OFS: 0x1C SIZE: 0x4 + int playbackId; //OFS: 0x20 SIZE: 0x4 + int shooter; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_whizby, 0x28); + ASSERT_STRUCT_OFFSET(snd_whizby, alias, 0x0); + ASSERT_STRUCT_OFFSET(snd_whizby, start, 0x4); + ASSERT_STRUCT_OFFSET(snd_whizby, end, 0x10); + ASSERT_STRUCT_OFFSET(snd_whizby, t, 0x1C); + ASSERT_STRUCT_OFFSET(snd_whizby, playbackId, 0x20); + ASSERT_STRUCT_OFFSET(snd_whizby, shooter, 0x24); + + struct snd_speaker_angle + { + snd_speaker_flag speaker; //OFS: 0x0 SIZE: 0x4 + float angle; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_speaker_angle, 0x8); + ASSERT_STRUCT_OFFSET(snd_speaker_angle, speaker, 0x0); + ASSERT_STRUCT_OFFSET(snd_speaker_angle, angle, 0x4); + + struct snd_speaker_config + { + char * name; //OFS: 0x0 SIZE: 0x4 + snd_speaker_flag outputFormat; //OFS: 0x4 SIZE: 0x4 + unsigned int speakerCount; //OFS: 0x8 SIZE: 0x4 + unsigned int speakerMapCount; //OFS: 0xC SIZE: 0x4 + unsigned int angleCount; //OFS: 0x10 SIZE: 0x4 + snd_speaker_angle angles[8]; //OFS: 0x14 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(snd_speaker_config, 0x54); + ASSERT_STRUCT_OFFSET(snd_speaker_config, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_speaker_config, outputFormat, 0x4); + ASSERT_STRUCT_OFFSET(snd_speaker_config, speakerCount, 0x8); + ASSERT_STRUCT_OFFSET(snd_speaker_config, speakerMapCount, 0xC); + ASSERT_STRUCT_OFFSET(snd_speaker_config, angleCount, 0x10); + ASSERT_STRUCT_OFFSET(snd_speaker_config, angles, 0x14); + + // SoundState + + struct GrassForce + { + float worldPosition[3]; //OFS: 0x0 SIZE: 0xC + float radius; //OFS: 0xC SIZE: 0x4 + float strength; //OFS: 0x10 SIZE: 0x4 + float frequency; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GrassForce, 0x18); + ASSERT_STRUCT_OFFSET(GrassForce, worldPosition, 0x0); + ASSERT_STRUCT_OFFSET(GrassForce, radius, 0xC); + ASSERT_STRUCT_OFFSET(GrassForce, strength, 0x10); + ASSERT_STRUCT_OFFSET(GrassForce, frequency, 0x14); + + struct GrassWindForce + { + float worldPosition[2]; //OFS: 0x0 SIZE: 0x8 + float inverseRadiusSquared; //OFS: 0x8 SIZE: 0x4 + float strength; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GrassWindForce, 0x10); + ASSERT_STRUCT_OFFSET(GrassWindForce, worldPosition, 0x0); + ASSERT_STRUCT_OFFSET(GrassWindForce, inverseRadiusSquared, 0x8); + ASSERT_STRUCT_OFFSET(GrassWindForce, strength, 0xC); + + struct PerFrameFoliageInfo + { + GrassForce grassInstantForces[16]; //OFS: 0x0 SIZE: 0x180 + GrassForce grassPersistantForces[8]; //OFS: 0x180 SIZE: 0xC0 + GrassWindForce grassWindForces[16]; //OFS: 0x240 SIZE: 0x100 + unsigned int numGrassInstantForces; //OFS: 0x340 SIZE: 0x4 + unsigned int numGrassPersistantForces; //OFS: 0x344 SIZE: 0x4 + unsigned int numGrassWindForces; //OFS: 0x348 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PerFrameFoliageInfo, 0x34C); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, grassInstantForces, 0x0); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, grassPersistantForces, 0x180); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, grassWindForces, 0x240); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, numGrassInstantForces, 0x340); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, numGrassPersistantForces, 0x344); + ASSERT_STRUCT_OFFSET(PerFrameFoliageInfo, numGrassWindForces, 0x348); + + struct GrassPersistForce + { + float worldPosition[3]; //OFS: 0x0 SIZE: 0xC + float radius; //OFS: 0xC SIZE: 0x4 + float strength; //OFS: 0x10 SIZE: 0x4 + float frequency; //OFS: 0x14 SIZE: 0x4 + float age; //OFS: 0x18 SIZE: 0x4 + float maxAge; //OFS: 0x1C SIZE: 0x4 + float maxStrength; //OFS: 0x20 SIZE: 0x4 + bool isActive; //OFS: 0x24 SIZE: 0x1 + ForceType forceType; //OFS: 0x28 SIZE: 0x4 + unsigned int id; //OFS: 0x2C SIZE: 0x4 + float curForcePercent; //OFS: 0x30 SIZE: 0x4 + float trgForcePercent; //OFS: 0x34 SIZE: 0x4 + ShakeForceState shakeForceState; //OFS: 0x38 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GrassPersistForce, 0x3C); + ASSERT_STRUCT_OFFSET(GrassPersistForce, worldPosition, 0x0); + ASSERT_STRUCT_OFFSET(GrassPersistForce, radius, 0xC); + ASSERT_STRUCT_OFFSET(GrassPersistForce, strength, 0x10); + ASSERT_STRUCT_OFFSET(GrassPersistForce, frequency, 0x14); + ASSERT_STRUCT_OFFSET(GrassPersistForce, age, 0x18); + ASSERT_STRUCT_OFFSET(GrassPersistForce, maxAge, 0x1C); + ASSERT_STRUCT_OFFSET(GrassPersistForce, maxStrength, 0x20); + ASSERT_STRUCT_OFFSET(GrassPersistForce, isActive, 0x24); + ASSERT_STRUCT_OFFSET(GrassPersistForce, forceType, 0x28); + ASSERT_STRUCT_OFFSET(GrassPersistForce, id, 0x2C); + ASSERT_STRUCT_OFFSET(GrassPersistForce, curForcePercent, 0x30); + ASSERT_STRUCT_OFFSET(GrassPersistForce, trgForcePercent, 0x34); + ASSERT_STRUCT_OFFSET(GrassPersistForce, shakeForceState, 0x38); + + struct ClientFoliageInfo + { + PerFrameFoliageInfo perFrame[2]; //OFS: 0x0 SIZE: 0x698 + GrassPersistForce persistantForces[8]; //OFS: 0x698 SIZE: 0x1E0 + float clientPlayerPos[3]; //OFS: 0x878 SIZE: 0xC + bool clientIsActive; //OFS: 0x884 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(ClientFoliageInfo, 0x888); + ASSERT_STRUCT_OFFSET(ClientFoliageInfo, perFrame, 0x0); + ASSERT_STRUCT_OFFSET(ClientFoliageInfo, persistantForces, 0x698); + ASSERT_STRUCT_OFFSET(ClientFoliageInfo, clientPlayerPos, 0x878); + ASSERT_STRUCT_OFFSET(ClientFoliageInfo, clientIsActive, 0x884); + + struct WindState + { + float windDirection[3]; //OFS: 0x0 SIZE: 0xC + float windSpringAngle[16]; //OFS: 0xC SIZE: 0x40 + float windRustleAngle[16][3]; //OFS: 0x4C SIZE: 0xC0 + }; + ASSERT_STRUCT_SIZE(WindState, 0x10C); + ASSERT_STRUCT_OFFSET(WindState, windDirection, 0x0); + ASSERT_STRUCT_OFFSET(WindState, windSpringAngle, 0xC); + ASSERT_STRUCT_OFFSET(WindState, windRustleAngle, 0x4C); + + struct __declspec(align(8)) cdl_proftimer + { + unsigned __int64 stamp; //OFS: 0x0 SIZE: 0x8 + unsigned __int64 value; //OFS: 0x8 SIZE: 0x8 + unsigned __int64 avr; //OFS: 0x10 SIZE: 0x8 + unsigned __int64 tot; //OFS: 0x18 SIZE: 0x8 + unsigned __int64 capture_count; //OFS: 0x20 SIZE: 0x8 + unsigned __int64 calls; //OFS: 0x28 SIZE: 0x8 + bool capture; //OFS: 0x30 SIZE: 0x1 + unsigned __int64 mx[5]; //OFS: 0x38 SIZE: 0x28 + }; + ASSERT_STRUCT_SIZE(cdl_proftimer, 0x60); + ASSERT_STRUCT_OFFSET(cdl_proftimer, stamp, 0x0); + ASSERT_STRUCT_OFFSET(cdl_proftimer, value, 0x8); + ASSERT_STRUCT_OFFSET(cdl_proftimer, avr, 0x10); + ASSERT_STRUCT_OFFSET(cdl_proftimer, tot, 0x18); + ASSERT_STRUCT_OFFSET(cdl_proftimer, capture_count, 0x20); + ASSERT_STRUCT_OFFSET(cdl_proftimer, calls, 0x28); + ASSERT_STRUCT_OFFSET(cdl_proftimer, capture, 0x30); + ASSERT_STRUCT_OFFSET(cdl_proftimer, mx, 0x38); + + struct WaterSimulationCmdUpdate + { + unsigned int startTile; //OFS: 0x0 SIZE: 0x4 + unsigned int srcBuf; //OFS: 0x4 SIZE: 0x4 + unsigned int destBuf; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(WaterSimulationCmdUpdate, 0xC); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdUpdate, startTile, 0x0); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdUpdate, srcBuf, 0x4); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdUpdate, destBuf, 0x8); + + struct GfxWaterVertex + { + char pos[4]; //OFS: 0x0 SIZE: 0x4 + char normal[4]; //OFS: 0x4 SIZE: 0x4 + GfxColor color; //OFS: 0x8 SIZE: 0x4 + char texCoord[4]; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWaterVertex, 0x10); + ASSERT_STRUCT_OFFSET(GfxWaterVertex, pos, 0x0); + ASSERT_STRUCT_OFFSET(GfxWaterVertex, normal, 0x4); + ASSERT_STRUCT_OFFSET(GfxWaterVertex, color, 0x8); + ASSERT_STRUCT_OFFSET(GfxWaterVertex, texCoord, 0xC); + + struct tilemesh_t + { + int srcU; //OFS: 0x0 SIZE: 0x4 + int srcV; //OFS: 0x4 SIZE: 0x4 + int worldX; //OFS: 0x8 SIZE: 0x4 + int worldY; //OFS: 0xC SIZE: 0x4 + int worldZ; //OFS: 0x10 SIZE: 0x4 + int lastSkinTime; //OFS: 0x14 SIZE: 0x4 + unsigned int baseVertex; //OFS: 0x18 SIZE: 0x4 + GfxWaterVertex * lockedData; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(tilemesh_t, 0x20); + ASSERT_STRUCT_OFFSET(tilemesh_t, srcU, 0x0); + ASSERT_STRUCT_OFFSET(tilemesh_t, srcV, 0x4); + ASSERT_STRUCT_OFFSET(tilemesh_t, worldX, 0x8); + ASSERT_STRUCT_OFFSET(tilemesh_t, worldY, 0xC); + ASSERT_STRUCT_OFFSET(tilemesh_t, worldZ, 0x10); + ASSERT_STRUCT_OFFSET(tilemesh_t, lastSkinTime, 0x14); + ASSERT_STRUCT_OFFSET(tilemesh_t, baseVertex, 0x18); + ASSERT_STRUCT_OFFSET(tilemesh_t, lockedData, 0x1C); + + union WaterSimulationCmdSkin_u + { + tilemesh_t * meshesEA[16]; //OFS: 0x0 SIZE: 0x40 + tilemesh_t * meshes[16]; //OFS: 0x1 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(WaterSimulationCmdSkin_u, 0x40); + + struct WaterSimulationCmdSkin + { + unsigned int startTile; //OFS: 0x0 SIZE: 0x4 + unsigned int srcBuf; //OFS: 0x4 SIZE: 0x4 + WaterSimulationCmdSkin_u u; //OFS: 0x8 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(WaterSimulationCmdSkin, 0x48); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdSkin, startTile, 0x0); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdSkin, srcBuf, 0x4); + ASSERT_STRUCT_OFFSET(WaterSimulationCmdSkin, u, 0x8); + + struct WaterSimulationCmd + { + WaterSimulationCmdUpdate update; //OFS: 0x0 SIZE: 0xC + WaterSimulationCmdSkin skin; //OFS: 0xC SIZE: 0x48 + }; + ASSERT_STRUCT_SIZE(WaterSimulationCmd, 0x54); + ASSERT_STRUCT_OFFSET(WaterSimulationCmd, update, 0x0); + ASSERT_STRUCT_OFFSET(WaterSimulationCmd, skin, 0xC); + + struct staticmodeltrace_t + { + TraceExtents extents; //OFS: 0x0 SIZE: 0x30 + int contents; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(staticmodeltrace_t, 0x34); + ASSERT_STRUCT_OFFSET(staticmodeltrace_t, extents, 0x0); + ASSERT_STRUCT_OFFSET(staticmodeltrace_t, contents, 0x30); + + struct cg_hudelem_t + { + float x; //OFS: 0x0 SIZE: 0x4 + float y; //OFS: 0x4 SIZE: 0x4 + float rotation; //OFS: 0x8 SIZE: 0x4 + float width; //OFS: 0xC SIZE: 0x4 + float height; //OFS: 0x10 SIZE: 0x4 + char hudElemLabel[256]; //OFS: 0x14 SIZE: 0x100 + float labelWidth; //OFS: 0x114 SIZE: 0x4 + char hudElemText[256]; //OFS: 0x118 SIZE: 0x100 + float textWidth; //OFS: 0x218 SIZE: 0x4 + Font_s * font; //OFS: 0x21C SIZE: 0x4 + float fontScale; //OFS: 0x220 SIZE: 0x4 + float fontHeight; //OFS: 0x224 SIZE: 0x4 + float color[4]; //OFS: 0x228 SIZE: 0x10 + int timeNow; //OFS: 0x238 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cg_hudelem_t, 0x23C); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, x, 0x0); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, y, 0x4); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, rotation, 0x8); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, width, 0xC); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, height, 0x10); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, hudElemLabel, 0x14); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, labelWidth, 0x114); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, hudElemText, 0x118); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, textWidth, 0x218); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, font, 0x21C); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, fontScale, 0x220); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, fontHeight, 0x224); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, color, 0x228); + ASSERT_STRUCT_OFFSET(cg_hudelem_t, timeNow, 0x238); + + struct __declspec(align(2)) GfxCmdHeader + { + GfxRenderCommand id; //OFS: 0x0 SIZE: 0x1 + unsigned __int16 byteCount; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxCmdHeader, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdHeader, id, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdHeader, byteCount, 0x2); + + struct GfxCmdDrawText2D + { + GfxCmdHeader header; //OFS: 0x0 SIZE: 0x4 + float x; //OFS: 0x4 SIZE: 0x4 + float y; //OFS: 0x8 SIZE: 0x4 + float rotation; //OFS: 0xC SIZE: 0x4 + Font_s * font; //OFS: 0x10 SIZE: 0x4 + float xScale; //OFS: 0x14 SIZE: 0x4 + float yScale; //OFS: 0x18 SIZE: 0x4 + GfxColor color; //OFS: 0x1C SIZE: 0x4 + int maxChars; //OFS: 0x20 SIZE: 0x4 + int renderFlags; //OFS: 0x24 SIZE: 0x4 + int cursorPos; //OFS: 0x28 SIZE: 0x4 + char cursorLetter; //OFS: 0x2C SIZE: 0x1 + GfxColor glowForceColor; //OFS: 0x30 SIZE: 0x4 + int fxBirthTime; //OFS: 0x34 SIZE: 0x4 + int fxLetterTime; //OFS: 0x38 SIZE: 0x4 + int fxDecayStartTime; //OFS: 0x3C SIZE: 0x4 + int fxDecayDuration; //OFS: 0x40 SIZE: 0x4 + Material * fxMaterial; //OFS: 0x44 SIZE: 0x4 + Material * fxMaterialGlow; //OFS: 0x48 SIZE: 0x4 + float padding; //OFS: 0x4C SIZE: 0x4 + char text[3]; //OFS: 0x50 SIZE: 0x3 + }; + ASSERT_STRUCT_SIZE(GfxCmdDrawText2D, 0x54); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, header, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, x, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, y, 0x8); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, rotation, 0xC); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, font, 0x10); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, xScale, 0x14); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, yScale, 0x18); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, color, 0x1C); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, maxChars, 0x20); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, renderFlags, 0x24); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, cursorPos, 0x28); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, cursorLetter, 0x2C); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, glowForceColor, 0x30); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxBirthTime, 0x34); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxLetterTime, 0x38); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxDecayStartTime, 0x3C); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxDecayDuration, 0x40); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxMaterial, 0x44); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, fxMaterialGlow, 0x48); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, padding, 0x4C); + ASSERT_STRUCT_OFFSET(GfxCmdDrawText2D, text, 0x50); + + struct GfxCmdArray + { + unsigned __int8 * cmds; //OFS: 0x0 SIZE: 0x4 + int usedTotal; //OFS: 0x4 SIZE: 0x4 + int usedCritical; //OFS: 0x8 SIZE: 0x4 + GfxCmdHeader * lastCmd; //OFS: 0xC SIZE: 0x4 + int byteSize; //OFS: 0x10 SIZE: 0x4 + int warnSize; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCmdArray, 0x18); + ASSERT_STRUCT_OFFSET(GfxCmdArray, cmds, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdArray, usedTotal, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdArray, usedCritical, 0x8); + ASSERT_STRUCT_OFFSET(GfxCmdArray, lastCmd, 0xC); + ASSERT_STRUCT_OFFSET(GfxCmdArray, byteSize, 0x10); + ASSERT_STRUCT_OFFSET(GfxCmdArray, warnSize, 0x14); + + struct GfxCmdStretchPic + { + GfxCmdHeader header; //OFS: 0x0 SIZE: 0x4 + Material * material; //OFS: 0x4 SIZE: 0x4 + float x; //OFS: 0x8 SIZE: 0x4 + float y; //OFS: 0xC SIZE: 0x4 + float w; //OFS: 0x10 SIZE: 0x4 + float h; //OFS: 0x14 SIZE: 0x4 + float s0; //OFS: 0x18 SIZE: 0x4 + float t0; //OFS: 0x1C SIZE: 0x4 + float s1; //OFS: 0x20 SIZE: 0x4 + float t1; //OFS: 0x24 SIZE: 0x4 + GfxColor color; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCmdStretchPic, 0x2C); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, header, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, material, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, x, 0x8); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, y, 0xC); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, w, 0x10); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, h, 0x14); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, s0, 0x18); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, t0, 0x1C); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, s1, 0x20); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, t1, 0x24); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPic, color, 0x28); + + struct GfxCmdDrawQuadPic + { + GfxCmdHeader header; //OFS: 0x0 SIZE: 0x4 + Material * material; //OFS: 0x4 SIZE: 0x4 + float verts[4][2]; //OFS: 0x8 SIZE: 0x20 + GfxColor color; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCmdDrawQuadPic, 0x2C); + ASSERT_STRUCT_OFFSET(GfxCmdDrawQuadPic, header, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdDrawQuadPic, material, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdDrawQuadPic, verts, 0x8); + ASSERT_STRUCT_OFFSET(GfxCmdDrawQuadPic, color, 0x28); + + struct config_s + { + unsigned __int16 good_length; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 max_lazy; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 nice_length; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 max_chain; //OFS: 0x6 SIZE: 0x2 + block_state (__cdecl *func)(deflate_or_inflate_state *, int); //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(config_s, 0xC); + ASSERT_STRUCT_OFFSET(config_s, good_length, 0x0); + ASSERT_STRUCT_OFFSET(config_s, max_lazy, 0x2); + ASSERT_STRUCT_OFFSET(config_s, nice_length, 0x4); + ASSERT_STRUCT_OFFSET(config_s, max_chain, 0x6); + ASSERT_STRUCT_OFFSET(config_s, func, 0x8); + + struct __declspec(align(8)) sharedUiInfo_t + { + CachedAssets_t assets; //OFS: 0x0 SIZE: 0x54 + char field_54[4]; //OFS: 0x54 SIZE: 0x4 + int sharedUiInfo_playerCount; //OFS: 0x58 SIZE: 0x4 + _BYTE field_5C[256]; //OFS: 0x5C SIZE: 0x100 + int field_15C[1]; //OFS: 0x15C SIZE: 0x4 + int field_160; //OFS: 0x160 SIZE: 0x4 + int field_164; //OFS: 0x164 SIZE: 0x4 + int field_168; //OFS: 0x168 SIZE: 0x4 + int field_16C; //OFS: 0x16C SIZE: 0x4 + char field_170[12]; //OFS: 0x170 SIZE: 0xC + char field_17C[1396]; //OFS: 0x17C SIZE: 0x574 + int field_6F0; //OFS: 0x6F0 SIZE: 0x4 + _BYTE gap6F4[3456]; //OFS: 0x6F4 SIZE: 0xD80 + int field_1474; //OFS: 0x1474 SIZE: 0x4 + char field_1478[11]; //OFS: 0x1478 SIZE: 0xB + char field_1483; //OFS: 0x1483 SIZE: 0x1 + char field_1484[1396]; //OFS: 0x1484 SIZE: 0x574 + int field_19F8; //OFS: 0x19F8 SIZE: 0x4 + char field_19FC[32]; //OFS: 0x19FC SIZE: 0x20 + char field_1A1C[56]; //OFS: 0x1A1C SIZE: 0x38 + int field_1A54[1]; //OFS: 0x1A54 SIZE: 0x4 + char field_1A58[8]; //OFS: 0x1A58 SIZE: 0x8 + int field_1A60[1]; //OFS: 0x1A60 SIZE: 0x4 + _BYTE gap1A64[128]; //OFS: 0x1A64 SIZE: 0x80 + int field_1AE4[1]; //OFS: 0x1AE4 SIZE: 0x4 + int field_1AE8[7653]; //OFS: 0x1AE8 SIZE: 0x7794 + int field_927C[1]; //OFS: 0x927C SIZE: 0x4 + int field_9280; //OFS: 0x9280 SIZE: 0x4 + int field_9284; //OFS: 0x9284 SIZE: 0x4 + int field_9288; //OFS: 0x9288 SIZE: 0x4 + _BYTE gap928C[8]; //OFS: 0x928C SIZE: 0x8 + int field_9294; //OFS: 0x9294 SIZE: 0x4 + int field_9298; //OFS: 0x9298 SIZE: 0x4 + _BYTE gap929C[8]; //OFS: 0x929C SIZE: 0x8 + int sharedUiInfo_serverHardwareIconList[1]; //OFS: 0x92A4 SIZE: 0x4 + int sharedUiInfo_modList[383]; //OFS: 0x92A8 SIZE: 0x5FC + int sharedUiInfo_modCount; //OFS: 0x98A4 SIZE: 0x4 + int field_98A8; //OFS: 0x98A8 SIZE: 0x4 + char field_98AC[4]; //OFS: 0x98AC SIZE: 0x4 + __int64 field_98B0; //OFS: 0x98B0 SIZE: 0x8 + int field_98B8; //OFS: 0x98B8 SIZE: 0x4 + int field_98BC; //OFS: 0x98BC SIZE: 0x4 + _BYTE gap98C0[1104]; //OFS: 0x98C0 SIZE: 0x450 + int field_9D10; //OFS: 0x9D10 SIZE: 0x4 + char field_9D14[4]; //OFS: 0x9D14 SIZE: 0x4 + int field_9D18; //OFS: 0x9D18 SIZE: 0x4 + int field_9D1C; //OFS: 0x9D1C SIZE: 0x4 + _BYTE gap9D20[4]; //OFS: 0x9D20 SIZE: 0x4 + int field_9D24; //OFS: 0x9D24 SIZE: 0x4 + int field_9D28[1]; //OFS: 0x9D28 SIZE: 0x4 + int serverNumber[20000]; //OFS: 0x9D2C SIZE: 0x13880 + size_t field_1D5AC; //OFS: 0x1D5AC SIZE: 0x4 + int field_1D5B0; //OFS: 0x1D5B0 SIZE: 0x4 + int field_1D5B4; //OFS: 0x1D5B4 SIZE: 0x4 + int field_1D5B8; //OFS: 0x1D5B8 SIZE: 0x4 + char field_1D5BC[4]; //OFS: 0x1D5BC SIZE: 0x4 + int field_1D5C0; //OFS: 0x1D5C0 SIZE: 0x4 + int field_1D5C4; //OFS: 0x1D5C4 SIZE: 0x4 + int field_1D5C8; //OFS: 0x1D5C8 SIZE: 0x4 + _BYTE gap1D5CC[16]; //OFS: 0x1D5CC SIZE: 0x10 + char field_1D5DC[1023]; //OFS: 0x1D5DC SIZE: 0x3FF + char field_1D9DB[1]; //OFS: 0x1D9DB SIZE: 0x1 + char field_1D9DC[100]; //OFS: 0x1D9DC SIZE: 0x64 + char field_1DA40[64]; //OFS: 0x1DA40 SIZE: 0x40 + char field_1DA80[64]; //OFS: 0x1DA80 SIZE: 0x40 + int field_1DAC0[771]; //OFS: 0x1DAC0 SIZE: 0xC0C + int haredUiInfo_serverStatusInfo_numLines; //OFS: 0x1E6CC SIZE: 0x4 + int field_1E6D0; //OFS: 0x1E6D0 SIZE: 0x4 + int field_1E6D4; //OFS: 0x1E6D4 SIZE: 0x4 + _BYTE gap1E6D8[2239]; //OFS: 0x1E6D8 SIZE: 0x8BF + char field_1EF97; //OFS: 0x1EF97 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(sharedUiInfo_t, 0x1EF98); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, assets, 0x0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_54, 0x54); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, sharedUiInfo_playerCount, 0x58); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_5C, 0x5C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_15C, 0x15C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_160, 0x160); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_164, 0x164); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_168, 0x168); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_16C, 0x16C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_170, 0x170); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_17C, 0x17C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_6F0, 0x6F0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap6F4, 0x6F4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1474, 0x1474); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1478, 0x1478); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1483, 0x1483); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1484, 0x1484); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_19F8, 0x19F8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_19FC, 0x19FC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1A1C, 0x1A1C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1A54, 0x1A54); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1A58, 0x1A58); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1A60, 0x1A60); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap1A64, 0x1A64); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1AE4, 0x1AE4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1AE8, 0x1AE8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_927C, 0x927C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9280, 0x9280); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9284, 0x9284); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9288, 0x9288); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap928C, 0x928C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9294, 0x9294); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9298, 0x9298); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap929C, 0x929C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, sharedUiInfo_serverHardwareIconList, 0x92A4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, sharedUiInfo_modList, 0x92A8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, sharedUiInfo_modCount, 0x98A4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_98A8, 0x98A8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_98AC, 0x98AC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_98B0, 0x98B0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_98B8, 0x98B8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_98BC, 0x98BC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap98C0, 0x98C0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D10, 0x9D10); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D14, 0x9D14); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D18, 0x9D18); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D1C, 0x9D1C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap9D20, 0x9D20); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D24, 0x9D24); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_9D28, 0x9D28); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, serverNumber, 0x9D2C); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5AC, 0x1D5AC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5B0, 0x1D5B0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5B4, 0x1D5B4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5B8, 0x1D5B8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5BC, 0x1D5BC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5C0, 0x1D5C0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5C4, 0x1D5C4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5C8, 0x1D5C8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap1D5CC, 0x1D5CC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D5DC, 0x1D5DC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D9DB, 0x1D9DB); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1D9DC, 0x1D9DC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1DA40, 0x1DA40); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1DA80, 0x1DA80); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1DAC0, 0x1DAC0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, haredUiInfo_serverStatusInfo_numLines, 0x1E6CC); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1E6D0, 0x1E6D0); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1E6D4, 0x1E6D4); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, gap1E6D8, 0x1E6D8); + ASSERT_STRUCT_OFFSET(sharedUiInfo_t, field_1EF97, 0x1EF97); + + struct playlistEntry + { + char mapname[32]; //OFS: 0x0 SIZE: 0x20 + char gametype[16]; //OFS: 0x20 SIZE: 0x10 + int fullWeight; //OFS: 0x30 SIZE: 0x4 + int remainingWeight; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(playlistEntry, 0x38); + ASSERT_STRUCT_OFFSET(playlistEntry, mapname, 0x0); + ASSERT_STRUCT_OFFSET(playlistEntry, gametype, 0x20); + ASSERT_STRUCT_OFFSET(playlistEntry, fullWeight, 0x30); + ASSERT_STRUCT_OFFSET(playlistEntry, remainingWeight, 0x34); + + struct playlistInfo + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + char description[256]; //OFS: 0x40 SIZE: 0x100 + char lockdescription[256]; //OFS: 0x140 SIZE: 0x100 + char icon[32]; //OFS: 0x240 SIZE: 0x20 + char rules[1024]; //OFS: 0x260 SIZE: 0x400 + playlistEntry entries[128]; //OFS: 0x660 SIZE: 0x1C00 + int numEntries; //OFS: 0x2260 SIZE: 0x4 + int unlockXp; //OFS: 0x2264 SIZE: 0x4 + int gametypeban; //OFS: 0x2268 SIZE: 0x4 + int maxPartySize; //OFS: 0x226C SIZE: 0x4 + int dlc; //OFS: 0x2270 SIZE: 0x4 + char ranked; //OFS: 0x2274 SIZE: 0x1 + char collectors; //OFS: 0x2275 SIZE: 0x1 + char finishedsolo; //OFS: 0x2276 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(playlistInfo, 0x2278); + ASSERT_STRUCT_OFFSET(playlistInfo, name, 0x0); + ASSERT_STRUCT_OFFSET(playlistInfo, description, 0x40); + ASSERT_STRUCT_OFFSET(playlistInfo, lockdescription, 0x140); + ASSERT_STRUCT_OFFSET(playlistInfo, icon, 0x240); + ASSERT_STRUCT_OFFSET(playlistInfo, rules, 0x260); + ASSERT_STRUCT_OFFSET(playlistInfo, entries, 0x660); + ASSERT_STRUCT_OFFSET(playlistInfo, numEntries, 0x2260); + ASSERT_STRUCT_OFFSET(playlistInfo, unlockXp, 0x2264); + ASSERT_STRUCT_OFFSET(playlistInfo, gametypeban, 0x2268); + ASSERT_STRUCT_OFFSET(playlistInfo, maxPartySize, 0x226C); + ASSERT_STRUCT_OFFSET(playlistInfo, dlc, 0x2270); + ASSERT_STRUCT_OFFSET(playlistInfo, ranked, 0x2274); + ASSERT_STRUCT_OFFSET(playlistInfo, collectors, 0x2275); + ASSERT_STRUCT_OFFSET(playlistInfo, finishedsolo, 0x2276); + + struct __declspec(align(1)) playlistGametype + { + char scriptName[16]; //OFS: 0x0 SIZE: 0x10 + char internalName[16]; //OFS: 0x10 SIZE: 0x10 + char localizedName[64]; //OFS: 0x20 SIZE: 0x40 + char rules[1024]; //OFS: 0x60 SIZE: 0x400 + bool teamBased; //OFS: 0x460 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(playlistGametype, 0x461); + ASSERT_STRUCT_OFFSET(playlistGametype, scriptName, 0x0); + ASSERT_STRUCT_OFFSET(playlistGametype, internalName, 0x10); + ASSERT_STRUCT_OFFSET(playlistGametype, localizedName, 0x20); + ASSERT_STRUCT_OFFSET(playlistGametype, rules, 0x60); + ASSERT_STRUCT_OFFSET(playlistGametype, teamBased, 0x460); + + struct PendingSave + { + char filename[64]; //OFS: 0x0 SIZE: 0x40 + char description[256]; //OFS: 0x40 SIZE: 0x100 + char screenShotName[64]; //OFS: 0x140 SIZE: 0x40 + int saveId; //OFS: 0x180 SIZE: 0x4 + SaveType saveType; //OFS: 0x184 SIZE: 0x4 + unsigned int commitLevel; //OFS: 0x188 SIZE: 0x4 + bool suppressPlayerNotify; //OFS: 0x18C SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(PendingSave, 0x190); + ASSERT_STRUCT_OFFSET(PendingSave, filename, 0x0); + ASSERT_STRUCT_OFFSET(PendingSave, description, 0x40); + ASSERT_STRUCT_OFFSET(PendingSave, screenShotName, 0x140); + ASSERT_STRUCT_OFFSET(PendingSave, saveId, 0x180); + ASSERT_STRUCT_OFFSET(PendingSave, saveType, 0x184); + ASSERT_STRUCT_OFFSET(PendingSave, commitLevel, 0x188); + ASSERT_STRUCT_OFFSET(PendingSave, suppressPlayerNotify, 0x18C); + + struct PendingSaveList + { + PendingSave pendingSaves[3]; //OFS: 0x0 SIZE: 0x4B0 + int count; //OFS: 0x4B0 SIZE: 0x4 + bool isAutoSaving; //OFS: 0x4B4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(PendingSaveList, 0x4B8); + ASSERT_STRUCT_OFFSET(PendingSaveList, pendingSaves, 0x0); + ASSERT_STRUCT_OFFSET(PendingSaveList, count, 0x4B0); + ASSERT_STRUCT_OFFSET(PendingSaveList, isAutoSaving, 0x4B4); + + struct GfxCmdStretchPicRotateXY + { + GfxCmdHeader header; //OFS: 0x0 SIZE: 0x4 + Material * material; //OFS: 0x4 SIZE: 0x4 + float x; //OFS: 0x8 SIZE: 0x4 + float y; //OFS: 0xC SIZE: 0x4 + float w; //OFS: 0x10 SIZE: 0x4 + float h; //OFS: 0x14 SIZE: 0x4 + float s0; //OFS: 0x18 SIZE: 0x4 + float t0; //OFS: 0x1C SIZE: 0x4 + float s1; //OFS: 0x20 SIZE: 0x4 + float t1; //OFS: 0x24 SIZE: 0x4 + GfxColor color; //OFS: 0x28 SIZE: 0x4 + float rotation; //OFS: 0x2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCmdStretchPicRotateXY, 0x30); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, header, 0x0); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, material, 0x4); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, x, 0x8); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, y, 0xC); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, w, 0x10); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, h, 0x14); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, s0, 0x18); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, t0, 0x1C); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, s1, 0x20); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, t1, 0x24); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, color, 0x28); + ASSERT_STRUCT_OFFSET(GfxCmdStretchPicRotateXY, rotation, 0x2C); + + struct XZoneMemory + { + XBlock blocks[9]; //OFS: 0x0 SIZE: 0x48 + char * lockedVertexData; //OFS: 0x48 SIZE: 0x4 + char * lockedIndexData; //OFS: 0x4C SIZE: 0x4 + void * vertexBuffer; //OFS: 0x50 SIZE: 0x4 + void * indexBuffer; //OFS: 0x54 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XZoneMemory, 0x58); + ASSERT_STRUCT_OFFSET(XZoneMemory, blocks, 0x0); + ASSERT_STRUCT_OFFSET(XZoneMemory, lockedVertexData, 0x48); + ASSERT_STRUCT_OFFSET(XZoneMemory, lockedIndexData, 0x4C); + ASSERT_STRUCT_OFFSET(XZoneMemory, vertexBuffer, 0x50); + ASSERT_STRUCT_OFFSET(XZoneMemory, indexBuffer, 0x54); + + struct SaveMemoryGlob + { + SaveGame * committedGameSave; //OFS: 0x0 SIZE: 0x4 + SaveGame * currentGameSave; //OFS: 0x4 SIZE: 0x4 + SaveGame game0; //OFS: 0x8 SIZE: 0x1054C + SaveGame game1; //OFS: 0x10554 SIZE: 0x1054C + char field_20AA0[2097152]; //OFS: 0x20AA0 SIZE: 0x200000 + char field_220AA0[1048576]; //OFS: 0x220AA0 SIZE: 0x100000 + char field_320AA0[2097152]; //OFS: 0x320AA0 SIZE: 0x200000 + char field_520AA0[1048576]; //OFS: 0x520AA0 SIZE: 0x100000 + int recentLoadTime; //OFS: 0x620AA0 SIZE: 0x4 + char isCommitForced; //OFS: 0x620AA4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SaveMemoryGlob, 0x620AA8); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, committedGameSave, 0x0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, currentGameSave, 0x4); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, game0, 0x8); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, game1, 0x10554); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, field_20AA0, 0x20AA0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, field_220AA0, 0x220AA0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, field_320AA0, 0x320AA0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, field_520AA0, 0x520AA0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, recentLoadTime, 0x620AA0); + ASSERT_STRUCT_OFFSET(SaveMemoryGlob, isCommitForced, 0x620AA4); + + struct file_in_zip_read_info_s + { + char * read_buffer; //OFS: 0x0 SIZE: 0x4 + z_stream_s stream; //OFS: 0x4 SIZE: 0x34 + unsigned int pos_in_zipfile; //OFS: 0x38 SIZE: 0x4 + unsigned int stream_initialised; //OFS: 0x3C SIZE: 0x4 + unsigned int offset_local_extrafield; //OFS: 0x40 SIZE: 0x4 + unsigned int size_local_extrafield; //OFS: 0x44 SIZE: 0x4 + unsigned int pos_local_extrafield; //OFS: 0x48 SIZE: 0x4 + unsigned int rest_read_compressed; //OFS: 0x4C SIZE: 0x4 + unsigned int rest_read_uncompressed; //OFS: 0x50 SIZE: 0x4 + _iobuf * file; //OFS: 0x54 SIZE: 0x4 + unsigned int compression_method; //OFS: 0x58 SIZE: 0x4 + unsigned int byte_before_the_zipfile; //OFS: 0x5C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(file_in_zip_read_info_s, 0x60); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, read_buffer, 0x0); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, stream, 0x4); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, pos_in_zipfile, 0x38); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, stream_initialised, 0x3C); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, offset_local_extrafield, 0x40); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, size_local_extrafield, 0x44); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, pos_local_extrafield, 0x48); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, rest_read_compressed, 0x4C); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, rest_read_uncompressed, 0x50); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, file, 0x54); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, compression_method, 0x58); + ASSERT_STRUCT_OFFSET(file_in_zip_read_info_s, byte_before_the_zipfile, 0x5C); + + struct flamePhysics_t + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float newPos[3]; //OFS: 0xC SIZE: 0xC + float velocity[3]; //OFS: 0x18 SIZE: 0xC + float invStartSpeed; //OFS: 0x24 SIZE: 0x4 + float gravity; //OFS: 0x28 SIZE: 0x4 + float rotation; //OFS: 0x2C SIZE: 0x4 + float rotVel; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flamePhysics_t, 0x34); + ASSERT_STRUCT_OFFSET(flamePhysics_t, origin, 0x0); + ASSERT_STRUCT_OFFSET(flamePhysics_t, newPos, 0xC); + ASSERT_STRUCT_OFFSET(flamePhysics_t, velocity, 0x18); + ASSERT_STRUCT_OFFSET(flamePhysics_t, invStartSpeed, 0x24); + ASSERT_STRUCT_OFFSET(flamePhysics_t, gravity, 0x28); + ASSERT_STRUCT_OFFSET(flamePhysics_t, rotation, 0x2C); + ASSERT_STRUCT_OFFSET(flamePhysics_t, rotVel, 0x30); + + struct flameSize_t + { + float current; //OFS: 0x0 SIZE: 0x4 + float rate; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameSize_t, 0x8); + ASSERT_STRUCT_OFFSET(flameSize_t, current, 0x0); + ASSERT_STRUCT_OFFSET(flameSize_t, rate, 0x4); + + struct flameAge_t + { + int lastUpdateTime; //OFS: 0x0 SIZE: 0x4 + int startTime; //OFS: 0x4 SIZE: 0x4 + int endTime; //OFS: 0x8 SIZE: 0x4 + float invTimeScale; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameAge_t, 0x10); + ASSERT_STRUCT_OFFSET(flameAge_t, lastUpdateTime, 0x0); + ASSERT_STRUCT_OFFSET(flameAge_t, startTime, 0x4); + ASSERT_STRUCT_OFFSET(flameAge_t, endTime, 0x8); + ASSERT_STRUCT_OFFSET(flameAge_t, invTimeScale, 0xC); + + struct flameList_t + { + flameGeneric_s * prev; //OFS: 0x0 SIZE: 0x4 + flameGeneric_s * next; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameList_t, 0x8); + ASSERT_STRUCT_OFFSET(flameList_t, prev, 0x0); + ASSERT_STRUCT_OFFSET(flameList_t, next, 0x4); + + struct flameRender_s + { + char name[128]; //OFS: 0x0 SIZE: 0x80 + flameGeneric_s * fireList; //OFS: 0x80 SIZE: 0x4 + flameGeneric_s * dripsList; //OFS: 0x84 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameRender_s, 0x88); + ASSERT_STRUCT_OFFSET(flameRender_s, name, 0x0); + ASSERT_STRUCT_OFFSET(flameRender_s, fireList, 0x80); + ASSERT_STRUCT_OFFSET(flameRender_s, dripsList, 0x84); + + struct flameGeneric_s + { + flamePhysics_t phys; //OFS: 0x0 SIZE: 0x34 + flameSize_t size; //OFS: 0x34 SIZE: 0x8 + flameAge_t age; //OFS: 0x3C SIZE: 0x10 + flameList_t listGlobal; //OFS: 0x4C SIZE: 0x8 + flameList_t listLocal; //OFS: 0x54 SIZE: 0x8 + flameStream_s * stream; //OFS: 0x5C SIZE: 0x4 + __int32 _bf_60; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameGeneric_s, 0x64); + ASSERT_STRUCT_OFFSET(flameGeneric_s, phys, 0x0); + ASSERT_STRUCT_OFFSET(flameGeneric_s, size, 0x34); + ASSERT_STRUCT_OFFSET(flameGeneric_s, age, 0x3C); + ASSERT_STRUCT_OFFSET(flameGeneric_s, listGlobal, 0x4C); + ASSERT_STRUCT_OFFSET(flameGeneric_s, listLocal, 0x54); + ASSERT_STRUCT_OFFSET(flameGeneric_s, stream, 0x5C); + ASSERT_STRUCT_OFFSET(flameGeneric_s, _bf_60, 0x60); + + struct flameChunk_s + { + flameGeneric_s gen; //OFS: 0x0 SIZE: 0x64 + int spawnFireInterval; //OFS: 0x64 SIZE: 0x4 + int lastSpawnFire; //OFS: 0x68 SIZE: 0x4 + int spawnDripsInterval; //OFS: 0x6C SIZE: 0x4 + int spawnSmokeInterval; //OFS: 0x70 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameChunk_s, 0x74); + ASSERT_STRUCT_OFFSET(flameChunk_s, gen, 0x0); + ASSERT_STRUCT_OFFSET(flameChunk_s, spawnFireInterval, 0x64); + ASSERT_STRUCT_OFFSET(flameChunk_s, lastSpawnFire, 0x68); + ASSERT_STRUCT_OFFSET(flameChunk_s, spawnDripsInterval, 0x6C); + ASSERT_STRUCT_OFFSET(flameChunk_s, spawnSmokeInterval, 0x70); + + struct flameStream_s + { + flameGeneric_s gen; //OFS: 0x0 SIZE: 0x64 + float fuelVerts[128][3]; //OFS: 0x64 SIZE: 0x600 + float flameVerts[128][3]; //OFS: 0x664 SIZE: 0x600 + flameTable * flameVars; //OFS: 0xC64 SIZE: 0x4 + flameRender_s * flameRend; //OFS: 0xC68 SIZE: 0x4 + flameChunk_s * chunkList; //OFS: 0xC6C SIZE: 0x4 + int lastSmokeChunkTime; //OFS: 0xC70 SIZE: 0x4 + int lastDripChunkTime; //OFS: 0xC74 SIZE: 0x4 + int entityNum; //OFS: 0xC78 SIZE: 0x4 + int damage; //OFS: 0xC7C SIZE: 0x4 + float damageDuration; //OFS: 0xC80 SIZE: 0x4 + float damageInterval; //OFS: 0xC84 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameStream_s, 0xC88); + ASSERT_STRUCT_OFFSET(flameStream_s, gen, 0x0); + ASSERT_STRUCT_OFFSET(flameStream_s, fuelVerts, 0x64); + ASSERT_STRUCT_OFFSET(flameStream_s, flameVerts, 0x664); + ASSERT_STRUCT_OFFSET(flameStream_s, flameVars, 0xC64); + ASSERT_STRUCT_OFFSET(flameStream_s, flameRend, 0xC68); + ASSERT_STRUCT_OFFSET(flameStream_s, chunkList, 0xC6C); + ASSERT_STRUCT_OFFSET(flameStream_s, lastSmokeChunkTime, 0xC70); + ASSERT_STRUCT_OFFSET(flameStream_s, lastDripChunkTime, 0xC74); + ASSERT_STRUCT_OFFSET(flameStream_s, entityNum, 0xC78); + ASSERT_STRUCT_OFFSET(flameStream_s, damage, 0xC7C); + ASSERT_STRUCT_OFFSET(flameStream_s, damageDuration, 0xC80); + ASSERT_STRUCT_OFFSET(flameStream_s, damageInterval, 0xC84); + + struct flameSmoke_t + { + flameGeneric_s gen; //OFS: 0x0 SIZE: 0x64 + Material * material; //OFS: 0x64 SIZE: 0x4 + float smokeFadein; //OFS: 0x68 SIZE: 0x4 + float smokeFadeout; //OFS: 0x6C SIZE: 0x4 + float smokeMaxAlpha; //OFS: 0x70 SIZE: 0x4 + float smokeBrightness; //OFS: 0x74 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameSmoke_t, 0x78); + ASSERT_STRUCT_OFFSET(flameSmoke_t, gen, 0x0); + ASSERT_STRUCT_OFFSET(flameSmoke_t, material, 0x64); + ASSERT_STRUCT_OFFSET(flameSmoke_t, smokeFadein, 0x68); + ASSERT_STRUCT_OFFSET(flameSmoke_t, smokeFadeout, 0x6C); + ASSERT_STRUCT_OFFSET(flameSmoke_t, smokeMaxAlpha, 0x70); + ASSERT_STRUCT_OFFSET(flameSmoke_t, smokeBrightness, 0x74); + + struct flameDrips_t + { + flameGeneric_s gen; //OFS: 0x0 SIZE: 0x64 + flameRender_s * flameRend; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameDrips_t, 0x68); + ASSERT_STRUCT_OFFSET(flameDrips_t, gen, 0x0); + ASSERT_STRUCT_OFFSET(flameDrips_t, flameRend, 0x64); + + struct flameFire_t + { + flameGeneric_s gen; //OFS: 0x0 SIZE: 0x64 + flameRender_s * flameRend; //OFS: 0x64 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameFire_t, 0x68); + ASSERT_STRUCT_OFFSET(flameFire_t, gen, 0x0); + ASSERT_STRUCT_OFFSET(flameFire_t, flameRend, 0x64); + + struct flameWeaponConfig_t + { + bool bIsFiring; //OFS: 0x0 SIZE: 0x1 + bool bFireWhileIdle; //OFS: 0x1 SIZE: 0x1 + float origin[3]; //OFS: 0x4 SIZE: 0xC + float angle[3]; //OFS: 0x10 SIZE: 0xC + float strength; //OFS: 0x1C SIZE: 0x4 + float thickness; //OFS: 0x20 SIZE: 0x4 + float burnRate; //OFS: 0x24 SIZE: 0x4 + float entityOrigin[3]; //OFS: 0x28 SIZE: 0xC + flameTable * fTable; //OFS: 0x34 SIZE: 0x4 + int damage; //OFS: 0x38 SIZE: 0x4 + float damageDuration; //OFS: 0x3C SIZE: 0x4 + float damageInterval; //OFS: 0x40 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameWeaponConfig_t, 0x44); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, bIsFiring, 0x0); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, bFireWhileIdle, 0x1); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, origin, 0x4); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, angle, 0x10); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, strength, 0x1C); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, thickness, 0x20); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, burnRate, 0x24); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, entityOrigin, 0x28); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, fTable, 0x34); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, damage, 0x38); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, damageDuration, 0x3C); + ASSERT_STRUCT_OFFSET(flameWeaponConfig_t, damageInterval, 0x40); + + struct flameChunkSpawnVars_t + { + int time; //OFS: 0x0 SIZE: 0x4 + int duration; //OFS: 0x4 SIZE: 0x4 + float origin[3]; //OFS: 0x8 SIZE: 0xC + float angle[3]; //OFS: 0x14 SIZE: 0xC + float speed; //OFS: 0x20 SIZE: 0x4 + float decel; //OFS: 0x24 SIZE: 0x4 + float gravityStart; //OFS: 0x28 SIZE: 0x4 + float gravityEnd; //OFS: 0x2C SIZE: 0x4 + float sizeMax; //OFS: 0x30 SIZE: 0x4 + float sizeStart; //OFS: 0x34 SIZE: 0x4 + float sizeEnd; //OFS: 0x38 SIZE: 0x4 + float sizeRate; //OFS: 0x3C SIZE: 0x4 + float spawnFireIntervalStart; //OFS: 0x40 SIZE: 0x4 + float spawnFireIntervalEnd; //OFS: 0x44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameChunkSpawnVars_t, 0x48); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, time, 0x0); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, duration, 0x4); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, origin, 0x8); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, angle, 0x14); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, speed, 0x20); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, decel, 0x24); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, gravityStart, 0x28); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, gravityEnd, 0x2C); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, sizeMax, 0x30); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, sizeStart, 0x34); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, sizeEnd, 0x38); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, sizeRate, 0x3C); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, spawnFireIntervalStart, 0x40); + ASSERT_STRUCT_OFFSET(flameChunkSpawnVars_t, spawnFireIntervalEnd, 0x44); + + struct FxEffectDefTableEntry + { + unsigned int key; //OFS: 0x0 SIZE: 0x4 + FxEffectDef * effectDef; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxEffectDefTableEntry, 0x8); + ASSERT_STRUCT_OFFSET(FxEffectDefTableEntry, key, 0x0); + ASSERT_STRUCT_OFFSET(FxEffectDefTableEntry, effectDef, 0x4); + + struct FxEffectDefTable + { + int count; //OFS: 0x0 SIZE: 0x4 + FxEffectDefTableEntry entries[512]; //OFS: 0x4 SIZE: 0x1000 + }; + ASSERT_STRUCT_SIZE(FxEffectDefTable, 0x1004); + ASSERT_STRUCT_OFFSET(FxEffectDefTable, count, 0x0); + ASSERT_STRUCT_OFFSET(FxEffectDefTable, entries, 0x4); + + struct flameSource_t + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float angle[3]; //OFS: 0xC SIZE: 0xC + float entityOrigin[3]; //OFS: 0x18 SIZE: 0xC + flameStream_s * currentStream; //OFS: 0x24 SIZE: 0x4 + int lastUsedTime; //OFS: 0x28 SIZE: 0x4 + int entityNum; //OFS: 0x2C SIZE: 0x4 + int firstDobjHandle; //OFS: 0x30 SIZE: 0x4 + int thirdDobjHandle; //OFS: 0x34 SIZE: 0x4 + snd_fader soundLerp; //OFS: 0x38 SIZE: 0xC + int lastSoundTime; //OFS: 0x44 SIZE: 0x4 + float flameSoundPoint[3]; //OFS: 0x48 SIZE: 0xC + int soundOffLoopId; //OFS: 0x54 SIZE: 0x4 + int soundOnLoopId; //OFS: 0x58 SIZE: 0x4 + int soundCooldownId; //OFS: 0x5C SIZE: 0x4 + int soundIgniteId; //OFS: 0x60 SIZE: 0x4 + bool bIsFiring; //OFS: 0x64 SIZE: 0x1 + bool inUse; //OFS: 0x65 SIZE: 0x1 + bool is_server_alloc; //OFS: 0x66 SIZE: 0x1 + bool wasFiring; //OFS: 0x67 SIZE: 0x1 + unsigned __int8 firstBoneIndex; //OFS: 0x68 SIZE: 0x1 + unsigned __int8 thirdBoneIndex; //OFS: 0x69 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(flameSource_t, 0x6C); + ASSERT_STRUCT_OFFSET(flameSource_t, origin, 0x0); + ASSERT_STRUCT_OFFSET(flameSource_t, angle, 0xC); + ASSERT_STRUCT_OFFSET(flameSource_t, entityOrigin, 0x18); + ASSERT_STRUCT_OFFSET(flameSource_t, currentStream, 0x24); + ASSERT_STRUCT_OFFSET(flameSource_t, lastUsedTime, 0x28); + ASSERT_STRUCT_OFFSET(flameSource_t, entityNum, 0x2C); + ASSERT_STRUCT_OFFSET(flameSource_t, firstDobjHandle, 0x30); + ASSERT_STRUCT_OFFSET(flameSource_t, thirdDobjHandle, 0x34); + ASSERT_STRUCT_OFFSET(flameSource_t, soundLerp, 0x38); + ASSERT_STRUCT_OFFSET(flameSource_t, lastSoundTime, 0x44); + ASSERT_STRUCT_OFFSET(flameSource_t, flameSoundPoint, 0x48); + ASSERT_STRUCT_OFFSET(flameSource_t, soundOffLoopId, 0x54); + ASSERT_STRUCT_OFFSET(flameSource_t, soundOnLoopId, 0x58); + ASSERT_STRUCT_OFFSET(flameSource_t, soundCooldownId, 0x5C); + ASSERT_STRUCT_OFFSET(flameSource_t, soundIgniteId, 0x60); + ASSERT_STRUCT_OFFSET(flameSource_t, bIsFiring, 0x64); + ASSERT_STRUCT_OFFSET(flameSource_t, inUse, 0x65); + ASSERT_STRUCT_OFFSET(flameSource_t, is_server_alloc, 0x66); + ASSERT_STRUCT_OFFSET(flameSource_t, wasFiring, 0x67); + ASSERT_STRUCT_OFFSET(flameSource_t, firstBoneIndex, 0x68); + ASSERT_STRUCT_OFFSET(flameSource_t, thirdBoneIndex, 0x69); + + struct __declspec(align(1)) _FM_BURNSAMPLE + { + ComBurnableSample active[32]; //OFS: 0x0 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(_FM_BURNSAMPLE, 0x20); + ASSERT_STRUCT_OFFSET(_FM_BURNSAMPLE, active, 0x0); + + struct _fm_activecell + { + float pos[3]; //OFS: 0x0 SIZE: 0xC + int time; //OFS: 0xC SIZE: 0x4 + unsigned int index; //OFS: 0x10 SIZE: 0x4 + float spreadProbability; //OFS: 0x14 SIZE: 0x4 + unsigned __int8 x; //OFS: 0x18 SIZE: 0x1 + unsigned __int8 y; //OFS: 0x19 SIZE: 0x1 + unsigned __int8 stage; //OFS: 0x1A SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(_fm_activecell, 0x1C); + ASSERT_STRUCT_OFFSET(_fm_activecell, pos, 0x0); + ASSERT_STRUCT_OFFSET(_fm_activecell, time, 0xC); + ASSERT_STRUCT_OFFSET(_fm_activecell, index, 0x10); + ASSERT_STRUCT_OFFSET(_fm_activecell, spreadProbability, 0x14); + ASSERT_STRUCT_OFFSET(_fm_activecell, x, 0x18); + ASSERT_STRUCT_OFFSET(_fm_activecell, y, 0x19); + ASSERT_STRUCT_OFFSET(_fm_activecell, stage, 0x1A); + + struct loadAnim_t + { + scr_anim_s anim; //OFS: 0x0 SIZE: 0x4 + int iNameHash; //OFS: 0x4 SIZE: 0x4 + char szAnimName[64]; //OFS: 0x8 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(loadAnim_t, 0x48); + ASSERT_STRUCT_OFFSET(loadAnim_t, anim, 0x0); + ASSERT_STRUCT_OFFSET(loadAnim_t, iNameHash, 0x4); + ASSERT_STRUCT_OFFSET(loadAnim_t, szAnimName, 0x8); + + struct animVehicleSeats_t + { + int seats; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(animVehicleSeats_t, 0x4); + ASSERT_STRUCT_OFFSET(animVehicleSeats_t, seats, 0x0); + + struct TIMED_RADIUS_DAMAGE + { + float pos[3]; //OFS: 0x0 SIZE: 0xC + int life; //OFS: 0xC SIZE: 0x4 + float radiusSqr; //OFS: 0x10 SIZE: 0x4 + int damage; //OFS: 0x14 SIZE: 0x4 + int rate; //OFS: 0x18 SIZE: 0x4 + int mod; //OFS: 0x1C SIZE: 0x4 + int weapon; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(TIMED_RADIUS_DAMAGE, 0x24); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, pos, 0x0); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, life, 0xC); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, radiusSqr, 0x10); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, damage, 0x14); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, rate, 0x18); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, mod, 0x1C); + ASSERT_STRUCT_OFFSET(TIMED_RADIUS_DAMAGE, weapon, 0x20); + + struct VehicleLocalPhysics + { + trace_t groundTrace; //OFS: 0x0 SIZE: 0x34 + int hasGround; //OFS: 0x34 SIZE: 0x4 + int onGround; //OFS: 0x38 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(VehicleLocalPhysics, 0x3C); + ASSERT_STRUCT_OFFSET(VehicleLocalPhysics, groundTrace, 0x0); + ASSERT_STRUCT_OFFSET(VehicleLocalPhysics, hasGround, 0x34); + ASSERT_STRUCT_OFFSET(VehicleLocalPhysics, onGround, 0x38); + + struct VehiclePhysicsBackup + { + vehicle_pathpos_t pathPos; //OFS: 0x0 SIZE: 0xC0 + vehicle_physic_t phys; //OFS: 0xC0 SIZE: 0x108 + }; + ASSERT_STRUCT_SIZE(VehiclePhysicsBackup, 0x1C8); + ASSERT_STRUCT_OFFSET(VehiclePhysicsBackup, pathPos, 0x0); + ASSERT_STRUCT_OFFSET(VehiclePhysicsBackup, phys, 0xC0); + + struct phys_free_list_NitrousVehicle_T_internal_base + { + phys_free_list_NitrousVehicle_T_internal * m_prev_T_internal; //OFS: 0x0 SIZE: 0x4 + phys_free_list_NitrousVehicle_T_internal * m_next_T_internal; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(phys_free_list_NitrousVehicle_T_internal_base, 0x8); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle_T_internal_base, m_prev_T_internal, 0x0); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle_T_internal_base, m_next_T_internal, 0x4); + + struct phys_free_list_NitrousVehicle_T_internal + { + NitrousVehicle m_data; //OFS: 0x0 SIZE: 0x380 + phys_free_list_NitrousVehicle_T_internal_base m_ptr; //OFS: 0x380 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(phys_free_list_NitrousVehicle_T_internal, 0x388); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle_T_internal, m_data, 0x0); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle_T_internal, m_ptr, 0x380); + + struct phys_memory_heap + { + char * m_buffer_start; //OFS: 0x0 SIZE: 0x4 + char * m_buffer_end; //OFS: 0x4 SIZE: 0x4 + char * m_buffer_cur; //OFS: 0x8 SIZE: 0x4 + char * m_user_start; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(phys_memory_heap, 0x10); + ASSERT_STRUCT_OFFSET(phys_memory_heap, m_buffer_start, 0x0); + ASSERT_STRUCT_OFFSET(phys_memory_heap, m_buffer_end, 0x4); + ASSERT_STRUCT_OFFSET(phys_memory_heap, m_buffer_cur, 0x8); + ASSERT_STRUCT_OFFSET(phys_memory_heap, m_user_start, 0xC); + + struct phys_memory_manager_new + { + int m_memory_buffer_size; //OFS: 0x0 SIZE: 0x4 + int m_memory_buffer_alignment; //OFS: 0x4 SIZE: 0x4 + void * m_memory_buffer; //OFS: 0x8 SIZE: 0x4 + phys_memory_heap m_allocater; //OFS: 0xC SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(phys_memory_manager_new, 0x1C); + ASSERT_STRUCT_OFFSET(phys_memory_manager_new, m_memory_buffer_size, 0x0); + ASSERT_STRUCT_OFFSET(phys_memory_manager_new, m_memory_buffer_alignment, 0x4); + ASSERT_STRUCT_OFFSET(phys_memory_manager_new, m_memory_buffer, 0x8); + ASSERT_STRUCT_OFFSET(phys_memory_manager_new, m_allocater, 0xC); + + struct phys_free_list_NitrousVehicle + { + phys_free_list_NitrousVehicle_T_internal_base m_dummy_head; //OFS: 0x0 SIZE: 0x8 + int m_allocated_slot_count; //OFS: 0x8 SIZE: 0x4 + phys_memory_manager_new * m_pmm; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(phys_free_list_NitrousVehicle, 0x10); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle, m_dummy_head, 0x0); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle, m_allocated_slot_count, 0x8); + ASSERT_STRUCT_OFFSET(phys_free_list_NitrousVehicle, m_pmm, 0xC); + + struct HudGrenade + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float predicted_dmg_ratio; //OFS: 0xC SIZE: 0x4 + float predicted_time_ratio; //OFS: 0x10 SIZE: 0x4 + Material * material; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(HudGrenade, 0x18); + ASSERT_STRUCT_OFFSET(HudGrenade, origin, 0x0); + ASSERT_STRUCT_OFFSET(HudGrenade, predicted_dmg_ratio, 0xC); + ASSERT_STRUCT_OFFSET(HudGrenade, predicted_time_ratio, 0x10); + ASSERT_STRUCT_OFFSET(HudGrenade, material, 0x14); + + struct SaveTimeGlob + { + bool isSaving; //OFS: 0x0 SIZE: 0x1 + bool callWrite; //OFS: 0x1 SIZE: 0x1 + int saveTime; //OFS: 0x4 SIZE: 0x4 + bool hasfirstFrameShown; //OFS: 0x8 SIZE: 0x1 + const char * saveMenuName; //OFS: 0xC SIZE: 0x4 + char execOnSuccess[256]; //OFS: 0x10 SIZE: 0x100 + bool hasExecOnSuccess; //OFS: 0x110 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(SaveTimeGlob, 0x114); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, isSaving, 0x0); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, callWrite, 0x1); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, saveTime, 0x4); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, hasfirstFrameShown, 0x8); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, saveMenuName, 0xC); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, execOnSuccess, 0x10); + ASSERT_STRUCT_OFFSET(SaveTimeGlob, hasExecOnSuccess, 0x110); + + struct SentientGlobals + { + int lastTime; //OFS: 0x0 SIZE: 0x4 + int lastSample; //OFS: 0x4 SIZE: 0x4 + float playerTrail[2][3]; //OFS: 0x8 SIZE: 0x18 + int sampleTime[2]; //OFS: 0x20 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(SentientGlobals, 0x28); + ASSERT_STRUCT_OFFSET(SentientGlobals, lastTime, 0x0); + ASSERT_STRUCT_OFFSET(SentientGlobals, lastSample, 0x4); + ASSERT_STRUCT_OFFSET(SentientGlobals, playerTrail, 0x8); + ASSERT_STRUCT_OFFSET(SentientGlobals, sampleTime, 0x20); + + struct DynEnt_FadeData + { + unsigned __int16 id; //OFS: 0x0 SIZE: 0x2 + int startTime; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEnt_FadeData, 0x8); + ASSERT_STRUCT_OFFSET(DynEnt_FadeData, id, 0x0); + ASSERT_STRUCT_OFFSET(DynEnt_FadeData, startTime, 0x4); + - typedef void(__cdecl* BuiltinMethod)(scr_entref_t); - typedef void(__cdecl* BuiltinFunction)(); #ifdef __cplusplus } diff --git a/src/game/xasset.hpp b/src/game/xasset.hpp new file mode 100644 index 0000000..6852073 --- /dev/null +++ b/src/game/xasset.hpp @@ -0,0 +1,5422 @@ +#pragma once + +#ifdef __cplusplus +#include +#endif + +#ifdef __cplusplus +namespace game +{ +#endif + + struct pathnode_t; + struct pathnode_tree_t; + struct GfxPortal; + struct GfxCell; + struct menuDef_t; + + enum XAssetType + { + ASSET_TYPE_XMODELPIECES = 0x0, + ASSET_TYPE_PHYSPRESET = 0x1, + ASSET_TYPE_PHYSCONSTRAINTS = 0x2, + ASSET_TYPE_DESTRUCTIBLEDEF = 0x3, + ASSET_TYPE_XANIMPARTS = 0x4, + ASSET_TYPE_XMODEL = 0x5, + ASSET_TYPE_MATERIAL = 0x6, + ASSET_TYPE_TECHNIQUE_SET = 0x7, + ASSET_TYPE_IMAGE = 0x8, + ASSET_TYPE_SOUND = 0x9, + ASSET_TYPE_LOADED_SOUND = 0xA, + ASSET_TYPE_CLIPMAP = 0xB, + ASSET_TYPE_CLIPMAP_PVS = 0xC, + ASSET_TYPE_COMWORLD = 0xD, + ASSET_TYPE_GAMEWORLD_SP = 0xE, + ASSET_TYPE_GAMEWORLD_MP = 0xF, + ASSET_TYPE_MAP_ENTS = 0x10, + ASSET_TYPE_GFXWORLD = 0x11, + ASSET_TYPE_LIGHT_DEF = 0x12, + ASSET_TYPE_UI_MAP = 0x13, + ASSET_TYPE_FONT = 0x14, + ASSET_TYPE_MENULIST = 0x15, + ASSET_TYPE_MENU = 0x16, + ASSET_TYPE_LOCALIZE_ENTRY = 0x17, + ASSET_TYPE_WEAPON = 0x18, + ASSET_TYPE_SNDDRIVER_GLOBALS = 0x19, + ASSET_TYPE_FX = 0x1A, + ASSET_TYPE_IMPACT_FX = 0x1B, + ASSET_TYPE_AITYPE = 0x1C, + ASSET_TYPE_MPTYPE = 0x1D, + ASSET_TYPE_CHARACTER = 0x1E, + ASSET_TYPE_XMODELALIAS = 0x1F, + ASSET_TYPE_RAWFILE = 0x20, + ASSET_TYPE_STRINGTABLE = 0x21, + ASSET_TYPE_PACK_INDEX = 0x22, + ASSET_TYPE_COUNT = 0x23, + ASSET_TYPE_STRING = 0x23, + ASSET_TYPE_ASSETLIST = 0x24, + }; + + enum MapType + { + MAPTYPE_NONE = 0x0, + MAPTYPE_INVALID1 = 0x1, + MAPTYPE_INVALID2 = 0x2, + MAPTYPE_2D = 0x3, + MAPTYPE_3D = 0x4, + MAPTYPE_CUBE = 0x5, + MAPTYPE_COUNT = 0x6, + }; + + enum ConstraintType : __int32 + { + CONSTRAINT_NONE = 0x0, + CONSTRAINT_POINT = 0x1, + CONSTRAINT_DISTANCE = 0x2, + CONSTRAINT_HINGE = 0x3, + CONSTRAINT_JOINT = 0x4, + CONSTRAINT_ACTUATOR = 0x5, + CONSTRAINT_FAKE_SHAKE = 0x6, + CONSTRAINT_LAUNCH = 0x7, + CONSTRAINT_ROPE = 0x8, + NUM_CONSTRAINT_TYPES = 0x9, + }; + + enum AttachPointType : __int32 + { + ATTACH_POINT_WORLD = 0x0, + ATTACH_POINT_DYNENT = 0x1, + ATTACH_POINT_ENT = 0x2, + ATTACH_POINT_BONE = 0x3, + }; + + enum snd_limit_type_t : __int32 + { + SND_LIMIT_NONE = 0x0, + SND_LIMIT_OLDEST = 0x1, + SND_LIMIT_REJECT = 0x2, + SND_LIMIT_PRIORITY = 0x3, + SND_LIMIT_SOFTEST = 0x4, + SND_LIMIT_COUNT = 0x5, + }; + + enum snd_randomize_type_t : __int32 + { + SND_RANDOMIZE_INSTANCE = 0x0, + SND_RANDOMIZE_ENTITY_VOLUME = 0x1, + SND_RANDOMIZE_ENTITY_PITCH = 0x2, + SND_RANDOMIZE_ENTITY_VARIANT = 0x4, + }; + + enum DynEntityType : __int32 + { + DYNENT_TYPE_INVALID = 0x0, + DYNENT_TYPE_CLUTTER = 0x1, + DYNENT_TYPE_DESTRUCT = 0x2, + DYNENT_TYPE_COUNT = 0x3, + }; + + enum nodeType : __int32 + { + NODE_BADNODE = 0x0, + NODE_PATHNODE = 0x1, + NODE_COVER_STAND = 0x2, + NODE_COVER_CROUCH = 0x3, + NODE_COVER_CROUCH_WINDOW = 0x4, + NODE_COVER_PRONE = 0x5, + NODE_COVER_RIGHT = 0x6, + NODE_COVER_LEFT = 0x7, + NODE_COVER_WIDE_RIGHT = 0x8, + NODE_COVER_WIDE_LEFT = 0x9, + NODE_CONCEALMENT_STAND = 0xA, + NODE_CONCEALMENT_CROUCH = 0xB, + NODE_CONCEALMENT_PRONE = 0xC, + NODE_REACQUIRE = 0xD, + NODE_BALCONY = 0xE, + NODE_SCRIPTED = 0xF, + NODE_NEGOTIATION_BEGIN = 0x10, + NODE_NEGOTIATION_END = 0x11, + NODE_TURRET = 0x12, + NODE_GUARD = 0x13, + NODE_NUMTYPES = 0x14, + NODE_DONTLINK = 0x14, + }; + + enum expDataType : __int32 + { + VAL_INT = 0x0, + VAL_FLOAT = 0x1, + VAL_STRING = 0x2, + }; + + enum expOperationEnum + { + OP_NEGATE = 0x7, + NUM_EXPRESSION_OPERATORS = 0x18, + MAX_OPERATOR_VALUE = 0x4000, + }; + + enum snd_category_t : __int32 + { + SND_CATEGORY_SFX = 0x0, + SND_CATEGORY_MUSIC = 0x1, + SND_CATEGORY_VOICE = 0x2, + }; + + enum weapType_t : __int32 + { + WEAPTYPE_BULLET = 0x0, + WEAPTYPE_GRENADE = 0x1, + WEAPTYPE_PROJECTILE = 0x2, + WEAPTYPE_BINOCULARS = 0x3, + WEAPTYPE_GAS = 0x4, + WEAPTYPE_BOMB = 0x5, + WEAPTYPE_MINE = 0x6, + WEAPTYPE_NUM = 0x7, + }; + + enum weapClass_t : __int32 + { + WEAPCLASS_RIFLE = 0x0, + WEAPCLASS_MG = 0x1, + WEAPCLASS_SMG = 0x2, + WEAPCLASS_SPREAD = 0x3, + WEAPCLASS_PISTOL = 0x4, + WEAPCLASS_GRENADE = 0x5, + WEAPCLASS_ROCKETLAUNCHER = 0x6, + WEAPCLASS_TURRET = 0x7, + WEAPCLASS_NON_PLAYER = 0x8, + WEAPCLASS_GAS = 0x9, + WEAPCLASS_ITEM = 0xA, + WEAPCLASS_NUM = 0xB, + }; + + enum PenetrateType : __int32 + { + PENETRATE_TYPE_NONE = 0x0, + PENETRATE_TYPE_SMALL = 0x1, + PENETRATE_TYPE_MEDIUM = 0x2, + PENETRATE_TYPE_LARGE = 0x3, + PENETRATE_TYPE_COUNT = 0x4, + }; + + enum ImpactType : __int32 + { + IMPACT_TYPE_NONE = 0x0, + IMPACT_TYPE_BULLET_SMALL = 0x1, + IMPACT_TYPE_BULLET_LARGE = 0x2, + IMPACT_TYPE_BULLET_AP = 0x3, + IMPACT_TYPE_SHOTGUN = 0x4, + IMPACT_TYPE_GRENADE_BOUNCE = 0x5, + IMPACT_TYPE_GRENADE_EXPLODE = 0x6, + IMPACT_TYPE_RIFLE_GRENADE = 0x7, + IMPACT_TYPE_ROCKET_EXPLODE = 0x8, + IMPACT_TYPE_PROJECTILE_DUD = 0x9, + IMPACT_TYPE_MORTAR_SHELL = 0xA, + IMPACT_TYPE_TANK_SHELL = 0xB, + IMPACT_TYPE_COUNT = 0xC, + }; + + enum weapInventoryType_t : __int32 + { + WEAPINVENTORY_PRIMARY = 0x0, + WEAPINVENTORY_OFFHAND = 0x1, + WEAPINVENTORY_ITEM = 0x2, + WEAPINVENTORY_ALTMODE = 0x3, + WEAPINVENTORYCOUNT = 0x4, + }; + + enum weapFireType_t : __int32 + { + WEAPON_FIRETYPE_FULLAUTO = 0x0, + WEAPON_FIRETYPE_SINGLESHOT = 0x1, + WEAPON_FIRETYPE_BURSTFIRE2 = 0x2, + WEAPON_FIRETYPE_BURSTFIRE3 = 0x3, + WEAPON_FIRETYPE_BURSTFIRE4 = 0x4, + WEAPON_FIRETYPECOUNT = 0x5, + }; + + enum OffhandClass : __int32 + { + OFFHAND_CLASS_NONE = 0x0, + OFFHAND_CLASS_FRAG_GRENADE = 0x1, + OFFHAND_CLASS_SMOKE_GRENADE = 0x2, + OFFHAND_CLASS_FLASH_GRENADE = 0x3, + OFFHAND_CLASS_COUNT = 0x4, + }; + + enum weapStance_t : __int32 + { + WEAPSTANCE_STAND = 0x0, + WEAPSTANCE_DUCK = 0x1, + WEAPSTANCE_PRONE = 0x2, + WEAPSTANCE_NUM = 0x3, + }; + + enum activeReticleType_t : __int32 + { + VEH_ACTIVE_RETICLE_NONE = 0x0, + VEH_ACTIVE_RETICLE_PIP_ON_A_STICK = 0x1, + VEH_ACTIVE_RETICLE_BOUNCING_DIAMOND = 0x2, + VEH_ACTIVE_RETICLE_COUNT = 0x3, + }; + + enum weaponIconRatioType_t : __int32 + { + WEAPON_ICON_RATIO_1TO1 = 0x0, + WEAPON_ICON_RATIO_2TO1 = 0x1, + WEAPON_ICON_RATIO_4TO1 = 0x2, + WEAPON_ICON_RATIO_COUNT = 0x3, + }; + + enum ammoCounterClipType_t : __int32 + { + AMMO_COUNTER_CLIP_NONE = 0x0, + AMMO_COUNTER_CLIP_MAGAZINE = 0x1, + AMMO_COUNTER_CLIP_SHORTMAGAZINE = 0x2, + AMMO_COUNTER_CLIP_SHOTGUN = 0x3, + AMMO_COUNTER_CLIP_ROCKET = 0x4, + AMMO_COUNTER_CLIP_BELTFED = 0x5, + AMMO_COUNTER_CLIP_ALTWEAPON = 0x6, + AMMO_COUNTER_CLIP_COUNT = 0x7, + }; + + enum weapOverlayReticle_t : __int32 + { + WEAPOVERLAYRETICLE_NONE = 0x0, + WEAPOVERLAYRETICLE_CROSSHAIR = 0x1, + WEAPOVERLAYRETICLE_NUM = 0x2, + }; + + enum WeapOverlayInteface_t : __int32 + { + WEAPOVERLAYINTERFACE_NONE = 0x0, + WEAPOVERLAYINTERFACE_JAVELIN = 0x1, + WEAPOVERLAYINTERFACE_TURRETSCOPE = 0x2, + WEAPOVERLAYINTERFACECOUNT = 0x3, + }; + + enum weapProjExposion_t : __int32 + { + WEAPPROJEXP_GRENADE = 0x0, + WEAPPROJEXP_ROCKET = 0x1, + WEAPPROJEXP_FLASHBANG = 0x2, + WEAPPROJEXP_NONE = 0x3, + WEAPPROJEXP_DUD = 0x4, + WEAPPROJEXP_SMOKE = 0x5, + WEAPPROJEXP_HEAVY = 0x6, + WEAPPROJEXP_FIRE = 0x7, + WEAPPROJEXP_NAPALMBLOB = 0x8, + WEAPPROJEXP_NUM = 0x9, + }; + + enum WeapStickinessType : __int32 + { + WEAPSTICKINESS_NONE = 0x0, + WEAPSTICKINESS_ALL = 0x1, + WEAPSTICKINESS_GROUND = 0x2, + WEAPSTICKINESS_GROUND_WITH_YAW = 0x3, + WEAPSTICKINESS_COUNT = 0x4, + }; + + enum guidedMissileType_t : __int32 + { + MISSILE_GUIDANCE_NONE = 0x0, + MISSILE_GUIDANCE_SIDEWINDER = 0x1, + MISSILE_GUIDANCE_HELLFIRE = 0x2, + MISSILE_GUIDANCE_JAVELIN = 0x3, + MISSILE_GUIDANCE_BALLISTIC = 0x4, + MISSILE_GUIDANCE_COUNT = 0x5, + }; + + struct DObjAnimMat + { + float quat[4]; //OFS: 0x0 SIZE: 0x10 + float trans[3]; //OFS: 0x10 SIZE: 0xC + float transWeight; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DObjAnimMat, 0x20); + ASSERT_STRUCT_OFFSET(DObjAnimMat, quat, 0x0); + ASSERT_STRUCT_OFFSET(DObjAnimMat, trans, 0x10); + ASSERT_STRUCT_OFFSET(DObjAnimMat, transWeight, 0x1C); + + struct XSurfaceVertexInfo + { + __int16 vertCount[4]; //OFS: 0x0 SIZE: 0x8 + unsigned __int16* vertsBlend; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XSurfaceVertexInfo, 0xC); + ASSERT_STRUCT_OFFSET(XSurfaceVertexInfo, vertCount, 0x0); + ASSERT_STRUCT_OFFSET(XSurfaceVertexInfo, vertsBlend, 0x8); + + union GfxColor + { + unsigned int packed; //OFS: 0x0 SIZE: 0x4 + unsigned __int8 array[4]; //OFS: 0x1 SIZE: 0x4 + }; + + union PackedTexCoords + { + unsigned int packed; //OFS: 0x0 SIZE: 0x4 + }; + + union PackedUnitVec + { + unsigned int packed; //OFS: 0x0 SIZE: 0x4 + }; + + struct GfxPackedVertex + { + float xyz[3]; //OFS: 0x0 SIZE: 0xC + float binormalSign; //OFS: 0xC SIZE: 0x4 + GfxColor color; //OFS: 0x10 SIZE: 0x4 + PackedTexCoords texCoord; //OFS: 0x14 SIZE: 0x4 + PackedUnitVec normal; //OFS: 0x18 SIZE: 0x4 + PackedUnitVec tangent; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxPackedVertex, 0x20); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, xyz, 0x0); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, binormalSign, 0xC); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, color, 0x10); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, texCoord, 0x14); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, normal, 0x18); + ASSERT_STRUCT_OFFSET(GfxPackedVertex, tangent, 0x1C); + + struct __declspec(align(2)) XSurfaceCollisionAabb + { + unsigned __int16 mins[3]; //OFS: 0x0 SIZE: 0x6 + unsigned __int16 maxs[3]; //OFS: 0x6 SIZE: 0x6 + }; + ASSERT_STRUCT_SIZE(XSurfaceCollisionAabb, 0xC); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionAabb, mins, 0x0); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionAabb, maxs, 0x6); + + struct __declspec(align(2)) XSurfaceCollisionNode + { + XSurfaceCollisionAabb aabb; //OFS: 0x0 SIZE: 0xC + unsigned __int16 childBeginIndex; //OFS: 0xC SIZE: 0x2 + unsigned __int16 childCount; //OFS: 0xE SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XSurfaceCollisionNode, 0x10); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionNode, aabb, 0x0); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionNode, childBeginIndex, 0xC); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionNode, childCount, 0xE); + + struct __declspec(align(2)) XSurfaceCollisionLeaf + { + unsigned __int16 triangleBeginIndex; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XSurfaceCollisionLeaf, 0x2); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionLeaf, triangleBeginIndex, 0x0); + + struct XSurfaceCollisionTree + { + float trans[3]; //OFS: 0x0 SIZE: 0xC + float scale[3]; //OFS: 0xC SIZE: 0xC + unsigned int nodeCount; //OFS: 0x18 SIZE: 0x4 + XSurfaceCollisionNode* nodes; //OFS: 0x1C SIZE: 0x4 + unsigned int leafCount; //OFS: 0x20 SIZE: 0x4 + XSurfaceCollisionLeaf* leafs; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XSurfaceCollisionTree, 0x28); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, trans, 0x0); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, scale, 0xC); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, nodeCount, 0x18); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, nodes, 0x1C); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, leafCount, 0x20); + ASSERT_STRUCT_OFFSET(XSurfaceCollisionTree, leafs, 0x24); + + struct XRigidVertList + { + unsigned __int16 boneOffset; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 vertCount; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 triOffset; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 triCount; //OFS: 0x6 SIZE: 0x2 + XSurfaceCollisionTree* collisionTree; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XRigidVertList, 0xC); + ASSERT_STRUCT_OFFSET(XRigidVertList, boneOffset, 0x0); + ASSERT_STRUCT_OFFSET(XRigidVertList, vertCount, 0x2); + ASSERT_STRUCT_OFFSET(XRigidVertList, triOffset, 0x4); + ASSERT_STRUCT_OFFSET(XRigidVertList, triCount, 0x6); + ASSERT_STRUCT_OFFSET(XRigidVertList, collisionTree, 0x8); + + struct XSurface + { + char tileMode; //OFS: 0x0 SIZE: 0x1 + bool deformed; //OFS: 0x1 SIZE: 0x1 + unsigned __int16 vertCount; //OFS: 0x2 SIZE: 0x2 + unsigned __int16 triCount; //OFS: 0x4 SIZE: 0x2 + char zoneHandle; //OFS: 0x6 SIZE: 0x1 + unsigned __int16 baseTriIndex; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 baseVertIndex; //OFS: 0xA SIZE: 0x2 + unsigned __int16* triIndices; //OFS: 0xC SIZE: 0x4 + XSurfaceVertexInfo vertInfo; //OFS: 0x10 SIZE: 0xC + GfxPackedVertex* verts0; //OFS: 0x1C SIZE: 0x4 + IDirect3DVertexBuffer9* vb0; //OFS: 0x20 SIZE: 0x4 + unsigned int vertListCount; //OFS: 0x24 SIZE: 0x4 + XRigidVertList* vertList; //OFS: 0x28 SIZE: 0x4 + int partBits[4]; //OFS: 0x2C SIZE: 0x10 + IDirect3DIndexBuffer9* indexBuffer; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XSurface, 0x40); + ASSERT_STRUCT_OFFSET(XSurface, tileMode, 0x0); + ASSERT_STRUCT_OFFSET(XSurface, deformed, 0x1); + ASSERT_STRUCT_OFFSET(XSurface, vertCount, 0x2); + ASSERT_STRUCT_OFFSET(XSurface, triCount, 0x4); + ASSERT_STRUCT_OFFSET(XSurface, zoneHandle, 0x6); + ASSERT_STRUCT_OFFSET(XSurface, baseTriIndex, 0x8); + ASSERT_STRUCT_OFFSET(XSurface, baseVertIndex, 0xA); + ASSERT_STRUCT_OFFSET(XSurface, triIndices, 0xC); + ASSERT_STRUCT_OFFSET(XSurface, vertInfo, 0x10); + ASSERT_STRUCT_OFFSET(XSurface, verts0, 0x1C); + ASSERT_STRUCT_OFFSET(XSurface, vb0, 0x20); + ASSERT_STRUCT_OFFSET(XSurface, vertListCount, 0x24); + ASSERT_STRUCT_OFFSET(XSurface, vertList, 0x28); + ASSERT_STRUCT_OFFSET(XSurface, partBits, 0x2C); + ASSERT_STRUCT_OFFSET(XSurface, indexBuffer, 0x3C); + + struct GfxDrawSurfFields + { + unsigned __int64 objectId : 16; + unsigned __int64 reflectionProbeIndex : 8; + unsigned __int64 customIndex : 5; + unsigned __int64 materialSortedIndex : 11; + unsigned __int64 prepass : 2; + unsigned __int64 primaryLightIndex : 8; + unsigned __int64 surfType : 4; + unsigned __int64 primarySortKey : 6; + unsigned __int64 unused : 4; + }; + ASSERT_STRUCT_SIZE(GfxDrawSurfFields, 0x8); + + union GfxDrawSurf + { + GfxDrawSurfFields fields; //OFS: 0x0 SIZE: 0x8 + unsigned __int64 packed; //OFS: 0x1 SIZE: 0x8 + }; + + struct __declspec(align(8)) MaterialInfo + { + const char* name; //OFS: 0x0 SIZE: 0x4 + char gameFlags; //OFS: 0x4 SIZE: 0x1 + char sortKey; //OFS: 0x5 SIZE: 0x1 + char textureAtlasRowCount; //OFS: 0x6 SIZE: 0x1 + char textureAtlasColumnCount; //OFS: 0x7 SIZE: 0x1 + GfxDrawSurf drawSurf; //OFS: 0x8 SIZE: 0x8 + unsigned int surfaceTypeBits; //OFS: 0x10 SIZE: 0x4 + unsigned __int16 hashIndex; //OFS: 0x14 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(MaterialInfo, 0x18); + ASSERT_STRUCT_OFFSET(MaterialInfo, name, 0x0); + ASSERT_STRUCT_OFFSET(MaterialInfo, gameFlags, 0x4); + ASSERT_STRUCT_OFFSET(MaterialInfo, sortKey, 0x5); + ASSERT_STRUCT_OFFSET(MaterialInfo, textureAtlasRowCount, 0x6); + ASSERT_STRUCT_OFFSET(MaterialInfo, textureAtlasColumnCount, 0x7); + ASSERT_STRUCT_OFFSET(MaterialInfo, drawSurf, 0x8); + ASSERT_STRUCT_OFFSET(MaterialInfo, surfaceTypeBits, 0x10); + ASSERT_STRUCT_OFFSET(MaterialInfo, hashIndex, 0x14); + + struct __declspec(align(1)) MaterialStreamRouting + { + char source; //OFS: 0x0 SIZE: 0x1 + char dest; //OFS: 0x1 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(MaterialStreamRouting, 0x2); + ASSERT_STRUCT_OFFSET(MaterialStreamRouting, source, 0x0); + ASSERT_STRUCT_OFFSET(MaterialStreamRouting, dest, 0x1); + + struct MaterialVertexStreamRouting + { + MaterialStreamRouting data[16]; //OFS: 0x0 SIZE: 0x20 + IDirect3DVertexDeclaration9* decl[17]; //OFS: 0x20 SIZE: 0x44 + }; + ASSERT_STRUCT_SIZE(MaterialVertexStreamRouting, 0x64); + ASSERT_STRUCT_OFFSET(MaterialVertexStreamRouting, data, 0x0); + ASSERT_STRUCT_OFFSET(MaterialVertexStreamRouting, decl, 0x20); + + struct MaterialVertexDeclaration + { + char streamCount; //OFS: 0x0 SIZE: 0x1 + bool hasOptionalSource; //OFS: 0x1 SIZE: 0x1 + bool isLoaded; //OFS: 0x2 SIZE: 0x1 + MaterialVertexStreamRouting routing; //OFS: 0x4 SIZE: 0x64 + }; + ASSERT_STRUCT_SIZE(MaterialVertexDeclaration, 0x68); + ASSERT_STRUCT_OFFSET(MaterialVertexDeclaration, streamCount, 0x0); + ASSERT_STRUCT_OFFSET(MaterialVertexDeclaration, hasOptionalSource, 0x1); + ASSERT_STRUCT_OFFSET(MaterialVertexDeclaration, isLoaded, 0x2); + ASSERT_STRUCT_OFFSET(MaterialVertexDeclaration, routing, 0x4); + + struct GfxVertexShaderLoadDef + { + unsigned int* program; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 programSize; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 loadForRenderer; //OFS: 0x6 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxVertexShaderLoadDef, 0x8); + ASSERT_STRUCT_OFFSET(GfxVertexShaderLoadDef, program, 0x0); + ASSERT_STRUCT_OFFSET(GfxVertexShaderLoadDef, programSize, 0x4); + ASSERT_STRUCT_OFFSET(GfxVertexShaderLoadDef, loadForRenderer, 0x6); + + struct MaterialVertexShaderProgram + { + IDirect3DVertexShader9* vs; //OFS: 0x0 SIZE: 0x4 + GfxVertexShaderLoadDef loadDef; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(MaterialVertexShaderProgram, 0xC); + ASSERT_STRUCT_OFFSET(MaterialVertexShaderProgram, vs, 0x0); + ASSERT_STRUCT_OFFSET(MaterialVertexShaderProgram, loadDef, 0x4); + + struct MaterialVertexShader + { + const char* name; //OFS: 0x0 SIZE: 0x4 + MaterialVertexShaderProgram prog; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(MaterialVertexShader, 0x10); + ASSERT_STRUCT_OFFSET(MaterialVertexShader, name, 0x0); + ASSERT_STRUCT_OFFSET(MaterialVertexShader, prog, 0x4); + + struct GfxPixelShaderLoadDef + { + unsigned int* program; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 programSize; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 loadForRenderer; //OFS: 0x6 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxPixelShaderLoadDef, 0x8); + ASSERT_STRUCT_OFFSET(GfxPixelShaderLoadDef, program, 0x0); + ASSERT_STRUCT_OFFSET(GfxPixelShaderLoadDef, programSize, 0x4); + ASSERT_STRUCT_OFFSET(GfxPixelShaderLoadDef, loadForRenderer, 0x6); + + struct MaterialPixelShaderProgram + { + IDirect3DPixelShader9* ps; //OFS: 0x0 SIZE: 0x4 + GfxPixelShaderLoadDef loadDef; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(MaterialPixelShaderProgram, 0xC); + ASSERT_STRUCT_OFFSET(MaterialPixelShaderProgram, ps, 0x0); + ASSERT_STRUCT_OFFSET(MaterialPixelShaderProgram, loadDef, 0x4); + + struct MaterialPixelShader + { + const char* name; //OFS: 0x0 SIZE: 0x4 + MaterialPixelShaderProgram prog; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(MaterialPixelShader, 0x10); + ASSERT_STRUCT_OFFSET(MaterialPixelShader, name, 0x0); + ASSERT_STRUCT_OFFSET(MaterialPixelShader, prog, 0x4); + + struct __declspec(align(2)) MaterialArgumentCodeConst + { + unsigned __int16 index; //OFS: 0x0 SIZE: 0x2 + char firstRow; //OFS: 0x2 SIZE: 0x1 + char rowCount; //OFS: 0x3 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(MaterialArgumentCodeConst, 0x4); + ASSERT_STRUCT_OFFSET(MaterialArgumentCodeConst, index, 0x0); + ASSERT_STRUCT_OFFSET(MaterialArgumentCodeConst, firstRow, 0x2); + ASSERT_STRUCT_OFFSET(MaterialArgumentCodeConst, rowCount, 0x3); + + union MaterialArgumentDef + { + const float* literalConst; //OFS: 0x0 SIZE: 0x4 + MaterialArgumentCodeConst codeConst; //OFS: 0x1 SIZE: 0x4 + unsigned int codeSampler; //OFS: 0x2 SIZE: 0x4 + unsigned int nameHash; //OFS: 0x3 SIZE: 0x4 + }; + + struct MaterialShaderArgument + { + unsigned __int16 type; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 dest; //OFS: 0x2 SIZE: 0x2 + MaterialArgumentDef u; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MaterialShaderArgument, 0x8); + ASSERT_STRUCT_OFFSET(MaterialShaderArgument, type, 0x0); + ASSERT_STRUCT_OFFSET(MaterialShaderArgument, dest, 0x2); + ASSERT_STRUCT_OFFSET(MaterialShaderArgument, u, 0x4); + + struct MaterialPass + { + MaterialVertexDeclaration* vertexDecl; //OFS: 0x0 SIZE: 0x4 + MaterialVertexShader* vertexShader; //OFS: 0x4 SIZE: 0x4 + MaterialPixelShader* pixelShader; //OFS: 0x8 SIZE: 0x4 + char perPrimArgCount; //OFS: 0xC SIZE: 0x1 + char perObjArgCount; //OFS: 0xD SIZE: 0x1 + char stableArgCount; //OFS: 0xE SIZE: 0x1 + char customSamplerFlags; //OFS: 0xF SIZE: 0x1 + MaterialShaderArgument* args; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MaterialPass, 0x14); + ASSERT_STRUCT_OFFSET(MaterialPass, vertexDecl, 0x0); + ASSERT_STRUCT_OFFSET(MaterialPass, vertexShader, 0x4); + ASSERT_STRUCT_OFFSET(MaterialPass, pixelShader, 0x8); + ASSERT_STRUCT_OFFSET(MaterialPass, perPrimArgCount, 0xC); + ASSERT_STRUCT_OFFSET(MaterialPass, perObjArgCount, 0xD); + ASSERT_STRUCT_OFFSET(MaterialPass, stableArgCount, 0xE); + ASSERT_STRUCT_OFFSET(MaterialPass, customSamplerFlags, 0xF); + ASSERT_STRUCT_OFFSET(MaterialPass, args, 0x10); + + struct MaterialTechnique + { + const char* name; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 flags; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 passCount; //OFS: 0x6 SIZE: 0x2 + MaterialPass passArray[1]; //OFS: 0x8 SIZE: 0x14 + }; + ASSERT_STRUCT_SIZE(MaterialTechnique, 0x1C); + ASSERT_STRUCT_OFFSET(MaterialTechnique, name, 0x0); + ASSERT_STRUCT_OFFSET(MaterialTechnique, flags, 0x4); + ASSERT_STRUCT_OFFSET(MaterialTechnique, passCount, 0x6); + ASSERT_STRUCT_OFFSET(MaterialTechnique, passArray, 0x8); + + struct MaterialTechniqueSet + { + const char* name; //OFS: 0x0 SIZE: 0x4 + char worldVertFormat; //OFS: 0x4 SIZE: 0x1 + bool hasBeenUploaded; //OFS: 0x5 SIZE: 0x1 + char unused[1]; //OFS: 0x6 SIZE: 0x1 + MaterialTechniqueSet* remappedTechniqueSet; //OFS: 0x8 SIZE: 0x4 + MaterialTechnique* techniques[59]; //OFS: 0xC SIZE: 0xEC + }; + ASSERT_STRUCT_SIZE(MaterialTechniqueSet, 0xF8); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, name, 0x0); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, worldVertFormat, 0x4); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, hasBeenUploaded, 0x5); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, unused, 0x6); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, remappedTechniqueSet, 0x8); + ASSERT_STRUCT_OFFSET(MaterialTechniqueSet, techniques, 0xC); + + struct GfxImageLoadDef + { + char levelCount; //OFS: 0x0 SIZE: 0x1 + char flags; //OFS: 0x1 SIZE: 0x1 + __int16 dimensions[3]; //OFS: 0x2 SIZE: 0x6 + int format; //OFS: 0x8 SIZE: 0x4 + int resourceSize; //OFS: 0xC SIZE: 0x4 + char data[1]; //OFS: 0x10 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(GfxImageLoadDef, 0x14); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, levelCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, flags, 0x1); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, dimensions, 0x2); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, format, 0x8); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, resourceSize, 0xC); + ASSERT_STRUCT_OFFSET(GfxImageLoadDef, data, 0x10); + + union GfxTexture + { + IDirect3DBaseTexture9* basemap; //OFS: 0x0 SIZE: 0x4 + IDirect3DTexture9* map; //OFS: 0x1 SIZE: 0x4 + IDirect3DVolumeTexture9* volmap; //OFS: 0x2 SIZE: 0x4 + IDirect3DCubeTexture9* cubemap; //OFS: 0x3 SIZE: 0x4 + GfxImageLoadDef* loadDef; //OFS: 0x4 SIZE: 0x4 + }; + + struct __declspec(align(1)) Picmip + { + char platform[2]; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(Picmip, 0x2); + ASSERT_STRUCT_OFFSET(Picmip, platform, 0x0); + + struct CardMemory + { + int platform[2]; //OFS: 0x0 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(CardMemory, 0x8); + ASSERT_STRUCT_OFFSET(CardMemory, platform, 0x0); + + struct GfxImage + { + MapType mapType; //OFS: 0x0 SIZE: 0x4 + GfxTexture texture; //OFS: 0x4 SIZE: 0x4 + Picmip picmip; //OFS: 0x8 SIZE: 0x2 + bool noPicmip; //OFS: 0xA SIZE: 0x1 + char semantic; //OFS: 0xB SIZE: 0x1 + char track; //OFS: 0xC SIZE: 0x1 + CardMemory cardMemory; //OFS: 0x10 SIZE: 0x8 + unsigned __int16 width; //OFS: 0x18 SIZE: 0x2 + unsigned __int16 height; //OFS: 0x1A SIZE: 0x2 + unsigned __int16 depth; //OFS: 0x1C SIZE: 0x2 + char category; //OFS: 0x1E SIZE: 0x1 + bool delayLoadPixels; //OFS: 0x1F SIZE: 0x1 + const char* name; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxImage, 0x24); + ASSERT_STRUCT_OFFSET(GfxImage, mapType, 0x0); + ASSERT_STRUCT_OFFSET(GfxImage, texture, 0x4); + ASSERT_STRUCT_OFFSET(GfxImage, picmip, 0x8); + ASSERT_STRUCT_OFFSET(GfxImage, noPicmip, 0xA); + ASSERT_STRUCT_OFFSET(GfxImage, semantic, 0xB); + ASSERT_STRUCT_OFFSET(GfxImage, track, 0xC); + ASSERT_STRUCT_OFFSET(GfxImage, cardMemory, 0x10); + ASSERT_STRUCT_OFFSET(GfxImage, width, 0x18); + ASSERT_STRUCT_OFFSET(GfxImage, height, 0x1A); + ASSERT_STRUCT_OFFSET(GfxImage, depth, 0x1C); + ASSERT_STRUCT_OFFSET(GfxImage, category, 0x1E); + ASSERT_STRUCT_OFFSET(GfxImage, delayLoadPixels, 0x1F); + ASSERT_STRUCT_OFFSET(GfxImage, name, 0x20); + + struct WaterWritable + { + float floatTime; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(WaterWritable, 0x4); + ASSERT_STRUCT_OFFSET(WaterWritable, floatTime, 0x0); + + struct complex_s + { + float real; //OFS: 0x0 SIZE: 0x4 + float imag; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(complex_s, 0x8); + ASSERT_STRUCT_OFFSET(complex_s, real, 0x0); + ASSERT_STRUCT_OFFSET(complex_s, imag, 0x4); + + struct water_t + { + WaterWritable writable; //OFS: 0x0 SIZE: 0x4 + complex_s* H0; //OFS: 0x4 SIZE: 0x4 + float* wTerm; //OFS: 0x8 SIZE: 0x4 + int M; //OFS: 0xC SIZE: 0x4 + int N; //OFS: 0x10 SIZE: 0x4 + float Lx; //OFS: 0x14 SIZE: 0x4 + float Lz; //OFS: 0x18 SIZE: 0x4 + float gravity; //OFS: 0x1C SIZE: 0x4 + float windvel; //OFS: 0x20 SIZE: 0x4 + float winddir[2]; //OFS: 0x24 SIZE: 0x8 + float amplitude; //OFS: 0x2C SIZE: 0x4 + float codeConstant[4]; //OFS: 0x30 SIZE: 0x10 + GfxImage* image; //OFS: 0x40 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(water_t, 0x44); + ASSERT_STRUCT_OFFSET(water_t, writable, 0x0); + ASSERT_STRUCT_OFFSET(water_t, H0, 0x4); + ASSERT_STRUCT_OFFSET(water_t, wTerm, 0x8); + ASSERT_STRUCT_OFFSET(water_t, M, 0xC); + ASSERT_STRUCT_OFFSET(water_t, N, 0x10); + ASSERT_STRUCT_OFFSET(water_t, Lx, 0x14); + ASSERT_STRUCT_OFFSET(water_t, Lz, 0x18); + ASSERT_STRUCT_OFFSET(water_t, gravity, 0x1C); + ASSERT_STRUCT_OFFSET(water_t, windvel, 0x20); + ASSERT_STRUCT_OFFSET(water_t, winddir, 0x24); + ASSERT_STRUCT_OFFSET(water_t, amplitude, 0x2C); + ASSERT_STRUCT_OFFSET(water_t, codeConstant, 0x30); + ASSERT_STRUCT_OFFSET(water_t, image, 0x40); + + union MaterialTextureDefInfo + { + GfxImage* image; //OFS: 0x0 SIZE: 0x4 + water_t* water; //OFS: 0x1 SIZE: 0x4 + }; + + struct MaterialTextureDef + { + unsigned int nameHash; //OFS: 0x0 SIZE: 0x4 + char nameStart; //OFS: 0x4 SIZE: 0x1 + char nameEnd; //OFS: 0x5 SIZE: 0x1 + char samplerState; //OFS: 0x6 SIZE: 0x1 + char semantic; //OFS: 0x7 SIZE: 0x1 + char isMatureContent; //OFS: 0x8 SIZE: 0x1 + MaterialTextureDefInfo u; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MaterialTextureDef, 0x10); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, nameHash, 0x0); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, nameStart, 0x4); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, nameEnd, 0x5); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, samplerState, 0x6); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, semantic, 0x7); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, isMatureContent, 0x8); + ASSERT_STRUCT_OFFSET(MaterialTextureDef, u, 0xC); + + struct MaterialConstantDef + { + unsigned int nameHash; //OFS: 0x0 SIZE: 0x4 + char name[12]; //OFS: 0x4 SIZE: 0xC + float literal[4]; //OFS: 0x10 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(MaterialConstantDef, 0x20); + ASSERT_STRUCT_OFFSET(MaterialConstantDef, nameHash, 0x0); + ASSERT_STRUCT_OFFSET(MaterialConstantDef, name, 0x4); + ASSERT_STRUCT_OFFSET(MaterialConstantDef, literal, 0x10); + + struct GfxStateBits + { + unsigned int loadBits[2]; //OFS: 0x0 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(GfxStateBits, 0x8); + ASSERT_STRUCT_OFFSET(GfxStateBits, loadBits, 0x0); + + struct Material + { + MaterialInfo info; //OFS: 0x0 SIZE: 0x18 + char stateBitsEntry[67]; //OFS: 0x18 SIZE: 0x43 + char textureCount; //OFS: 0x5B SIZE: 0x1 + char constantCount; //OFS: 0x5C SIZE: 0x1 + char stateBitsCount; //OFS: 0x5D SIZE: 0x1 + char stateFlags; //OFS: 0x5E SIZE: 0x1 + char cameraRegion; //OFS: 0x5F SIZE: 0x1 + MaterialTechniqueSet* techniqueSet; //OFS: 0x60 SIZE: 0x4 + MaterialTextureDef* textureTable; //OFS: 0x64 SIZE: 0x4 + MaterialConstantDef* constantTable; //OFS: 0x68 SIZE: 0x4 + GfxStateBits* stateBitsTable; //OFS: 0x6C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Material, 0x70); + ASSERT_STRUCT_OFFSET(Material, info, 0x0); + ASSERT_STRUCT_OFFSET(Material, stateBitsEntry, 0x18); + ASSERT_STRUCT_OFFSET(Material, textureCount, 0x5B); + ASSERT_STRUCT_OFFSET(Material, constantCount, 0x5C); + ASSERT_STRUCT_OFFSET(Material, stateBitsCount, 0x5D); + ASSERT_STRUCT_OFFSET(Material, stateFlags, 0x5E); + ASSERT_STRUCT_OFFSET(Material, cameraRegion, 0x5F); + ASSERT_STRUCT_OFFSET(Material, techniqueSet, 0x60); + ASSERT_STRUCT_OFFSET(Material, textureTable, 0x64); + ASSERT_STRUCT_OFFSET(Material, constantTable, 0x68); + ASSERT_STRUCT_OFFSET(Material, stateBitsTable, 0x6C); + + struct XModelLodInfo + { + float dist; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 numsurfs; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 surfIndex; //OFS: 0x6 SIZE: 0x2 + int partBits[4]; //OFS: 0x8 SIZE: 0x10 + char lod; //OFS: 0x18 SIZE: 0x1 + char smcIndexPlusOne; //OFS: 0x19 SIZE: 0x1 + char smcAllocBits; //OFS: 0x1A SIZE: 0x1 + char unused; //OFS: 0x1B SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(XModelLodInfo, 0x1C); + ASSERT_STRUCT_OFFSET(XModelLodInfo, dist, 0x0); + ASSERT_STRUCT_OFFSET(XModelLodInfo, numsurfs, 0x4); + ASSERT_STRUCT_OFFSET(XModelLodInfo, surfIndex, 0x6); + ASSERT_STRUCT_OFFSET(XModelLodInfo, partBits, 0x8); + ASSERT_STRUCT_OFFSET(XModelLodInfo, lod, 0x18); + ASSERT_STRUCT_OFFSET(XModelLodInfo, smcIndexPlusOne, 0x19); + ASSERT_STRUCT_OFFSET(XModelLodInfo, smcAllocBits, 0x1A); + ASSERT_STRUCT_OFFSET(XModelLodInfo, unused, 0x1B); + + struct XModelCollTri_s + { + float plane[4]; //OFS: 0x0 SIZE: 0x10 + float svec[4]; //OFS: 0x10 SIZE: 0x10 + float tvec[4]; //OFS: 0x20 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(XModelCollTri_s, 0x30); + ASSERT_STRUCT_OFFSET(XModelCollTri_s, plane, 0x0); + ASSERT_STRUCT_OFFSET(XModelCollTri_s, svec, 0x10); + ASSERT_STRUCT_OFFSET(XModelCollTri_s, tvec, 0x20); + + struct XModelCollSurf_s + { + XModelCollTri_s* collTris; //OFS: 0x0 SIZE: 0x4 + int numCollTris; //OFS: 0x4 SIZE: 0x4 + float mins[3]; //OFS: 0x8 SIZE: 0xC + float maxs[3]; //OFS: 0x14 SIZE: 0xC + int boneIdx; //OFS: 0x20 SIZE: 0x4 + int contents; //OFS: 0x24 SIZE: 0x4 + int surfFlags; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XModelCollSurf_s, 0x2C); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, collTris, 0x0); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, numCollTris, 0x4); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, mins, 0x8); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, maxs, 0x14); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, boneIdx, 0x20); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, contents, 0x24); + ASSERT_STRUCT_OFFSET(XModelCollSurf_s, surfFlags, 0x28); + + struct XBoneInfo + { + float bounds[2][3]; //OFS: 0x0 SIZE: 0x18 + float offset[3]; //OFS: 0x18 SIZE: 0xC + float radiusSquared; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XBoneInfo, 0x28); + ASSERT_STRUCT_OFFSET(XBoneInfo, bounds, 0x0); + ASSERT_STRUCT_OFFSET(XBoneInfo, offset, 0x18); + ASSERT_STRUCT_OFFSET(XBoneInfo, radiusSquared, 0x24); + + struct XModelHighMipBounds + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS 0xC SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(XModelHighMipBounds, 0x18); + ASSERT_STRUCT_OFFSET(XModelHighMipBounds, mins, 0x0); + ASSERT_STRUCT_OFFSET(XModelHighMipBounds, maxs, 0xC); + + struct XModelStreamInfo + { + XModelHighMipBounds* highMipBounds; //OFS 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XModelStreamInfo, 0x4); + ASSERT_STRUCT_OFFSET(XModelStreamInfo, highMipBounds, 0x0); + + struct PhysPreset + { + const char* name; //OFS: 0x0 SIZE: 0x4 + int type; //OFS: 0x4 SIZE: 0x4 + float mass; //OFS: 0x8 SIZE: 0x4 + float bounce; //OFS: 0xC SIZE: 0x4 + float friction; //OFS: 0x10 SIZE: 0x4 + float bulletForceScale; //OFS: 0x14 SIZE: 0x4 + float explosiveForceScale; //OFS: 0x18 SIZE: 0x4 + const char* sndAliasPrefix; //OFS: 0x1C SIZE: 0x4 + float piecesSpreadFraction; //OFS: 0x20 SIZE: 0x4 + float piecesUpwardVelocity; //OFS: 0x24 SIZE: 0x4 + bool tempDefaultToCylinder; //OFS: 0x28 SIZE: 0x1 + int canFloat; //OFS: 0x2C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysPreset, 0x30); + ASSERT_STRUCT_OFFSET(PhysPreset, name, 0x0); + ASSERT_STRUCT_OFFSET(PhysPreset, type, 0x4); + ASSERT_STRUCT_OFFSET(PhysPreset, mass, 0x8); + ASSERT_STRUCT_OFFSET(PhysPreset, bounce, 0xC); + ASSERT_STRUCT_OFFSET(PhysPreset, friction, 0x10); + ASSERT_STRUCT_OFFSET(PhysPreset, bulletForceScale, 0x14); + ASSERT_STRUCT_OFFSET(PhysPreset, explosiveForceScale, 0x18); + ASSERT_STRUCT_OFFSET(PhysPreset, sndAliasPrefix, 0x1C); + ASSERT_STRUCT_OFFSET(PhysPreset, piecesSpreadFraction, 0x20); + ASSERT_STRUCT_OFFSET(PhysPreset, piecesUpwardVelocity, 0x24); + ASSERT_STRUCT_OFFSET(PhysPreset, tempDefaultToCylinder, 0x28); + ASSERT_STRUCT_OFFSET(PhysPreset, canFloat, 0x2C); + + struct cplane_s + { + float normal[3]; //OFS: 0x0 SIZE: 0xC + float dist; //OFS: 0xC SIZE: 0x4 + char type; //OFS: 0x10 SIZE: 0x1 + char signbits; //OFS: 0x11 SIZE: 0x1 + char pad[2]; //OFS: 0x12 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(cplane_s, 0x14); + ASSERT_STRUCT_OFFSET(cplane_s, normal, 0x0); + ASSERT_STRUCT_OFFSET(cplane_s, dist, 0xC); + ASSERT_STRUCT_OFFSET(cplane_s, type, 0x10); + ASSERT_STRUCT_OFFSET(cplane_s, signbits, 0x11); + ASSERT_STRUCT_OFFSET(cplane_s, pad, 0x12); + + struct cbrushside_t + { + cplane_s* plane; //OFS: 0x0 SIZE: 0x4 + unsigned int materialNum; //OFS: 0x4 SIZE: 0x4 + __int16 firstAdjacentSideOffset; //OFS: 0x8 SIZE: 0x2 + char edgeCount; //OFS: 0xA SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(cbrushside_t, 0xC); + ASSERT_STRUCT_OFFSET(cbrushside_t, plane, 0x0); + ASSERT_STRUCT_OFFSET(cbrushside_t, materialNum, 0x4); + ASSERT_STRUCT_OFFSET(cbrushside_t, firstAdjacentSideOffset, 0x8); + ASSERT_STRUCT_OFFSET(cbrushside_t, edgeCount, 0xA); + + struct __declspec(align(16)) BrushWrapper + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + int contents; //OFS: 0xC SIZE: 0x4 + float maxs[3]; //OFS: 0x10 SIZE: 0xC + unsigned int numsides; //OFS: 0x1C SIZE: 0x4 + cbrushside_t* sides; //OFS: 0x20 SIZE: 0x4 + __int16 axialMaterialNum[2][3]; //OFS: 0x24 SIZE: 0xC + char* baseAdjacentSide; //OFS: 0x30 SIZE: 0x4 + __int16 firstAdjacentSideOffsets[2][3]; //OFS: 0x34 SIZE: 0xC + char edgeCount[2][3]; //OFS: 0x40 SIZE: 0x6 + unsigned int numverts; //OFS: 0x48 SIZE: 0x4 + float (*verts)[3]; //OFS: 0x4C SIZE: 0x4 + int totalEdgeCount; //OFS: 0x50 SIZE: 0x4 + cplane_s* planes; //OFS: 0x54 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(BrushWrapper, 0x60); + ASSERT_STRUCT_OFFSET(BrushWrapper, mins, 0x0); + ASSERT_STRUCT_OFFSET(BrushWrapper, contents, 0xC); + ASSERT_STRUCT_OFFSET(BrushWrapper, maxs, 0x10); + ASSERT_STRUCT_OFFSET(BrushWrapper, numsides, 0x1C); + ASSERT_STRUCT_OFFSET(BrushWrapper, sides, 0x20); + ASSERT_STRUCT_OFFSET(BrushWrapper, axialMaterialNum, 0x24); + ASSERT_STRUCT_OFFSET(BrushWrapper, baseAdjacentSide, 0x30); + ASSERT_STRUCT_OFFSET(BrushWrapper, firstAdjacentSideOffsets, 0x34); + ASSERT_STRUCT_OFFSET(BrushWrapper, edgeCount, 0x40); + ASSERT_STRUCT_OFFSET(BrushWrapper, numverts, 0x48); + ASSERT_STRUCT_OFFSET(BrushWrapper, verts, 0x4C); + ASSERT_STRUCT_OFFSET(BrushWrapper, totalEdgeCount, 0x50); + ASSERT_STRUCT_OFFSET(BrushWrapper, planes, 0x54); + + struct PhysGeomInfo + { + BrushWrapper* brush; //OFS: 0x0 SIZE: 0x4 + int type; //OFS: 0x4 SIZE: 0x4 + float orientation[3][3]; //OFS: 0x8 SIZE: 0x24 + float offset[3]; //OFS: 0x2C SIZE: 0xC + float halfLengths[3]; //OFS: 0x38 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(PhysGeomInfo, 0x44); + ASSERT_STRUCT_OFFSET(PhysGeomInfo, brush, 0x0); + ASSERT_STRUCT_OFFSET(PhysGeomInfo, type, 0x4); + ASSERT_STRUCT_OFFSET(PhysGeomInfo, orientation, 0x8); + ASSERT_STRUCT_OFFSET(PhysGeomInfo, offset, 0x2C); + ASSERT_STRUCT_OFFSET(PhysGeomInfo, halfLengths, 0x38); + + struct PhysMass + { + float centerOfMass[3]; //OFS: 0x0 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(PhysMass, 0xC); + ASSERT_STRUCT_OFFSET(PhysMass, centerOfMass, 0x0); + + struct PhysGeomList + { + unsigned int count; //OFS: 0x0 SIZE: 0x4 + PhysGeomInfo* geoms; //OFS: 0x4 SIZE: 0x4 + PhysMass mass; //OFS: 0x8 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(PhysGeomList, 0x14); + ASSERT_STRUCT_OFFSET(PhysGeomList, count, 0x0); + ASSERT_STRUCT_OFFSET(PhysGeomList, geoms, 0x4); + ASSERT_STRUCT_OFFSET(PhysGeomList, mass, 0x8); + + struct PhysConstraint + { + unsigned __int16 targetname; //OFS: 0x0 SIZE: 0x2 + ConstraintType type; //OFS: 0x4 SIZE: 0x4 + AttachPointType attach_point_type1; //OFS: 0x8 SIZE: 0x4 + int target_index1; //OFS: 0xC SIZE: 0x4 + unsigned __int16 target_ent1; //OFS: 0x10 SIZE: 0x2 + char* target_bone1; //OFS: 0x14 SIZE: 0x4 + AttachPointType attach_point_type2; //OFS: 0x18 SIZE: 0x4 + int target_index2; //OFS: 0x1C SIZE: 0x4 + unsigned __int16 target_ent2; //OFS: 0x20 SIZE: 0x2 + char* target_bone2; //OFS: 0x24 SIZE: 0x4 + float offset[3]; //OFS: 0x28 SIZE: 0xC + float pos[3]; //OFS: 0x34 SIZE: 0xC + float pos2[3]; //OFS: 0x40 SIZE: 0xC + float dir[3]; //OFS: 0x4C SIZE: 0xC + int flags; //OFS: 0x58 SIZE: 0x4 + int timeout; //OFS: 0x5C SIZE: 0x4 + int min_health; //OFS: 0x60 SIZE: 0x4 + int max_health; //OFS: 0x64 SIZE: 0x4 + float distance; //OFS: 0x68 SIZE: 0x4 + float damp; //OFS: 0x6C SIZE: 0x4 + float power; //OFS: 0x70 SIZE: 0x4 + float scale[3]; //OFS: 0x74 SIZE: 0xC + float spin_scale; //OFS: 0x80 SIZE: 0x4 + float minAngle; //OFS: 0x84 SIZE: 0x4 + float maxAngle; //OFS: 0x88 SIZE: 0x4 + Material* material; //OFS: 0x8C SIZE: 0x4 + int constraintHandle; //OFS: 0x90 SIZE: 0x4 + int rope_index; //OFS: 0x94 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PhysConstraint, 0x98); + ASSERT_STRUCT_OFFSET(PhysConstraint, targetname, 0x0); + ASSERT_STRUCT_OFFSET(PhysConstraint, type, 0x4); + ASSERT_STRUCT_OFFSET(PhysConstraint, attach_point_type1, 0x8); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_index1, 0xC); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_ent1, 0x10); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_bone1, 0x14); + ASSERT_STRUCT_OFFSET(PhysConstraint, attach_point_type2, 0x18); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_index2, 0x1C); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_ent2, 0x20); + ASSERT_STRUCT_OFFSET(PhysConstraint, target_bone2, 0x24); + ASSERT_STRUCT_OFFSET(PhysConstraint, offset, 0x28); + ASSERT_STRUCT_OFFSET(PhysConstraint, pos, 0x34); + ASSERT_STRUCT_OFFSET(PhysConstraint, pos2, 0x40); + ASSERT_STRUCT_OFFSET(PhysConstraint, dir, 0x4C); + ASSERT_STRUCT_OFFSET(PhysConstraint, flags, 0x58); + ASSERT_STRUCT_OFFSET(PhysConstraint, timeout, 0x5C); + ASSERT_STRUCT_OFFSET(PhysConstraint, min_health, 0x60); + ASSERT_STRUCT_OFFSET(PhysConstraint, max_health, 0x64); + ASSERT_STRUCT_OFFSET(PhysConstraint, distance, 0x68); + ASSERT_STRUCT_OFFSET(PhysConstraint, damp, 0x6C); + ASSERT_STRUCT_OFFSET(PhysConstraint, power, 0x70); + ASSERT_STRUCT_OFFSET(PhysConstraint, scale, 0x74); + ASSERT_STRUCT_OFFSET(PhysConstraint, spin_scale, 0x80); + ASSERT_STRUCT_OFFSET(PhysConstraint, minAngle, 0x84); + ASSERT_STRUCT_OFFSET(PhysConstraint, maxAngle, 0x88); + ASSERT_STRUCT_OFFSET(PhysConstraint, material, 0x8C); + ASSERT_STRUCT_OFFSET(PhysConstraint, constraintHandle, 0x90); + ASSERT_STRUCT_OFFSET(PhysConstraint, rope_index, 0x94); + + struct PhysConstraints + { + char* name; //OFS: 0x0 SIZE: 0x4 + unsigned int count; //OFS: 0x4 SIZE: 0x4 + PhysConstraint data[16]; //OFS: 0x8 SIZE: 0x980 + }; + ASSERT_STRUCT_SIZE(PhysConstraints, 0x988); + ASSERT_STRUCT_OFFSET(PhysConstraints, name, 0x0); + ASSERT_STRUCT_OFFSET(PhysConstraints, count, 0x4); + ASSERT_STRUCT_OFFSET(PhysConstraints, data, 0x8); + + struct XModel + { + const char* name; //OFS: 0x0 SIZE: 0x4 + char numBones; //OFS: 0x4 SIZE: 0x1 + char numRootBones; //OFS: 0x5 SIZE: 0x1 + char numsurfs; //OFS: 0x6 SIZE: 0x1 + char lodRampType; //OFS: 0x7 SIZE: 0x1 + unsigned __int16* boneNames; //OFS: 0x8 SIZE: 0x4 + char* parentList; //OFS: 0xC SIZE: 0x4 + __int16* quats; //OFS: 0x10 SIZE: 0x4 + float* trans; //OFS: 0x14 SIZE: 0x4 + char* partClassification; //OFS: 0x18 SIZE: 0x4 + DObjAnimMat* baseMat; //OFS: 0x1C SIZE: 0x4 + XSurface* surfs; //OFS: 0x20 SIZE: 0x4 + Material** materialHandles; //OFS: 0x24 SIZE: 0x4 + XModelLodInfo lodInfo[4]; //OFS: 0x28 SIZE: 0x70 + XModelCollSurf_s* collSurfs; //OFS: 0x98 SIZE: 0x4 + int numCollSurfs; //OFS: 0x9C SIZE: 0x4 + int contents; //OFS: 0xA0 SIZE: 0x4 + XBoneInfo* boneInfo; //OFS: 0xA4 SIZE: 0x4 + float radius; //OFS: 0xA8 SIZE: 0x4 + float mins[3]; //OFS: 0xAC SIZE: 0xC + float maxs[3]; //OFS: 0xB8 SIZE: 0xC + __int16 numLods; //OFS: 0xC4 SIZE: 0x2 + __int16 collLod; //OFS: 0xC6 SIZE: 0x2 + XModelStreamInfo streamInfo; //OFS: 0xC8 SIZE: 0x4 + int memUsage; //OFS: 0xCC SIZE: 0x4 + char flags; //OFS: 0xD0 SIZE: 0x1 + bool bad; //OFS: 0xD1 SIZE: 0x1 + PhysPreset* physPreset; //OFS: 0xD4 SIZE: 0x4 + PhysGeomList* physGeoms; //OFS: 0xD8 SIZE: 0x4 + PhysGeomList* collmap; //OFS: 0xDC SIZE: 0x4 + PhysConstraints* physConstraints; //OFS: 0xE0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XModel, 0xE4); + ASSERT_STRUCT_OFFSET(XModel, name, 0x0); + ASSERT_STRUCT_OFFSET(XModel, numBones, 0x4); + ASSERT_STRUCT_OFFSET(XModel, numRootBones, 0x5); + ASSERT_STRUCT_OFFSET(XModel, numsurfs, 0x6); + ASSERT_STRUCT_OFFSET(XModel, lodRampType, 0x7); + ASSERT_STRUCT_OFFSET(XModel, boneNames, 0x8); + ASSERT_STRUCT_OFFSET(XModel, parentList, 0xC); + ASSERT_STRUCT_OFFSET(XModel, quats, 0x10); + ASSERT_STRUCT_OFFSET(XModel, trans, 0x14); + ASSERT_STRUCT_OFFSET(XModel, partClassification, 0x18); + ASSERT_STRUCT_OFFSET(XModel, baseMat, 0x1C); + ASSERT_STRUCT_OFFSET(XModel, surfs, 0x20); + ASSERT_STRUCT_OFFSET(XModel, materialHandles, 0x24); + ASSERT_STRUCT_OFFSET(XModel, lodInfo, 0x28); + ASSERT_STRUCT_OFFSET(XModel, collSurfs, 0x98); + ASSERT_STRUCT_OFFSET(XModel, numCollSurfs, 0x9C); + ASSERT_STRUCT_OFFSET(XModel, contents, 0xA0); + ASSERT_STRUCT_OFFSET(XModel, boneInfo, 0xA4); + ASSERT_STRUCT_OFFSET(XModel, radius, 0xA8); + ASSERT_STRUCT_OFFSET(XModel, mins, 0xAC); + ASSERT_STRUCT_OFFSET(XModel, maxs, 0xB8); + ASSERT_STRUCT_OFFSET(XModel, numLods, 0xC4); + ASSERT_STRUCT_OFFSET(XModel, collLod, 0xC6); + ASSERT_STRUCT_OFFSET(XModel, streamInfo, 0xC8); + ASSERT_STRUCT_OFFSET(XModel, memUsage, 0xCC); + ASSERT_STRUCT_OFFSET(XModel, flags, 0xD0); + ASSERT_STRUCT_OFFSET(XModel, bad, 0xD1); + ASSERT_STRUCT_OFFSET(XModel, physPreset, 0xD4); + ASSERT_STRUCT_OFFSET(XModel, physGeoms, 0xD8); + ASSERT_STRUCT_OFFSET(XModel, collmap, 0xDC); + ASSERT_STRUCT_OFFSET(XModel, physConstraints, 0xE0); + + struct XModelPiece + { + XModel* model; //OFS: 0x0 SIZE: 0x4 + float offset[3]; //OFS: 0x4 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(XModelPiece, 0x10); + ASSERT_STRUCT_OFFSET(XModelPiece, model, 0x0); + ASSERT_STRUCT_OFFSET(XModelPiece, offset, 0x4); + + struct XModelPieces + { + char* name; //OFS: 0x0 SIZE: 0x4 + int numpieces; //OFS: 0x4 SIZE: 0x4 + XModelPiece* pieces; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XModelPieces, 0xC); + ASSERT_STRUCT_OFFSET(XModelPieces, name, 0x0); + ASSERT_STRUCT_OFFSET(XModelPieces, numpieces, 0x4); + ASSERT_STRUCT_OFFSET(XModelPieces, pieces, 0x8); + + struct FxSpawnDefLooping + { + int intervalMsec; //OFS: 0x0 SIZE: 0x4 + int count; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxSpawnDefLooping, 0x8); + ASSERT_STRUCT_OFFSET(FxSpawnDefLooping, intervalMsec, 0x0); + ASSERT_STRUCT_OFFSET(FxSpawnDefLooping, count, 0x4); + + struct FxIntRange + { + int base; //OFS: 0x0 SIZE: 0x4 + int amplitude; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxIntRange, 0x8); + ASSERT_STRUCT_OFFSET(FxIntRange, base, 0x0); + ASSERT_STRUCT_OFFSET(FxIntRange, amplitude, 0x4); + + struct FxSpawnDefOneShot + { + FxIntRange count; //OFS: 0x0 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(FxSpawnDefOneShot, 0x8); + ASSERT_STRUCT_OFFSET(FxSpawnDefOneShot, count, 0x0); + + union FxSpawnDef + { + FxSpawnDefLooping looping; //OFS: 0x0 SIZE: 0x8 + FxSpawnDefOneShot oneShot; //OFS: 0x1 SIZE: 0x8 + }; + + struct FxFloatRange + { + float base; //OFS: 0x0 SIZE: 0x4 + float amplitude; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxFloatRange, 0x8); + ASSERT_STRUCT_OFFSET(FxFloatRange, base, 0x0); + ASSERT_STRUCT_OFFSET(FxFloatRange, amplitude, 0x4); + + struct __declspec(align(2)) FxElemAtlas + { + unsigned __int8 behavior; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 index; //OFS: 0x1 SIZE: 0x1 + unsigned __int8 fps; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 loopCount; //OFS: 0x3 SIZE: 0x1 + unsigned __int8 colIndexBits; //OFS: 0x4 SIZE: 0x1 + unsigned __int8 rowIndexBits; //OFS: 0x5 SIZE: 0x1 + __int16 entryCount; //OFS: 0x6 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(FxElemAtlas, 0x8); + ASSERT_STRUCT_OFFSET(FxElemAtlas, behavior, 0x0); + ASSERT_STRUCT_OFFSET(FxElemAtlas, index, 0x1); + ASSERT_STRUCT_OFFSET(FxElemAtlas, fps, 0x2); + ASSERT_STRUCT_OFFSET(FxElemAtlas, loopCount, 0x3); + ASSERT_STRUCT_OFFSET(FxElemAtlas, colIndexBits, 0x4); + ASSERT_STRUCT_OFFSET(FxElemAtlas, rowIndexBits, 0x5); + ASSERT_STRUCT_OFFSET(FxElemAtlas, entryCount, 0x6); + + struct FxElemVec3Range + { + float base[3]; //OFS: 0x0 SIZE: 0xC + float amplitude[3]; //OFS: 0xC SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(FxElemVec3Range, 0x18); + ASSERT_STRUCT_OFFSET(FxElemVec3Range, base, 0x0); + ASSERT_STRUCT_OFFSET(FxElemVec3Range, amplitude, 0xC); + + struct FxElemVelStateInFrame + { + FxElemVec3Range velocity; //OFS: 0x0 SIZE: 0x18 + FxElemVec3Range totalDelta; //OFS: 0x18 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(FxElemVelStateInFrame, 0x30); + ASSERT_STRUCT_OFFSET(FxElemVelStateInFrame, velocity, 0x0); + ASSERT_STRUCT_OFFSET(FxElemVelStateInFrame, totalDelta, 0x18); + + struct FxElemVelStateSample + { + FxElemVelStateInFrame local; //OFS: 0x0 SIZE: 0x30 + FxElemVelStateInFrame world; //OFS: 0x30 SIZE: 0x30 + }; + ASSERT_STRUCT_SIZE(FxElemVelStateSample, 0x60); + ASSERT_STRUCT_OFFSET(FxElemVelStateSample, local, 0x0); + ASSERT_STRUCT_OFFSET(FxElemVelStateSample, world, 0x30); + + struct FxElemVisualState + { + unsigned __int8 color[4]; //OFS: 0x0 SIZE: 0x4 + float rotationDelta; //OFS: 0x4 SIZE: 0x4 + float rotationTotal; //OFS: 0x8 SIZE: 0x4 + float size[2]; //OFS: 0xC SIZE: 0x8 + float scale; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxElemVisualState, 0x18); + ASSERT_STRUCT_OFFSET(FxElemVisualState, color, 0x0); + ASSERT_STRUCT_OFFSET(FxElemVisualState, rotationDelta, 0x4); + ASSERT_STRUCT_OFFSET(FxElemVisualState, rotationTotal, 0x8); + ASSERT_STRUCT_OFFSET(FxElemVisualState, size, 0xC); + ASSERT_STRUCT_OFFSET(FxElemVisualState, scale, 0x14); + + struct FxElemVisStateSample + { + FxElemVisualState base; //OFS: 0x0 SIZE: 0x18 + FxElemVisualState amplitude; //OFS: 0x18 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(FxElemVisStateSample, 0x30); + ASSERT_STRUCT_OFFSET(FxElemVisStateSample, base, 0x0); + ASSERT_STRUCT_OFFSET(FxElemVisStateSample, amplitude, 0x18); + + struct FxElemMarkVisuals + { + Material* materials[2]; //OFS: 0x0 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(FxElemMarkVisuals, 0x8); + ASSERT_STRUCT_OFFSET(FxElemMarkVisuals, materials, 0x0); + + struct FxEffectDefRef + { + char* name; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxEffectDefRef, 0x4); + ASSERT_STRUCT_OFFSET(FxEffectDefRef, name, 0x0); + + union FxElemVisuals + { + const void* anonymous; //OFS: 0x0 SIZE: 0x4 + Material* material; //OFS: 0x1 SIZE: 0x4 + XModel* model; //OFS: 0x2 SIZE: 0x4 + FxEffectDefRef effectDef; //OFS: 0x3 SIZE: 0x4 + const char* soundName; //OFS: 0x4 SIZE: 0x4 + }; + + union FxElemDefVisuals + { + FxElemMarkVisuals* markArray; //OFS: 0x0 SIZE: 0x4 + FxElemVisuals* array; //OFS: 0x1 SIZE: 0x4 + FxElemVisuals instance; //OFS: 0x2 SIZE: 0x4 + }; + + struct FxTrailVertex + { + float pos[2]; //OFS: 0x0 SIZE: 0x8 + float normal[2]; //OFS: 0x8 SIZE: 0x8 + float texCoord; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxTrailVertex, 0x14); + ASSERT_STRUCT_OFFSET(FxTrailVertex, pos, 0x0); + ASSERT_STRUCT_OFFSET(FxTrailVertex, normal, 0x8); + ASSERT_STRUCT_OFFSET(FxTrailVertex, texCoord, 0x10); + + struct FxTrailDef + { + int scrollTimeMsec; //OFS: 0x0 SIZE: 0x4 + int repeatDist; //OFS: 0x4 SIZE: 0x4 + int splitDist; //OFS: 0x8 SIZE: 0x4 + int vertCount; //OFS: 0xC SIZE: 0x4 + FxTrailVertex* verts; //OFS: 0x10 SIZE: 0x4 + int indCount; //OFS: 0x14 SIZE: 0x4 + unsigned __int16* inds; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxTrailDef, 0x1C); + ASSERT_STRUCT_OFFSET(FxTrailDef, scrollTimeMsec, 0x0); + ASSERT_STRUCT_OFFSET(FxTrailDef, repeatDist, 0x4); + ASSERT_STRUCT_OFFSET(FxTrailDef, splitDist, 0x8); + ASSERT_STRUCT_OFFSET(FxTrailDef, vertCount, 0xC); + ASSERT_STRUCT_OFFSET(FxTrailDef, verts, 0x10); + ASSERT_STRUCT_OFFSET(FxTrailDef, indCount, 0x14); + ASSERT_STRUCT_OFFSET(FxTrailDef, inds, 0x18); + + struct FxElemDef + { + int flags; //OFS: 0x0 SIZE: 0x4 + FxSpawnDef spawn; //OFS: 0x4 SIZE: 0x8 + FxFloatRange spawnRange; //OFS: 0xC SIZE: 0x8 + FxFloatRange fadeInRange; //OFS: 0x14 SIZE: 0x8 + FxFloatRange fadeOutRange; //OFS: 0x1C SIZE: 0x8 + float spawnFrustumCullRadius; //OFS: 0x24 SIZE: 0x4 + FxIntRange spawnDelayMsec; //OFS: 0x28 SIZE: 0x8 + FxIntRange lifeSpanMsec; //OFS: 0x30 SIZE: 0x8 + FxFloatRange spawnOrigin[3]; //OFS: 0x38 SIZE: 0x18 + FxFloatRange spawnOffsetRadius; //OFS: 0x50 SIZE: 0x8 + FxFloatRange spawnOffsetHeight; //OFS: 0x58 SIZE: 0x8 + FxFloatRange spawnAngles[3]; //OFS: 0x60 SIZE: 0x18 + FxFloatRange angularVelocity[3]; //OFS: 0x78 SIZE: 0x18 + FxFloatRange initialRotation; //OFS: 0x90 SIZE: 0x8 + FxFloatRange gravity; //OFS: 0x98 SIZE: 0x8 + FxFloatRange reflectionFactor; //OFS: 0xA0 SIZE: 0x8 + FxElemAtlas atlas; //OFS: 0xA8 SIZE: 0x8 + float windInfluence; //OFS: 0xB0 SIZE: 0x4 + unsigned __int8 elemType; //OFS: 0xB4 SIZE: 0x1 + unsigned __int8 visualCount; //OFS: 0xB5 SIZE: 0x1 + unsigned __int8 velIntervalCount; //OFS: 0xB6 SIZE: 0x1 + unsigned __int8 visStateIntervalCount; //OFS: 0xB7 SIZE: 0x1 + FxElemVelStateSample* velSamples; //OFS: 0xB8 SIZE: 0x4 + FxElemVisStateSample* visSamples; //OFS: 0xBC SIZE: 0x4 + FxElemDefVisuals visuals; //OFS: 0xC0 SIZE: 0x4 + float collMins[3]; //OFS: 0xC4 SIZE: 0xC + float collMaxs[3]; //OFS: 0xD0 SIZE: 0xC + FxEffectDefRef effectOnImpact; //OFS: 0xDC SIZE: 0x4 + FxEffectDefRef effectOnDeath; //OFS: 0xE0 SIZE: 0x4 + FxEffectDefRef effectEmitted; //OFS: 0xE4 SIZE: 0x4 + FxFloatRange emitDist; //OFS: 0xE8 SIZE: 0x8 + FxFloatRange emitDistVariance; //OFS: 0xF0 SIZE: 0x8 + FxTrailDef* trailDef; //OFS: 0xF8 SIZE: 0x4 + unsigned __int8 sortOrder; //OFS: 0xFC SIZE: 0x1 + unsigned __int8 lightingFrac; //OFS: 0xFD SIZE: 0x1 + unsigned __int8 useItemClip; //OFS: 0xFE SIZE: 0x1 + unsigned __int8 unused[1]; //OFS: 0xFF SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(FxElemDef, 0x100); + ASSERT_STRUCT_OFFSET(FxElemDef, flags, 0x0); + ASSERT_STRUCT_OFFSET(FxElemDef, spawn, 0x4); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnRange, 0xC); + ASSERT_STRUCT_OFFSET(FxElemDef, fadeInRange, 0x14); + ASSERT_STRUCT_OFFSET(FxElemDef, fadeOutRange, 0x1C); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnFrustumCullRadius, 0x24); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnDelayMsec, 0x28); + ASSERT_STRUCT_OFFSET(FxElemDef, lifeSpanMsec, 0x30); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnOrigin, 0x38); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnOffsetRadius, 0x50); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnOffsetHeight, 0x58); + ASSERT_STRUCT_OFFSET(FxElemDef, spawnAngles, 0x60); + ASSERT_STRUCT_OFFSET(FxElemDef, angularVelocity, 0x78); + ASSERT_STRUCT_OFFSET(FxElemDef, initialRotation, 0x90); + ASSERT_STRUCT_OFFSET(FxElemDef, gravity, 0x98); + ASSERT_STRUCT_OFFSET(FxElemDef, reflectionFactor, 0xA0); + ASSERT_STRUCT_OFFSET(FxElemDef, atlas, 0xA8); + ASSERT_STRUCT_OFFSET(FxElemDef, windInfluence, 0xB0); + ASSERT_STRUCT_OFFSET(FxElemDef, elemType, 0xB4); + ASSERT_STRUCT_OFFSET(FxElemDef, visualCount, 0xB5); + ASSERT_STRUCT_OFFSET(FxElemDef, velIntervalCount, 0xB6); + ASSERT_STRUCT_OFFSET(FxElemDef, visStateIntervalCount, 0xB7); + ASSERT_STRUCT_OFFSET(FxElemDef, velSamples, 0xB8); + ASSERT_STRUCT_OFFSET(FxElemDef, visSamples, 0xBC); + ASSERT_STRUCT_OFFSET(FxElemDef, visuals, 0xC0); + ASSERT_STRUCT_OFFSET(FxElemDef, collMins, 0xC4); + ASSERT_STRUCT_OFFSET(FxElemDef, collMaxs, 0xD0); + ASSERT_STRUCT_OFFSET(FxElemDef, effectOnImpact, 0xDC); + ASSERT_STRUCT_OFFSET(FxElemDef, effectOnDeath, 0xE0); + ASSERT_STRUCT_OFFSET(FxElemDef, effectEmitted, 0xE4); + ASSERT_STRUCT_OFFSET(FxElemDef, emitDist, 0xE8); + ASSERT_STRUCT_OFFSET(FxElemDef, emitDistVariance, 0xF0); + ASSERT_STRUCT_OFFSET(FxElemDef, trailDef, 0xF8); + ASSERT_STRUCT_OFFSET(FxElemDef, sortOrder, 0xFC); + ASSERT_STRUCT_OFFSET(FxElemDef, lightingFrac, 0xFD); + ASSERT_STRUCT_OFFSET(FxElemDef, useItemClip, 0xFE); + ASSERT_STRUCT_OFFSET(FxElemDef, unused, 0xFF); + + struct FxEffectDef + { + char* name; //OFS: 0x0 SIZE: 0x4 + int flags; //OFS: 0x4 SIZE: 0x4 + int totalSize; //OFS: 0x8 SIZE: 0x4 + int msecLoopingLife; //OFS: 0xC SIZE: 0x4 + int elemDefCountLooping; //OFS: 0x10 SIZE: 0x4 + int elemDefCountOneShot; //OFS: 0x14 SIZE: 0x4 + int elemDefCountEmission; //OFS: 0x18 SIZE: 0x4 + unsigned __int8 efPriority; //OFS: 0x1C SIZE: 0x1 + FxElemDef* elemDefs; //OFS: 0x20 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxEffectDef, 0x24); + ASSERT_STRUCT_OFFSET(FxEffectDef, name, 0x0); + ASSERT_STRUCT_OFFSET(FxEffectDef, flags, 0x4); + ASSERT_STRUCT_OFFSET(FxEffectDef, totalSize, 0x8); + ASSERT_STRUCT_OFFSET(FxEffectDef, msecLoopingLife, 0xC); + ASSERT_STRUCT_OFFSET(FxEffectDef, elemDefCountLooping, 0x10); + ASSERT_STRUCT_OFFSET(FxEffectDef, elemDefCountOneShot, 0x14); + ASSERT_STRUCT_OFFSET(FxEffectDef, elemDefCountEmission, 0x18); + ASSERT_STRUCT_OFFSET(FxEffectDef, efPriority, 0x1C); + ASSERT_STRUCT_OFFSET(FxEffectDef, elemDefs, 0x20); + + struct snd_asset + { + char* data; //OFS: 0x0 SIZE: 0x4 + int data_size; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_asset, 0x8); + ASSERT_STRUCT_OFFSET(snd_asset, data, 0x0); + ASSERT_STRUCT_OFFSET(snd_asset, data_size, 0x4); + + struct LoadedSound + { + char* name; //OFS: 0x0 SIZE: 0x4 + snd_asset sound; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(LoadedSound, 0xC); + ASSERT_STRUCT_OFFSET(LoadedSound, name, 0x0); + ASSERT_STRUCT_OFFSET(LoadedSound, sound, 0x4); + + struct StreamFileName + { + unsigned int hash; //OFS: 0x0 SIZE: 0x4 + const char* dir; //OFS: 0x4 SIZE: 0x4 + const char* name; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StreamFileName, 0xC); + ASSERT_STRUCT_OFFSET(StreamFileName, hash, 0x0); + ASSERT_STRUCT_OFFSET(StreamFileName, dir, 0x4); + ASSERT_STRUCT_OFFSET(StreamFileName, name, 0x8); + + struct PrimedSound + { + const char* name; //OFS: 0x0 SIZE: 0x4 + unsigned __int8* buffer; //OFS: 0x4 SIZE: 0x4 + unsigned int size; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PrimedSound, 0xC); + ASSERT_STRUCT_OFFSET(PrimedSound, name, 0x0); + ASSERT_STRUCT_OFFSET(PrimedSound, buffer, 0x4); + ASSERT_STRUCT_OFFSET(PrimedSound, size, 0x8); + + struct StreamedSound + { + StreamFileName filename; //OFS: 0x0 SIZE: 0xC + PrimedSound* primeSnd; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StreamedSound, 0x10); + ASSERT_STRUCT_OFFSET(StreamedSound, filename, 0x0); + ASSERT_STRUCT_OFFSET(StreamedSound, primeSnd, 0xC); + + union SoundFileRef + { + LoadedSound* loadSnd; //OFS: 0x0 SIZE: 0x4 + StreamedSound streamSnd; //OFS: 0x1 SIZE: 0x10 + }; + + struct SoundFile + { + unsigned __int8 type; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 exists; //OFS: 0x1 SIZE: 0x1 + SoundFileRef u; //OFS: 0x4 SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(SoundFile, 0x14); + ASSERT_STRUCT_OFFSET(SoundFile, type, 0x0); + ASSERT_STRUCT_OFFSET(SoundFile, exists, 0x1); + ASSERT_STRUCT_OFFSET(SoundFile, u, 0x4); + + struct snd_alias_t + { + char* aliasName; //OFS: 0x0 SIZE: 0x4 + int aliasNameHash; //OFS: 0x4 SIZE: 0x4 + char* subtitle; //OFS: 0x8 SIZE: 0x4 + char* secondaryAliasName; //OFS: 0xC SIZE: 0x4 + char* chainAliasName; //OFS: 0x10 SIZE: 0x4 + SoundFile* soundFile; //OFS: 0x14 SIZE: 0x4 + unsigned int sequence; //OFS: 0x18 SIZE: 0x4 + float volMin; //OFS: 0x1C SIZE: 0x4 + float volMax; //OFS: 0x20 SIZE: 0x4 + float pitchMin; //OFS: 0x24 SIZE: 0x4 + float pitchMax; //OFS: 0x28 SIZE: 0x4 + float distMin; //OFS: 0x2C SIZE: 0x4 + float distMax; //OFS: 0x30 SIZE: 0x4 + float distReverbMax; //OFS: 0x34 SIZE: 0x4 + float slavePercentage; //OFS: 0x38 SIZE: 0x4 + float probability; //OFS: 0x3C SIZE: 0x4 + float lfePercentage; //OFS: 0x40 SIZE: 0x4 + float centerPercentage; //OFS: 0x44 SIZE: 0x4 + float envelopMin; //OFS: 0x48 SIZE: 0x4 + float envelopMax; //OFS: 0x4C SIZE: 0x4 + float envelopPercentage; //OFS: 0x50 SIZE: 0x4 + float minPriority; //OFS: 0x54 SIZE: 0x4 + float maxPriority; //OFS: 0x58 SIZE: 0x4 + float minPriorityThreshold; //OFS: 0x5C SIZE: 0x4 + float maxPriorityThreshold; //OFS: 0x60 SIZE: 0x4 + float reverbSend; //OFS: 0x64 SIZE: 0x4 + int gap2; //OFS: 0x68 SIZE: 0x4 + int gap3; //OFS: 0x6C SIZE: 0x4 + float occlusionLevel; //OFS: 0x70 SIZE: 0x4 + float occlusionWetDry; //OFS: 0x74 SIZE: 0x4 + unsigned int moveTime; //OFS: 0x78 SIZE: 0x4 + unsigned int startDelay; //OFS: 0x7C SIZE: 0x4 + unsigned int speakerMap; //OFS: 0x80 SIZE: 0x4 + int flags; //OFS: 0x84 SIZE: 0x4 + unsigned int volumeFalloffCurve; //OFS: 0x88 SIZE: 0x4 + unsigned int reverbFalloffCurve; //OFS: 0x8C SIZE: 0x4 + unsigned int volumeMinFalloffCurve; //OFS: 0x90 SIZE: 0x4 + unsigned int reverbMinFalloffCurve; //OFS: 0x94 SIZE: 0x4 + snd_limit_type_t limitType; //OFS: 0x98 SIZE: 0x4 + int gap5; //OFS: 0x9C SIZE: 0x4 + unsigned int entityLimitCount; //OFS: 0xA0 SIZE: 0x4 + int gap6; //OFS: 0xA4 SIZE: 0x4 + snd_randomize_type_t randomizeType; //OFS: 0xA8 SIZE: 0x4 + int gap7; //OFS: 0xAC SIZE: 0x4 + int gap8; //OFS: 0xB0 SIZE: 0x4 + int gap9; //OFS: 0xB4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_alias_t, 0xB8); + ASSERT_STRUCT_OFFSET(snd_alias_t, aliasName, 0x0); + ASSERT_STRUCT_OFFSET(snd_alias_t, aliasNameHash, 0x4); + ASSERT_STRUCT_OFFSET(snd_alias_t, subtitle, 0x8); + ASSERT_STRUCT_OFFSET(snd_alias_t, secondaryAliasName, 0xC); + ASSERT_STRUCT_OFFSET(snd_alias_t, chainAliasName, 0x10); + ASSERT_STRUCT_OFFSET(snd_alias_t, soundFile, 0x14); + ASSERT_STRUCT_OFFSET(snd_alias_t, sequence, 0x18); + ASSERT_STRUCT_OFFSET(snd_alias_t, volMin, 0x1C); + ASSERT_STRUCT_OFFSET(snd_alias_t, volMax, 0x20); + ASSERT_STRUCT_OFFSET(snd_alias_t, pitchMin, 0x24); + ASSERT_STRUCT_OFFSET(snd_alias_t, pitchMax, 0x28); + ASSERT_STRUCT_OFFSET(snd_alias_t, distMin, 0x2C); + ASSERT_STRUCT_OFFSET(snd_alias_t, distMax, 0x30); + ASSERT_STRUCT_OFFSET(snd_alias_t, distReverbMax, 0x34); + ASSERT_STRUCT_OFFSET(snd_alias_t, slavePercentage, 0x38); + ASSERT_STRUCT_OFFSET(snd_alias_t, probability, 0x3C); + ASSERT_STRUCT_OFFSET(snd_alias_t, lfePercentage, 0x40); + ASSERT_STRUCT_OFFSET(snd_alias_t, centerPercentage, 0x44); + ASSERT_STRUCT_OFFSET(snd_alias_t, envelopMin, 0x48); + ASSERT_STRUCT_OFFSET(snd_alias_t, envelopMax, 0x4C); + ASSERT_STRUCT_OFFSET(snd_alias_t, envelopPercentage, 0x50); + ASSERT_STRUCT_OFFSET(snd_alias_t, minPriority, 0x54); + ASSERT_STRUCT_OFFSET(snd_alias_t, maxPriority, 0x58); + ASSERT_STRUCT_OFFSET(snd_alias_t, minPriorityThreshold, 0x5C); + ASSERT_STRUCT_OFFSET(snd_alias_t, maxPriorityThreshold, 0x60); + ASSERT_STRUCT_OFFSET(snd_alias_t, reverbSend, 0x64); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap2, 0x68); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap3, 0x6C); + ASSERT_STRUCT_OFFSET(snd_alias_t, occlusionLevel, 0x70); + ASSERT_STRUCT_OFFSET(snd_alias_t, occlusionWetDry, 0x74); + ASSERT_STRUCT_OFFSET(snd_alias_t, moveTime, 0x78); + ASSERT_STRUCT_OFFSET(snd_alias_t, startDelay, 0x7C); + ASSERT_STRUCT_OFFSET(snd_alias_t, speakerMap, 0x80); + ASSERT_STRUCT_OFFSET(snd_alias_t, flags, 0x84); + ASSERT_STRUCT_OFFSET(snd_alias_t, volumeFalloffCurve, 0x88); + ASSERT_STRUCT_OFFSET(snd_alias_t, reverbFalloffCurve, 0x8C); + ASSERT_STRUCT_OFFSET(snd_alias_t, volumeMinFalloffCurve, 0x90); + ASSERT_STRUCT_OFFSET(snd_alias_t, reverbMinFalloffCurve, 0x94); + ASSERT_STRUCT_OFFSET(snd_alias_t, limitType, 0x98); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap5, 0x9C); + ASSERT_STRUCT_OFFSET(snd_alias_t, entityLimitCount, 0xA0); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap6, 0xA4); + ASSERT_STRUCT_OFFSET(snd_alias_t, randomizeType, 0xA8); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap7, 0xAC); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap8, 0xB0); + ASSERT_STRUCT_OFFSET(snd_alias_t, gap9, 0xB4); + + struct snd_alias_list_t + { + char* aliasName; //OFS: 0x0 SIZE: 0x4 + snd_alias_t* head; //OFS: 0x4 SIZE: 0x4 + int count; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_alias_list_t, 0xC); + ASSERT_STRUCT_OFFSET(snd_alias_list_t, aliasName, 0x0); + ASSERT_STRUCT_OFFSET(snd_alias_list_t, head, 0x4); + ASSERT_STRUCT_OFFSET(snd_alias_list_t, count, 0x8); + + struct DestructibleModel + { + XModel* model; //OFS: 0x0 SIZE: 0x4 + float breakHealth; //OFS: 0x4 SIZE: 0x4 + unsigned int flags; //OFS: 0x8 SIZE: 0x4 + FxEffectDef* breakEffect; //OFS: 0xC SIZE: 0x4 + snd_alias_list_t* breakSound; //OFS: 0x10 SIZE: 0x4 + char* breakNotify; //OFS: 0x14 SIZE: 0x4 + char* loopSound; //OFS: 0x18 SIZE: 0x4 + XModel* spawnModel[3]; //OFS: 0x1C SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(DestructibleModel, 0x28); + ASSERT_STRUCT_OFFSET(DestructibleModel, model, 0x0); + ASSERT_STRUCT_OFFSET(DestructibleModel, breakHealth, 0x4); + ASSERT_STRUCT_OFFSET(DestructibleModel, flags, 0x8); + ASSERT_STRUCT_OFFSET(DestructibleModel, breakEffect, 0xC); + ASSERT_STRUCT_OFFSET(DestructibleModel, breakSound, 0x10); + ASSERT_STRUCT_OFFSET(DestructibleModel, breakNotify, 0x14); + ASSERT_STRUCT_OFFSET(DestructibleModel, loopSound, 0x18); + ASSERT_STRUCT_OFFSET(DestructibleModel, spawnModel, 0x1C); + + struct DestructiblePiece + { + DestructibleModel dmodels[5]; //OFS: 0x0 SIZE: 0xC8 + char* attachBone; //OFS: 0xC8 SIZE: 0x4 + unsigned __int16 attachBoneHash; //OFS: 0xCC SIZE: 0x2 + unsigned __int8 parentPiece; //OFS: 0xCE SIZE: 0x1 + float parentDamagePercent; //OFS: 0xD0 SIZE: 0x4 + float bulletDamageScale; //OFS: 0xD4 SIZE: 0x4 + float explosiveDamageScale; //OFS: 0xD8 SIZE: 0x4 + float entityDamageTransfer; //OFS: 0xDC SIZE: 0x4 + PhysConstraints* physConstraints; //OFS: 0xE0 SIZE: 0x4 + int health; //OFS: 0xE4 SIZE: 0x4 + snd_alias_t* damageSound; //OFS: 0xE8 SIZE: 0x4 + FxEffectDef* burnEffect; //OFS: 0xEC SIZE: 0x4 + snd_alias_t* burnSound; //OFS: 0xF0 SIZE: 0x4 + unsigned __int16 enableLabel; //OFS: 0xF4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(DestructiblePiece, 0xF8); + ASSERT_STRUCT_OFFSET(DestructiblePiece, dmodels, 0x0); + ASSERT_STRUCT_OFFSET(DestructiblePiece, attachBone, 0xC8); + ASSERT_STRUCT_OFFSET(DestructiblePiece, attachBoneHash, 0xCC); + ASSERT_STRUCT_OFFSET(DestructiblePiece, parentPiece, 0xCE); + ASSERT_STRUCT_OFFSET(DestructiblePiece, parentDamagePercent, 0xD0); + ASSERT_STRUCT_OFFSET(DestructiblePiece, bulletDamageScale, 0xD4); + ASSERT_STRUCT_OFFSET(DestructiblePiece, explosiveDamageScale, 0xD8); + ASSERT_STRUCT_OFFSET(DestructiblePiece, entityDamageTransfer, 0xDC); + ASSERT_STRUCT_OFFSET(DestructiblePiece, physConstraints, 0xE0); + ASSERT_STRUCT_OFFSET(DestructiblePiece, health, 0xE4); + ASSERT_STRUCT_OFFSET(DestructiblePiece, damageSound, 0xE8); + ASSERT_STRUCT_OFFSET(DestructiblePiece, burnEffect, 0xEC); + ASSERT_STRUCT_OFFSET(DestructiblePiece, burnSound, 0xF0); + ASSERT_STRUCT_OFFSET(DestructiblePiece, enableLabel, 0xF4); + + struct DestructibleDef + { + char* name; //OFS: 0x0 SIZE: 0x4 + XModel* baseModel; //OFS: 0x4 SIZE: 0x4 + int numPieces; //OFS: 0x8 SIZE: 0x4 + DestructiblePiece* pieces; //OFS: 0xC SIZE: 0x4 + int clientOnly; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DestructibleDef, 0x14); + ASSERT_STRUCT_OFFSET(DestructibleDef, name, 0x0); + ASSERT_STRUCT_OFFSET(DestructibleDef, baseModel, 0x4); + ASSERT_STRUCT_OFFSET(DestructibleDef, numPieces, 0x8); + ASSERT_STRUCT_OFFSET(DestructibleDef, pieces, 0xC); + ASSERT_STRUCT_OFFSET(DestructibleDef, clientOnly, 0x10); + + union XAnimIndices + { + char* _1; //OFS: 0x0 SIZE: 0x4 + unsigned __int16* _2; //OFS: 0x1 SIZE: 0x4 + void* data; //OFS: 0x2 SIZE: 0x4 + }; + + struct XAnimNotifyInfo + { + unsigned __int16 name; //OFS: 0x0 SIZE: 0x2 + float time; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimNotifyInfo, 0x8); + ASSERT_STRUCT_OFFSET(XAnimNotifyInfo, name, 0x0); + ASSERT_STRUCT_OFFSET(XAnimNotifyInfo, time, 0x4); + + union XAnimDynamicFrames + { + unsigned __int8 (*_1)[3]; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 (*_2)[3]; //OFS: 0x1 SIZE: 0x4 + }; + + union XAnimDynamicIndices + { + char _1[1]; //OFS: 0x0 SIZE: 0x1 + unsigned __int16 _2[1]; //OFS: 0x1 SIZE: 0x2 + }; + + struct XAnimPartTransFrames + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float size[3]; //OFS: 0xC SIZE: 0xC + XAnimDynamicFrames frames; //OFS: 0x18 SIZE: 0x4 + XAnimDynamicIndices indices; //OFS: 0x1C SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XAnimPartTransFrames, 0x20); + ASSERT_STRUCT_OFFSET(XAnimPartTransFrames, mins, 0x0); + ASSERT_STRUCT_OFFSET(XAnimPartTransFrames, size, 0xC); + ASSERT_STRUCT_OFFSET(XAnimPartTransFrames, frames, 0x18); + ASSERT_STRUCT_OFFSET(XAnimPartTransFrames, indices, 0x1C); + + union XAnimPartTransData + { + XAnimPartTransFrames frames; //OFS: 0x0 SIZE: 0x20 + float frame0[3]; //OFS: 0x1 SIZE: 0xC + }; + + struct XAnimPartTrans + { + unsigned __int16 size; //OFS: 0x0 SIZE: 0x2 + char smallTrans; //OFS: 0x2 SIZE: 0x1 + XAnimPartTransData u; //OFS: 0x4 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(XAnimPartTrans, 0x24); + ASSERT_STRUCT_OFFSET(XAnimPartTrans, size, 0x0); + ASSERT_STRUCT_OFFSET(XAnimPartTrans, smallTrans, 0x2); + ASSERT_STRUCT_OFFSET(XAnimPartTrans, u, 0x4); + + struct XAnimDeltaPartQuatDataFrames + { + __int16 (*frames)[2]; //OFS: 0x0 SIZE: 0x4 + XAnimDynamicIndices indices; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XAnimDeltaPartQuatDataFrames, 0x8); + ASSERT_STRUCT_OFFSET(XAnimDeltaPartQuatDataFrames, frames, 0x0); + ASSERT_STRUCT_OFFSET(XAnimDeltaPartQuatDataFrames, indices, 0x4); + + union XAnimDeltaPartQuatData + { + XAnimDeltaPartQuatDataFrames frames; //OFS: 0x0 SIZE: 0x8 + __int16 frame0[2]; //OFS: 0x1 SIZE: 0x4 + }; + + struct XAnimDeltaPartQuat + { + unsigned __int16 size; //OFS: 0x0 SIZE: 0x2 + XAnimDeltaPartQuatData u; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(XAnimDeltaPartQuat, 0xC); + ASSERT_STRUCT_OFFSET(XAnimDeltaPartQuat, size, 0x0); + ASSERT_STRUCT_OFFSET(XAnimDeltaPartQuat, u, 0x4); + + struct XAnimDeltaPart + { + XAnimPartTrans* trans; //OFS: 0x0 SIZE: 0x4 + XAnimDeltaPartQuat* quat; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimDeltaPart, 0x8); + ASSERT_STRUCT_OFFSET(XAnimDeltaPart, trans, 0x0); + ASSERT_STRUCT_OFFSET(XAnimDeltaPart, quat, 0x4); + + struct XAnimParts + { + const char* name; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 dataByteCount; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 dataShortCount; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 dataIntCount; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 randomDataByteCount; //OFS: 0xA SIZE: 0x2 + unsigned __int16 randomDataIntCount; //OFS: 0xC SIZE: 0x2 + unsigned __int16 numframes; //OFS: 0xE SIZE: 0x2 + bool bLoop; //OFS: 0x10 SIZE: 0x1 + bool bDelta; //OFS: 0x11 SIZE: 0x1 + char boneCount[10]; //OFS: 0x12 SIZE: 0xA + char notifyCount; //OFS: 0x1C SIZE: 0x1 + char assetType; //OFS: 0x1D SIZE: 0x1 + bool isDefault; //OFS: 0x1E SIZE: 0x1 + unsigned int randomDataShortCount; //OFS: 0x20 SIZE: 0x4 + unsigned int indexCount; //OFS: 0x24 SIZE: 0x4 + float framerate; //OFS: 0x28 SIZE: 0x4 + float frequency; //OFS: 0x2C SIZE: 0x4 + unsigned __int16* names; //OFS: 0x30 SIZE: 0x4 + char* dataByte; //OFS: 0x34 SIZE: 0x4 + __int16* dataShort; //OFS: 0x38 SIZE: 0x4 + int* dataInt; //OFS: 0x3C SIZE: 0x4 + __int16* randomDataShort; //OFS: 0x40 SIZE: 0x4 + char* randomDataByte; //OFS: 0x44 SIZE: 0x4 + int* randomDataInt; //OFS: 0x48 SIZE: 0x4 + XAnimIndices indices; //OFS: 0x4C SIZE: 0x4 + XAnimNotifyInfo* notify; //OFS: 0x50 SIZE: 0x4 + XAnimDeltaPart* deltaPart; //OFS: 0x54 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAnimParts, 0x58); + ASSERT_STRUCT_OFFSET(XAnimParts, name, 0x0); + ASSERT_STRUCT_OFFSET(XAnimParts, dataByteCount, 0x4); + ASSERT_STRUCT_OFFSET(XAnimParts, dataShortCount, 0x6); + ASSERT_STRUCT_OFFSET(XAnimParts, dataIntCount, 0x8); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataByteCount, 0xA); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataIntCount, 0xC); + ASSERT_STRUCT_OFFSET(XAnimParts, numframes, 0xE); + ASSERT_STRUCT_OFFSET(XAnimParts, bLoop, 0x10); + ASSERT_STRUCT_OFFSET(XAnimParts, bDelta, 0x11); + ASSERT_STRUCT_OFFSET(XAnimParts, boneCount, 0x12); + ASSERT_STRUCT_OFFSET(XAnimParts, notifyCount, 0x1C); + ASSERT_STRUCT_OFFSET(XAnimParts, assetType, 0x1D); + ASSERT_STRUCT_OFFSET(XAnimParts, isDefault, 0x1E); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataShortCount, 0x20); + ASSERT_STRUCT_OFFSET(XAnimParts, indexCount, 0x24); + ASSERT_STRUCT_OFFSET(XAnimParts, framerate, 0x28); + ASSERT_STRUCT_OFFSET(XAnimParts, frequency, 0x2C); + ASSERT_STRUCT_OFFSET(XAnimParts, names, 0x30); + ASSERT_STRUCT_OFFSET(XAnimParts, dataByte, 0x34); + ASSERT_STRUCT_OFFSET(XAnimParts, dataShort, 0x38); + ASSERT_STRUCT_OFFSET(XAnimParts, dataInt, 0x3C); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataShort, 0x40); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataByte, 0x44); + ASSERT_STRUCT_OFFSET(XAnimParts, randomDataInt, 0x48); + ASSERT_STRUCT_OFFSET(XAnimParts, indices, 0x4C); + ASSERT_STRUCT_OFFSET(XAnimParts, notify, 0x50); + ASSERT_STRUCT_OFFSET(XAnimParts, deltaPart, 0x54); + + struct __declspec(align(2)) cStaticModelWritable + { + unsigned __int16 nextModelInWorldSector; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(cStaticModelWritable, 0x2); + ASSERT_STRUCT_OFFSET(cStaticModelWritable, nextModelInWorldSector, 0x0); + + struct cStaticModel_s + { + cStaticModelWritable writable; //OFS: 0x0 SIZE: 0x2 + XModel* xmodel; //OFS: 0x4 SIZE: 0x4 + float origin[3]; //OFS: 0x8 SIZE: 0xC + float invScaledAxis[3][3]; //OFS: 0x14 SIZE: 0x24 + float absmin[3]; //OFS: 0x38 SIZE: 0xC + float absmax[3]; //OFS: 0x44 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(cStaticModel_s, 0x50); + ASSERT_STRUCT_OFFSET(cStaticModel_s, writable, 0x0); + ASSERT_STRUCT_OFFSET(cStaticModel_s, xmodel, 0x4); + ASSERT_STRUCT_OFFSET(cStaticModel_s, origin, 0x8); + ASSERT_STRUCT_OFFSET(cStaticModel_s, invScaledAxis, 0x14); + ASSERT_STRUCT_OFFSET(cStaticModel_s, absmin, 0x38); + ASSERT_STRUCT_OFFSET(cStaticModel_s, absmax, 0x44); + + struct dmaterial_t + { + char material[64]; //OFS: 0x0 SIZE: 0x40 + int surfaceFlags; //OFS: 0x40 SIZE: 0x4 + int contentFlags; //OFS: 0x44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(dmaterial_t, 0x48); + ASSERT_STRUCT_OFFSET(dmaterial_t, material, 0x0); + ASSERT_STRUCT_OFFSET(dmaterial_t, surfaceFlags, 0x40); + ASSERT_STRUCT_OFFSET(dmaterial_t, contentFlags, 0x44); + + struct cNode_t + { + cplane_s* plane; //OFS: 0x0 SIZE: 0x4 + __int16 children[2]; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cNode_t, 0x8); + ASSERT_STRUCT_OFFSET(cNode_t, plane, 0x0); + ASSERT_STRUCT_OFFSET(cNode_t, children, 0x4); + + struct cLeaf_s + { + unsigned __int16 firstCollAabbIndex; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 collAabbCount; //OFS: 0x2 SIZE: 0x2 + int brushContents; //OFS: 0x4 SIZE: 0x4 + int terrainContents; //OFS: 0x8 SIZE: 0x4 + float mins[3]; //OFS: 0xC SIZE: 0xC + float maxs[3]; //OFS: 0x18 SIZE: 0xC + int leafBrushNode; //OFS: 0x24 SIZE: 0x4 + __int16 cluster; //OFS: 0x28 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(cLeaf_s, 0x2C); + ASSERT_STRUCT_OFFSET(cLeaf_s, firstCollAabbIndex, 0x0); + ASSERT_STRUCT_OFFSET(cLeaf_s, collAabbCount, 0x2); + ASSERT_STRUCT_OFFSET(cLeaf_s, brushContents, 0x4); + ASSERT_STRUCT_OFFSET(cLeaf_s, terrainContents, 0x8); + ASSERT_STRUCT_OFFSET(cLeaf_s, mins, 0xC); + ASSERT_STRUCT_OFFSET(cLeaf_s, maxs, 0x18); + ASSERT_STRUCT_OFFSET(cLeaf_s, leafBrushNode, 0x24); + ASSERT_STRUCT_OFFSET(cLeaf_s, cluster, 0x28); + + struct cLeafBrushNodeLeaf_t + { + unsigned __int16* brushes; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cLeafBrushNodeLeaf_t, 0x4); + ASSERT_STRUCT_OFFSET(cLeafBrushNodeLeaf_t, brushes, 0x0); + + struct cLeafBrushNodeChildren_t + { + float dist; //OFS: 0x0 SIZE: 0x4 + float range; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 childOffset[2]; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cLeafBrushNodeChildren_t, 0xC); + ASSERT_STRUCT_OFFSET(cLeafBrushNodeChildren_t, dist, 0x0); + ASSERT_STRUCT_OFFSET(cLeafBrushNodeChildren_t, range, 0x4); + ASSERT_STRUCT_OFFSET(cLeafBrushNodeChildren_t, childOffset, 0x8); + + union cLeafBrushNodeData_t + { + cLeafBrushNodeLeaf_t leaf; //OFS: 0x0 SIZE: 0x4 + cLeafBrushNodeChildren_t children; //OFS: 0x1 SIZE: 0xC + }; + + struct cLeafBrushNode_s + { + unsigned __int8 axis; //OFS: 0x0 SIZE: 0x1 + __int16 leafBrushCount; //OFS: 0x2 SIZE: 0x2 + int contents; //OFS: 0x4 SIZE: 0x4 + cLeafBrushNodeData_t data; //OFS: 0x8 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(cLeafBrushNode_s, 0x14); + ASSERT_STRUCT_OFFSET(cLeafBrushNode_s, axis, 0x0); + ASSERT_STRUCT_OFFSET(cLeafBrushNode_s, leafBrushCount, 0x2); + ASSERT_STRUCT_OFFSET(cLeafBrushNode_s, contents, 0x4); + ASSERT_STRUCT_OFFSET(cLeafBrushNode_s, data, 0x8); + + struct CollisionBorder + { + float distEq[3]; //OFS: 0x0 SIZE: 0xC + float zBase; //OFS: 0xC SIZE: 0x4 + float zSlope; //OFS: 0x10 SIZE: 0x4 + float start; //OFS: 0x14 SIZE: 0x4 + float length; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CollisionBorder, 0x1C); + ASSERT_STRUCT_OFFSET(CollisionBorder, distEq, 0x0); + ASSERT_STRUCT_OFFSET(CollisionBorder, zBase, 0xC); + ASSERT_STRUCT_OFFSET(CollisionBorder, zSlope, 0x10); + ASSERT_STRUCT_OFFSET(CollisionBorder, start, 0x14); + ASSERT_STRUCT_OFFSET(CollisionBorder, length, 0x18); + + struct CollisionPartition + { + unsigned __int8 triCount; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 borderCount; //OFS: 0x1 SIZE: 0x1 + int firstTri; //OFS: 0x4 SIZE: 0x4 + int nuinds; //OFS: 0x8 SIZE: 0x4 + int fuind; //OFS: 0xC SIZE: 0x4 + CollisionBorder* borders; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CollisionPartition, 0x14); + ASSERT_STRUCT_OFFSET(CollisionPartition, triCount, 0x0); + ASSERT_STRUCT_OFFSET(CollisionPartition, borderCount, 0x1); + ASSERT_STRUCT_OFFSET(CollisionPartition, firstTri, 0x4); + ASSERT_STRUCT_OFFSET(CollisionPartition, nuinds, 0x8); + ASSERT_STRUCT_OFFSET(CollisionPartition, fuind, 0xC); + ASSERT_STRUCT_OFFSET(CollisionPartition, borders, 0x10); + + union CollisionAabbTreeIndex + { + int firstChildIndex; //OFS: 0x0 SIZE: 0x4 + int partitionIndex; //OFS: 0x1 SIZE: 0x4 + }; + + struct CollisionAabbTree + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + unsigned __int16 materialIndex; //OFS: 0xC SIZE: 0x2 + unsigned __int16 childCount; //OFS: 0xE SIZE: 0x2 + float halfSize[3]; //OFS: 0x10 SIZE: 0xC + CollisionAabbTreeIndex u; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(CollisionAabbTree, 0x20); + ASSERT_STRUCT_OFFSET(CollisionAabbTree, origin, 0x0); + ASSERT_STRUCT_OFFSET(CollisionAabbTree, materialIndex, 0xC); + ASSERT_STRUCT_OFFSET(CollisionAabbTree, childCount, 0xE); + ASSERT_STRUCT_OFFSET(CollisionAabbTree, halfSize, 0x10); + ASSERT_STRUCT_OFFSET(CollisionAabbTree, u, 0x1C); + + struct cmodel_t + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + float radius; //OFS: 0x18 SIZE: 0x4 + cLeaf_s leaf; //OFS: 0x1C SIZE: 0x2C + }; + ASSERT_STRUCT_SIZE(cmodel_t, 0x48); + ASSERT_STRUCT_OFFSET(cmodel_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(cmodel_t, maxs, 0xC); + ASSERT_STRUCT_OFFSET(cmodel_t, radius, 0x18); + ASSERT_STRUCT_OFFSET(cmodel_t, leaf, 0x1C); + + struct cbrush_t + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + int contents; //OFS: 0xC SIZE: 0x4 + float maxs[3]; //OFS: 0x10 SIZE: 0xC + unsigned int numsides; //OFS: 0x1C SIZE: 0x4 + cbrushside_t* sides; //OFS: 0x20 SIZE: 0x4 + __int16 axialMaterialNum[2][3]; //OFS: 0x24 SIZE: 0xC + unsigned __int8* baseAdjacentSide; //OFS: 0x30 SIZE: 0x4 + __int16 firstAdjacentSideOffsets[2][3]; //OFS: 0x34 SIZE: 0xC + unsigned __int8 edgeCount[2][3]; //OFS: 0x40 SIZE: 0x6 + unsigned int numverts; //OFS: 0x48 SIZE: 0x4 + float(*verts)[3]; //OFS: 0x4C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(cbrush_t, 0x50); + ASSERT_STRUCT_OFFSET(cbrush_t, mins, 0x0); + ASSERT_STRUCT_OFFSET(cbrush_t, contents, 0xC); + ASSERT_STRUCT_OFFSET(cbrush_t, maxs, 0x10); + ASSERT_STRUCT_OFFSET(cbrush_t, numsides, 0x1C); + ASSERT_STRUCT_OFFSET(cbrush_t, sides, 0x20); + ASSERT_STRUCT_OFFSET(cbrush_t, axialMaterialNum, 0x24); + ASSERT_STRUCT_OFFSET(cbrush_t, baseAdjacentSide, 0x30); + ASSERT_STRUCT_OFFSET(cbrush_t, firstAdjacentSideOffsets, 0x34); + ASSERT_STRUCT_OFFSET(cbrush_t, edgeCount, 0x40); + ASSERT_STRUCT_OFFSET(cbrush_t, numverts, 0x48); + ASSERT_STRUCT_OFFSET(cbrush_t, verts, 0x4C); + + struct MapEnts + { + char* name; //OFS: 0x0 SIZE: 0x4 + char* entityString; //OFS: 0x4 SIZE: 0x4 + int numEntityChars; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MapEnts, 0xC); + ASSERT_STRUCT_OFFSET(MapEnts, name, 0x0); + ASSERT_STRUCT_OFFSET(MapEnts, entityString, 0x4); + ASSERT_STRUCT_OFFSET(MapEnts, numEntityChars, 0x8); + + struct GfxPlacement + { + float quat[4]; //OFS: 0x0 SIZE: 0x10 + float origin[3]; //OFS: 0x10 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(GfxPlacement, 0x1C); + ASSERT_STRUCT_OFFSET(GfxPlacement, quat, 0x0); + ASSERT_STRUCT_OFFSET(GfxPlacement, origin, 0x10); + + struct DynEntityDef + { + DynEntityType type; //OFS: 0x0 SIZE: 0x4 + GfxPlacement pose; //OFS: 0x4 SIZE: 0x1C + XModel* xModel; //OFS: 0x20 SIZE: 0x4 + unsigned __int16 brushModel; //OFS: 0x24 SIZE: 0x2 + unsigned __int16 physicsBrushModel; //OFS: 0x26 SIZE: 0x2 + FxEffectDef* destroyFx; //OFS: 0x28 SIZE: 0x4 + XModelPieces* destroyPieces; //OFS: 0x2C SIZE: 0x4 + PhysPreset* physPreset; //OFS: 0x30 SIZE: 0x4 + unsigned __int8 physConstraints[4]; //OFS: 0x34 SIZE: 0x4 + int health; //OFS: 0x38 SIZE: 0x4 + PhysMass mass; //OFS: 0x3C SIZE: 0xC + int flags; //OFS: 0x48 SIZE: 0x4 + int contents; //OFS: 0x4C SIZE: 0x4 + unsigned __int16 targetname; //OFS: 0x50 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(DynEntityDef, 0x54); + ASSERT_STRUCT_OFFSET(DynEntityDef, type, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityDef, pose, 0x4); + ASSERT_STRUCT_OFFSET(DynEntityDef, xModel, 0x20); + ASSERT_STRUCT_OFFSET(DynEntityDef, brushModel, 0x24); + ASSERT_STRUCT_OFFSET(DynEntityDef, physicsBrushModel, 0x26); + ASSERT_STRUCT_OFFSET(DynEntityDef, destroyFx, 0x28); + ASSERT_STRUCT_OFFSET(DynEntityDef, destroyPieces, 0x2C); + ASSERT_STRUCT_OFFSET(DynEntityDef, physPreset, 0x30); + ASSERT_STRUCT_OFFSET(DynEntityDef, physConstraints, 0x34); + ASSERT_STRUCT_OFFSET(DynEntityDef, health, 0x38); + ASSERT_STRUCT_OFFSET(DynEntityDef, mass, 0x3C); + ASSERT_STRUCT_OFFSET(DynEntityDef, flags, 0x48); + ASSERT_STRUCT_OFFSET(DynEntityDef, contents, 0x4C); + ASSERT_STRUCT_OFFSET(DynEntityDef, targetname, 0x50); + + struct DynEntityPose + { + GfxPlacement pose; //OFS: 0x0 SIZE: 0x1C + float radius; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEntityPose, 0x20); + ASSERT_STRUCT_OFFSET(DynEntityPose, pose, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityPose, radius, 0x1C); + + struct DynEntityClient + { + int physObjId; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 flags; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 lightingHandle; //OFS: 0x6 SIZE: 0x2 + int health; //OFS: 0x8 SIZE: 0x4 + unsigned __int16 burnTime; //OFS: 0xC SIZE: 0x2 + unsigned __int16 fadeTime; //OFS: 0xE SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(DynEntityClient, 0x10); + ASSERT_STRUCT_OFFSET(DynEntityClient, physObjId, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityClient, flags, 0x4); + ASSERT_STRUCT_OFFSET(DynEntityClient, lightingHandle, 0x6); + ASSERT_STRUCT_OFFSET(DynEntityClient, health, 0x8); + ASSERT_STRUCT_OFFSET(DynEntityClient, burnTime, 0xC); + ASSERT_STRUCT_OFFSET(DynEntityClient, fadeTime, 0xE); + + struct DynEntityServer + { + unsigned __int16 flags; //OFS: 0x0 SIZE: 0x2 + int health; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEntityServer, 0x8); + ASSERT_STRUCT_OFFSET(DynEntityServer, flags, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityServer, health, 0x4); + + struct DynEntityColl + { + unsigned __int16 sector; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 nextEntInSector; //OFS: 0x2 SIZE: 0x2 + float linkMins[3]; //OFS: 0x4 SIZE: 0xC + float linkMaxs[3]; //OFS: 0x10 SIZE: 0xC + int contents; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(DynEntityColl, 0x20); + ASSERT_STRUCT_OFFSET(DynEntityColl, sector, 0x0); + ASSERT_STRUCT_OFFSET(DynEntityColl, nextEntInSector, 0x2); + ASSERT_STRUCT_OFFSET(DynEntityColl, linkMins, 0x4); + ASSERT_STRUCT_OFFSET(DynEntityColl, linkMaxs, 0x10); + ASSERT_STRUCT_OFFSET(DynEntityColl, contents, 0x1C); + + struct clipMap_t + { + char* name; //OFS: 0x0 SIZE: 0x4 + int isInUse; //OFS: 0x4 SIZE: 0x4 + int planeCount; //OFS: 0x8 SIZE: 0x4 + cplane_s* planes; //OFS: 0xC SIZE: 0x4 + unsigned int numStaticModels; //OFS: 0x10 SIZE: 0x4 + cStaticModel_s* staticModelList; //OFS: 0x14 SIZE: 0x4 + unsigned int numMaterials; //OFS: 0x18 SIZE: 0x4 + dmaterial_t* materials; //OFS: 0x1C SIZE: 0x4 + unsigned int numBrushSides; //OFS: 0x20 SIZE: 0x4 + cbrushside_t* brushsides; //OFS: 0x24 SIZE: 0x4 + unsigned int numBrushEdges; //OFS: 0x28 SIZE: 0x4 + unsigned __int8* brushEdges; //OFS: 0x2C SIZE: 0x4 + unsigned int numNodes; //OFS: 0x30 SIZE: 0x4 + cNode_t* nodes; //OFS: 0x34 SIZE: 0x4 + unsigned int numLeafs; //OFS: 0x38 SIZE: 0x4 + cLeaf_s* leafs; //OFS: 0x3C SIZE: 0x4 + unsigned int leafbrushNodesCount; //OFS: 0x40 SIZE: 0x4 + cLeafBrushNode_s* leafbrushNodes; //OFS: 0x44 SIZE: 0x4 + unsigned int numLeafBrushes; //OFS: 0x48 SIZE: 0x4 + unsigned __int16* leafbrushes; //OFS: 0x4C SIZE: 0x4 + unsigned int numLeafSurfaces; //OFS: 0x50 SIZE: 0x4 + unsigned int* leafsurfaces; //OFS: 0x54 SIZE: 0x4 + unsigned int vertCount; //OFS: 0x58 SIZE: 0x4 + float(*verts)[3]; //OFS: 0x5C SIZE: 0x4 + unsigned int numBrushVerts; //OFS: 0x60 SIZE: 0x4 + float(*brushVerts)[3]; //OFS: 0x64 SIZE: 0x4 + unsigned int nuinds; //OFS: 0x68 SIZE: 0x4 + unsigned __int16* uinds; //OFS: 0x6C SIZE: 0x4 + int triCount; //OFS: 0x70 SIZE: 0x4 + unsigned __int16* triIndices; //OFS: 0x74 SIZE: 0x4 + unsigned __int8* triEdgeIsWalkable; //OFS: 0x78 SIZE: 0x4 + int borderCount; //OFS: 0x7C SIZE: 0x4 + CollisionBorder* borders; //OFS: 0x80 SIZE: 0x4 + int partitionCount; //OFS: 0x84 SIZE: 0x4 + CollisionPartition* partitions; //OFS: 0x88 SIZE: 0x4 + int aabbTreeCount; //OFS: 0x8C SIZE: 0x4 + CollisionAabbTree* aabbTrees; //OFS: 0x90 SIZE: 0x4 + unsigned int numSubModels; //OFS: 0x94 SIZE: 0x4 + cmodel_t* cmodels; //OFS: 0x98 SIZE: 0x4 + unsigned __int16 numBrushes; //OFS: 0x9C SIZE: 0x2 + cbrush_t* brushes; //OFS: 0xA0 SIZE: 0x4 + int numClusters; //OFS: 0xA4 SIZE: 0x4 + int clusterBytes; //OFS: 0xA8 SIZE: 0x4 + unsigned __int8* visibility; //OFS: 0xAC SIZE: 0x4 + int vised; //OFS: 0xB0 SIZE: 0x4 + MapEnts* mapEnts; //OFS: 0xB4 SIZE: 0x4 + cbrush_t* box_brush; //OFS: 0xB8 SIZE: 0x4 + cmodel_t box_model; //OFS: 0xBC SIZE: 0x48 + unsigned __int16 originalDynEntCount; //OFS: 0x104 SIZE: 0x2 + unsigned __int16 dynEntCount[4]; //OFS: 0x106 SIZE: 0x8 + DynEntityDef* dynEntDefList[2]; //OFS: 0x110 SIZE: 0x8 + DynEntityPose* dynEntPoseList[2]; //OFS: 0x118 SIZE: 0x8 + DynEntityClient* dynEntClientList[2]; //OFS: 0x120 SIZE: 0x8 + DynEntityServer* dynEntServerList[2]; //OFS: 0x128 SIZE: 0x8 + DynEntityColl* dynEntCollList[4]; //OFS: 0x130 SIZE: 0x10 + int num_constraints; //OFS: 0x140 SIZE: 0x4 + PhysConstraint* constraints; //OFS: 0x144 SIZE: 0x4 + unsigned int checksum; //OFS: 0x148 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(clipMap_t, 0x14C); + ASSERT_STRUCT_OFFSET(clipMap_t, name, 0x0); + ASSERT_STRUCT_OFFSET(clipMap_t, isInUse, 0x4); + ASSERT_STRUCT_OFFSET(clipMap_t, planeCount, 0x8); + ASSERT_STRUCT_OFFSET(clipMap_t, planes, 0xC); + ASSERT_STRUCT_OFFSET(clipMap_t, numStaticModels, 0x10); + ASSERT_STRUCT_OFFSET(clipMap_t, staticModelList, 0x14); + ASSERT_STRUCT_OFFSET(clipMap_t, numMaterials, 0x18); + ASSERT_STRUCT_OFFSET(clipMap_t, materials, 0x1C); + ASSERT_STRUCT_OFFSET(clipMap_t, numBrushSides, 0x20); + ASSERT_STRUCT_OFFSET(clipMap_t, brushsides, 0x24); + ASSERT_STRUCT_OFFSET(clipMap_t, numBrushEdges, 0x28); + ASSERT_STRUCT_OFFSET(clipMap_t, brushEdges, 0x2C); + ASSERT_STRUCT_OFFSET(clipMap_t, numNodes, 0x30); + ASSERT_STRUCT_OFFSET(clipMap_t, nodes, 0x34); + ASSERT_STRUCT_OFFSET(clipMap_t, numLeafs, 0x38); + ASSERT_STRUCT_OFFSET(clipMap_t, leafs, 0x3C); + ASSERT_STRUCT_OFFSET(clipMap_t, leafbrushNodesCount, 0x40); + ASSERT_STRUCT_OFFSET(clipMap_t, leafbrushNodes, 0x44); + ASSERT_STRUCT_OFFSET(clipMap_t, numLeafBrushes, 0x48); + ASSERT_STRUCT_OFFSET(clipMap_t, leafbrushes, 0x4C); + ASSERT_STRUCT_OFFSET(clipMap_t, numLeafSurfaces, 0x50); + ASSERT_STRUCT_OFFSET(clipMap_t, leafsurfaces, 0x54); + ASSERT_STRUCT_OFFSET(clipMap_t, vertCount, 0x58); + ASSERT_STRUCT_OFFSET(clipMap_t, verts, 0x5C); + ASSERT_STRUCT_OFFSET(clipMap_t, numBrushVerts, 0x60); + ASSERT_STRUCT_OFFSET(clipMap_t, brushVerts, 0x64); + ASSERT_STRUCT_OFFSET(clipMap_t, nuinds, 0x68); + ASSERT_STRUCT_OFFSET(clipMap_t, uinds, 0x6C); + ASSERT_STRUCT_OFFSET(clipMap_t, triCount, 0x70); + ASSERT_STRUCT_OFFSET(clipMap_t, triIndices, 0x74); + ASSERT_STRUCT_OFFSET(clipMap_t, triEdgeIsWalkable, 0x78); + ASSERT_STRUCT_OFFSET(clipMap_t, borderCount, 0x7C); + ASSERT_STRUCT_OFFSET(clipMap_t, borders, 0x80); + ASSERT_STRUCT_OFFSET(clipMap_t, partitionCount, 0x84); + ASSERT_STRUCT_OFFSET(clipMap_t, partitions, 0x88); + ASSERT_STRUCT_OFFSET(clipMap_t, aabbTreeCount, 0x8C); + ASSERT_STRUCT_OFFSET(clipMap_t, aabbTrees, 0x90); + ASSERT_STRUCT_OFFSET(clipMap_t, numSubModels, 0x94); + ASSERT_STRUCT_OFFSET(clipMap_t, cmodels, 0x98); + ASSERT_STRUCT_OFFSET(clipMap_t, numBrushes, 0x9C); + ASSERT_STRUCT_OFFSET(clipMap_t, brushes, 0xA0); + ASSERT_STRUCT_OFFSET(clipMap_t, numClusters, 0xA4); + ASSERT_STRUCT_OFFSET(clipMap_t, clusterBytes, 0xA8); + ASSERT_STRUCT_OFFSET(clipMap_t, visibility, 0xAC); + ASSERT_STRUCT_OFFSET(clipMap_t, vised, 0xB0); + ASSERT_STRUCT_OFFSET(clipMap_t, mapEnts, 0xB4); + ASSERT_STRUCT_OFFSET(clipMap_t, box_brush, 0xB8); + ASSERT_STRUCT_OFFSET(clipMap_t, box_model, 0xBC); + ASSERT_STRUCT_OFFSET(clipMap_t, originalDynEntCount, 0x104); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntCount, 0x106); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntDefList, 0x110); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntPoseList, 0x118); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntClientList, 0x120); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntServerList, 0x128); + ASSERT_STRUCT_OFFSET(clipMap_t, dynEntCollList, 0x130); + ASSERT_STRUCT_OFFSET(clipMap_t, num_constraints, 0x140); + ASSERT_STRUCT_OFFSET(clipMap_t, constraints, 0x144); + ASSERT_STRUCT_OFFSET(clipMap_t, checksum, 0x148); + + struct ComPrimaryLight + { + unsigned __int8 type; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 canUseShadowMap; //OFS: 0x1 SIZE: 0x1 + unsigned __int8 exponent; //OFS: 0x2 SIZE: 0x1 + char priority; //OFS: 0x3 SIZE: 0x1 + __int16 cullDist; //OFS: 0x4 SIZE: 0x2 + float color[3]; //OFS: 0x8 SIZE: 0xC + float dir[3]; //OFS: 0x14 SIZE: 0xC + float origin[3]; //OFS: 0x20 SIZE: 0xC + float radius; //OFS: 0x2C SIZE: 0x4 + float cosHalfFovOuter; //OFS: 0x30 SIZE: 0x4 + float cosHalfFovInner; //OFS: 0x34 SIZE: 0x4 + float cosHalfFovExpanded; //OFS: 0x38 SIZE: 0x4 + float rotationLimit; //OFS: 0x3C SIZE: 0x4 + float translationLimit; //OFS: 0x40 SIZE: 0x4 + char* defName; //OFS: 0x44 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComPrimaryLight, 0x48); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, type, 0x0); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, canUseShadowMap, 0x1); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, exponent, 0x2); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, priority, 0x3); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, cullDist, 0x4); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, color, 0x8); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, dir, 0x14); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, origin, 0x20); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, radius, 0x2C); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, cosHalfFovOuter, 0x30); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, cosHalfFovInner, 0x34); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, cosHalfFovExpanded, 0x38); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, rotationLimit, 0x3C); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, translationLimit, 0x40); + ASSERT_STRUCT_OFFSET(ComPrimaryLight, defName, 0x44); + + struct ComWaterHeader + { + int minx; //OFS: 0x0 SIZE: 0x4 + int miny; //OFS: 0x4 SIZE: 0x4 + int maxx; //OFS: 0x8 SIZE: 0x4 + int maxy; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComWaterHeader, 0x10); + ASSERT_STRUCT_OFFSET(ComWaterHeader, minx, 0x0); + ASSERT_STRUCT_OFFSET(ComWaterHeader, miny, 0x4); + ASSERT_STRUCT_OFFSET(ComWaterHeader, maxx, 0x8); + ASSERT_STRUCT_OFFSET(ComWaterHeader, maxy, 0xC); + + struct __declspec(align(2)) ComWaterCell + { + __int16 waterheight; //OFS: 0x0 SIZE: 0x2 + char flooroffset; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 shoredist; //OFS: 0x3 SIZE: 0x1 + unsigned __int8 color[4]; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComWaterCell, 0x8); + ASSERT_STRUCT_OFFSET(ComWaterCell, waterheight, 0x0); + ASSERT_STRUCT_OFFSET(ComWaterCell, flooroffset, 0x2); + ASSERT_STRUCT_OFFSET(ComWaterCell, shoredist, 0x3); + ASSERT_STRUCT_OFFSET(ComWaterCell, color, 0x4); + + struct ComBurnableHeader + { + int minx; //OFS: 0x0 SIZE: 0x4 + int miny; //OFS: 0x4 SIZE: 0x4 + int maxx; //OFS: 0x8 SIZE: 0x4 + int maxy; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComBurnableHeader, 0x10); + ASSERT_STRUCT_OFFSET(ComBurnableHeader, minx, 0x0); + ASSERT_STRUCT_OFFSET(ComBurnableHeader, miny, 0x4); + ASSERT_STRUCT_OFFSET(ComBurnableHeader, maxx, 0x8); + ASSERT_STRUCT_OFFSET(ComBurnableHeader, maxy, 0xC); + + struct __declspec(align(1)) ComBurnableSample + { + unsigned __int8 state; //OFS: 0x0 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(ComBurnableSample, 0x1); + ASSERT_STRUCT_OFFSET(ComBurnableSample, state, 0x0); + + struct ComBurnableCell + { + int x; //OFS: 0x0 SIZE: 0x4 + int y; //OFS: 0x4 SIZE: 0x4 + ComBurnableSample* data; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComBurnableCell, 0xC); + ASSERT_STRUCT_OFFSET(ComBurnableCell, x, 0x0); + ASSERT_STRUCT_OFFSET(ComBurnableCell, y, 0x4); + ASSERT_STRUCT_OFFSET(ComBurnableCell, data, 0x8); + + struct ComWorld + { + char* name; //OFS: 0x0 SIZE: 0x4 + int isInUse; //OFS: 0x4 SIZE: 0x4 + unsigned int primaryLightCount; //OFS: 0x8 SIZE: 0x4 + ComPrimaryLight* primaryLights; //OFS: 0xC SIZE: 0x4 + ComWaterHeader waterHeader; //OFS: 0x10 SIZE: 0x10 + unsigned int numWaterCells; //OFS: 0x20 SIZE: 0x4 + ComWaterCell* waterCells; //OFS: 0x24 SIZE: 0x4 + ComBurnableHeader burnableHeader; //OFS: 0x28 SIZE: 0x10 + unsigned int numBurnableCells; //OFS: 0x38 SIZE: 0x4 + ComBurnableCell* burnableCells; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ComWorld, 0x40); + ASSERT_STRUCT_OFFSET(ComWorld, name, 0x0); + ASSERT_STRUCT_OFFSET(ComWorld, isInUse, 0x4); + ASSERT_STRUCT_OFFSET(ComWorld, primaryLightCount, 0x8); + ASSERT_STRUCT_OFFSET(ComWorld, primaryLights, 0xC); + ASSERT_STRUCT_OFFSET(ComWorld, waterHeader, 0x10); + ASSERT_STRUCT_OFFSET(ComWorld, numWaterCells, 0x20); + ASSERT_STRUCT_OFFSET(ComWorld, waterCells, 0x24); + ASSERT_STRUCT_OFFSET(ComWorld, burnableHeader, 0x28); + ASSERT_STRUCT_OFFSET(ComWorld, numBurnableCells, 0x38); + ASSERT_STRUCT_OFFSET(ComWorld, burnableCells, 0x3C); + + struct pathlink_s + { + float fDist; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 nodeNum; //OFS: 0x4 SIZE: 0x2 + unsigned __int8 disconnectCount; //OFS: 0x6 SIZE: 0x1 + unsigned __int8 negotiationLink; //OFS: 0x7 SIZE: 0x1 + unsigned __int8 ubBadPlaceCount[4]; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathlink_s, 0xC); + ASSERT_STRUCT_OFFSET(pathlink_s, fDist, 0x0); + ASSERT_STRUCT_OFFSET(pathlink_s, nodeNum, 0x4); + ASSERT_STRUCT_OFFSET(pathlink_s, disconnectCount, 0x6); + ASSERT_STRUCT_OFFSET(pathlink_s, negotiationLink, 0x7); + ASSERT_STRUCT_OFFSET(pathlink_s, ubBadPlaceCount, 0x8); + + struct pathnode_constant_t + { + nodeType type; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 spawnflags; //OFS: 0x4 SIZE: 0x2 + unsigned __int16 targetname; //OFS: 0x6 SIZE: 0x2 + unsigned __int16 script_linkName; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 script_noteworthy; //OFS: 0xA SIZE: 0x2 + unsigned __int16 target; //OFS: 0xC SIZE: 0x2 + unsigned __int16 animscript; //OFS: 0xE SIZE: 0x2 + int animscriptfunc; //OFS: 0x10 SIZE: 0x4 + float vOrigin[3]; //OFS: 0x14 SIZE: 0xC + float fAngle; //OFS: 0x20 SIZE: 0x4 + float forward[2]; //OFS: 0x24 SIZE: 0x8 + float fRadius; //OFS: 0x2C SIZE: 0x4 + float minUseDistSq; //OFS: 0x30 SIZE: 0x4 + __int16 wOverlapNode[2]; //OFS: 0x34 SIZE: 0x4 + __int16 wChainId; //OFS: 0x38 SIZE: 0x2 + __int16 wChainDepth; //OFS: 0x3A SIZE: 0x2 + __int16 wChainParent; //OFS: 0x3C SIZE: 0x2 + unsigned __int16 totalLinkCount; //OFS: 0x3E SIZE: 0x2 + pathlink_s* Links; //OFS: 0x40 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathnode_constant_t, 0x44); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, type, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, spawnflags, 0x4); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, targetname, 0x6); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, script_linkName, 0x8); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, script_noteworthy, 0xA); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, target, 0xC); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, animscript, 0xE); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, animscriptfunc, 0x10); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, vOrigin, 0x14); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, fAngle, 0x20); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, forward, 0x24); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, fRadius, 0x2C); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, minUseDistSq, 0x30); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, wOverlapNode, 0x34); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, wChainId, 0x38); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, wChainDepth, 0x3A); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, wChainParent, 0x3C); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, totalLinkCount, 0x3E); + ASSERT_STRUCT_OFFSET(pathnode_constant_t, Links, 0x40); + + struct __declspec(align(2)) SentientHandle + { + unsigned __int16 number; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 infoIndex; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(SentientHandle, 0x4); + ASSERT_STRUCT_OFFSET(SentientHandle, number, 0x0); + ASSERT_STRUCT_OFFSET(SentientHandle, infoIndex, 0x2); + + struct pathnode_dynamic_t + { + SentientHandle pOwner; //OFS: 0x0 SIZE: 0x4 + int iFreeTime; //OFS: 0x4 SIZE: 0x4 + int iValidTime[3]; //OFS: 0x8 SIZE: 0xC + int inPlayerLOSTime; //OFS: 0x14 SIZE: 0x4 + __int16 wLinkCount; //OFS: 0x18 SIZE: 0x2 + __int16 wOverlapCount; //OFS: 0x1A SIZE: 0x2 + __int16 turretEntNumber; //OFS: 0x1C SIZE: 0x2 + __int16 userCount; //OFS: 0x1E SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(pathnode_dynamic_t, 0x20); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, pOwner, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, iFreeTime, 0x4); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, iValidTime, 0x8); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, inPlayerLOSTime, 0x14); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, wLinkCount, 0x18); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, wOverlapCount, 0x1A); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, turretEntNumber, 0x1C); + ASSERT_STRUCT_OFFSET(pathnode_dynamic_t, userCount, 0x1E); + + struct pathnode_transient_t + { + int iSearchFrame; //OFS: 0x0 SIZE: 0x4 + pathnode_t* pNextOpen; //OFS: 0x4 SIZE: 0x4 + pathnode_t* pPrevOpen; //OFS: 0x8 SIZE: 0x4 + pathnode_t* pParent; //OFS: 0xC SIZE: 0x4 + float fCost; //OFS: 0x10 SIZE: 0x4 + float fHeuristic; //OFS: 0x14 SIZE: 0x4 + float costFactor; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathnode_transient_t, 0x1C); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, iSearchFrame, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, pNextOpen, 0x4); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, pPrevOpen, 0x8); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, pParent, 0xC); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, fCost, 0x10); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, fHeuristic, 0x14); + ASSERT_STRUCT_OFFSET(pathnode_transient_t, costFactor, 0x18); + + struct pathnode_t + { + pathnode_constant_t constant; //OFS: 0x0 SIZE: 0x44 + pathnode_dynamic_t dynamic; //OFS: 0x44 SIZE: 0x20 + pathnode_transient_t transient; //OFS: 0x64 SIZE: 0x1C + }; + ASSERT_STRUCT_SIZE(pathnode_t, 0x80); + ASSERT_STRUCT_OFFSET(pathnode_t, constant, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_t, dynamic, 0x44); + ASSERT_STRUCT_OFFSET(pathnode_t, transient, 0x64); + + struct pathbasenode_t + { + float vOrigin[3]; //OFS: 0x0 SIZE: 0xC + unsigned int type; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathbasenode_t, 0x10); + ASSERT_STRUCT_OFFSET(pathbasenode_t, vOrigin, 0x0); + ASSERT_STRUCT_OFFSET(pathbasenode_t, type, 0xC); + + struct pathnode_tree_nodes_t + { + int nodeCount; //OFS: 0x0 SIZE: 0x4 + unsigned __int16* nodes; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(pathnode_tree_nodes_t, 0x8); + ASSERT_STRUCT_OFFSET(pathnode_tree_nodes_t, nodeCount, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_tree_nodes_t, nodes, 0x4); + + union pathnode_tree_info_t + { + pathnode_tree_t* child[2]; //OFS: 0x0 SIZE: 0x8 + pathnode_tree_nodes_t s; //OFS: 0x1 SIZE: 0x8 + }; + + struct pathnode_tree_t + { + int axis; //OFS: 0x0 SIZE: 0x4 + float dist; //OFS: 0x4 SIZE: 0x4 + pathnode_tree_info_t u; //OFS: 0x8 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(pathnode_tree_t, 0x10); + ASSERT_STRUCT_OFFSET(pathnode_tree_t, axis, 0x0); + ASSERT_STRUCT_OFFSET(pathnode_tree_t, dist, 0x4); + ASSERT_STRUCT_OFFSET(pathnode_tree_t, u, 0x8); + + struct PathData + { + unsigned int nodeCount; //OFS: 0x0 SIZE: 0x4 + pathnode_t* nodes; //OFS: 0x4 SIZE: 0x4 + pathbasenode_t* basenodes; //OFS: 0x8 SIZE: 0x4 + unsigned int chainNodeCount; //OFS: 0xC SIZE: 0x4 + unsigned __int16* chainNodeForNode; //OFS: 0x10 SIZE: 0x4 + unsigned __int16* nodeForChainNode; //OFS: 0x14 SIZE: 0x4 + int visBytes; //OFS: 0x18 SIZE: 0x4 + unsigned __int8* pathVis; //OFS: 0x1C SIZE: 0x4 + int nodeTreeCount; //OFS: 0x20 SIZE: 0x4 + pathnode_tree_t* nodeTree; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PathData, 0x28); + ASSERT_STRUCT_OFFSET(PathData, nodeCount, 0x0); + ASSERT_STRUCT_OFFSET(PathData, nodes, 0x4); + ASSERT_STRUCT_OFFSET(PathData, basenodes, 0x8); + ASSERT_STRUCT_OFFSET(PathData, chainNodeCount, 0xC); + ASSERT_STRUCT_OFFSET(PathData, chainNodeForNode, 0x10); + ASSERT_STRUCT_OFFSET(PathData, nodeForChainNode, 0x14); + ASSERT_STRUCT_OFFSET(PathData, visBytes, 0x18); + ASSERT_STRUCT_OFFSET(PathData, pathVis, 0x1C); + ASSERT_STRUCT_OFFSET(PathData, nodeTreeCount, 0x20); + ASSERT_STRUCT_OFFSET(PathData, nodeTree, 0x24); + + struct GameWorldSp + { + const char* name; //OFS: 0x0 SIZE: 0x4 + PathData path; //OFS: 0x4 SIZE: 0x28 + }; + ASSERT_STRUCT_SIZE(GameWorldSp, 0x2C); + ASSERT_STRUCT_OFFSET(GameWorldSp, name, 0x0); + ASSERT_STRUCT_OFFSET(GameWorldSp, path, 0x4); + + struct GameWorldMp + { + char* name; //OFS: 0x0 SIZE: 0x4 + PathData path; //OFS: 0x4 SIZE: 0x28 + }; + ASSERT_STRUCT_SIZE(GameWorldMp, 0x2C); + ASSERT_STRUCT_OFFSET(GameWorldMp, name, 0x0); + ASSERT_STRUCT_OFFSET(GameWorldMp, path, 0x4); + + struct GfxWorldVertex + { + float xyz[3]; //OFS: 0x0 SIZE: 0xC + float binormalSign; //OFS: 0xC SIZE: 0x4 + GfxColor color; //OFS: 0x10 SIZE: 0x4 + float texCoord[2]; //OFS: 0x14 SIZE: 0x8 + float lmapCoord[2]; //OFS: 0x1C SIZE: 0x8 + PackedUnitVec normal; //OFS: 0x24 SIZE: 0x4 + PackedUnitVec tangent; //OFS: 0x28 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldVertex, 0x2C); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, xyz, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, binormalSign, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, color, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, texCoord, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, lmapCoord, 0x1C); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, normal, 0x24); + ASSERT_STRUCT_OFFSET(GfxWorldVertex, tangent, 0x28); + + struct GfxVertexBuffer + { + void* data; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxVertexBuffer, 0x4); + ASSERT_STRUCT_OFFSET(GfxVertexBuffer, data, 0x0); + + struct GfxWorldVertexData + { + GfxWorldVertex* vertices; //OFS: 0x0 SIZE: 0x4 + GfxVertexBuffer worldVb; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldVertexData, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldVertexData, vertices, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldVertexData, worldVb, 0x4); + + struct GfxWorldVertexLayerData + { + unsigned __int8* data; //OFS: 0x0 SIZE: 0x4 + GfxVertexBuffer layerVb; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldVertexLayerData, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldVertexLayerData, data, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldVertexLayerData, layerVb, 0x4); + + struct SunLightParseParams + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + float ambientScale; //OFS: 0x40 SIZE: 0x4 + float ambientColor[3]; //OFS: 0x44 SIZE: 0xC + float diffuseFraction; //OFS: 0x50 SIZE: 0x4 + float sunLight; //OFS: 0x54 SIZE: 0x4 + float sunColor[3]; //OFS: 0x58 SIZE: 0xC + float diffuseColor[3]; //OFS: 0x64 SIZE: 0xC + bool diffuseColorHasBeenSet; //OFS: 0x70 SIZE: 0x1 + float angles[3]; //OFS: 0x74 SIZE: 0xC + float treeScatterIntensity; //OFS: 0x80 SIZE: 0x4 + float treeScatterAmount; //OFS: 0x84 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(SunLightParseParams, 0x88); + ASSERT_STRUCT_OFFSET(SunLightParseParams, name, 0x0); + ASSERT_STRUCT_OFFSET(SunLightParseParams, ambientScale, 0x40); + ASSERT_STRUCT_OFFSET(SunLightParseParams, ambientColor, 0x44); + ASSERT_STRUCT_OFFSET(SunLightParseParams, diffuseFraction, 0x50); + ASSERT_STRUCT_OFFSET(SunLightParseParams, sunLight, 0x54); + ASSERT_STRUCT_OFFSET(SunLightParseParams, sunColor, 0x58); + ASSERT_STRUCT_OFFSET(SunLightParseParams, diffuseColor, 0x64); + ASSERT_STRUCT_OFFSET(SunLightParseParams, diffuseColorHasBeenSet, 0x70); + ASSERT_STRUCT_OFFSET(SunLightParseParams, angles, 0x74); + ASSERT_STRUCT_OFFSET(SunLightParseParams, treeScatterIntensity, 0x80); + ASSERT_STRUCT_OFFSET(SunLightParseParams, treeScatterAmount, 0x84); + + struct GfxLightImage + { + GfxImage* image; //OFS: 0x0 SIZE: 0x4 + unsigned __int8 samplerState; //OFS: 0x4 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(GfxLightImage, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightImage, image, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightImage, samplerState, 0x4); + + struct GfxLightDef + { + char* name; //OFS: 0x0 SIZE: 0x4 + GfxLightImage attenuation; //OFS: 0x4 SIZE: 0x8 + int lmapLookupStart; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightDef, 0x10); + ASSERT_STRUCT_OFFSET(GfxLightDef, name, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightDef, attenuation, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightDef, lmapLookupStart, 0xC); + + struct GfxLight + { + unsigned __int8 type; //OFS: 0x0 SIZE: 0x1 + unsigned __int8 canUseShadowMap; //OFS: 0x1 SIZE: 0x1 + __int16 cullDist; //OFS: 0x2 SIZE: 0x2 + float color[3]; //OFS: 0x4 SIZE: 0xC + float dir[3]; //OFS: 0x10 SIZE: 0xC + float origin[3]; //OFS: 0x1C SIZE: 0xC + float radius; //OFS: 0x28 SIZE: 0x4 + float cosHalfFovOuter; //OFS: 0x2C SIZE: 0x4 + float cosHalfFovInner; //OFS: 0x30 SIZE: 0x4 + int exponent; //OFS: 0x34 SIZE: 0x4 + unsigned int spotShadowIndex; //OFS: 0x38 SIZE: 0x4 + GfxLightDef* def; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLight, 0x40); + ASSERT_STRUCT_OFFSET(GfxLight, type, 0x0); + ASSERT_STRUCT_OFFSET(GfxLight, canUseShadowMap, 0x1); + ASSERT_STRUCT_OFFSET(GfxLight, cullDist, 0x2); + ASSERT_STRUCT_OFFSET(GfxLight, color, 0x4); + ASSERT_STRUCT_OFFSET(GfxLight, dir, 0x10); + ASSERT_STRUCT_OFFSET(GfxLight, origin, 0x1C); + ASSERT_STRUCT_OFFSET(GfxLight, radius, 0x28); + ASSERT_STRUCT_OFFSET(GfxLight, cosHalfFovOuter, 0x2C); + ASSERT_STRUCT_OFFSET(GfxLight, cosHalfFovInner, 0x30); + ASSERT_STRUCT_OFFSET(GfxLight, exponent, 0x34); + ASSERT_STRUCT_OFFSET(GfxLight, spotShadowIndex, 0x38); + ASSERT_STRUCT_OFFSET(GfxLight, def, 0x3C); + + struct GfxReflectionProbe + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + GfxImage* reflectionImage; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxReflectionProbe, 0x10); + ASSERT_STRUCT_OFFSET(GfxReflectionProbe, origin, 0x0); + ASSERT_STRUCT_OFFSET(GfxReflectionProbe, reflectionImage, 0xC); + + struct GfxLightCorona + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float radius; //OFS: 0xC SIZE: 0x4 + float color[3]; //OFS: 0x10 SIZE: 0xC + float intensity; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightCorona, 0x20); + ASSERT_STRUCT_OFFSET(GfxLightCorona, origin, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightCorona, radius, 0xC); + ASSERT_STRUCT_OFFSET(GfxLightCorona, color, 0x10); + ASSERT_STRUCT_OFFSET(GfxLightCorona, intensity, 0x1C); + + struct GfxWorldDpvsPlanes + { + int cellCount; //OFS: 0x0 SIZE: 0x4 + cplane_s* planes; //OFS: 0x4 SIZE: 0x4 + unsigned __int16* nodes; //OFS: 0x8 SIZE: 0x4 + unsigned int* sceneEntCellBits; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldDpvsPlanes, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsPlanes, cellCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsPlanes, planes, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsPlanes, nodes, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsPlanes, sceneEntCellBits, 0xC); + + struct GfxAabbTree + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + unsigned __int16 childCount; //OFS: 0x18 SIZE: 0x2 + unsigned __int16 surfaceCount; //OFS: 0x1A SIZE: 0x2 + unsigned __int16 startSurfIndex; //OFS: 0x1C SIZE: 0x2 + unsigned __int16 smodelIndexCount; //OFS: 0x1E SIZE: 0x2 + unsigned __int16* smodelIndexes; //OFS: 0x20 SIZE: 0x4 + int childrenOffset; //OFS: 0x24 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxAabbTree, 0x28); + ASSERT_STRUCT_OFFSET(GfxAabbTree, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxAabbTree, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxAabbTree, childCount, 0x18); + ASSERT_STRUCT_OFFSET(GfxAabbTree, surfaceCount, 0x1A); + ASSERT_STRUCT_OFFSET(GfxAabbTree, startSurfIndex, 0x1C); + ASSERT_STRUCT_OFFSET(GfxAabbTree, smodelIndexCount, 0x1E); + ASSERT_STRUCT_OFFSET(GfxAabbTree, smodelIndexes, 0x20); + ASSERT_STRUCT_OFFSET(GfxAabbTree, childrenOffset, 0x24); + + struct GfxPortalWritable + { + bool isQueued; //OFS: 0x0 SIZE: 0x1 + bool isAncestor; //OFS: 0x1 SIZE: 0x1 + unsigned __int8 recursionDepth; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 hullPointCount; //OFS: 0x3 SIZE: 0x1 + float (*hullPoints)[2]; //OFS: 0x4 SIZE: 0x4 + GfxPortal* queuedParent; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxPortalWritable, 0xC); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, isQueued, 0x0); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, isAncestor, 0x1); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, recursionDepth, 0x2); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, hullPointCount, 0x3); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, hullPoints, 0x4); + ASSERT_STRUCT_OFFSET(GfxPortalWritable, queuedParent, 0x8); + + struct DpvsPlane + { + float coeffs[4]; //OFS: 0x0 SIZE: 0x10 + unsigned __int8 side[3]; //OFS: 0x10 SIZE: 0x3 + unsigned __int8 pad; //OFS: 0x13 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(DpvsPlane, 0x14); + ASSERT_STRUCT_OFFSET(DpvsPlane, coeffs, 0x0); + ASSERT_STRUCT_OFFSET(DpvsPlane, side, 0x10); + ASSERT_STRUCT_OFFSET(DpvsPlane, pad, 0x13); + + struct GfxPortal + { + GfxPortalWritable writable; //OFS: 0x0 SIZE: 0xC + DpvsPlane plane; //OFS: 0xC SIZE: 0x14 + GfxCell* cell; //OFS: 0x20 SIZE: 0x4 + float (*vertices)[3]; //OFS: 0x24 SIZE: 0x4 + unsigned __int8 vertexCount; //OFS: 0x28 SIZE: 0x1 + float hullAxis[2][3]; //OFS: 0x2C SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(GfxPortal, 0x44); + ASSERT_STRUCT_OFFSET(GfxPortal, writable, 0x0); + ASSERT_STRUCT_OFFSET(GfxPortal, plane, 0xC); + ASSERT_STRUCT_OFFSET(GfxPortal, cell, 0x20); + ASSERT_STRUCT_OFFSET(GfxPortal, vertices, 0x24); + ASSERT_STRUCT_OFFSET(GfxPortal, vertexCount, 0x28); + ASSERT_STRUCT_OFFSET(GfxPortal, hullAxis, 0x2C); + + struct GfxCell + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + int aabbTreeCount; //OFS: 0x18 SIZE: 0x4 + GfxAabbTree* aabbTree; //OFS: 0x1C SIZE: 0x4 + int portalCount; //OFS: 0x20 SIZE: 0x4 + GfxPortal* portals; //OFS: 0x24 SIZE: 0x4 + int cullGroupCount; //OFS: 0x28 SIZE: 0x4 + int* cullGroups; //OFS: 0x2C SIZE: 0x4 + unsigned __int8 reflectionProbeCount; //OFS: 0x30 SIZE: 0x1 + unsigned __int8* reflectionProbes; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCell, 0x38); + ASSERT_STRUCT_OFFSET(GfxCell, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxCell, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxCell, aabbTreeCount, 0x18); + ASSERT_STRUCT_OFFSET(GfxCell, aabbTree, 0x1C); + ASSERT_STRUCT_OFFSET(GfxCell, portalCount, 0x20); + ASSERT_STRUCT_OFFSET(GfxCell, portals, 0x24); + ASSERT_STRUCT_OFFSET(GfxCell, cullGroupCount, 0x28); + ASSERT_STRUCT_OFFSET(GfxCell, cullGroups, 0x2C); + ASSERT_STRUCT_OFFSET(GfxCell, reflectionProbeCount, 0x30); + ASSERT_STRUCT_OFFSET(GfxCell, reflectionProbes, 0x34); + + struct __declspec(align(2)) GfxLightGridEntry + { + unsigned __int16 colorsIndex; //OFS: 0x0 SIZE: 0x2 + unsigned __int8 primaryLightIndex; //OFS: 0x2 SIZE: 0x1 + unsigned __int8 needsTrace; //OFS: 0x3 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(GfxLightGridEntry, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightGridEntry, colorsIndex, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGridEntry, primaryLightIndex, 0x2); + ASSERT_STRUCT_OFFSET(GfxLightGridEntry, needsTrace, 0x3); + + struct __declspec(align(1)) GfxLightGridColors + { + unsigned __int8 rgb[56][3]; //OFS: 0x0 SIZE: 0xA8 + }; + ASSERT_STRUCT_SIZE(GfxLightGridColors, 0xA8); + ASSERT_STRUCT_OFFSET(GfxLightGridColors, rgb, 0x0); + + struct GfxLightGrid + { + bool hasLightRegions; //OFS: 0x0 SIZE: 0x1 + unsigned int sunPrimaryLightIndex; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 mins[3]; //OFS: 0x8 SIZE: 0x6 + unsigned __int16 maxs[3]; //OFS: 0xE SIZE: 0x6 + unsigned int rowAxis; //OFS: 0x14 SIZE: 0x4 + unsigned int colAxis; //OFS: 0x18 SIZE: 0x4 + unsigned __int16* rowDataStart; //OFS: 0x1C SIZE: 0x4 + unsigned int rawRowDataSize; //OFS: 0x20 SIZE: 0x4 + unsigned __int8* rawRowData; //OFS: 0x24 SIZE: 0x4 + unsigned int entryCount; //OFS: 0x28 SIZE: 0x4 + GfxLightGridEntry* entries; //OFS: 0x2C SIZE: 0x4 + unsigned int colorCount; //OFS: 0x30 SIZE: 0x4 + GfxLightGridColors* colors; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightGrid, 0x38); + ASSERT_STRUCT_OFFSET(GfxLightGrid, hasLightRegions, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightGrid, sunPrimaryLightIndex, 0x4); + ASSERT_STRUCT_OFFSET(GfxLightGrid, mins, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightGrid, maxs, 0xE); + ASSERT_STRUCT_OFFSET(GfxLightGrid, rowAxis, 0x14); + ASSERT_STRUCT_OFFSET(GfxLightGrid, colAxis, 0x18); + ASSERT_STRUCT_OFFSET(GfxLightGrid, rowDataStart, 0x1C); + ASSERT_STRUCT_OFFSET(GfxLightGrid, rawRowDataSize, 0x20); + ASSERT_STRUCT_OFFSET(GfxLightGrid, rawRowData, 0x24); + ASSERT_STRUCT_OFFSET(GfxLightGrid, entryCount, 0x28); + ASSERT_STRUCT_OFFSET(GfxLightGrid, entries, 0x2C); + ASSERT_STRUCT_OFFSET(GfxLightGrid, colorCount, 0x30); + ASSERT_STRUCT_OFFSET(GfxLightGrid, colors, 0x34); + + struct _GXTlutObj + { + unsigned int dummy[3]; //OFS: 0x0 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(_GXTlutObj, 0xC); + ASSERT_STRUCT_OFFSET(_GXTlutObj, dummy, 0x0); + + struct nglPalette + { + _GXTlutObj TlutObj; //OFS: 0x0 SIZE: 0xC + unsigned int PaletteFormat; //OFS: 0xC SIZE: 0x4 + unsigned int PaletteSize; //OFS: 0x10 SIZE: 0x4 + unsigned __int8* PaletteData; //OFS: 0x14 SIZE: 0x4 + bool InPlace; //OFS: 0x18 SIZE: 0x1 + bool Dirty; //OFS: 0x19 SIZE: 0x1 + }; + ASSERT_STRUCT_SIZE(nglPalette, 0x1C); + ASSERT_STRUCT_OFFSET(nglPalette, TlutObj, 0x0); + ASSERT_STRUCT_OFFSET(nglPalette, PaletteFormat, 0xC); + ASSERT_STRUCT_OFFSET(nglPalette, PaletteSize, 0x10); + ASSERT_STRUCT_OFFSET(nglPalette, PaletteData, 0x14); + ASSERT_STRUCT_OFFSET(nglPalette, InPlace, 0x18); + ASSERT_STRUCT_OFFSET(nglPalette, Dirty, 0x19); + + struct _GXTexObj + { + unsigned int dummy[8]; //OFS: 0x0 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(_GXTexObj, 0x20); + ASSERT_STRUCT_OFFSET(_GXTexObj, dummy, 0x0); + + struct gpuTexture + { + unsigned __int16 Width; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 Height; //OFS: 0x2 SIZE: 0x2 + unsigned __int8 TexelFormat; //OFS: 0x4 SIZE: 0x1 + unsigned __int8 Levels; //OFS: 0x5 SIZE: 0x1 + unsigned __int16 Dummy; //OFS: 0x6 SIZE: 0x2 + void* Data; //OFS: 0x8 SIZE: 0x4 + nglPalette* Palette; //OFS: 0xC SIZE: 0x4 + _GXTexObj texObj; //OFS: 0x10 SIZE: 0x20 + }; + ASSERT_STRUCT_SIZE(gpuTexture, 0x30); + ASSERT_STRUCT_OFFSET(gpuTexture, Width, 0x0); + ASSERT_STRUCT_OFFSET(gpuTexture, Height, 0x2); + ASSERT_STRUCT_OFFSET(gpuTexture, TexelFormat, 0x4); + ASSERT_STRUCT_OFFSET(gpuTexture, Levels, 0x5); + ASSERT_STRUCT_OFFSET(gpuTexture, Dummy, 0x6); + ASSERT_STRUCT_OFFSET(gpuTexture, Data, 0x8); + ASSERT_STRUCT_OFFSET(gpuTexture, Palette, 0xC); + ASSERT_STRUCT_OFFSET(gpuTexture, texObj, 0x10); + + struct GfxBrushModelWritable + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(GfxBrushModelWritable, 0x18); + ASSERT_STRUCT_OFFSET(GfxBrushModelWritable, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxBrushModelWritable, maxs, 0xC); + + struct GfxBrushModel + { + GfxBrushModelWritable writable; //OFS: 0x0 SIZE: 0x18 + float bounds[2][3]; //OFS: 0x18 SIZE: 0x18 + unsigned int surfaceCount; //OFS: 0x30 SIZE: 0x4 + unsigned int startSurfIndex; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxBrushModel, 0x38); + ASSERT_STRUCT_OFFSET(GfxBrushModel, writable, 0x0); + ASSERT_STRUCT_OFFSET(GfxBrushModel, bounds, 0x18); + ASSERT_STRUCT_OFFSET(GfxBrushModel, surfaceCount, 0x30); + ASSERT_STRUCT_OFFSET(GfxBrushModel, startSurfIndex, 0x34); + + struct MaterialMemory + { + Material* material; //OFS: 0x0 SIZE: 0x4 + int memory; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MaterialMemory, 0x8); + ASSERT_STRUCT_OFFSET(MaterialMemory, material, 0x0); + ASSERT_STRUCT_OFFSET(MaterialMemory, memory, 0x4); + + struct sunflare_t + { + bool hasValidData; //OFS: 0x0 SIZE: 0x1 + Material* spriteMaterial; //OFS: 0x4 SIZE: 0x4 + Material* flareMaterial; //OFS: 0x8 SIZE: 0x4 + float spriteSize; //OFS: 0xC SIZE: 0x4 + float flareMinSize; //OFS: 0x10 SIZE: 0x4 + float flareMinDot; //OFS: 0x14 SIZE: 0x4 + float flareMaxSize; //OFS: 0x18 SIZE: 0x4 + float flareMaxDot; //OFS: 0x1C SIZE: 0x4 + float flareMaxAlpha; //OFS: 0x20 SIZE: 0x4 + int flareFadeInTime; //OFS: 0x24 SIZE: 0x4 + int flareFadeOutTime; //OFS: 0x28 SIZE: 0x4 + float blindMinDot; //OFS: 0x2C SIZE: 0x4 + float blindMaxDot; //OFS: 0x30 SIZE: 0x4 + float blindMaxDarken; //OFS: 0x34 SIZE: 0x4 + int blindFadeInTime; //OFS: 0x38 SIZE: 0x4 + int blindFadeOutTime; //OFS: 0x3C SIZE: 0x4 + float glareMinDot; //OFS: 0x40 SIZE: 0x4 + float glareMaxDot; //OFS: 0x44 SIZE: 0x4 + float glareMaxLighten; //OFS: 0x48 SIZE: 0x4 + int glareFadeInTime; //OFS: 0x4C SIZE: 0x4 + int glareFadeOutTime; //OFS: 0x50 SIZE: 0x4 + float sunFxPosition[3]; //OFS: 0x54 SIZE: 0xC + }; + ASSERT_STRUCT_SIZE(sunflare_t, 0x60); + ASSERT_STRUCT_OFFSET(sunflare_t, hasValidData, 0x0); + ASSERT_STRUCT_OFFSET(sunflare_t, spriteMaterial, 0x4); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMaterial, 0x8); + ASSERT_STRUCT_OFFSET(sunflare_t, spriteSize, 0xC); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMinSize, 0x10); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMinDot, 0x14); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMaxSize, 0x18); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMaxDot, 0x1C); + ASSERT_STRUCT_OFFSET(sunflare_t, flareMaxAlpha, 0x20); + ASSERT_STRUCT_OFFSET(sunflare_t, flareFadeInTime, 0x24); + ASSERT_STRUCT_OFFSET(sunflare_t, flareFadeOutTime, 0x28); + ASSERT_STRUCT_OFFSET(sunflare_t, blindMinDot, 0x2C); + ASSERT_STRUCT_OFFSET(sunflare_t, blindMaxDot, 0x30); + ASSERT_STRUCT_OFFSET(sunflare_t, blindMaxDarken, 0x34); + ASSERT_STRUCT_OFFSET(sunflare_t, blindFadeInTime, 0x38); + ASSERT_STRUCT_OFFSET(sunflare_t, blindFadeOutTime, 0x3C); + ASSERT_STRUCT_OFFSET(sunflare_t, glareMinDot, 0x40); + ASSERT_STRUCT_OFFSET(sunflare_t, glareMaxDot, 0x44); + ASSERT_STRUCT_OFFSET(sunflare_t, glareMaxLighten, 0x48); + ASSERT_STRUCT_OFFSET(sunflare_t, glareFadeInTime, 0x4C); + ASSERT_STRUCT_OFFSET(sunflare_t, glareFadeOutTime, 0x50); + ASSERT_STRUCT_OFFSET(sunflare_t, sunFxPosition, 0x54); + + struct __declspec(align(2)) XModelDrawInfo + { + unsigned __int16 lod; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 surfId; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XModelDrawInfo, 0x4); + ASSERT_STRUCT_OFFSET(XModelDrawInfo, lod, 0x0); + ASSERT_STRUCT_OFFSET(XModelDrawInfo, surfId, 0x2); + + struct __declspec(align(2)) GfxSceneDynModel + { + XModelDrawInfo info; //OFS: 0x0 SIZE: 0x4 + unsigned __int16 dynEntId; //OFS: 0x4 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxSceneDynModel, 0x6); + ASSERT_STRUCT_OFFSET(GfxSceneDynModel, info, 0x0); + ASSERT_STRUCT_OFFSET(GfxSceneDynModel, dynEntId, 0x4); + + struct __declspec(align(2)) BModelDrawInfo + { + unsigned __int16 surfId; //OFS: 0x0 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(BModelDrawInfo, 0x2); + ASSERT_STRUCT_OFFSET(BModelDrawInfo, surfId, 0x0); + + struct __declspec(align(2)) GfxSceneDynBrush + { + BModelDrawInfo info; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 dynEntId; //OFS: 0x2 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxSceneDynBrush, 0x4); + ASSERT_STRUCT_OFFSET(GfxSceneDynBrush, info, 0x0); + ASSERT_STRUCT_OFFSET(GfxSceneDynBrush, dynEntId, 0x2); + + struct GfxShadowGeometry + { + unsigned __int16 surfaceCount; //OFS: 0x0 SIZE: 0x2 + unsigned __int16 smodelCount; //OFS: 0x2 SIZE: 0x2 + unsigned __int16* sortedSurfIndex; //OFS: 0x4 SIZE: 0x4 + unsigned __int16* smodelIndex; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxShadowGeometry, 0xC); + ASSERT_STRUCT_OFFSET(GfxShadowGeometry, surfaceCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxShadowGeometry, smodelCount, 0x2); + ASSERT_STRUCT_OFFSET(GfxShadowGeometry, sortedSurfIndex, 0x4); + ASSERT_STRUCT_OFFSET(GfxShadowGeometry, smodelIndex, 0x8); + + struct GfxLightRegionAxis + { + float dir[3]; //OFS: 0x0 SIZE: 0xC + float midPoint; //OFS: 0xC SIZE: 0x4 + float halfSize; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightRegionAxis, 0x14); + ASSERT_STRUCT_OFFSET(GfxLightRegionAxis, dir, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightRegionAxis, midPoint, 0xC); + ASSERT_STRUCT_OFFSET(GfxLightRegionAxis, halfSize, 0x10); + + struct GfxLightRegionHull + { + float kdopMidPoint[9]; //OFS: 0x0 SIZE: 0x24 + float kdopHalfSize[9]; //OFS: 0x24 SIZE: 0x24 + unsigned int axisCount; //OFS: 0x48 SIZE: 0x4 + GfxLightRegionAxis* axis; //OFS: 0x4C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightRegionHull, 0x50); + ASSERT_STRUCT_OFFSET(GfxLightRegionHull, kdopMidPoint, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightRegionHull, kdopHalfSize, 0x24); + ASSERT_STRUCT_OFFSET(GfxLightRegionHull, axisCount, 0x48); + ASSERT_STRUCT_OFFSET(GfxLightRegionHull, axis, 0x4C); + + struct GfxLightRegion + { + unsigned int hullCount; //OFS: 0x0 SIZE: 0x4 + GfxLightRegionHull* hulls; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxLightRegion, 0x8); + ASSERT_STRUCT_OFFSET(GfxLightRegion, hullCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxLightRegion, hulls, 0x4); + + struct GfxStaticModelInst + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + GfxColor groundLighting; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxStaticModelInst, 0x1C); + ASSERT_STRUCT_OFFSET(GfxStaticModelInst, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxStaticModelInst, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxStaticModelInst, groundLighting, 0x18); + + struct srfTriangles_t + { + int vertexLayerData; //OFS: 0x0 SIZE: 0x4 + int firstVertex; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 vertexCount; //OFS: 0x8 SIZE: 0x2 + unsigned __int16 triCount; //OFS: 0xA SIZE: 0x2 + int baseIndex; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(srfTriangles_t, 0x10); + ASSERT_STRUCT_OFFSET(srfTriangles_t, vertexLayerData, 0x0); + ASSERT_STRUCT_OFFSET(srfTriangles_t, firstVertex, 0x4); + ASSERT_STRUCT_OFFSET(srfTriangles_t, vertexCount, 0x8); + ASSERT_STRUCT_OFFSET(srfTriangles_t, triCount, 0xA); + ASSERT_STRUCT_OFFSET(srfTriangles_t, baseIndex, 0xC); + + struct GfxSurface + { + srfTriangles_t tris; //OFS: 0x0 SIZE: 0x10 + int pad; //OFS: 0x10 SIZE: 0x4 + Material* material; //OFS: 0x14 SIZE: 0x4 + char lightmapIndex; //OFS: 0x18 SIZE: 0x1 + char reflectionProbeIndex; //OFS: 0x19 SIZE: 0x1 + char primaryLightIndex; //OFS: 0x1A SIZE: 0x1 + char flags; //OFS: 0x1B SIZE: 0x1 + float bounds[2][3]; //OFS: 0x1C SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(GfxSurface, 0x34); + ASSERT_STRUCT_OFFSET(GfxSurface, tris, 0x0); + ASSERT_STRUCT_OFFSET(GfxSurface, pad, 0x10); + ASSERT_STRUCT_OFFSET(GfxSurface, material, 0x14); + ASSERT_STRUCT_OFFSET(GfxSurface, lightmapIndex, 0x18); + ASSERT_STRUCT_OFFSET(GfxSurface, reflectionProbeIndex, 0x19); + ASSERT_STRUCT_OFFSET(GfxSurface, primaryLightIndex, 0x1A); + ASSERT_STRUCT_OFFSET(GfxSurface, flags, 0x1B); + ASSERT_STRUCT_OFFSET(GfxSurface, bounds, 0x1C); + + struct GfxCullGroup + { + float mins[3]; //OFS: 0x0 SIZE: 0xC + float maxs[3]; //OFS: 0xC SIZE: 0xC + int surfaceCount; //OFS: 0x18 SIZE: 0x4 + int startSurfIndex; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxCullGroup, 0x20); + ASSERT_STRUCT_OFFSET(GfxCullGroup, mins, 0x0); + ASSERT_STRUCT_OFFSET(GfxCullGroup, maxs, 0xC); + ASSERT_STRUCT_OFFSET(GfxCullGroup, surfaceCount, 0x18); + ASSERT_STRUCT_OFFSET(GfxCullGroup, startSurfIndex, 0x1C); + + struct GfxPackedPlacement + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float axis[3][3]; //OFS: 0xC SIZE: 0x24 + float scale; //OFS: 0x30 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxPackedPlacement, 0x34); + ASSERT_STRUCT_OFFSET(GfxPackedPlacement, origin, 0x0); + ASSERT_STRUCT_OFFSET(GfxPackedPlacement, axis, 0xC); + ASSERT_STRUCT_OFFSET(GfxPackedPlacement, scale, 0x30); + + struct ModelLodFade + { + unsigned int value; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ModelLodFade, 0x4); + ASSERT_STRUCT_OFFSET(ModelLodFade, value, 0x0); + + struct GfxStaticModelDrawInst + { + float cullDist; //OFS: 0x0 SIZE: 0x4 + GfxPackedPlacement placement; //OFS: 0x4 SIZE: 0x34 + XModel* model; //OFS: 0x38 SIZE: 0x4 + ModelLodFade lodFade_idk; //OFS: 0x3C SIZE: 0x4 + int cachedLightSettingIndex_idk; //OFS: 0x40 SIZE: 0x4 + char field_44; //OFS: 0x44 SIZE: 0x1 + char field_45; //OFS: 0x45 SIZE: 0x1 + unsigned __int8 reflectionProbeIndex; //OFS: 0x46 SIZE: 0x1 + unsigned __int8 primaryLightIndex; //OFS: 0x47 SIZE: 0x1 + int flags; //OFS: 0x48 SIZE: 0x4 + unsigned int sModelCacheIndex_idk[4]; //OFS: 0x4C SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(GfxStaticModelDrawInst, 0x5C); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, cullDist, 0x0); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, placement, 0x4); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, model, 0x38); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, lodFade_idk, 0x3C); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, cachedLightSettingIndex_idk, 0x40); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, field_44, 0x44); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, field_45, 0x45); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, reflectionProbeIndex, 0x46); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, primaryLightIndex, 0x47); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, flags, 0x48); + ASSERT_STRUCT_OFFSET(GfxStaticModelDrawInst, sModelCacheIndex_idk, 0x4C); + + struct GfxWorldDpvsStatic + { + unsigned int smodelCount; //OFS: 0x0 SIZE: 0x4 + unsigned int staticSurfaceCount; //OFS: 0x4 SIZE: 0x4 + unsigned int litSurfsBegin; //OFS: 0x8 SIZE: 0x4 + unsigned int litSurfsEnd; //OFS: 0xC SIZE: 0x4 + unsigned int decalSurfsBegin; //OFS: 0x10 SIZE: 0x4 + unsigned int decalSurfsEnd; //OFS: 0x14 SIZE: 0x4 + unsigned int emissiveSurfsBegin; //OFS: 0x18 SIZE: 0x4 + unsigned int emissiveSurfsEnd; //OFS: 0x1C SIZE: 0x4 + unsigned int smodelVisDataCount; //OFS: 0x20 SIZE: 0x4 + unsigned int surfaceVisDataCount; //OFS: 0x24 SIZE: 0x4 + unsigned __int8* smodelVisData[3]; //OFS: 0x28 SIZE: 0xC + unsigned __int8* surfaceVisData[3]; //OFS: 0x34 SIZE: 0xC + unsigned int* lodData; //OFS: 0x40 SIZE: 0x4 + unsigned __int16* sortedSurfIndex; //OFS: 0x44 SIZE: 0x4 + GfxStaticModelInst* smodelInsts; //OFS: 0x48 SIZE: 0x4 + GfxSurface* surfaces; //OFS: 0x4C SIZE: 0x4 + GfxCullGroup* cullGroups; //OFS: 0x50 SIZE: 0x4 + GfxStaticModelDrawInst* smodelDrawInsts; //OFS: 0x54 SIZE: 0x4 + GfxDrawSurf* surfaceMaterials; //OFS: 0x58 SIZE: 0x4 + unsigned int* surfaceCastsSunShadow; //OFS: 0x5C SIZE: 0x4 + int usageCount; //OFS: 0x60 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorldDpvsStatic, 0x64); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, smodelCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, staticSurfaceCount, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, litSurfsBegin, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, litSurfsEnd, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, decalSurfsBegin, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, decalSurfsEnd, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, emissiveSurfsBegin, 0x18); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, emissiveSurfsEnd, 0x1C); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, smodelVisDataCount, 0x20); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, surfaceVisDataCount, 0x24); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, smodelVisData, 0x28); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, surfaceVisData, 0x34); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, lodData, 0x40); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, sortedSurfIndex, 0x44); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, smodelInsts, 0x48); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, surfaces, 0x4C); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, cullGroups, 0x50); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, smodelDrawInsts, 0x54); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, surfaceMaterials, 0x58); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, surfaceCastsSunShadow, 0x5C); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsStatic, usageCount, 0x60); + + struct GfxWorldDpvsDynamic + { + unsigned int dynEntClientWordCount[2]; //OFS: 0x0 SIZE: 0x8 + unsigned int dynEntClientCount[2]; //OFS: 0x8 SIZE: 0x8 + unsigned int* dynEntCellBits[2]; //OFS: 0x10 SIZE: 0x8 + unsigned __int8* dynEntVisData[2][3]; //OFS: 0x18 SIZE: 0x18 + }; + ASSERT_STRUCT_SIZE(GfxWorldDpvsDynamic, 0x30); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsDynamic, dynEntClientWordCount, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsDynamic, dynEntClientCount, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsDynamic, dynEntCellBits, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldDpvsDynamic, dynEntVisData, 0x18); + + struct GfxWorldLodChain + { + float origin[3]; //OFS: 0x0 SIZE: 0xC + float lastDist; //OFS: 0xC SIZE: 0x4 + unsigned int firstLodInfo; //OFS: 0x10 SIZE: 0x4 + unsigned __int16 lodInfoCount; //OFS: 0x14 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxWorldLodChain, 0x18); + ASSERT_STRUCT_OFFSET(GfxWorldLodChain, origin, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldLodChain, lastDist, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldLodChain, firstLodInfo, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorldLodChain, lodInfoCount, 0x14); + + struct GfxWorldLodInfo + { + float dist; //OFS: 0x0 SIZE: 0x4 + unsigned int firstSurf; //OFS: 0x4 SIZE: 0x4 + unsigned __int16 surfCount; //OFS: 0x8 SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(GfxWorldLodInfo, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorldLodInfo, dist, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorldLodInfo, firstSurf, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorldLodInfo, surfCount, 0x8); + + struct GfxWaterBuffer + { + unsigned int bufferSize; //OFS: 0x0 SIZE: 0x4 + float (*buffer)[4]; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWaterBuffer, 0x8); + ASSERT_STRUCT_OFFSET(GfxWaterBuffer, bufferSize, 0x0); + ASSERT_STRUCT_OFFSET(GfxWaterBuffer, buffer, 0x4); + + struct GfxWorld + { + const char* name; //OFS: 0x0 SIZE: 0x4 + const char* baseName; //OFS: 0x4 SIZE: 0x4 + int planeCount; //OFS: 0x8 SIZE: 0x4 + int nodeCount; //OFS: 0xC SIZE: 0x4 + int indexCount; //OFS: 0x10 SIZE: 0x4 + unsigned __int16* indices; //OFS: 0x14 SIZE: 0x4 + int surfaceCount; //OFS: 0x18 SIZE: 0x4 + int streamInfo; //OFS: 0x1C SIZE: 0x4 + int skySurfCount; //OFS: 0x20 SIZE: 0x4 + int* skyStartSurfs; //OFS: 0x24 SIZE: 0x4 + GfxImage* skyImage; //OFS: 0x28 SIZE: 0x4 + unsigned __int8 skySamplerState; //OFS: 0x2C SIZE: 0x1 + char* skyBoxModel; //OFS: 0x30 SIZE: 0x4 + unsigned int vertexCount; //OFS: 0x34 SIZE: 0x4 + GfxWorldVertexData vd; //OFS: 0x38 SIZE: 0x8 + unsigned int vertexLayerDataSize; //OFS: 0x40 SIZE: 0x4 + GfxWorldVertexLayerData vld; //OFS: 0x44 SIZE: 0x8 + unsigned int vertexStream2DataSize; //OFS: 0x4C SIZE: 0x4 + SunLightParseParams sunParse; //OFS: 0x50 SIZE: 0x88 + GfxLight* sunLight; //OFS: 0xD8 SIZE: 0x4 + float sunColorFromBsp[3]; //OFS: 0xDC SIZE: 0xC + unsigned int sunPrimaryLightIndex; //OFS: 0xE8 SIZE: 0x4 + unsigned int primaryLightCount; //OFS: 0xEC SIZE: 0x4 + int cullGroupCount; //OFS: 0xF0 SIZE: 0x4 + unsigned int reflectionProbeCount; //OFS: 0xF4 SIZE: 0x4 + GfxReflectionProbe* reflectionProbes; //OFS: 0xF8 SIZE: 0x4 + GfxTexture* reflectionProbeTextures; //OFS: 0xFC SIZE: 0x4 + unsigned int coronaCount; //OFS: 0x100 SIZE: 0x4 + GfxLightCorona* coronas; //OFS: 0x104 SIZE: 0x4 + GfxWorldDpvsPlanes dpvsPlanes; //OFS: 0x108 SIZE: 0x10 + int cellBitsCount; //OFS: 0x118 SIZE: 0x4 + GfxCell* cells; //OFS: 0x11C SIZE: 0x4 + int lightmapCount; //OFS: 0x120 SIZE: 0x4 + GfxImage** lightmaps; //OFS: 0x124 SIZE: 0x4 + GfxLightGrid lightGrid; //OFS: 0x128 SIZE: 0x38 + gpuTexture* lightmapPrimaryTextures; //OFS: 0x160 SIZE: 0x4 + gpuTexture* lightmapSecondaryTextures; //OFS: 0x164 SIZE: 0x4 + int modelCount; //OFS: 0x168 SIZE: 0x4 + GfxBrushModel* models; //OFS: 0x16C SIZE: 0x4 + float mins[3]; //OFS: 0x170 SIZE: 0xC + float maxs[3]; //OFS: 0x17C SIZE: 0xC + unsigned int checksum; //OFS: 0x188 SIZE: 0x4 + int materialMemoryCount; //OFS: 0x18C SIZE: 0x4 + MaterialMemory* materialMemory; //OFS: 0x190 SIZE: 0x4 + sunflare_t sun; //OFS: 0x194 SIZE: 0x60 + float outdoorLookupMatrix[4][4]; //OFS: 0x1F4 SIZE: 0x40 + GfxImage* outdoorImage; //OFS: 0x234 SIZE: 0x4 + unsigned int* cellCasterBits; //OFS: 0x238 SIZE: 0x4 + GfxSceneDynModel* sceneDynModel; //OFS: 0x23C SIZE: 0x4 + GfxSceneDynBrush* sceneDynBrush; //OFS: 0x240 SIZE: 0x4 + unsigned int* primaryLightEntityShadowVis; //OFS: 0x244 SIZE: 0x4 + unsigned int* primaryLightDynEntShadowVis[2]; //OFS: 0x248 SIZE: 0x8 + char* nonSunPrimaryLightForModelDynEnt; //OFS: 0x250 SIZE: 0x4 + GfxShadowGeometry* shadowGeom; //OFS: 0x254 SIZE: 0x4 + GfxLightRegion* lightRegion; //OFS: 0x258 SIZE: 0x4 + GfxWorldDpvsStatic dpvs; //OFS: 0x25C SIZE: 0x64 + GfxWorldDpvsDynamic dpvsDyn; //OFS: 0x2C0 SIZE: 0x30 + unsigned int worldLodChainCount; //OFS: 0x2F0 SIZE: 0x4 + GfxWorldLodChain* worldLodChains; //OFS: 0x2F4 SIZE: 0x4 + unsigned int worldLodInfoCount; //OFS: 0x2F8 SIZE: 0x4 + GfxWorldLodInfo* worldLodInfos; //OFS: 0x2FC SIZE: 0x4 + unsigned int worldLodSurfaceCount; //OFS: 0x300 SIZE: 0x4 + unsigned int* worldLodSurfaces; //OFS: 0x304 SIZE: 0x4 + float waterDirection; //OFS: 0x308 SIZE: 0x4 + GfxWaterBuffer waterBuffers[2]; //OFS: 0x30C SIZE: 0x10 + Material* waterMaterial; //OFS: 0x31C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(GfxWorld, 0x320); + ASSERT_STRUCT_OFFSET(GfxWorld, name, 0x0); + ASSERT_STRUCT_OFFSET(GfxWorld, baseName, 0x4); + ASSERT_STRUCT_OFFSET(GfxWorld, planeCount, 0x8); + ASSERT_STRUCT_OFFSET(GfxWorld, nodeCount, 0xC); + ASSERT_STRUCT_OFFSET(GfxWorld, indexCount, 0x10); + ASSERT_STRUCT_OFFSET(GfxWorld, indices, 0x14); + ASSERT_STRUCT_OFFSET(GfxWorld, surfaceCount, 0x18); + ASSERT_STRUCT_OFFSET(GfxWorld, streamInfo, 0x1C); + ASSERT_STRUCT_OFFSET(GfxWorld, skySurfCount, 0x20); + ASSERT_STRUCT_OFFSET(GfxWorld, skyStartSurfs, 0x24); + ASSERT_STRUCT_OFFSET(GfxWorld, skyImage, 0x28); + ASSERT_STRUCT_OFFSET(GfxWorld, skySamplerState, 0x2C); + ASSERT_STRUCT_OFFSET(GfxWorld, skyBoxModel, 0x30); + ASSERT_STRUCT_OFFSET(GfxWorld, vertexCount, 0x34); + ASSERT_STRUCT_OFFSET(GfxWorld, vd, 0x38); + ASSERT_STRUCT_OFFSET(GfxWorld, vertexLayerDataSize, 0x40); + ASSERT_STRUCT_OFFSET(GfxWorld, vld, 0x44); + ASSERT_STRUCT_OFFSET(GfxWorld, vertexStream2DataSize, 0x4C); + ASSERT_STRUCT_OFFSET(GfxWorld, sunParse, 0x50); + ASSERT_STRUCT_OFFSET(GfxWorld, sunLight, 0xD8); + ASSERT_STRUCT_OFFSET(GfxWorld, sunColorFromBsp, 0xDC); + ASSERT_STRUCT_OFFSET(GfxWorld, sunPrimaryLightIndex, 0xE8); + ASSERT_STRUCT_OFFSET(GfxWorld, primaryLightCount, 0xEC); + ASSERT_STRUCT_OFFSET(GfxWorld, cullGroupCount, 0xF0); + ASSERT_STRUCT_OFFSET(GfxWorld, reflectionProbeCount, 0xF4); + ASSERT_STRUCT_OFFSET(GfxWorld, reflectionProbes, 0xF8); + ASSERT_STRUCT_OFFSET(GfxWorld, reflectionProbeTextures, 0xFC); + ASSERT_STRUCT_OFFSET(GfxWorld, coronaCount, 0x100); + ASSERT_STRUCT_OFFSET(GfxWorld, coronas, 0x104); + ASSERT_STRUCT_OFFSET(GfxWorld, dpvsPlanes, 0x108); + ASSERT_STRUCT_OFFSET(GfxWorld, cellBitsCount, 0x118); + ASSERT_STRUCT_OFFSET(GfxWorld, cells, 0x11C); + ASSERT_STRUCT_OFFSET(GfxWorld, lightmapCount, 0x120); + ASSERT_STRUCT_OFFSET(GfxWorld, lightmaps, 0x124); + ASSERT_STRUCT_OFFSET(GfxWorld, lightGrid, 0x128); + ASSERT_STRUCT_OFFSET(GfxWorld, lightmapPrimaryTextures, 0x160); + ASSERT_STRUCT_OFFSET(GfxWorld, lightmapSecondaryTextures, 0x164); + ASSERT_STRUCT_OFFSET(GfxWorld, modelCount, 0x168); + ASSERT_STRUCT_OFFSET(GfxWorld, models, 0x16C); + ASSERT_STRUCT_OFFSET(GfxWorld, mins, 0x170); + ASSERT_STRUCT_OFFSET(GfxWorld, maxs, 0x17C); + ASSERT_STRUCT_OFFSET(GfxWorld, checksum, 0x188); + ASSERT_STRUCT_OFFSET(GfxWorld, materialMemoryCount, 0x18C); + ASSERT_STRUCT_OFFSET(GfxWorld, materialMemory, 0x190); + ASSERT_STRUCT_OFFSET(GfxWorld, sun, 0x194); + ASSERT_STRUCT_OFFSET(GfxWorld, outdoorLookupMatrix, 0x1F4); + ASSERT_STRUCT_OFFSET(GfxWorld, outdoorImage, 0x234); + ASSERT_STRUCT_OFFSET(GfxWorld, cellCasterBits, 0x238); + ASSERT_STRUCT_OFFSET(GfxWorld, sceneDynModel, 0x23C); + ASSERT_STRUCT_OFFSET(GfxWorld, sceneDynBrush, 0x240); + ASSERT_STRUCT_OFFSET(GfxWorld, primaryLightEntityShadowVis, 0x244); + ASSERT_STRUCT_OFFSET(GfxWorld, primaryLightDynEntShadowVis, 0x248); + ASSERT_STRUCT_OFFSET(GfxWorld, nonSunPrimaryLightForModelDynEnt, 0x250); + ASSERT_STRUCT_OFFSET(GfxWorld, shadowGeom, 0x254); + ASSERT_STRUCT_OFFSET(GfxWorld, lightRegion, 0x258); + ASSERT_STRUCT_OFFSET(GfxWorld, dpvs, 0x25C); + ASSERT_STRUCT_OFFSET(GfxWorld, dpvsDyn, 0x2C0); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodChainCount, 0x2F0); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodChains, 0x2F4); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodInfoCount, 0x2F8); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodInfos, 0x2FC); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodSurfaceCount, 0x300); + ASSERT_STRUCT_OFFSET(GfxWorld, worldLodSurfaces, 0x304); + ASSERT_STRUCT_OFFSET(GfxWorld, waterDirection, 0x308); + ASSERT_STRUCT_OFFSET(GfxWorld, waterBuffers, 0x30C); + ASSERT_STRUCT_OFFSET(GfxWorld, waterMaterial, 0x31C); + + struct Glyph + { + unsigned __int16 letter; //OFS: 0x0 SIZE: 0x2 + char x0; //OFS: 0x2 SIZE: 0x1 + char y0; //OFS: 0x3 SIZE: 0x1 + unsigned __int8 _dx; //OFS: 0x4 SIZE: 0x1 + unsigned __int8 pixelWidth; //OFS: 0x5 SIZE: 0x1 + unsigned __int8 pixelHeight; //OFS: 0x6 SIZE: 0x1 + float s0; //OFS: 0x8 SIZE: 0x4 + float t0; //OFS: 0xC SIZE: 0x4 + float s1; //OFS: 0x10 SIZE: 0x4 + float t1; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Glyph, 0x18); + ASSERT_STRUCT_OFFSET(Glyph, letter, 0x0); + ASSERT_STRUCT_OFFSET(Glyph, x0, 0x2); + ASSERT_STRUCT_OFFSET(Glyph, y0, 0x3); + ASSERT_STRUCT_OFFSET(Glyph, _dx, 0x4); + ASSERT_STRUCT_OFFSET(Glyph, pixelWidth, 0x5); + ASSERT_STRUCT_OFFSET(Glyph, pixelHeight, 0x6); + ASSERT_STRUCT_OFFSET(Glyph, s0, 0x8); + ASSERT_STRUCT_OFFSET(Glyph, t0, 0xC); + ASSERT_STRUCT_OFFSET(Glyph, s1, 0x10); + ASSERT_STRUCT_OFFSET(Glyph, t1, 0x14); + + struct Font_s + { + char* fontName; //OFS: 0x0 SIZE: 0x4 + int pixelHeight; //OFS: 0x4 SIZE: 0x4 + int glyphCount; //OFS: 0x8 SIZE: 0x4 + Material* material; //OFS: 0xC SIZE: 0x4 + Material* glowMaterial; //OFS: 0x10 SIZE: 0x4 + Glyph* glyphs; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Font_s, 0x18); + ASSERT_STRUCT_OFFSET(Font_s, fontName, 0x0); + ASSERT_STRUCT_OFFSET(Font_s, pixelHeight, 0x4); + ASSERT_STRUCT_OFFSET(Font_s, glyphCount, 0x8); + ASSERT_STRUCT_OFFSET(Font_s, material, 0xC); + ASSERT_STRUCT_OFFSET(Font_s, glowMaterial, 0x10); + ASSERT_STRUCT_OFFSET(Font_s, glyphs, 0x14); + + struct rectDef_s + { + float x; //OFS: 0x0 SIZE: 0x4 + float y; //OFS: 0x4 SIZE: 0x4 + float w; //OFS: 0x8 SIZE: 0x4 + float h; //OFS: 0xC SIZE: 0x4 + int horzAlign; //OFS: 0x10 SIZE: 0x4 + int vertAlign; //OFS: 0x14 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(rectDef_s, 0x18); + ASSERT_STRUCT_OFFSET(rectDef_s, x, 0x0); + ASSERT_STRUCT_OFFSET(rectDef_s, y, 0x4); + ASSERT_STRUCT_OFFSET(rectDef_s, w, 0x8); + ASSERT_STRUCT_OFFSET(rectDef_s, h, 0xC); + ASSERT_STRUCT_OFFSET(rectDef_s, horzAlign, 0x10); + ASSERT_STRUCT_OFFSET(rectDef_s, vertAlign, 0x14); + + struct windowDef_t + { + const char* name; //OFS: 0x0 SIZE: 0x4 + rectDef_s rect; //OFS: 0x4 SIZE: 0x18 + rectDef_s rectClient; //OFS: 0x1C SIZE: 0x18 + const char* group; //OFS: 0x34 SIZE: 0x4 + int style; //OFS: 0x38 SIZE: 0x4 + int border; //OFS: 0x3C SIZE: 0x4 + int ownerDraw; //OFS: 0x40 SIZE: 0x4 + int ownerDrawFlags; //OFS: 0x44 SIZE: 0x4 + float borderSize; //OFS: 0x48 SIZE: 0x4 + int staticFlags; //OFS: 0x4C SIZE: 0x4 + int dynamicFlags[1]; //OFS: 0x50 SIZE: 0x4 + int nextTime; //OFS: 0x54 SIZE: 0x4 + float foreColor[4]; //OFS: 0x58 SIZE: 0x10 + float backColor[4]; //OFS: 0x68 SIZE: 0x10 + float borderColor[4]; //OFS: 0x78 SIZE: 0x10 + float outlineColor[4]; //OFS: 0x88 SIZE: 0x10 + Material* background; //OFS: 0x98 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(windowDef_t, 0x9C); + ASSERT_STRUCT_OFFSET(windowDef_t, name, 0x0); + ASSERT_STRUCT_OFFSET(windowDef_t, rect, 0x4); + ASSERT_STRUCT_OFFSET(windowDef_t, rectClient, 0x1C); + ASSERT_STRUCT_OFFSET(windowDef_t, group, 0x34); + ASSERT_STRUCT_OFFSET(windowDef_t, style, 0x38); + ASSERT_STRUCT_OFFSET(windowDef_t, border, 0x3C); + ASSERT_STRUCT_OFFSET(windowDef_t, ownerDraw, 0x40); + ASSERT_STRUCT_OFFSET(windowDef_t, ownerDrawFlags, 0x44); + ASSERT_STRUCT_OFFSET(windowDef_t, borderSize, 0x48); + ASSERT_STRUCT_OFFSET(windowDef_t, staticFlags, 0x4C); + ASSERT_STRUCT_OFFSET(windowDef_t, dynamicFlags, 0x50); + ASSERT_STRUCT_OFFSET(windowDef_t, nextTime, 0x54); + ASSERT_STRUCT_OFFSET(windowDef_t, foreColor, 0x58); + ASSERT_STRUCT_OFFSET(windowDef_t, backColor, 0x68); + ASSERT_STRUCT_OFFSET(windowDef_t, borderColor, 0x78); + ASSERT_STRUCT_OFFSET(windowDef_t, outlineColor, 0x88); + ASSERT_STRUCT_OFFSET(windowDef_t, background, 0x98); + + struct ItemKeyHandler + { + int key; //OFS: 0x0 SIZE: 0x4 + const char* action; //OFS: 0x4 SIZE: 0x4 + ItemKeyHandler* next; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ItemKeyHandler, 0xC); + ASSERT_STRUCT_OFFSET(ItemKeyHandler, key, 0x0); + ASSERT_STRUCT_OFFSET(ItemKeyHandler, action, 0x4); + ASSERT_STRUCT_OFFSET(ItemKeyHandler, next, 0x8); + + union operandInternalDataUnion + { + int intVal; //OFS: 0x0 SIZE: 0x4 + float floatVal; //OFS: 0x1 SIZE: 0x4 + const char* string; //OFS: 0x2 SIZE: 0x4 + }; + + struct Operand + { + expDataType dataType; //OFS: 0x0 SIZE: 0x4 + operandInternalDataUnion internals; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(Operand, 0x8); + ASSERT_STRUCT_OFFSET(Operand, dataType, 0x0); + ASSERT_STRUCT_OFFSET(Operand, internals, 0x4); + + union entryInternalData + { + expOperationEnum op; //OFS: 0x0 SIZE: 0x4 + Operand operand; //OFS: 0x1 SIZE: 0x8 + }; + + struct expressionEntry + { + int type; //OFS: 0x0 SIZE: 0x4 + entryInternalData data; //OFS: 0x4 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(expressionEntry, 0xC); + ASSERT_STRUCT_OFFSET(expressionEntry, type, 0x0); + ASSERT_STRUCT_OFFSET(expressionEntry, data, 0x4); + + struct statement_s + { + int numEntries; //OFS: 0x0 SIZE: 0x4 + expressionEntry** entries; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(statement_s, 0x8); + ASSERT_STRUCT_OFFSET(statement_s, numEntries, 0x0); + ASSERT_STRUCT_OFFSET(statement_s, entries, 0x4); + + struct columnInfo_s + { + int pos; //OFS: 0x0 SIZE: 0x4 + int width; //OFS: 0x4 SIZE: 0x4 + int maxChars; //OFS: 0x8 SIZE: 0x4 + int alignment; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(columnInfo_s, 0x10); + ASSERT_STRUCT_OFFSET(columnInfo_s, pos, 0x0); + ASSERT_STRUCT_OFFSET(columnInfo_s, width, 0x4); + ASSERT_STRUCT_OFFSET(columnInfo_s, maxChars, 0x8); + ASSERT_STRUCT_OFFSET(columnInfo_s, alignment, 0xC); + + struct listBoxDef_s + { + int mousePos; //OFS: 0x0 SIZE: 0x4 + int startPos[1]; //OFS: 0x4 SIZE: 0x4 + int endPos[1]; //OFS: 0x8 SIZE: 0x4 + int drawPadding; //OFS: 0xC SIZE: 0x4 + float elementWidth; //OFS: 0x10 SIZE: 0x4 + float elementHeight; //OFS: 0x14 SIZE: 0x4 + int elementStyle; //OFS: 0x18 SIZE: 0x4 + int numColumns; //OFS: 0x1C SIZE: 0x4 + columnInfo_s columnInfo[16]; //OFS: 0x20 SIZE: 0x100 + const char* doubleClick; //OFS: 0x120 SIZE: 0x4 + int notselectable; //OFS: 0x124 SIZE: 0x4 + int noScrollBars; //OFS: 0x128 SIZE: 0x4 + int usePaging; //OFS: 0x12C SIZE: 0x4 + float selectBorder[4]; //OFS: 0x130 SIZE: 0x10 + float disableColor[4]; //OFS: 0x140 SIZE: 0x10 + float focusColor[4]; //OFS: 0x150 SIZE: 0x10 + Material* selectIcon; //OFS: 0x160 SIZE: 0x4 + Material* backgroundItemListbox; //OFS: 0x164 SIZE: 0x4 + Material* highlightTexture; //OFS: 0x168 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(listBoxDef_s, 0x16C); + ASSERT_STRUCT_OFFSET(listBoxDef_s, mousePos, 0x0); + ASSERT_STRUCT_OFFSET(listBoxDef_s, startPos, 0x4); + ASSERT_STRUCT_OFFSET(listBoxDef_s, endPos, 0x8); + ASSERT_STRUCT_OFFSET(listBoxDef_s, drawPadding, 0xC); + ASSERT_STRUCT_OFFSET(listBoxDef_s, elementWidth, 0x10); + ASSERT_STRUCT_OFFSET(listBoxDef_s, elementHeight, 0x14); + ASSERT_STRUCT_OFFSET(listBoxDef_s, elementStyle, 0x18); + ASSERT_STRUCT_OFFSET(listBoxDef_s, numColumns, 0x1C); + ASSERT_STRUCT_OFFSET(listBoxDef_s, columnInfo, 0x20); + ASSERT_STRUCT_OFFSET(listBoxDef_s, doubleClick, 0x120); + ASSERT_STRUCT_OFFSET(listBoxDef_s, notselectable, 0x124); + ASSERT_STRUCT_OFFSET(listBoxDef_s, noScrollBars, 0x128); + ASSERT_STRUCT_OFFSET(listBoxDef_s, usePaging, 0x12C); + ASSERT_STRUCT_OFFSET(listBoxDef_s, selectBorder, 0x130); + ASSERT_STRUCT_OFFSET(listBoxDef_s, disableColor, 0x140); + ASSERT_STRUCT_OFFSET(listBoxDef_s, focusColor, 0x150); + ASSERT_STRUCT_OFFSET(listBoxDef_s, selectIcon, 0x160); + ASSERT_STRUCT_OFFSET(listBoxDef_s, backgroundItemListbox, 0x164); + ASSERT_STRUCT_OFFSET(listBoxDef_s, highlightTexture, 0x168); + + struct editFieldDef_s + { + float minVal; //OFS: 0x0 SIZE: 0x4 + float maxVal; //OFS: 0x4 SIZE: 0x4 + float defVal; //OFS: 0x8 SIZE: 0x4 + float range; //OFS: 0xC SIZE: 0x4 + int maxChars; //OFS: 0x10 SIZE: 0x4 + int maxCharsGotoNext; //OFS: 0x14 SIZE: 0x4 + int maxPaintChars; //OFS: 0x18 SIZE: 0x4 + int paintOffset; //OFS: 0x1C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(editFieldDef_s, 0x20); + ASSERT_STRUCT_OFFSET(editFieldDef_s, minVal, 0x0); + ASSERT_STRUCT_OFFSET(editFieldDef_s, maxVal, 0x4); + ASSERT_STRUCT_OFFSET(editFieldDef_s, defVal, 0x8); + ASSERT_STRUCT_OFFSET(editFieldDef_s, range, 0xC); + ASSERT_STRUCT_OFFSET(editFieldDef_s, maxChars, 0x10); + ASSERT_STRUCT_OFFSET(editFieldDef_s, maxCharsGotoNext, 0x14); + ASSERT_STRUCT_OFFSET(editFieldDef_s, maxPaintChars, 0x18); + ASSERT_STRUCT_OFFSET(editFieldDef_s, paintOffset, 0x1C); + + struct multiDef_s + { + const char* dvarList[32]; //OFS: 0x0 SIZE: 0x80 + const char* dvarStr[32]; //OFS: 0x80 SIZE: 0x80 + float dvarValue[32]; //OFS: 0x100 SIZE: 0x80 + int count; //OFS: 0x180 SIZE: 0x4 + int strDef; //OFS: 0x184 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(multiDef_s, 0x188); + ASSERT_STRUCT_OFFSET(multiDef_s, dvarList, 0x0); + ASSERT_STRUCT_OFFSET(multiDef_s, dvarStr, 0x80); + ASSERT_STRUCT_OFFSET(multiDef_s, dvarValue, 0x100); + ASSERT_STRUCT_OFFSET(multiDef_s, count, 0x180); + ASSERT_STRUCT_OFFSET(multiDef_s, strDef, 0x184); + + union itemDefData_t + { + listBoxDef_s* listBox; //OFS: 0x0 SIZE: 0x4 + editFieldDef_s* editField; //OFS: 0x1 SIZE: 0x4 + multiDef_s* multi; //OFS: 0x2 SIZE: 0x4 + const char* enumDvarName; //OFS: 0x3 SIZE: 0x4 + void* data; //OFS: 0x4 SIZE: 0x4 + }; + + struct itemDef_s + { + windowDef_t window; //OFS: 0x0 SIZE: 0x9C + rectDef_s textRect[1]; //OFS: 0x9C SIZE: 0x18 + int type; //OFS: 0xB4 SIZE: 0x4 + int dataType; //OFS: 0xB8 SIZE: 0x4 + int alignment; //OFS: 0xBC SIZE: 0x4 + int fontEnum; //OFS: 0xC0 SIZE: 0x4 + int textAlignMode; //OFS: 0xC4 SIZE: 0x4 + float textalignx; //OFS: 0xC8 SIZE: 0x4 + float textaligny; //OFS: 0xCC SIZE: 0x4 + float textscale; //OFS: 0xD0 SIZE: 0x4 + int textStyle; //OFS: 0xD4 SIZE: 0x4 + int gameMsgWindowIndex; //OFS: 0xD8 SIZE: 0x4 + int gameMsgWindowMode; //OFS: 0xDC SIZE: 0x4 + const char* text; //OFS: 0xE0 SIZE: 0x4 + int itemFlags; //OFS: 0xE4 SIZE: 0x4 + menuDef_t* parent; //OFS: 0xE8 SIZE: 0x4 + const char* mouseEnterText; //OFS: 0xEC SIZE: 0x4 + const char* mouseExitText; //OFS: 0xF0 SIZE: 0x4 + const char* mouseEnter; //OFS: 0xF4 SIZE: 0x4 + const char* mouseExit; //OFS: 0xF8 SIZE: 0x4 + const char* action; //OFS: 0xFC SIZE: 0x4 + const char* onAccept; //OFS: 0x100 SIZE: 0x4 + const char* onFocus; //OFS: 0x104 SIZE: 0x4 + const char* leaveFocus; //OFS: 0x108 SIZE: 0x4 + const char* dvar; //OFS: 0x10C SIZE: 0x4 + const char* dvarTest; //OFS: 0x110 SIZE: 0x4 + const char* onListboxSelectionChange; //OFS: 0x114 SIZE: 0x4 + ItemKeyHandler* onKey; //OFS: 0x118 SIZE: 0x4 + const char* enableDvar; //OFS: 0x11C SIZE: 0x4 + int dvarFlags; //OFS: 0x120 SIZE: 0x4 + void* focusSound; //OFS: 0x124 SIZE: 0x4 + float special; //OFS: 0x128 SIZE: 0x4 + int cursorPos[1]; //OFS: 0x12C SIZE: 0x4 + itemDefData_t typeData; //OFS: 0x130 SIZE: 0x4 + int imageTrack; //OFS: 0x134 SIZE: 0x4 + statement_s visibleExp; //OFS: 0x138 SIZE: 0x8 + statement_s textExp; //OFS: 0x140 SIZE: 0x8 + statement_s materialExp; //OFS: 0x148 SIZE: 0x8 + statement_s rectXExp; //OFS: 0x150 SIZE: 0x8 + statement_s rectYExp; //OFS: 0x158 SIZE: 0x8 + statement_s rectWExp; //OFS: 0x160 SIZE: 0x8 + statement_s rectHExp; //OFS: 0x168 SIZE: 0x8 + statement_s forecolorAExp; //OFS: 0x170 SIZE: 0x8 + }; + ASSERT_STRUCT_SIZE(itemDef_s, 0x178); + ASSERT_STRUCT_OFFSET(itemDef_s, window, 0x0); + ASSERT_STRUCT_OFFSET(itemDef_s, textRect, 0x9C); + ASSERT_STRUCT_OFFSET(itemDef_s, type, 0xB4); + ASSERT_STRUCT_OFFSET(itemDef_s, dataType, 0xB8); + ASSERT_STRUCT_OFFSET(itemDef_s, alignment, 0xBC); + ASSERT_STRUCT_OFFSET(itemDef_s, fontEnum, 0xC0); + ASSERT_STRUCT_OFFSET(itemDef_s, textAlignMode, 0xC4); + ASSERT_STRUCT_OFFSET(itemDef_s, textalignx, 0xC8); + ASSERT_STRUCT_OFFSET(itemDef_s, textaligny, 0xCC); + ASSERT_STRUCT_OFFSET(itemDef_s, textscale, 0xD0); + ASSERT_STRUCT_OFFSET(itemDef_s, textStyle, 0xD4); + ASSERT_STRUCT_OFFSET(itemDef_s, gameMsgWindowIndex, 0xD8); + ASSERT_STRUCT_OFFSET(itemDef_s, gameMsgWindowMode, 0xDC); + ASSERT_STRUCT_OFFSET(itemDef_s, text, 0xE0); + ASSERT_STRUCT_OFFSET(itemDef_s, itemFlags, 0xE4); + ASSERT_STRUCT_OFFSET(itemDef_s, parent, 0xE8); + ASSERT_STRUCT_OFFSET(itemDef_s, mouseEnterText, 0xEC); + ASSERT_STRUCT_OFFSET(itemDef_s, mouseExitText, 0xF0); + ASSERT_STRUCT_OFFSET(itemDef_s, mouseEnter, 0xF4); + ASSERT_STRUCT_OFFSET(itemDef_s, mouseExit, 0xF8); + ASSERT_STRUCT_OFFSET(itemDef_s, action, 0xFC); + ASSERT_STRUCT_OFFSET(itemDef_s, onAccept, 0x100); + ASSERT_STRUCT_OFFSET(itemDef_s, onFocus, 0x104); + ASSERT_STRUCT_OFFSET(itemDef_s, leaveFocus, 0x108); + ASSERT_STRUCT_OFFSET(itemDef_s, dvar, 0x10C); + ASSERT_STRUCT_OFFSET(itemDef_s, dvarTest, 0x110); + ASSERT_STRUCT_OFFSET(itemDef_s, onListboxSelectionChange, 0x114); + ASSERT_STRUCT_OFFSET(itemDef_s, onKey, 0x118); + ASSERT_STRUCT_OFFSET(itemDef_s, enableDvar, 0x11C); + ASSERT_STRUCT_OFFSET(itemDef_s, dvarFlags, 0x120); + ASSERT_STRUCT_OFFSET(itemDef_s, focusSound, 0x124); + ASSERT_STRUCT_OFFSET(itemDef_s, special, 0x128); + ASSERT_STRUCT_OFFSET(itemDef_s, cursorPos, 0x12C); + ASSERT_STRUCT_OFFSET(itemDef_s, typeData, 0x130); + ASSERT_STRUCT_OFFSET(itemDef_s, imageTrack, 0x134); + ASSERT_STRUCT_OFFSET(itemDef_s, visibleExp, 0x138); + ASSERT_STRUCT_OFFSET(itemDef_s, textExp, 0x140); + ASSERT_STRUCT_OFFSET(itemDef_s, materialExp, 0x148); + ASSERT_STRUCT_OFFSET(itemDef_s, rectXExp, 0x150); + ASSERT_STRUCT_OFFSET(itemDef_s, rectYExp, 0x158); + ASSERT_STRUCT_OFFSET(itemDef_s, rectWExp, 0x160); + ASSERT_STRUCT_OFFSET(itemDef_s, rectHExp, 0x168); + ASSERT_STRUCT_OFFSET(itemDef_s, forecolorAExp, 0x170); + + struct menuDef_t + { + windowDef_t window; //OFS: 0x0 SIZE: 0x9C + const char* font; //OFS: 0x9C SIZE: 0x4 + int fullScreen; //OFS: 0xA0 SIZE: 0x4 + int itemCount; //OFS: 0xA4 SIZE: 0x4 + int fontIndex; //OFS: 0xA8 SIZE: 0x4 + int cursorItem[1]; //OFS: 0xAC SIZE: 0x4 + int fadeCycle; //OFS: 0xB0 SIZE: 0x4 + float fadeClamp; //OFS: 0xB4 SIZE: 0x4 + float fadeAmount; //OFS: 0xB8 SIZE: 0x4 + float fadeInAmount; //OFS: 0xBC SIZE: 0x4 + float blurRadius; //OFS: 0xC0 SIZE: 0x4 + const char* onOpen; //OFS: 0xC4 SIZE: 0x4 + const char* onFocus; //OFS: 0xC8 SIZE: 0x4 + const char* onClose; //OFS: 0xCC SIZE: 0x4 + const char* onESC; //OFS: 0xD0 SIZE: 0x4 + ItemKeyHandler* onKey; //OFS: 0xD4 SIZE: 0x4 + statement_s visibleExp; //OFS: 0xD8 SIZE: 0x8 + const char* allowedBinding; //OFS: 0xE0 SIZE: 0x4 + const char* soundName; //OFS: 0xE4 SIZE: 0x4 + int imageTrack; //OFS: 0xE8 SIZE: 0x4 + float focusColor[4]; //OFS: 0xEC SIZE: 0x10 + float disableColor[4]; //OFS: 0xFC SIZE: 0x10 + statement_s rectXExp; //OFS: 0x10C SIZE: 0x8 + statement_s rectYExp; //OFS: 0x114 SIZE: 0x8 + itemDef_s** items; //OFS: 0x11C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(menuDef_t, 0x120); + ASSERT_STRUCT_OFFSET(menuDef_t, window, 0x0); + ASSERT_STRUCT_OFFSET(menuDef_t, font, 0x9C); + ASSERT_STRUCT_OFFSET(menuDef_t, fullScreen, 0xA0); + ASSERT_STRUCT_OFFSET(menuDef_t, itemCount, 0xA4); + ASSERT_STRUCT_OFFSET(menuDef_t, fontIndex, 0xA8); + ASSERT_STRUCT_OFFSET(menuDef_t, cursorItem, 0xAC); + ASSERT_STRUCT_OFFSET(menuDef_t, fadeCycle, 0xB0); + ASSERT_STRUCT_OFFSET(menuDef_t, fadeClamp, 0xB4); + ASSERT_STRUCT_OFFSET(menuDef_t, fadeAmount, 0xB8); + ASSERT_STRUCT_OFFSET(menuDef_t, fadeInAmount, 0xBC); + ASSERT_STRUCT_OFFSET(menuDef_t, blurRadius, 0xC0); + ASSERT_STRUCT_OFFSET(menuDef_t, onOpen, 0xC4); + ASSERT_STRUCT_OFFSET(menuDef_t, onFocus, 0xC8); + ASSERT_STRUCT_OFFSET(menuDef_t, onClose, 0xCC); + ASSERT_STRUCT_OFFSET(menuDef_t, onESC, 0xD0); + ASSERT_STRUCT_OFFSET(menuDef_t, onKey, 0xD4); + ASSERT_STRUCT_OFFSET(menuDef_t, visibleExp, 0xD8); + ASSERT_STRUCT_OFFSET(menuDef_t, allowedBinding, 0xE0); + ASSERT_STRUCT_OFFSET(menuDef_t, soundName, 0xE4); + ASSERT_STRUCT_OFFSET(menuDef_t, imageTrack, 0xE8); + ASSERT_STRUCT_OFFSET(menuDef_t, focusColor, 0xEC); + ASSERT_STRUCT_OFFSET(menuDef_t, disableColor, 0xFC); + ASSERT_STRUCT_OFFSET(menuDef_t, rectXExp, 0x10C); + ASSERT_STRUCT_OFFSET(menuDef_t, rectYExp, 0x114); + ASSERT_STRUCT_OFFSET(menuDef_t, items, 0x11C); + + struct MenuList + { + const char* name; //OFS: 0x0 SIZE: 0x4 + int menuCount; //OFS: 0x4 SIZE: 0x4 + menuDef_t** menus; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(MenuList, 0xC); + ASSERT_STRUCT_OFFSET(MenuList, name, 0x0); + ASSERT_STRUCT_OFFSET(MenuList, menuCount, 0x4); + ASSERT_STRUCT_OFFSET(MenuList, menus, 0x8); + + struct LocalizeEntry + { + char* value; //OFS: 0x0 SIZE: 0x4 + char* name; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(LocalizeEntry, 0x8); + ASSERT_STRUCT_OFFSET(LocalizeEntry, value, 0x0); + ASSERT_STRUCT_OFFSET(LocalizeEntry, name, 0x4); + + struct flameTable + { + float flameVar_streamChunkGravityStart; //OFS: 0x0 SIZE: 0x4 + float flameVar_streamChunkGravityEnd; //OFS: 0x4 SIZE: 0x4 + float flameVar_streamChunkMaxSize; //OFS: 0x8 SIZE: 0x4 + float flameVar_streamChunkStartSize; //OFS: 0xC SIZE: 0x4 + float flameVar_streamChunkEndSize; //OFS: 0x10 SIZE: 0x4 + float flameVar_streamChunkStartSizeRand; //OFS: 0x14 SIZE: 0x4 + float flameVar_streamChunkEndSizeRand; //OFS: 0x18 SIZE: 0x4 + float flameVar_streamChunkDistScalar; //OFS: 0x1C SIZE: 0x4 + float flameVar_streamChunkDistSwayScale; //OFS: 0x20 SIZE: 0x4 + float flameVar_streamChunkDistSwayVelMax; //OFS: 0x24 SIZE: 0x4 + float flameVar_streamChunkSpeed; //OFS: 0x28 SIZE: 0x4 + float flameVar_streamChunkDecel; //OFS: 0x2C SIZE: 0x4 + float flameVar_streamChunkVelocityAddScale; //OFS: 0x30 SIZE: 0x4 + float flameVar_streamChunkDuration; //OFS: 0x34 SIZE: 0x4 + float flameVar_streamChunkDurationScaleMaxVel; //OFS: 0x38 SIZE: 0x4 + float flameVar_streamChunkDurationVelScalar; //OFS: 0x3C SIZE: 0x4 + float flameVar_streamChunkSizeSpeedScale; //OFS: 0x40 SIZE: 0x4 + float flameVar_streamChunkSizeAgeScale; //OFS: 0x44 SIZE: 0x4 + float flameVar_streamChunkSpawnFireIntervalStart; //OFS: 0x48 SIZE: 0x4 + float flameVar_streamChunkSpawnFireIntervalEnd; //OFS: 0x4C SIZE: 0x4 + float flameVar_streamChunkSpawnFireMinLifeFrac; //OFS: 0x50 SIZE: 0x4 + float flameVar_streamChunkSpawnFireMaxLifeFrac; //OFS: 0x54 SIZE: 0x4 + float flameVar_streamChunkFireMinLifeFrac; //OFS: 0x58 SIZE: 0x4 + float flameVar_streamChunkFireMinLifeFracStart; //OFS: 0x5C SIZE: 0x4 + float flameVar_streamChunkFireMinLifeFracEnd; //OFS: 0x60 SIZE: 0x4 + float flameVar_streamChunkDripsMinLifeFrac; //OFS: 0x64 SIZE: 0x4 + float flameVar_streamChunkDripsMinLifeFracStart; //OFS: 0x68 SIZE: 0x4 + float flameVar_streamChunkDripsMinLifeFracEnd; //OFS: 0x6C SIZE: 0x4 + float flameVar_streamChunkRotationRange; //OFS: 0x70 SIZE: 0x4 + float flameVar_streamSizeRandSinWave; //OFS: 0x74 SIZE: 0x4 + float flameVar_streamSizeRandCosWave; //OFS: 0x78 SIZE: 0x4 + float flameVar_streamDripsChunkInterval; //OFS: 0x7C SIZE: 0x4 + float flameVar_streamDripsChunkMinFrac; //OFS: 0x80 SIZE: 0x4 + float flameVar_streamDripsChunkRandFrac; //OFS: 0x84 SIZE: 0x4 + float flameVar_streamSmokeChunkInterval; //OFS: 0x88 SIZE: 0x4 + float flameVar_streamSmokeChunkMinFrac; //OFS: 0x8C SIZE: 0x4 + float flameVar_streamSmokeChunkRandFrac; //OFS: 0x90 SIZE: 0x4 + float flameVar_streamChunkCullDistSizeFrac; //OFS: 0x94 SIZE: 0x4 + float flameVar_streamChunkCullMinLife; //OFS: 0x98 SIZE: 0x4 + float flameVar_streamChunkCullMaxLife; //OFS: 0x9C SIZE: 0x4 + float flameVar_streamFuelSizeStart; //OFS: 0xA0 SIZE: 0x4 + float flameVar_streamFuelSizeEnd; //OFS: 0xA4 SIZE: 0x4 + float flameVar_streamFuelLength; //OFS: 0xA8 SIZE: 0x4 + float flameVar_streamFuelNumSegments; //OFS: 0xAC SIZE: 0x4 + float flameVar_streamFuelAnimLoopTime; //OFS: 0xB0 SIZE: 0x4 + float flameVar_streamFlameSizeStart; //OFS: 0xB4 SIZE: 0x4 + float flameVar_streamFlameSizeEnd; //OFS: 0xB8 SIZE: 0x4 + float flameVar_streamFlameLength; //OFS: 0xBC SIZE: 0x4 + float flameVar_streamFlameNumSegments; //OFS: 0xC0 SIZE: 0x4 + float flameVar_streamFlameAnimLoopTime; //OFS: 0xC4 SIZE: 0x4 + float flameVar_streamPrimaryLightRadius; //OFS: 0xC8 SIZE: 0x4 + float flameVar_streamPrimaryLightRadiusFlutter; //OFS: 0xCC SIZE: 0x4 + float flameVar_streamPrimaryLightR; //OFS: 0xD0 SIZE: 0x4 + float flameVar_streamPrimaryLightG; //OFS: 0xD4 SIZE: 0x4 + float flameVar_streamPrimaryLightB; //OFS: 0xD8 SIZE: 0x4 + float flameVar_streamPrimaryLightFlutterR; //OFS: 0xDC SIZE: 0x4 + float flameVar_streamPrimaryLightFlutterG; //OFS: 0xE0 SIZE: 0x4 + float flameVar_streamPrimaryLightFlutterB; //OFS: 0xE4 SIZE: 0x4 + float flameVar_fireLife; //OFS: 0xE8 SIZE: 0x4 + float flameVar_fireLifeRand; //OFS: 0xEC SIZE: 0x4 + float flameVar_fireSpeedScale; //OFS: 0xF0 SIZE: 0x4 + float flameVar_fireSpeedScaleRand; //OFS: 0xF4 SIZE: 0x4 + float flameVar_fireVelocityAddZ; //OFS: 0xF8 SIZE: 0x4 + float flameVar_fireVelocityAddZRand; //OFS: 0xFC SIZE: 0x4 + float flameVar_fireVelocityAddSideways; //OFS: 0x100 SIZE: 0x4 + float flameVar_fireGravity; //OFS: 0x104 SIZE: 0x4 + float flameVar_fireGravityEnd; //OFS: 0x108 SIZE: 0x4 + float flameVar_fireMaxRotVel; //OFS: 0x10C SIZE: 0x4 + float flameVar_fireFriction; //OFS: 0x110 SIZE: 0x4 + float flameVar_fireEndSizeAdd; //OFS: 0x114 SIZE: 0x4 + float flameVar_fireStartSizeScale; //OFS: 0x118 SIZE: 0x4 + float flameVar_fireEndSizeScale; //OFS: 0x11C SIZE: 0x4 + float flameVar_dripsLife; //OFS: 0x120 SIZE: 0x4 + float flameVar_dripsLifeRand; //OFS: 0x124 SIZE: 0x4 + float flameVar_dripsSpeedScale; //OFS: 0x128 SIZE: 0x4 + float flameVar_dripsSpeedScaleRand; //OFS: 0x12C SIZE: 0x4 + float flameVar_dripsVelocityAddZ; //OFS: 0x130 SIZE: 0x4 + float flameVar_dripsVelocityAddZRand; //OFS: 0x134 SIZE: 0x4 + float flameVar_dripsVelocityAddSideways; //OFS: 0x138 SIZE: 0x4 + float flameVar_dripsGravity; //OFS: 0x13C SIZE: 0x4 + float flameVar_dripsGravityEnd; //OFS: 0x140 SIZE: 0x4 + float flameVar_dripsMaxRotVel; //OFS: 0x144 SIZE: 0x4 + float flameVar_dripsFriction; //OFS: 0x148 SIZE: 0x4 + float flameVar_dripsEndSizeAdd; //OFS: 0x14C SIZE: 0x4 + float flameVar_dripsStartSizeScale; //OFS: 0x150 SIZE: 0x4 + float flameVar_dripsEndSizeScale; //OFS: 0x154 SIZE: 0x4 + float flameVar_smokeLife; //OFS: 0x158 SIZE: 0x4 + float flameVar_smokeLifeRand; //OFS: 0x15C SIZE: 0x4 + float flameVar_smokeSpeedScale; //OFS: 0x160 SIZE: 0x4 + float flameVar_smokeVelocityAddZ; //OFS: 0x164 SIZE: 0x4 + float flameVar_smokeGravity; //OFS: 0x168 SIZE: 0x4 + float flameVar_smokeGravityEnd; //OFS: 0x16C SIZE: 0x4 + float flameVar_smokeMaxRotation; //OFS: 0x170 SIZE: 0x4 + float flameVar_smokeMaxRotVel; //OFS: 0x174 SIZE: 0x4 + float flameVar_smokeFriction; //OFS: 0x178 SIZE: 0x4 + float flameVar_smokeEndSizeAdd; //OFS: 0x17C SIZE: 0x4 + float flameVar_smokeStartSizeAdd; //OFS: 0x180 SIZE: 0x4 + float flameVar_smokeOriginSizeOfsZScale; //OFS: 0x184 SIZE: 0x4 + float flameVar_smokeOriginOfsZ; //OFS: 0x188 SIZE: 0x4 + float flameVar_smokeFadein; //OFS: 0x18C SIZE: 0x4 + float flameVar_smokeFadeout; //OFS: 0x190 SIZE: 0x4 + float flameVar_smokeMaxAlpha; //OFS: 0x194 SIZE: 0x4 + float flameVar_smokeBrightness; //OFS: 0x198 SIZE: 0x4 + float flameVar_smokeOriginOffset; //OFS: 0x19C SIZE: 0x4 + float flameVar_collisionSpeedScale; //OFS: 0x1A0 SIZE: 0x4 + float flameVar_collisionVolumeScale; //OFS: 0x1A4 SIZE: 0x4 + const char* name; //OFS: 0x1A8 SIZE: 0x4 + Material* fire; //OFS: 0x1AC SIZE: 0x4 + Material* smoke; //OFS: 0x1B0 SIZE: 0x4 + Material* heat; //OFS: 0x1B4 SIZE: 0x4 + Material* drips; //OFS: 0x1B8 SIZE: 0x4 + Material* streamFuel; //OFS: 0x1BC SIZE: 0x4 + Material* streamFuel2; //OFS: 0x1C0 SIZE: 0x4 + Material* streamFlame; //OFS: 0x1C4 SIZE: 0x4 + Material* streamFlame2; //OFS: 0x1C8 SIZE: 0x4 + snd_alias_list_t* flameOffLoopSound; //OFS: 0x1CC SIZE: 0x4 + snd_alias_list_t* flameIgniteSound; //OFS: 0x1D0 SIZE: 0x4 + snd_alias_list_t* flameOnLoopSound; //OFS: 0x1D4 SIZE: 0x4 + snd_alias_list_t* flameCooldownSound; //OFS: 0x1D8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(flameTable, 0x1DC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkGravityStart, 0x0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkGravityEnd, 0x4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkMaxSize, 0x8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkStartSize, 0xC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkEndSize, 0x10); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkStartSizeRand, 0x14); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkEndSizeRand, 0x18); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDistScalar, 0x1C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDistSwayScale, 0x20); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDistSwayVelMax, 0x24); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSpeed, 0x28); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDecel, 0x2C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkVelocityAddScale, 0x30); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDuration, 0x34); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDurationScaleMaxVel, 0x38); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDurationVelScalar, 0x3C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSizeSpeedScale, 0x40); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSizeAgeScale, 0x44); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSpawnFireIntervalStart, 0x48); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSpawnFireIntervalEnd, 0x4C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSpawnFireMinLifeFrac, 0x50); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkSpawnFireMaxLifeFrac, 0x54); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkFireMinLifeFrac, 0x58); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkFireMinLifeFracStart, 0x5C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkFireMinLifeFracEnd, 0x60); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDripsMinLifeFrac, 0x64); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDripsMinLifeFracStart, 0x68); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkDripsMinLifeFracEnd, 0x6C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkRotationRange, 0x70); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamSizeRandSinWave, 0x74); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamSizeRandCosWave, 0x78); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamDripsChunkInterval, 0x7C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamDripsChunkMinFrac, 0x80); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamDripsChunkRandFrac, 0x84); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamSmokeChunkInterval, 0x88); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamSmokeChunkMinFrac, 0x8C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamSmokeChunkRandFrac, 0x90); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkCullDistSizeFrac, 0x94); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkCullMinLife, 0x98); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamChunkCullMaxLife, 0x9C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFuelSizeStart, 0xA0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFuelSizeEnd, 0xA4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFuelLength, 0xA8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFuelNumSegments, 0xAC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFuelAnimLoopTime, 0xB0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFlameSizeStart, 0xB4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFlameSizeEnd, 0xB8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFlameLength, 0xBC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFlameNumSegments, 0xC0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamFlameAnimLoopTime, 0xC4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightRadius, 0xC8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightRadiusFlutter, 0xCC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightR, 0xD0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightG, 0xD4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightB, 0xD8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightFlutterR, 0xDC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightFlutterG, 0xE0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_streamPrimaryLightFlutterB, 0xE4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireLife, 0xE8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireLifeRand, 0xEC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireSpeedScale, 0xF0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireSpeedScaleRand, 0xF4); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireVelocityAddZ, 0xF8); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireVelocityAddZRand, 0xFC); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireVelocityAddSideways, 0x100); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireGravity, 0x104); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireGravityEnd, 0x108); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireMaxRotVel, 0x10C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireFriction, 0x110); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireEndSizeAdd, 0x114); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireStartSizeScale, 0x118); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_fireEndSizeScale, 0x11C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsLife, 0x120); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsLifeRand, 0x124); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsSpeedScale, 0x128); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsSpeedScaleRand, 0x12C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsVelocityAddZ, 0x130); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsVelocityAddZRand, 0x134); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsVelocityAddSideways, 0x138); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsGravity, 0x13C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsGravityEnd, 0x140); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsMaxRotVel, 0x144); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsFriction, 0x148); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsEndSizeAdd, 0x14C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsStartSizeScale, 0x150); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_dripsEndSizeScale, 0x154); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeLife, 0x158); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeLifeRand, 0x15C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeSpeedScale, 0x160); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeVelocityAddZ, 0x164); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeGravity, 0x168); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeGravityEnd, 0x16C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeMaxRotation, 0x170); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeMaxRotVel, 0x174); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeFriction, 0x178); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeEndSizeAdd, 0x17C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeStartSizeAdd, 0x180); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeOriginSizeOfsZScale, 0x184); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeOriginOfsZ, 0x188); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeFadein, 0x18C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeFadeout, 0x190); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeMaxAlpha, 0x194); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeBrightness, 0x198); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_smokeOriginOffset, 0x19C); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_collisionSpeedScale, 0x1A0); + ASSERT_STRUCT_OFFSET(flameTable, flameVar_collisionVolumeScale, 0x1A4); + ASSERT_STRUCT_OFFSET(flameTable, name, 0x1A8); + ASSERT_STRUCT_OFFSET(flameTable, fire, 0x1AC); + ASSERT_STRUCT_OFFSET(flameTable, smoke, 0x1B0); + ASSERT_STRUCT_OFFSET(flameTable, heat, 0x1B4); + ASSERT_STRUCT_OFFSET(flameTable, drips, 0x1B8); + ASSERT_STRUCT_OFFSET(flameTable, streamFuel, 0x1BC); + ASSERT_STRUCT_OFFSET(flameTable, streamFuel2, 0x1C0); + ASSERT_STRUCT_OFFSET(flameTable, streamFlame, 0x1C4); + ASSERT_STRUCT_OFFSET(flameTable, streamFlame2, 0x1C8); + ASSERT_STRUCT_OFFSET(flameTable, flameOffLoopSound, 0x1CC); + ASSERT_STRUCT_OFFSET(flameTable, flameIgniteSound, 0x1D0); + ASSERT_STRUCT_OFFSET(flameTable, flameOnLoopSound, 0x1D4); + ASSERT_STRUCT_OFFSET(flameTable, flameCooldownSound, 0x1D8); + + struct WeaponDef + { + const char* szInternalName; //OFS: 0x0 SIZE: 0x4 + const char* szDisplayName; //OFS: 0x4 SIZE: 0x4 + const char* szOverlayName; //OFS: 0x8 SIZE: 0x4 + XModel* gunXModel[16]; //OFS: 0xC SIZE: 0x40 + XModel* handXModel; //OFS: 0x4C SIZE: 0x4 + const char* someAnim; //OFS: 0x50 SIZE: 0x4 + const char* sidleAnim; //OFS: 0x54 SIZE: 0x4 + const char* semptyIdleAnim; //OFS: 0x58 SIZE: 0x4 + const char* sfireAnim; //OFS: 0x5C SIZE: 0x4 + const char* sholdFireAnim; //OFS: 0x60 SIZE: 0x4 + const char* slastShotAnim; //OFS: 0x64 SIZE: 0x4 + const char* srechamberAnim; //OFS: 0x68 SIZE: 0x4 + const char* smeleeAnim; //OFS: 0x6C SIZE: 0x4 + const char* smeleeChargeAnim; //OFS: 0x70 SIZE: 0x4 + const char* sreloadAnim; //OFS: 0x74 SIZE: 0x4 + const char* sreloadEmptyAnim; //OFS: 0x78 SIZE: 0x4 + const char* sreloadStartAnim; //OFS: 0x7C SIZE: 0x4 + const char* sreloadEndAnim; //OFS: 0x80 SIZE: 0x4 + const char* sraiseAnim; //OFS: 0x84 SIZE: 0x4 + const char* sfirstRaiseAnim; //OFS: 0x88 SIZE: 0x4 + const char* sdropAnim; //OFS: 0x8C SIZE: 0x4 + const char* saltRaiseAnim; //OFS: 0x90 SIZE: 0x4 + const char* saltDropAnim; //OFS: 0x94 SIZE: 0x4 + const char* squickRaiseAnim; //OFS: 0x98 SIZE: 0x4 + const char* squickDropAnim; //OFS: 0x9C SIZE: 0x4 + const char* semptyRaiseAnim; //OFS: 0xA0 SIZE: 0x4 + const char* semptyDropAnim; //OFS: 0xA4 SIZE: 0x4 + const char* ssprintInAnim; //OFS: 0xA8 SIZE: 0x4 + const char* ssprintLoopAnim; //OFS: 0xAC SIZE: 0x4 + const char* ssprintOutAnim; //OFS: 0xB0 SIZE: 0x4 + const char* sdeployAnim; //OFS: 0xB4 SIZE: 0x4 + const char* sbreakdownAnim; //OFS: 0xB8 SIZE: 0x4 + const char* sdetonateAnim; //OFS: 0xBC SIZE: 0x4 + const char* snightVisionWearAnim; //OFS: 0xC0 SIZE: 0x4 + const char* snightVisionRemoveAnim; //OFS: 0xC4 SIZE: 0x4 + const char* sadsFireAnim; //OFS: 0xC8 SIZE: 0x4 + const char* sadsLastShotAnim; //OFS: 0xCC SIZE: 0x4 + const char* sadsRechamberAnim; //OFS: 0xD0 SIZE: 0x4 + const char* sadsUpAnim; //OFS: 0xD4 SIZE: 0x4 + const char* sadsDownAnim; //OFS: 0xD8 SIZE: 0x4 + const char* szModeName; //OFS: 0xDC SIZE: 0x4 + unsigned __int16 hideTags[8]; //OFS: 0xE0 SIZE: 0x10 + unsigned __int16 notetrackSoundMapKeys[20]; //OFS: 0xF0 SIZE: 0x28 + unsigned __int16 notetrackSoundMapValues[20]; //OFS: 0x118 SIZE: 0x28 + int playerAnimType; //OFS: 0x140 SIZE: 0x4 + weapType_t weapType; //OFS: 0x144 SIZE: 0x4 + weapClass_t weapClass; //OFS: 0x148 SIZE: 0x4 + PenetrateType penetrateType; //OFS: 0x14C SIZE: 0x4 + ImpactType impactType; //OFS: 0x150 SIZE: 0x4 + weapInventoryType_t inventoryType; //OFS: 0x154 SIZE: 0x4 + weapFireType_t fireType; //OFS: 0x158 SIZE: 0x4 + int clipType; //OFS: 0x15C SIZE: 0x4 + int overheatWeapon; //OFS: 0x160 SIZE: 0x4 + float overheatRate; //OFS: 0x164 SIZE: 0x4 + float cooldownRate; //OFS: 0x168 SIZE: 0x4 + float overheatEndVal; //OFS: 0x16C SIZE: 0x4 + int coolWhileFiring; //OFS: 0x170 SIZE: 0x4 + OffhandClass offhandClass; //OFS: 0x174 SIZE: 0x4 + weapStance_t stance; //OFS: 0x178 SIZE: 0x4 + FxEffectDef* viewFlashEffect; //OFS: 0x17C SIZE: 0x4 + FxEffectDef* worldFlashEffect; //OFS: 0x180 SIZE: 0x4 + snd_alias_list_t* pickupSound; //OFS: 0x184 SIZE: 0x4 + snd_alias_list_t* pickupSoundPlayer; //OFS: 0x188 SIZE: 0x4 + snd_alias_list_t* ammoPickupSound; //OFS: 0x18C SIZE: 0x4 + snd_alias_list_t* ammoPickupSoundPlayer; //OFS: 0x190 SIZE: 0x4 + snd_alias_list_t* projectileSound; //OFS: 0x194 SIZE: 0x4 + snd_alias_list_t* pullbackSound; //OFS: 0x198 SIZE: 0x4 + snd_alias_list_t* pullbackSoundPlayer; //OFS: 0x19C SIZE: 0x4 + snd_alias_list_t* fireSound; //OFS: 0x1A0 SIZE: 0x4 + snd_alias_list_t* fireSoundPlayer; //OFS: 0x1A4 SIZE: 0x4 + snd_alias_list_t* fireLoopSound; //OFS: 0x1A8 SIZE: 0x4 + snd_alias_list_t* fireLoopSoundPlayer; //OFS: 0x1AC SIZE: 0x4 + snd_alias_list_t* fireStopSound; //OFS: 0x1B0 SIZE: 0x4 + snd_alias_list_t* fireStopSoundPlayer; //OFS: 0x1B4 SIZE: 0x4 + snd_alias_list_t* fireLastSound; //OFS: 0x1B8 SIZE: 0x4 + snd_alias_list_t* fireLastSoundPlayer; //OFS: 0x1BC SIZE: 0x4 + snd_alias_list_t* emptyFireSound; //OFS: 0x1C0 SIZE: 0x4 + snd_alias_list_t* emptyFireSoundPlayer; //OFS: 0x1C4 SIZE: 0x4 + snd_alias_list_t* crackSound; //OFS: 0x1C8 SIZE: 0x4 + snd_alias_list_t* whizbySound; //OFS: 0x1CC SIZE: 0x4 + snd_alias_list_t* meleeSwipeSound; //OFS: 0x1D0 SIZE: 0x4 + snd_alias_list_t* meleeSwipeSoundPlayer; //OFS: 0x1D4 SIZE: 0x4 + snd_alias_list_t* meleeHitSound; //OFS: 0x1D8 SIZE: 0x4 + snd_alias_list_t* meleeMissSound; //OFS: 0x1DC SIZE: 0x4 + snd_alias_list_t* rechamberSound; //OFS: 0x1E0 SIZE: 0x4 + snd_alias_list_t* rechamberSoundPlayer; //OFS: 0x1E4 SIZE: 0x4 + snd_alias_list_t* reloadSound; //OFS: 0x1E8 SIZE: 0x4 + snd_alias_list_t* reloadSoundPlayer; //OFS: 0x1EC SIZE: 0x4 + snd_alias_list_t* reloadEmptySound; //OFS: 0x1F0 SIZE: 0x4 + snd_alias_list_t* reloadEmptySoundPlayer; //OFS: 0x1F4 SIZE: 0x4 + snd_alias_list_t* reloadStartSound; //OFS: 0x1F8 SIZE: 0x4 + snd_alias_list_t* reloadStartSoundPlayer; //OFS: 0x1FC SIZE: 0x4 + snd_alias_list_t* reloadEndSound; //OFS: 0x200 SIZE: 0x4 + snd_alias_list_t* reloadEndSoundPlayer; //OFS: 0x204 SIZE: 0x4 + snd_alias_list_t* rotateLoopSound; //OFS: 0x208 SIZE: 0x4 + snd_alias_list_t* rotateLoopSoundPlayer; //OFS: 0x20C SIZE: 0x4 + snd_alias_list_t* deploySound; //OFS: 0x210 SIZE: 0x4 + snd_alias_list_t* deploySoundPlayer; //OFS: 0x214 SIZE: 0x4 + snd_alias_list_t* finishDeploySound; //OFS: 0x218 SIZE: 0x4 + snd_alias_list_t* finishDeploySoundPlayer; //OFS: 0x21C SIZE: 0x4 + snd_alias_list_t* breakdownSound; //OFS: 0x220 SIZE: 0x4 + snd_alias_list_t* breakdownSoundPlayer; //OFS: 0x224 SIZE: 0x4 + snd_alias_list_t* finishBreakdownSound; //OFS: 0x228 SIZE: 0x4 + snd_alias_list_t* finishBreakdownSoundPlayer; //OFS: 0x22C SIZE: 0x4 + snd_alias_list_t* detonateSound; //OFS: 0x230 SIZE: 0x4 + snd_alias_list_t* detonateSoundPlayer; //OFS: 0x234 SIZE: 0x4 + snd_alias_list_t* nightVisionWearSound; //OFS: 0x238 SIZE: 0x4 + snd_alias_list_t* nightVisionWearSoundPlayer; //OFS: 0x23C SIZE: 0x4 + snd_alias_list_t* nightVisionRemoveSound; //OFS: 0x240 SIZE: 0x4 + snd_alias_list_t* nightVisionRemoveSoundPlayer; //OFS: 0x244 SIZE: 0x4 + snd_alias_list_t* altSwitchSound; //OFS: 0x248 SIZE: 0x4 + snd_alias_list_t* altSwitchSoundPlayer; //OFS: 0x24C SIZE: 0x4 + snd_alias_list_t* raiseSound; //OFS: 0x250 SIZE: 0x4 + snd_alias_list_t* raiseSoundPlayer; //OFS: 0x254 SIZE: 0x4 + snd_alias_list_t* firstRaiseSound; //OFS: 0x258 SIZE: 0x4 + snd_alias_list_t* firstRaiseSoundPlayer; //OFS: 0x25C SIZE: 0x4 + snd_alias_list_t* putawaySound; //OFS: 0x260 SIZE: 0x4 + snd_alias_list_t* putawaySoundPlayer; //OFS: 0x264 SIZE: 0x4 + snd_alias_list_t* overheatSound; //OFS: 0x268 SIZE: 0x4 + snd_alias_list_t* overheatSoundPlayer; //OFS: 0x26C SIZE: 0x4 + snd_alias_list_t** bounceSound; //OFS: 0x270 SIZE: 0x4 + WeaponDef* standMountedWeapdef; //OFS: 0x274 SIZE: 0x4 + WeaponDef* crouchMountedWeapdef; //OFS: 0x278 SIZE: 0x4 + WeaponDef* proneMountedWeapdef; //OFS: 0x27C SIZE: 0x4 + int StandMountedIndex; //OFS: 0x280 SIZE: 0x4 + int CrouchMountedIndex; //OFS: 0x284 SIZE: 0x4 + int ProneMountedIndex; //OFS: 0x288 SIZE: 0x4 + FxEffectDef* viewShellEjectEffect; //OFS: 0x28C SIZE: 0x4 + FxEffectDef* worldShellEjectEffect; //OFS: 0x290 SIZE: 0x4 + FxEffectDef* viewLastShotEjectEffect; //OFS: 0x294 SIZE: 0x4 + FxEffectDef* worldLastShotEjectEffect; //OFS: 0x298 SIZE: 0x4 + Material* reticleCenter; //OFS: 0x29C SIZE: 0x4 + Material* reticleSide; //OFS: 0x2A0 SIZE: 0x4 + int iReticleCenterSize; //OFS: 0x2A4 SIZE: 0x4 + int iReticleSideSize; //OFS: 0x2A8 SIZE: 0x4 + int iReticleMinOfs; //OFS: 0x2AC SIZE: 0x4 + activeReticleType_t activeReticleType; //OFS: 0x2B0 SIZE: 0x4 + float vStandMove[3]; //OFS: 0x2B4 SIZE: 0xC + float vStandRot[3]; //OFS: 0x2C0 SIZE: 0xC + float vDuckedOfs[3]; //OFS: 0x2CC SIZE: 0xC + float vDuckedMove[3]; //OFS: 0x2D8 SIZE: 0xC + float duckedSprintOfs[3]; //OFS: 0x2E4 SIZE: 0xC + float duckedSprintRot[3]; //OFS: 0x2F0 SIZE: 0xC + float duckedSprintBob[2]; //OFS: 0x2FC SIZE: 0x8 + float duckedSprintScale; //OFS: 0x304 SIZE: 0x4 + float sprintOfs[3]; //OFS: 0x308 SIZE: 0xC + float sprintRot[3]; //OFS: 0x314 SIZE: 0xC + float sprintBob[2]; //OFS: 0x320 SIZE: 0x8 + float sprintScale; //OFS: 0x328 SIZE: 0x4 + float vDuckedRot[3]; //OFS: 0x32C SIZE: 0xC + float vProneOfs[3]; //OFS: 0x338 SIZE: 0xC + float vProneMove[3]; //OFS: 0x344 SIZE: 0xC + float vProneRot[3]; //OFS: 0x350 SIZE: 0xC + float fPosMoveRate; //OFS: 0x35C SIZE: 0x4 + float fPosProneMoveRate; //OFS: 0x360 SIZE: 0x4 + float fStandMoveMinSpeed; //OFS: 0x364 SIZE: 0x4 + float fDuckedMoveMinSpeed; //OFS: 0x368 SIZE: 0x4 + float fProneMoveMinSpeed; //OFS: 0x36C SIZE: 0x4 + float fPosRotRate; //OFS: 0x370 SIZE: 0x4 + float fPosProneRotRate; //OFS: 0x374 SIZE: 0x4 + float fStandRotMinSpeed; //OFS: 0x378 SIZE: 0x4 + float fDuckedRotMinSpeed; //OFS: 0x37C SIZE: 0x4 + float fProneRotMinSpeed; //OFS: 0x380 SIZE: 0x4 + XModel* worldModel[16]; //OFS: 0x384 SIZE: 0x40 + XModel* worldClipModel; //OFS: 0x3C4 SIZE: 0x4 + XModel* rocketModel; //OFS: 0x3C8 SIZE: 0x4 + XModel* knifeModel; //OFS: 0x3CC SIZE: 0x4 + XModel* worldKnifeModel; //OFS: 0x3D0 SIZE: 0x4 + XModel* mountedModel; //OFS: 0x3D4 SIZE: 0x4 + Material* hudIcon; //OFS: 0x3D8 SIZE: 0x4 + weaponIconRatioType_t hudIconRatio; //OFS: 0x3DC SIZE: 0x4 + Material* ammoCounterIcon; //OFS: 0x3E0 SIZE: 0x4 + weaponIconRatioType_t ammoCounterIconRatio; //OFS: 0x3E4 SIZE: 0x4 + ammoCounterClipType_t ammoCounterClip; //OFS: 0x3E8 SIZE: 0x4 + int iStartAmmo; //OFS: 0x3EC SIZE: 0x4 + const char* szAmmoName; //OFS: 0x3F0 SIZE: 0x4 + int iAmmoIndex; //OFS: 0x3F4 SIZE: 0x4 + const char* szClipName; //OFS: 0x3F8 SIZE: 0x4 + int iClipIndex; //OFS: 0x3FC SIZE: 0x4 + int iHeatIndex; //OFS: 0x400 SIZE: 0x4 + int iMaxAmmo; //OFS: 0x404 SIZE: 0x4 + int iClipSize; //OFS: 0x408 SIZE: 0x4 + int shotCount; //OFS: 0x40C SIZE: 0x4 + const char* szSharedAmmoCapName; //OFS: 0x410 SIZE: 0x4 + int iSharedAmmoCapIndex; //OFS: 0x414 SIZE: 0x4 + int iSharedAmmoCap; //OFS: 0x418 SIZE: 0x4 + int unlimitedAmmo; //OFS: 0x41C SIZE: 0x4 + int damage; //OFS: 0x420 SIZE: 0x4 + int damageDuration; //OFS: 0x424 SIZE: 0x4 + int damageInterval; //OFS: 0x428 SIZE: 0x4 + int playerDamage; //OFS: 0x42C SIZE: 0x4 + int iMeleeDamage; //OFS: 0x430 SIZE: 0x4 + int iDamageType; //OFS: 0x434 SIZE: 0x4 + int iFireDelay; //OFS: 0x438 SIZE: 0x4 + int iMeleeDelay; //OFS: 0x43C SIZE: 0x4 + int meleeChargeDelay; //OFS: 0x440 SIZE: 0x4 + int iDetonateDelay; //OFS: 0x444 SIZE: 0x4 + int iFireTime; //OFS: 0x448 SIZE: 0x4 + int iRechamberTime; //OFS: 0x44C SIZE: 0x4 + int iRechamberBoltTime; //OFS: 0x450 SIZE: 0x4 + int iHoldFireTime; //OFS: 0x454 SIZE: 0x4 + int iDetonateTime; //OFS: 0x458 SIZE: 0x4 + int iMeleeTime; //OFS: 0x45C SIZE: 0x4 + int meleeChargeTime; //OFS: 0x460 SIZE: 0x4 + int iReloadTime; //OFS: 0x464 SIZE: 0x4 + int reloadShowRocketTime; //OFS: 0x468 SIZE: 0x4 + int iReloadEmptyTime; //OFS: 0x46C SIZE: 0x4 + int iReloadAddTime; //OFS: 0x470 SIZE: 0x4 + int reloadEmptyAddTime; //OFS: 0x474 SIZE: 0x4 + int iReloadStartTime; //OFS: 0x478 SIZE: 0x4 + int iReloadStartAddTime; //OFS: 0x47C SIZE: 0x4 + int iReloadEndTime; //OFS: 0x480 SIZE: 0x4 + int iDropTime; //OFS: 0x484 SIZE: 0x4 + int iRaiseTime; //OFS: 0x488 SIZE: 0x4 + int iAltDropTime; //OFS: 0x48C SIZE: 0x4 + int iAltRaiseTime; //OFS: 0x490 SIZE: 0x4 + int quickDropTime; //OFS: 0x494 SIZE: 0x4 + int quickRaiseTime; //OFS: 0x498 SIZE: 0x4 + int iFirstRaiseTime; //OFS: 0x49C SIZE: 0x4 + int iEmptyRaiseTime; //OFS: 0x4A0 SIZE: 0x4 + int iEmptyDropTime; //OFS: 0x4A4 SIZE: 0x4 + int sprintInTime; //OFS: 0x4A8 SIZE: 0x4 + int sprintLoopTime; //OFS: 0x4AC SIZE: 0x4 + int sprintOutTime; //OFS: 0x4B0 SIZE: 0x4 + int deployTime; //OFS: 0x4B4 SIZE: 0x4 + int breakdownTime; //OFS: 0x4B8 SIZE: 0x4 + int nightVisionWearTime; //OFS: 0x4BC SIZE: 0x4 + int nightVisionWearTimeFadeOutEnd; //OFS: 0x4C0 SIZE: 0x4 + int nightVisionWearTimePowerUp; //OFS: 0x4C4 SIZE: 0x4 + int nightVisionRemoveTime; //OFS: 0x4C8 SIZE: 0x4 + int nightVisionRemoveTimePowerDown; //OFS: 0x4CC SIZE: 0x4 + int nightVisionRemoveTimeFadeInStart; //OFS: 0x4D0 SIZE: 0x4 + int fuseTime; //OFS: 0x4D4 SIZE: 0x4 + int aiFuseTime; //OFS: 0x4D8 SIZE: 0x4 + int requireLockonToFire; //OFS: 0x4DC SIZE: 0x4 + int noAdsWhenMagEmpty; //OFS: 0x4E0 SIZE: 0x4 + int avoidDropCleanup; //OFS: 0x4E4 SIZE: 0x4 + float autoAimRange; //OFS: 0x4E8 SIZE: 0x4 + float aimAssistRange; //OFS: 0x4EC SIZE: 0x4 + float aimAssistRangeAds; //OFS: 0x4F0 SIZE: 0x4 + int mountableWeapon; //OFS: 0x4F4 SIZE: 0x4 + float aimPadding; //OFS: 0x4F8 SIZE: 0x4 + float enemyCrosshairRange; //OFS: 0x4FC SIZE: 0x4 + int crosshairColorChange; //OFS: 0x500 SIZE: 0x4 + float moveSpeedScale; //OFS: 0x504 SIZE: 0x4 + float adsMoveSpeedScale; //OFS: 0x508 SIZE: 0x4 + float sprintDurationScale; //OFS: 0x50C SIZE: 0x4 + float fAdsZoomFov; //OFS: 0x510 SIZE: 0x4 + float fAdsZoomInFrac; //OFS: 0x514 SIZE: 0x4 + float fAdsZoomOutFrac; //OFS: 0x518 SIZE: 0x4 + Material* overlayMaterial; //OFS: 0x51C SIZE: 0x4 + Material* overlayMaterialLowRes; //OFS: 0x520 SIZE: 0x4 + weapOverlayReticle_t overlayReticle; //OFS: 0x524 SIZE: 0x4 + WeapOverlayInteface_t overlayInterface; //OFS: 0x528 SIZE: 0x4 + float overlayWidth; //OFS: 0x52C SIZE: 0x4 + float overlayHeight; //OFS: 0x530 SIZE: 0x4 + float fAdsBobFactor; //OFS: 0x534 SIZE: 0x4 + float fAdsViewBobMult; //OFS: 0x538 SIZE: 0x4 + float fHipSpreadStandMin; //OFS: 0x53C SIZE: 0x4 + float fHipSpreadDuckedMin; //OFS: 0x540 SIZE: 0x4 + float fHipSpreadProneMin; //OFS: 0x544 SIZE: 0x4 + float hipSpreadStandMax; //OFS: 0x548 SIZE: 0x4 + float hipSpreadDuckedMax; //OFS: 0x54C SIZE: 0x4 + float hipSpreadProneMax; //OFS: 0x550 SIZE: 0x4 + float fHipSpreadDecayRate; //OFS: 0x554 SIZE: 0x4 + float fHipSpreadFireAdd; //OFS: 0x558 SIZE: 0x4 + float fHipSpreadTurnAdd; //OFS: 0x55C SIZE: 0x4 + float fHipSpreadMoveAdd; //OFS: 0x560 SIZE: 0x4 + float fHipSpreadDuckedDecay; //OFS: 0x564 SIZE: 0x4 + float fHipSpreadProneDecay; //OFS: 0x568 SIZE: 0x4 + float fHipReticleSidePos; //OFS: 0x56C SIZE: 0x4 + int iAdsTransInTime; //OFS: 0x570 SIZE: 0x4 + int iAdsTransOutTime; //OFS: 0x574 SIZE: 0x4 + float fAdsIdleAmount; //OFS: 0x578 SIZE: 0x4 + float fHipIdleAmount; //OFS: 0x57C SIZE: 0x4 + float adsIdleSpeed; //OFS: 0x580 SIZE: 0x4 + float hipIdleSpeed; //OFS: 0x584 SIZE: 0x4 + float fIdleCrouchFactor; //OFS: 0x588 SIZE: 0x4 + float fIdleProneFactor; //OFS: 0x58C SIZE: 0x4 + float fGunMaxPitch; //OFS: 0x590 SIZE: 0x4 + float fGunMaxYaw; //OFS: 0x594 SIZE: 0x4 + float swayMaxAngle; //OFS: 0x598 SIZE: 0x4 + float swayLerpSpeed; //OFS: 0x59C SIZE: 0x4 + float swayPitchScale; //OFS: 0x5A0 SIZE: 0x4 + float swayYawScale; //OFS: 0x5A4 SIZE: 0x4 + float swayHorizScale; //OFS: 0x5A8 SIZE: 0x4 + float swayVertScale; //OFS: 0x5AC SIZE: 0x4 + float swayShellShockScale; //OFS: 0x5B0 SIZE: 0x4 + float adsSwayMaxAngle; //OFS: 0x5B4 SIZE: 0x4 + float adsSwayLerpSpeed; //OFS: 0x5B8 SIZE: 0x4 + float adsSwayPitchScale; //OFS: 0x5BC SIZE: 0x4 + float adsSwayYawScale; //OFS: 0x5C0 SIZE: 0x4 + float adsSwayHorizScale; //OFS: 0x5C4 SIZE: 0x4 + float adsSwayVertScale; //OFS: 0x5C8 SIZE: 0x4 + int bRifleBullet; //OFS: 0x5CC SIZE: 0x4 + int armorPiercing; //OFS: 0x5D0 SIZE: 0x4 + int bBoltAction; //OFS: 0x5D4 SIZE: 0x4 + int aimDownSight; //OFS: 0x5D8 SIZE: 0x4 + int bRechamberWhileAds; //OFS: 0x5DC SIZE: 0x4 + float adsViewErrorMin; //OFS: 0x5E0 SIZE: 0x4 + float adsViewErrorMax; //OFS: 0x5E4 SIZE: 0x4 + int bCookOffHold; //OFS: 0x5E8 SIZE: 0x4 + int bClipOnly; //OFS: 0x5EC SIZE: 0x4 + int canUseInVehicle; //OFS: 0x5F0 SIZE: 0x4 + int noDropsOrRaises; //OFS: 0x5F4 SIZE: 0x4 + int adsFireOnly; //OFS: 0x5F8 SIZE: 0x4 + int cancelAutoHolsterWhenEmpty; //OFS: 0x5FC SIZE: 0x4 + int suppressAmmoReserveDisplay; //OFS: 0x600 SIZE: 0x4 + int enhanced; //OFS: 0x604 SIZE: 0x4 + int laserSightDuringNightvision; //OFS: 0x608 SIZE: 0x4 + int bayonet; //OFS: 0x60C SIZE: 0x4 + Material* killIcon; //OFS: 0x610 SIZE: 0x4 + weaponIconRatioType_t killIconRatio; //OFS: 0x614 SIZE: 0x4 + int flipKillIcon; //OFS: 0x618 SIZE: 0x4 + Material* dpadIcon; //OFS: 0x61C SIZE: 0x4 + weaponIconRatioType_t dpadIconRatio; //OFS: 0x620 SIZE: 0x4 + int bNoPartialReload; //OFS: 0x624 SIZE: 0x4 + int bSegmentedReload; //OFS: 0x628 SIZE: 0x4 + int noADSAutoReload; //OFS: 0x62C SIZE: 0x4 + int iReloadAmmoAdd; //OFS: 0x630 SIZE: 0x4 + int iReloadStartAdd; //OFS: 0x634 SIZE: 0x4 + const char* szAltWeaponName; //OFS: 0x638 SIZE: 0x4 + unsigned int altWeaponIndex; //OFS: 0x63C SIZE: 0x4 + int iDropAmmoMin; //OFS: 0x640 SIZE: 0x4 + int iDropAmmoMax; //OFS: 0x644 SIZE: 0x4 + int blocksProne; //OFS: 0x648 SIZE: 0x4 + int silenced; //OFS: 0x64C SIZE: 0x4 + int iExplosionRadius; //OFS: 0x650 SIZE: 0x4 + int iExplosionRadiusMin; //OFS: 0x654 SIZE: 0x4 + int iExplosionInnerDamage; //OFS: 0x658 SIZE: 0x4 + int iExplosionOuterDamage; //OFS: 0x65C SIZE: 0x4 + float damageConeAngle; //OFS: 0x660 SIZE: 0x4 + int iProjectileSpeed; //OFS: 0x664 SIZE: 0x4 + int iProjectileSpeedUp; //OFS: 0x668 SIZE: 0x4 + int iProjectileSpeedForward; //OFS: 0x66C SIZE: 0x4 + int iProjectileActivateDist; //OFS: 0x670 SIZE: 0x4 + float projLifetime; //OFS: 0x674 SIZE: 0x4 + float timeToAccelerate; //OFS: 0x678 SIZE: 0x4 + float projectileCurvature; //OFS: 0x67C SIZE: 0x4 + XModel* projectileModel; //OFS: 0x680 SIZE: 0x4 + weapProjExposion_t projExplosion; //OFS: 0x684 SIZE: 0x4 + FxEffectDef* projExplosionEffect; //OFS: 0x688 SIZE: 0x4 + int projExplosionEffectForceNormalUp; //OFS: 0x68C SIZE: 0x4 + FxEffectDef* projDudEffect; //OFS: 0x690 SIZE: 0x4 + snd_alias_list_t* projExplosionSound; //OFS: 0x694 SIZE: 0x4 + snd_alias_list_t* projDudSound; //OFS: 0x698 SIZE: 0x4 + snd_alias_list_t* mortarShellSound; //OFS: 0x69C SIZE: 0x4 + snd_alias_list_t* tankShellSound; //OFS: 0x6A0 SIZE: 0x4 + int bProjImpactExplode; //OFS: 0x6A4 SIZE: 0x4 + WeapStickinessType stickiness; //OFS: 0x6A8 SIZE: 0x4 + int hasDetonator; //OFS: 0x6AC SIZE: 0x4 + int timedDetonation; //OFS: 0x6B0 SIZE: 0x4 + int rotate; //OFS: 0x6B4 SIZE: 0x4 + int holdButtonToThrow; //OFS: 0x6B8 SIZE: 0x4 + int freezeMovementWhenFiring; //OFS: 0x6BC SIZE: 0x4 + float lowAmmoWarningThreshold; //OFS: 0x6C0 SIZE: 0x4 + float parallelBounce[31]; //OFS: 0x6C4 SIZE: 0x7C + float perpendicularBounce[31]; //OFS: 0x740 SIZE: 0x7C + FxEffectDef* projTrailEffect; //OFS: 0x7BC SIZE: 0x4 + float vProjectileColor[3]; //OFS: 0x7C0 SIZE: 0xC + guidedMissileType_t guidedMissileType; //OFS: 0x7CC SIZE: 0x4 + float maxSteeringAccel; //OFS: 0x7D0 SIZE: 0x4 + int projIgnitionDelay; //OFS: 0x7D4 SIZE: 0x4 + FxEffectDef* projIgnitionEffect; //OFS: 0x7D8 SIZE: 0x4 + snd_alias_list_t* projIgnitionSound; //OFS: 0x7DC SIZE: 0x4 + float fAdsAimPitch; //OFS: 0x7E0 SIZE: 0x4 + float fAdsCrosshairInFrac; //OFS: 0x7E4 SIZE: 0x4 + float fAdsCrosshairOutFrac; //OFS: 0x7E8 SIZE: 0x4 + int adsGunKickReducedKickBullets; //OFS: 0x7EC SIZE: 0x4 + float adsGunKickReducedKickPercent; //OFS: 0x7F0 SIZE: 0x4 + float fAdsGunKickPitchMin; //OFS: 0x7F4 SIZE: 0x4 + float fAdsGunKickPitchMax; //OFS: 0x7F8 SIZE: 0x4 + float fAdsGunKickYawMin; //OFS: 0x7FC SIZE: 0x4 + float fAdsGunKickYawMax; //OFS: 0x800 SIZE: 0x4 + float fAdsGunKickAccel; //OFS: 0x804 SIZE: 0x4 + float fAdsGunKickSpeedMax; //OFS: 0x808 SIZE: 0x4 + float fAdsGunKickSpeedDecay; //OFS: 0x80C SIZE: 0x4 + float fAdsGunKickStaticDecay; //OFS: 0x810 SIZE: 0x4 + float fAdsViewKickPitchMin; //OFS: 0x814 SIZE: 0x4 + float fAdsViewKickPitchMax; //OFS: 0x818 SIZE: 0x4 + float fAdsViewKickYawMin; //OFS: 0x81C SIZE: 0x4 + float fAdsViewKickYawMax; //OFS: 0x820 SIZE: 0x4 + float fAdsViewKickCenterSpeed; //OFS: 0x824 SIZE: 0x4 + float fAdsViewScatterMin; //OFS: 0x828 SIZE: 0x4 + float fAdsViewScatterMax; //OFS: 0x82C SIZE: 0x4 + float fAdsSpread; //OFS: 0x830 SIZE: 0x4 + int hipGunKickReducedKickBullets; //OFS: 0x834 SIZE: 0x4 + float hipGunKickReducedKickPercent; //OFS: 0x838 SIZE: 0x4 + float fHipGunKickPitchMin; //OFS: 0x83C SIZE: 0x4 + float fHipGunKickPitchMax; //OFS: 0x840 SIZE: 0x4 + float fHipGunKickYawMin; //OFS: 0x844 SIZE: 0x4 + float fHipGunKickYawMax; //OFS: 0x848 SIZE: 0x4 + float fHipGunKickAccel; //OFS: 0x84C SIZE: 0x4 + float fHipGunKickSpeedMax; //OFS: 0x850 SIZE: 0x4 + float fHipGunKickSpeedDecay; //OFS: 0x854 SIZE: 0x4 + float fHipGunKickStaticDecay; //OFS: 0x858 SIZE: 0x4 + float fHipViewKickPitchMin; //OFS: 0x85C SIZE: 0x4 + float fHipViewKickPitchMax; //OFS: 0x860 SIZE: 0x4 + float fHipViewKickYawMin; //OFS: 0x864 SIZE: 0x4 + float fHipViewKickYawMax; //OFS: 0x868 SIZE: 0x4 + float fHipViewKickCenterSpeed; //OFS: 0x86C SIZE: 0x4 + float fHipViewScatterMin; //OFS: 0x870 SIZE: 0x4 + float fHipViewScatterMax; //OFS: 0x874 SIZE: 0x4 + float fightDist; //OFS: 0x878 SIZE: 0x4 + float maxDist; //OFS: 0x87C SIZE: 0x4 + const char* accuracyGraphName[2]; //OFS: 0x880 SIZE: 0x8 + float(*accuracyGraphKnots[2])[2]; //OFS: 0x888 SIZE: 0x8 + float(*originalAccuracyGraphKnots[2])[2]; //OFS: 0x890 SIZE: 0x8 + int accuracyGraphKnotCount[2]; //OFS: 0x898 SIZE: 0x8 + int originalAccuracyGraphKnotCount[2]; //OFS: 0x8A0 SIZE: 0x8 + int iPositionReloadTransTime; //OFS: 0x8A8 SIZE: 0x4 + float leftArc; //OFS: 0x8AC SIZE: 0x4 + float rightArc; //OFS: 0x8B0 SIZE: 0x4 + float topArc; //OFS: 0x8B4 SIZE: 0x4 + float bottomArc; //OFS: 0x8B8 SIZE: 0x4 + float accuracy; //OFS: 0x8BC SIZE: 0x4 + float aiSpread; //OFS: 0x8C0 SIZE: 0x4 + float playerSpread; //OFS: 0x8C4 SIZE: 0x4 + float minTurnSpeed[2]; //OFS: 0x8C8 SIZE: 0x8 + float maxTurnSpeed[2]; //OFS: 0x8D0 SIZE: 0x8 + float pitchConvergenceTime; //OFS: 0x8D8 SIZE: 0x4 + float yawConvergenceTime; //OFS: 0x8DC SIZE: 0x4 + float suppressTime; //OFS: 0x8E0 SIZE: 0x4 + float maxRange; //OFS: 0x8E4 SIZE: 0x4 + float fAnimHorRotateInc; //OFS: 0x8E8 SIZE: 0x4 + float fPlayerPositionDist; //OFS: 0x8EC SIZE: 0x4 + const char* szUseHintString; //OFS: 0x8F0 SIZE: 0x4 + const char* dropHintString; //OFS: 0x8F4 SIZE: 0x4 + int iUseHintStringIndex; //OFS: 0x8F8 SIZE: 0x4 + int dropHintStringIndex; //OFS: 0x8FC SIZE: 0x4 + float horizViewJitter; //OFS: 0x900 SIZE: 0x4 + float vertViewJitter; //OFS: 0x904 SIZE: 0x4 + const char* szScript; //OFS: 0x908 SIZE: 0x4 + float fOOPosAnimLength[2]; //OFS: 0x90C SIZE: 0x8 + int minDamage; //OFS: 0x914 SIZE: 0x4 + int minPlayerDamage; //OFS: 0x918 SIZE: 0x4 + float fMaxDamageRange; //OFS: 0x91C SIZE: 0x4 + float fMinDamageRange; //OFS: 0x920 SIZE: 0x4 + float destabilizationRateTime; //OFS: 0x924 SIZE: 0x4 + float destabilizationCurvatureMax; //OFS: 0x928 SIZE: 0x4 + int destabilizeDistance; //OFS: 0x92C SIZE: 0x4 + float locNone; //OFS: 0x930 SIZE: 0x4 + float locHelmet; //OFS: 0x934 SIZE: 0x4 + float locHead; //OFS: 0x938 SIZE: 0x4 + float locNeck; //OFS: 0x93C SIZE: 0x4 + float locTorsoUpper; //OFS: 0x940 SIZE: 0x4 + float locTorsoLower; //OFS: 0x944 SIZE: 0x4 + float locRightArmUpper; //OFS: 0x948 SIZE: 0x4 + float locLeftArmUpper; //OFS: 0x94C SIZE: 0x4 + float locRightArmLower; //OFS: 0x950 SIZE: 0x4 + float locLeftArmLower; //OFS: 0x954 SIZE: 0x4 + float locRightHand; //OFS: 0x958 SIZE: 0x4 + float locLeftHand; //OFS: 0x95C SIZE: 0x4 + float locRightLegUpper; //OFS: 0x960 SIZE: 0x4 + float locLeftLegUpper; //OFS: 0x964 SIZE: 0x4 + float locRightLegLower; //OFS: 0x968 SIZE: 0x4 + float locLeftLegLower; //OFS: 0x96C SIZE: 0x4 + float locRightFoot; //OFS: 0x970 SIZE: 0x4 + float locLeftFoot; //OFS: 0x974 SIZE: 0x4 + float locGun; //OFS: 0x978 SIZE: 0x4 + const char* fireRumble; //OFS: 0x97C SIZE: 0x4 + const char* meleeImpactRumble; //OFS: 0x980 SIZE: 0x4 + float adsDofStart; //OFS: 0x984 SIZE: 0x4 + float adsDofEnd; //OFS: 0x988 SIZE: 0x4 + float hipDofStart; //OFS: 0x98C SIZE: 0x4 + float hipDofEnd; //OFS: 0x990 SIZE: 0x4 + const char* flameTableFirstPerson; //OFS: 0x994 SIZE: 0x4 + const char* flameTableThirdPerson; //OFS: 0x998 SIZE: 0x4 + flameTable* flameTableFirstPersonPtr; //OFS: 0x99C SIZE: 0x4 + flameTable* flameTableThirdPersonPtr; //OFS: 0x9A0 SIZE: 0x4 + FxEffectDef* tagFx_preparationEffect; //OFS: 0x9A4 SIZE: 0x4 + FxEffectDef* tagFlash_preparationEffect; //OFS: 0x9A8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(WeaponDef, 0x9AC); + ASSERT_STRUCT_OFFSET(WeaponDef, szInternalName, 0x0); + ASSERT_STRUCT_OFFSET(WeaponDef, szDisplayName, 0x4); + ASSERT_STRUCT_OFFSET(WeaponDef, szOverlayName, 0x8); + ASSERT_STRUCT_OFFSET(WeaponDef, gunXModel, 0xC); + ASSERT_STRUCT_OFFSET(WeaponDef, handXModel, 0x4C); + ASSERT_STRUCT_OFFSET(WeaponDef, someAnim, 0x50); + ASSERT_STRUCT_OFFSET(WeaponDef, sidleAnim, 0x54); + ASSERT_STRUCT_OFFSET(WeaponDef, semptyIdleAnim, 0x58); + ASSERT_STRUCT_OFFSET(WeaponDef, sfireAnim, 0x5C); + ASSERT_STRUCT_OFFSET(WeaponDef, sholdFireAnim, 0x60); + ASSERT_STRUCT_OFFSET(WeaponDef, slastShotAnim, 0x64); + ASSERT_STRUCT_OFFSET(WeaponDef, srechamberAnim, 0x68); + ASSERT_STRUCT_OFFSET(WeaponDef, smeleeAnim, 0x6C); + ASSERT_STRUCT_OFFSET(WeaponDef, smeleeChargeAnim, 0x70); + ASSERT_STRUCT_OFFSET(WeaponDef, sreloadAnim, 0x74); + ASSERT_STRUCT_OFFSET(WeaponDef, sreloadEmptyAnim, 0x78); + ASSERT_STRUCT_OFFSET(WeaponDef, sreloadStartAnim, 0x7C); + ASSERT_STRUCT_OFFSET(WeaponDef, sreloadEndAnim, 0x80); + ASSERT_STRUCT_OFFSET(WeaponDef, sraiseAnim, 0x84); + ASSERT_STRUCT_OFFSET(WeaponDef, sfirstRaiseAnim, 0x88); + ASSERT_STRUCT_OFFSET(WeaponDef, sdropAnim, 0x8C); + ASSERT_STRUCT_OFFSET(WeaponDef, saltRaiseAnim, 0x90); + ASSERT_STRUCT_OFFSET(WeaponDef, saltDropAnim, 0x94); + ASSERT_STRUCT_OFFSET(WeaponDef, squickRaiseAnim, 0x98); + ASSERT_STRUCT_OFFSET(WeaponDef, squickDropAnim, 0x9C); + ASSERT_STRUCT_OFFSET(WeaponDef, semptyRaiseAnim, 0xA0); + ASSERT_STRUCT_OFFSET(WeaponDef, semptyDropAnim, 0xA4); + ASSERT_STRUCT_OFFSET(WeaponDef, ssprintInAnim, 0xA8); + ASSERT_STRUCT_OFFSET(WeaponDef, ssprintLoopAnim, 0xAC); + ASSERT_STRUCT_OFFSET(WeaponDef, ssprintOutAnim, 0xB0); + ASSERT_STRUCT_OFFSET(WeaponDef, sdeployAnim, 0xB4); + ASSERT_STRUCT_OFFSET(WeaponDef, sbreakdownAnim, 0xB8); + ASSERT_STRUCT_OFFSET(WeaponDef, sdetonateAnim, 0xBC); + ASSERT_STRUCT_OFFSET(WeaponDef, snightVisionWearAnim, 0xC0); + ASSERT_STRUCT_OFFSET(WeaponDef, snightVisionRemoveAnim, 0xC4); + ASSERT_STRUCT_OFFSET(WeaponDef, sadsFireAnim, 0xC8); + ASSERT_STRUCT_OFFSET(WeaponDef, sadsLastShotAnim, 0xCC); + ASSERT_STRUCT_OFFSET(WeaponDef, sadsRechamberAnim, 0xD0); + ASSERT_STRUCT_OFFSET(WeaponDef, sadsUpAnim, 0xD4); + ASSERT_STRUCT_OFFSET(WeaponDef, sadsDownAnim, 0xD8); + ASSERT_STRUCT_OFFSET(WeaponDef, szModeName, 0xDC); + ASSERT_STRUCT_OFFSET(WeaponDef, hideTags, 0xE0); + ASSERT_STRUCT_OFFSET(WeaponDef, notetrackSoundMapKeys, 0xF0); + ASSERT_STRUCT_OFFSET(WeaponDef, notetrackSoundMapValues, 0x118); + ASSERT_STRUCT_OFFSET(WeaponDef, playerAnimType, 0x140); + ASSERT_STRUCT_OFFSET(WeaponDef, weapType, 0x144); + ASSERT_STRUCT_OFFSET(WeaponDef, weapClass, 0x148); + ASSERT_STRUCT_OFFSET(WeaponDef, penetrateType, 0x14C); + ASSERT_STRUCT_OFFSET(WeaponDef, impactType, 0x150); + ASSERT_STRUCT_OFFSET(WeaponDef, inventoryType, 0x154); + ASSERT_STRUCT_OFFSET(WeaponDef, fireType, 0x158); + ASSERT_STRUCT_OFFSET(WeaponDef, clipType, 0x15C); + ASSERT_STRUCT_OFFSET(WeaponDef, overheatWeapon, 0x160); + ASSERT_STRUCT_OFFSET(WeaponDef, overheatRate, 0x164); + ASSERT_STRUCT_OFFSET(WeaponDef, cooldownRate, 0x168); + ASSERT_STRUCT_OFFSET(WeaponDef, overheatEndVal, 0x16C); + ASSERT_STRUCT_OFFSET(WeaponDef, coolWhileFiring, 0x170); + ASSERT_STRUCT_OFFSET(WeaponDef, offhandClass, 0x174); + ASSERT_STRUCT_OFFSET(WeaponDef, stance, 0x178); + ASSERT_STRUCT_OFFSET(WeaponDef, viewFlashEffect, 0x17C); + ASSERT_STRUCT_OFFSET(WeaponDef, worldFlashEffect, 0x180); + ASSERT_STRUCT_OFFSET(WeaponDef, pickupSound, 0x184); + ASSERT_STRUCT_OFFSET(WeaponDef, pickupSoundPlayer, 0x188); + ASSERT_STRUCT_OFFSET(WeaponDef, ammoPickupSound, 0x18C); + ASSERT_STRUCT_OFFSET(WeaponDef, ammoPickupSoundPlayer, 0x190); + ASSERT_STRUCT_OFFSET(WeaponDef, projectileSound, 0x194); + ASSERT_STRUCT_OFFSET(WeaponDef, pullbackSound, 0x198); + ASSERT_STRUCT_OFFSET(WeaponDef, pullbackSoundPlayer, 0x19C); + ASSERT_STRUCT_OFFSET(WeaponDef, fireSound, 0x1A0); + ASSERT_STRUCT_OFFSET(WeaponDef, fireSoundPlayer, 0x1A4); + ASSERT_STRUCT_OFFSET(WeaponDef, fireLoopSound, 0x1A8); + ASSERT_STRUCT_OFFSET(WeaponDef, fireLoopSoundPlayer, 0x1AC); + ASSERT_STRUCT_OFFSET(WeaponDef, fireStopSound, 0x1B0); + ASSERT_STRUCT_OFFSET(WeaponDef, fireStopSoundPlayer, 0x1B4); + ASSERT_STRUCT_OFFSET(WeaponDef, fireLastSound, 0x1B8); + ASSERT_STRUCT_OFFSET(WeaponDef, fireLastSoundPlayer, 0x1BC); + ASSERT_STRUCT_OFFSET(WeaponDef, emptyFireSound, 0x1C0); + ASSERT_STRUCT_OFFSET(WeaponDef, emptyFireSoundPlayer, 0x1C4); + ASSERT_STRUCT_OFFSET(WeaponDef, crackSound, 0x1C8); + ASSERT_STRUCT_OFFSET(WeaponDef, whizbySound, 0x1CC); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeSwipeSound, 0x1D0); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeSwipeSoundPlayer, 0x1D4); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeHitSound, 0x1D8); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeMissSound, 0x1DC); + ASSERT_STRUCT_OFFSET(WeaponDef, rechamberSound, 0x1E0); + ASSERT_STRUCT_OFFSET(WeaponDef, rechamberSoundPlayer, 0x1E4); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadSound, 0x1E8); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadSoundPlayer, 0x1EC); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadEmptySound, 0x1F0); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadEmptySoundPlayer, 0x1F4); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadStartSound, 0x1F8); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadStartSoundPlayer, 0x1FC); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadEndSound, 0x200); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadEndSoundPlayer, 0x204); + ASSERT_STRUCT_OFFSET(WeaponDef, rotateLoopSound, 0x208); + ASSERT_STRUCT_OFFSET(WeaponDef, rotateLoopSoundPlayer, 0x20C); + ASSERT_STRUCT_OFFSET(WeaponDef, deploySound, 0x210); + ASSERT_STRUCT_OFFSET(WeaponDef, deploySoundPlayer, 0x214); + ASSERT_STRUCT_OFFSET(WeaponDef, finishDeploySound, 0x218); + ASSERT_STRUCT_OFFSET(WeaponDef, finishDeploySoundPlayer, 0x21C); + ASSERT_STRUCT_OFFSET(WeaponDef, breakdownSound, 0x220); + ASSERT_STRUCT_OFFSET(WeaponDef, breakdownSoundPlayer, 0x224); + ASSERT_STRUCT_OFFSET(WeaponDef, finishBreakdownSound, 0x228); + ASSERT_STRUCT_OFFSET(WeaponDef, finishBreakdownSoundPlayer, 0x22C); + ASSERT_STRUCT_OFFSET(WeaponDef, detonateSound, 0x230); + ASSERT_STRUCT_OFFSET(WeaponDef, detonateSoundPlayer, 0x234); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionWearSound, 0x238); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionWearSoundPlayer, 0x23C); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionRemoveSound, 0x240); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionRemoveSoundPlayer, 0x244); + ASSERT_STRUCT_OFFSET(WeaponDef, altSwitchSound, 0x248); + ASSERT_STRUCT_OFFSET(WeaponDef, altSwitchSoundPlayer, 0x24C); + ASSERT_STRUCT_OFFSET(WeaponDef, raiseSound, 0x250); + ASSERT_STRUCT_OFFSET(WeaponDef, raiseSoundPlayer, 0x254); + ASSERT_STRUCT_OFFSET(WeaponDef, firstRaiseSound, 0x258); + ASSERT_STRUCT_OFFSET(WeaponDef, firstRaiseSoundPlayer, 0x25C); + ASSERT_STRUCT_OFFSET(WeaponDef, putawaySound, 0x260); + ASSERT_STRUCT_OFFSET(WeaponDef, putawaySoundPlayer, 0x264); + ASSERT_STRUCT_OFFSET(WeaponDef, overheatSound, 0x268); + ASSERT_STRUCT_OFFSET(WeaponDef, overheatSoundPlayer, 0x26C); + ASSERT_STRUCT_OFFSET(WeaponDef, bounceSound, 0x270); + ASSERT_STRUCT_OFFSET(WeaponDef, standMountedWeapdef, 0x274); + ASSERT_STRUCT_OFFSET(WeaponDef, crouchMountedWeapdef, 0x278); + ASSERT_STRUCT_OFFSET(WeaponDef, proneMountedWeapdef, 0x27C); + ASSERT_STRUCT_OFFSET(WeaponDef, StandMountedIndex, 0x280); + ASSERT_STRUCT_OFFSET(WeaponDef, CrouchMountedIndex, 0x284); + ASSERT_STRUCT_OFFSET(WeaponDef, ProneMountedIndex, 0x288); + ASSERT_STRUCT_OFFSET(WeaponDef, viewShellEjectEffect, 0x28C); + ASSERT_STRUCT_OFFSET(WeaponDef, worldShellEjectEffect, 0x290); + ASSERT_STRUCT_OFFSET(WeaponDef, viewLastShotEjectEffect, 0x294); + ASSERT_STRUCT_OFFSET(WeaponDef, worldLastShotEjectEffect, 0x298); + ASSERT_STRUCT_OFFSET(WeaponDef, reticleCenter, 0x29C); + ASSERT_STRUCT_OFFSET(WeaponDef, reticleSide, 0x2A0); + ASSERT_STRUCT_OFFSET(WeaponDef, iReticleCenterSize, 0x2A4); + ASSERT_STRUCT_OFFSET(WeaponDef, iReticleSideSize, 0x2A8); + ASSERT_STRUCT_OFFSET(WeaponDef, iReticleMinOfs, 0x2AC); + ASSERT_STRUCT_OFFSET(WeaponDef, activeReticleType, 0x2B0); + ASSERT_STRUCT_OFFSET(WeaponDef, vStandMove, 0x2B4); + ASSERT_STRUCT_OFFSET(WeaponDef, vStandRot, 0x2C0); + ASSERT_STRUCT_OFFSET(WeaponDef, vDuckedOfs, 0x2CC); + ASSERT_STRUCT_OFFSET(WeaponDef, vDuckedMove, 0x2D8); + ASSERT_STRUCT_OFFSET(WeaponDef, duckedSprintOfs, 0x2E4); + ASSERT_STRUCT_OFFSET(WeaponDef, duckedSprintRot, 0x2F0); + ASSERT_STRUCT_OFFSET(WeaponDef, duckedSprintBob, 0x2FC); + ASSERT_STRUCT_OFFSET(WeaponDef, duckedSprintScale, 0x304); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintOfs, 0x308); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintRot, 0x314); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintBob, 0x320); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintScale, 0x328); + ASSERT_STRUCT_OFFSET(WeaponDef, vDuckedRot, 0x32C); + ASSERT_STRUCT_OFFSET(WeaponDef, vProneOfs, 0x338); + ASSERT_STRUCT_OFFSET(WeaponDef, vProneMove, 0x344); + ASSERT_STRUCT_OFFSET(WeaponDef, vProneRot, 0x350); + ASSERT_STRUCT_OFFSET(WeaponDef, fPosMoveRate, 0x35C); + ASSERT_STRUCT_OFFSET(WeaponDef, fPosProneMoveRate, 0x360); + ASSERT_STRUCT_OFFSET(WeaponDef, fStandMoveMinSpeed, 0x364); + ASSERT_STRUCT_OFFSET(WeaponDef, fDuckedMoveMinSpeed, 0x368); + ASSERT_STRUCT_OFFSET(WeaponDef, fProneMoveMinSpeed, 0x36C); + ASSERT_STRUCT_OFFSET(WeaponDef, fPosRotRate, 0x370); + ASSERT_STRUCT_OFFSET(WeaponDef, fPosProneRotRate, 0x374); + ASSERT_STRUCT_OFFSET(WeaponDef, fStandRotMinSpeed, 0x378); + ASSERT_STRUCT_OFFSET(WeaponDef, fDuckedRotMinSpeed, 0x37C); + ASSERT_STRUCT_OFFSET(WeaponDef, fProneRotMinSpeed, 0x380); + ASSERT_STRUCT_OFFSET(WeaponDef, worldModel, 0x384); + ASSERT_STRUCT_OFFSET(WeaponDef, worldClipModel, 0x3C4); + ASSERT_STRUCT_OFFSET(WeaponDef, rocketModel, 0x3C8); + ASSERT_STRUCT_OFFSET(WeaponDef, knifeModel, 0x3CC); + ASSERT_STRUCT_OFFSET(WeaponDef, worldKnifeModel, 0x3D0); + ASSERT_STRUCT_OFFSET(WeaponDef, mountedModel, 0x3D4); + ASSERT_STRUCT_OFFSET(WeaponDef, hudIcon, 0x3D8); + ASSERT_STRUCT_OFFSET(WeaponDef, hudIconRatio, 0x3DC); + ASSERT_STRUCT_OFFSET(WeaponDef, ammoCounterIcon, 0x3E0); + ASSERT_STRUCT_OFFSET(WeaponDef, ammoCounterIconRatio, 0x3E4); + ASSERT_STRUCT_OFFSET(WeaponDef, ammoCounterClip, 0x3E8); + ASSERT_STRUCT_OFFSET(WeaponDef, iStartAmmo, 0x3EC); + ASSERT_STRUCT_OFFSET(WeaponDef, szAmmoName, 0x3F0); + ASSERT_STRUCT_OFFSET(WeaponDef, iAmmoIndex, 0x3F4); + ASSERT_STRUCT_OFFSET(WeaponDef, szClipName, 0x3F8); + ASSERT_STRUCT_OFFSET(WeaponDef, iClipIndex, 0x3FC); + ASSERT_STRUCT_OFFSET(WeaponDef, iHeatIndex, 0x400); + ASSERT_STRUCT_OFFSET(WeaponDef, iMaxAmmo, 0x404); + ASSERT_STRUCT_OFFSET(WeaponDef, iClipSize, 0x408); + ASSERT_STRUCT_OFFSET(WeaponDef, shotCount, 0x40C); + ASSERT_STRUCT_OFFSET(WeaponDef, szSharedAmmoCapName, 0x410); + ASSERT_STRUCT_OFFSET(WeaponDef, iSharedAmmoCapIndex, 0x414); + ASSERT_STRUCT_OFFSET(WeaponDef, iSharedAmmoCap, 0x418); + ASSERT_STRUCT_OFFSET(WeaponDef, unlimitedAmmo, 0x41C); + ASSERT_STRUCT_OFFSET(WeaponDef, damage, 0x420); + ASSERT_STRUCT_OFFSET(WeaponDef, damageDuration, 0x424); + ASSERT_STRUCT_OFFSET(WeaponDef, damageInterval, 0x428); + ASSERT_STRUCT_OFFSET(WeaponDef, playerDamage, 0x42C); + ASSERT_STRUCT_OFFSET(WeaponDef, iMeleeDamage, 0x430); + ASSERT_STRUCT_OFFSET(WeaponDef, iDamageType, 0x434); + ASSERT_STRUCT_OFFSET(WeaponDef, iFireDelay, 0x438); + ASSERT_STRUCT_OFFSET(WeaponDef, iMeleeDelay, 0x43C); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeChargeDelay, 0x440); + ASSERT_STRUCT_OFFSET(WeaponDef, iDetonateDelay, 0x444); + ASSERT_STRUCT_OFFSET(WeaponDef, iFireTime, 0x448); + ASSERT_STRUCT_OFFSET(WeaponDef, iRechamberTime, 0x44C); + ASSERT_STRUCT_OFFSET(WeaponDef, iRechamberBoltTime, 0x450); + ASSERT_STRUCT_OFFSET(WeaponDef, iHoldFireTime, 0x454); + ASSERT_STRUCT_OFFSET(WeaponDef, iDetonateTime, 0x458); + ASSERT_STRUCT_OFFSET(WeaponDef, iMeleeTime, 0x45C); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeChargeTime, 0x460); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadTime, 0x464); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadShowRocketTime, 0x468); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadEmptyTime, 0x46C); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadAddTime, 0x470); + ASSERT_STRUCT_OFFSET(WeaponDef, reloadEmptyAddTime, 0x474); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadStartTime, 0x478); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadStartAddTime, 0x47C); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadEndTime, 0x480); + ASSERT_STRUCT_OFFSET(WeaponDef, iDropTime, 0x484); + ASSERT_STRUCT_OFFSET(WeaponDef, iRaiseTime, 0x488); + ASSERT_STRUCT_OFFSET(WeaponDef, iAltDropTime, 0x48C); + ASSERT_STRUCT_OFFSET(WeaponDef, iAltRaiseTime, 0x490); + ASSERT_STRUCT_OFFSET(WeaponDef, quickDropTime, 0x494); + ASSERT_STRUCT_OFFSET(WeaponDef, quickRaiseTime, 0x498); + ASSERT_STRUCT_OFFSET(WeaponDef, iFirstRaiseTime, 0x49C); + ASSERT_STRUCT_OFFSET(WeaponDef, iEmptyRaiseTime, 0x4A0); + ASSERT_STRUCT_OFFSET(WeaponDef, iEmptyDropTime, 0x4A4); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintInTime, 0x4A8); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintLoopTime, 0x4AC); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintOutTime, 0x4B0); + ASSERT_STRUCT_OFFSET(WeaponDef, deployTime, 0x4B4); + ASSERT_STRUCT_OFFSET(WeaponDef, breakdownTime, 0x4B8); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionWearTime, 0x4BC); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionWearTimeFadeOutEnd, 0x4C0); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionWearTimePowerUp, 0x4C4); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionRemoveTime, 0x4C8); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionRemoveTimePowerDown, 0x4CC); + ASSERT_STRUCT_OFFSET(WeaponDef, nightVisionRemoveTimeFadeInStart, 0x4D0); + ASSERT_STRUCT_OFFSET(WeaponDef, fuseTime, 0x4D4); + ASSERT_STRUCT_OFFSET(WeaponDef, aiFuseTime, 0x4D8); + ASSERT_STRUCT_OFFSET(WeaponDef, requireLockonToFire, 0x4DC); + ASSERT_STRUCT_OFFSET(WeaponDef, noAdsWhenMagEmpty, 0x4E0); + ASSERT_STRUCT_OFFSET(WeaponDef, avoidDropCleanup, 0x4E4); + ASSERT_STRUCT_OFFSET(WeaponDef, autoAimRange, 0x4E8); + ASSERT_STRUCT_OFFSET(WeaponDef, aimAssistRange, 0x4EC); + ASSERT_STRUCT_OFFSET(WeaponDef, aimAssistRangeAds, 0x4F0); + ASSERT_STRUCT_OFFSET(WeaponDef, mountableWeapon, 0x4F4); + ASSERT_STRUCT_OFFSET(WeaponDef, aimPadding, 0x4F8); + ASSERT_STRUCT_OFFSET(WeaponDef, enemyCrosshairRange, 0x4FC); + ASSERT_STRUCT_OFFSET(WeaponDef, crosshairColorChange, 0x500); + ASSERT_STRUCT_OFFSET(WeaponDef, moveSpeedScale, 0x504); + ASSERT_STRUCT_OFFSET(WeaponDef, adsMoveSpeedScale, 0x508); + ASSERT_STRUCT_OFFSET(WeaponDef, sprintDurationScale, 0x50C); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsZoomFov, 0x510); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsZoomInFrac, 0x514); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsZoomOutFrac, 0x518); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayMaterial, 0x51C); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayMaterialLowRes, 0x520); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayReticle, 0x524); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayInterface, 0x528); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayWidth, 0x52C); + ASSERT_STRUCT_OFFSET(WeaponDef, overlayHeight, 0x530); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsBobFactor, 0x534); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewBobMult, 0x538); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadStandMin, 0x53C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadDuckedMin, 0x540); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadProneMin, 0x544); + ASSERT_STRUCT_OFFSET(WeaponDef, hipSpreadStandMax, 0x548); + ASSERT_STRUCT_OFFSET(WeaponDef, hipSpreadDuckedMax, 0x54C); + ASSERT_STRUCT_OFFSET(WeaponDef, hipSpreadProneMax, 0x550); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadDecayRate, 0x554); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadFireAdd, 0x558); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadTurnAdd, 0x55C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadMoveAdd, 0x560); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadDuckedDecay, 0x564); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipSpreadProneDecay, 0x568); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipReticleSidePos, 0x56C); + ASSERT_STRUCT_OFFSET(WeaponDef, iAdsTransInTime, 0x570); + ASSERT_STRUCT_OFFSET(WeaponDef, iAdsTransOutTime, 0x574); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsIdleAmount, 0x578); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipIdleAmount, 0x57C); + ASSERT_STRUCT_OFFSET(WeaponDef, adsIdleSpeed, 0x580); + ASSERT_STRUCT_OFFSET(WeaponDef, hipIdleSpeed, 0x584); + ASSERT_STRUCT_OFFSET(WeaponDef, fIdleCrouchFactor, 0x588); + ASSERT_STRUCT_OFFSET(WeaponDef, fIdleProneFactor, 0x58C); + ASSERT_STRUCT_OFFSET(WeaponDef, fGunMaxPitch, 0x590); + ASSERT_STRUCT_OFFSET(WeaponDef, fGunMaxYaw, 0x594); + ASSERT_STRUCT_OFFSET(WeaponDef, swayMaxAngle, 0x598); + ASSERT_STRUCT_OFFSET(WeaponDef, swayLerpSpeed, 0x59C); + ASSERT_STRUCT_OFFSET(WeaponDef, swayPitchScale, 0x5A0); + ASSERT_STRUCT_OFFSET(WeaponDef, swayYawScale, 0x5A4); + ASSERT_STRUCT_OFFSET(WeaponDef, swayHorizScale, 0x5A8); + ASSERT_STRUCT_OFFSET(WeaponDef, swayVertScale, 0x5AC); + ASSERT_STRUCT_OFFSET(WeaponDef, swayShellShockScale, 0x5B0); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayMaxAngle, 0x5B4); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayLerpSpeed, 0x5B8); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayPitchScale, 0x5BC); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayYawScale, 0x5C0); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayHorizScale, 0x5C4); + ASSERT_STRUCT_OFFSET(WeaponDef, adsSwayVertScale, 0x5C8); + ASSERT_STRUCT_OFFSET(WeaponDef, bRifleBullet, 0x5CC); + ASSERT_STRUCT_OFFSET(WeaponDef, armorPiercing, 0x5D0); + ASSERT_STRUCT_OFFSET(WeaponDef, bBoltAction, 0x5D4); + ASSERT_STRUCT_OFFSET(WeaponDef, aimDownSight, 0x5D8); + ASSERT_STRUCT_OFFSET(WeaponDef, bRechamberWhileAds, 0x5DC); + ASSERT_STRUCT_OFFSET(WeaponDef, adsViewErrorMin, 0x5E0); + ASSERT_STRUCT_OFFSET(WeaponDef, adsViewErrorMax, 0x5E4); + ASSERT_STRUCT_OFFSET(WeaponDef, bCookOffHold, 0x5E8); + ASSERT_STRUCT_OFFSET(WeaponDef, bClipOnly, 0x5EC); + ASSERT_STRUCT_OFFSET(WeaponDef, canUseInVehicle, 0x5F0); + ASSERT_STRUCT_OFFSET(WeaponDef, noDropsOrRaises, 0x5F4); + ASSERT_STRUCT_OFFSET(WeaponDef, adsFireOnly, 0x5F8); + ASSERT_STRUCT_OFFSET(WeaponDef, cancelAutoHolsterWhenEmpty, 0x5FC); + ASSERT_STRUCT_OFFSET(WeaponDef, suppressAmmoReserveDisplay, 0x600); + ASSERT_STRUCT_OFFSET(WeaponDef, enhanced, 0x604); + ASSERT_STRUCT_OFFSET(WeaponDef, laserSightDuringNightvision, 0x608); + ASSERT_STRUCT_OFFSET(WeaponDef, bayonet, 0x60C); + ASSERT_STRUCT_OFFSET(WeaponDef, killIcon, 0x610); + ASSERT_STRUCT_OFFSET(WeaponDef, killIconRatio, 0x614); + ASSERT_STRUCT_OFFSET(WeaponDef, flipKillIcon, 0x618); + ASSERT_STRUCT_OFFSET(WeaponDef, dpadIcon, 0x61C); + ASSERT_STRUCT_OFFSET(WeaponDef, dpadIconRatio, 0x620); + ASSERT_STRUCT_OFFSET(WeaponDef, bNoPartialReload, 0x624); + ASSERT_STRUCT_OFFSET(WeaponDef, bSegmentedReload, 0x628); + ASSERT_STRUCT_OFFSET(WeaponDef, noADSAutoReload, 0x62C); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadAmmoAdd, 0x630); + ASSERT_STRUCT_OFFSET(WeaponDef, iReloadStartAdd, 0x634); + ASSERT_STRUCT_OFFSET(WeaponDef, szAltWeaponName, 0x638); + ASSERT_STRUCT_OFFSET(WeaponDef, altWeaponIndex, 0x63C); + ASSERT_STRUCT_OFFSET(WeaponDef, iDropAmmoMin, 0x640); + ASSERT_STRUCT_OFFSET(WeaponDef, iDropAmmoMax, 0x644); + ASSERT_STRUCT_OFFSET(WeaponDef, blocksProne, 0x648); + ASSERT_STRUCT_OFFSET(WeaponDef, silenced, 0x64C); + ASSERT_STRUCT_OFFSET(WeaponDef, iExplosionRadius, 0x650); + ASSERT_STRUCT_OFFSET(WeaponDef, iExplosionRadiusMin, 0x654); + ASSERT_STRUCT_OFFSET(WeaponDef, iExplosionInnerDamage, 0x658); + ASSERT_STRUCT_OFFSET(WeaponDef, iExplosionOuterDamage, 0x65C); + ASSERT_STRUCT_OFFSET(WeaponDef, damageConeAngle, 0x660); + ASSERT_STRUCT_OFFSET(WeaponDef, iProjectileSpeed, 0x664); + ASSERT_STRUCT_OFFSET(WeaponDef, iProjectileSpeedUp, 0x668); + ASSERT_STRUCT_OFFSET(WeaponDef, iProjectileSpeedForward, 0x66C); + ASSERT_STRUCT_OFFSET(WeaponDef, iProjectileActivateDist, 0x670); + ASSERT_STRUCT_OFFSET(WeaponDef, projLifetime, 0x674); + ASSERT_STRUCT_OFFSET(WeaponDef, timeToAccelerate, 0x678); + ASSERT_STRUCT_OFFSET(WeaponDef, projectileCurvature, 0x67C); + ASSERT_STRUCT_OFFSET(WeaponDef, projectileModel, 0x680); + ASSERT_STRUCT_OFFSET(WeaponDef, projExplosion, 0x684); + ASSERT_STRUCT_OFFSET(WeaponDef, projExplosionEffect, 0x688); + ASSERT_STRUCT_OFFSET(WeaponDef, projExplosionEffectForceNormalUp, 0x68C); + ASSERT_STRUCT_OFFSET(WeaponDef, projDudEffect, 0x690); + ASSERT_STRUCT_OFFSET(WeaponDef, projExplosionSound, 0x694); + ASSERT_STRUCT_OFFSET(WeaponDef, projDudSound, 0x698); + ASSERT_STRUCT_OFFSET(WeaponDef, mortarShellSound, 0x69C); + ASSERT_STRUCT_OFFSET(WeaponDef, tankShellSound, 0x6A0); + ASSERT_STRUCT_OFFSET(WeaponDef, bProjImpactExplode, 0x6A4); + ASSERT_STRUCT_OFFSET(WeaponDef, stickiness, 0x6A8); + ASSERT_STRUCT_OFFSET(WeaponDef, hasDetonator, 0x6AC); + ASSERT_STRUCT_OFFSET(WeaponDef, timedDetonation, 0x6B0); + ASSERT_STRUCT_OFFSET(WeaponDef, rotate, 0x6B4); + ASSERT_STRUCT_OFFSET(WeaponDef, holdButtonToThrow, 0x6B8); + ASSERT_STRUCT_OFFSET(WeaponDef, freezeMovementWhenFiring, 0x6BC); + ASSERT_STRUCT_OFFSET(WeaponDef, lowAmmoWarningThreshold, 0x6C0); + ASSERT_STRUCT_OFFSET(WeaponDef, parallelBounce, 0x6C4); + ASSERT_STRUCT_OFFSET(WeaponDef, perpendicularBounce, 0x740); + ASSERT_STRUCT_OFFSET(WeaponDef, projTrailEffect, 0x7BC); + ASSERT_STRUCT_OFFSET(WeaponDef, vProjectileColor, 0x7C0); + ASSERT_STRUCT_OFFSET(WeaponDef, guidedMissileType, 0x7CC); + ASSERT_STRUCT_OFFSET(WeaponDef, maxSteeringAccel, 0x7D0); + ASSERT_STRUCT_OFFSET(WeaponDef, projIgnitionDelay, 0x7D4); + ASSERT_STRUCT_OFFSET(WeaponDef, projIgnitionEffect, 0x7D8); + ASSERT_STRUCT_OFFSET(WeaponDef, projIgnitionSound, 0x7DC); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsAimPitch, 0x7E0); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsCrosshairInFrac, 0x7E4); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsCrosshairOutFrac, 0x7E8); + ASSERT_STRUCT_OFFSET(WeaponDef, adsGunKickReducedKickBullets, 0x7EC); + ASSERT_STRUCT_OFFSET(WeaponDef, adsGunKickReducedKickPercent, 0x7F0); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickPitchMin, 0x7F4); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickPitchMax, 0x7F8); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickYawMin, 0x7FC); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickYawMax, 0x800); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickAccel, 0x804); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickSpeedMax, 0x808); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickSpeedDecay, 0x80C); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsGunKickStaticDecay, 0x810); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewKickPitchMin, 0x814); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewKickPitchMax, 0x818); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewKickYawMin, 0x81C); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewKickYawMax, 0x820); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewKickCenterSpeed, 0x824); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewScatterMin, 0x828); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsViewScatterMax, 0x82C); + ASSERT_STRUCT_OFFSET(WeaponDef, fAdsSpread, 0x830); + ASSERT_STRUCT_OFFSET(WeaponDef, hipGunKickReducedKickBullets, 0x834); + ASSERT_STRUCT_OFFSET(WeaponDef, hipGunKickReducedKickPercent, 0x838); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickPitchMin, 0x83C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickPitchMax, 0x840); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickYawMin, 0x844); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickYawMax, 0x848); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickAccel, 0x84C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickSpeedMax, 0x850); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickSpeedDecay, 0x854); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipGunKickStaticDecay, 0x858); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewKickPitchMin, 0x85C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewKickPitchMax, 0x860); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewKickYawMin, 0x864); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewKickYawMax, 0x868); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewKickCenterSpeed, 0x86C); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewScatterMin, 0x870); + ASSERT_STRUCT_OFFSET(WeaponDef, fHipViewScatterMax, 0x874); + ASSERT_STRUCT_OFFSET(WeaponDef, fightDist, 0x878); + ASSERT_STRUCT_OFFSET(WeaponDef, maxDist, 0x87C); + ASSERT_STRUCT_OFFSET(WeaponDef, accuracyGraphName, 0x880); + ASSERT_STRUCT_OFFSET(WeaponDef, accuracyGraphKnots, 0x888); + ASSERT_STRUCT_OFFSET(WeaponDef, originalAccuracyGraphKnots, 0x890); + ASSERT_STRUCT_OFFSET(WeaponDef, accuracyGraphKnotCount, 0x898); + ASSERT_STRUCT_OFFSET(WeaponDef, originalAccuracyGraphKnotCount, 0x8A0); + ASSERT_STRUCT_OFFSET(WeaponDef, iPositionReloadTransTime, 0x8A8); + ASSERT_STRUCT_OFFSET(WeaponDef, leftArc, 0x8AC); + ASSERT_STRUCT_OFFSET(WeaponDef, rightArc, 0x8B0); + ASSERT_STRUCT_OFFSET(WeaponDef, topArc, 0x8B4); + ASSERT_STRUCT_OFFSET(WeaponDef, bottomArc, 0x8B8); + ASSERT_STRUCT_OFFSET(WeaponDef, accuracy, 0x8BC); + ASSERT_STRUCT_OFFSET(WeaponDef, aiSpread, 0x8C0); + ASSERT_STRUCT_OFFSET(WeaponDef, playerSpread, 0x8C4); + ASSERT_STRUCT_OFFSET(WeaponDef, minTurnSpeed, 0x8C8); + ASSERT_STRUCT_OFFSET(WeaponDef, maxTurnSpeed, 0x8D0); + ASSERT_STRUCT_OFFSET(WeaponDef, pitchConvergenceTime, 0x8D8); + ASSERT_STRUCT_OFFSET(WeaponDef, yawConvergenceTime, 0x8DC); + ASSERT_STRUCT_OFFSET(WeaponDef, suppressTime, 0x8E0); + ASSERT_STRUCT_OFFSET(WeaponDef, maxRange, 0x8E4); + ASSERT_STRUCT_OFFSET(WeaponDef, fAnimHorRotateInc, 0x8E8); + ASSERT_STRUCT_OFFSET(WeaponDef, fPlayerPositionDist, 0x8EC); + ASSERT_STRUCT_OFFSET(WeaponDef, szUseHintString, 0x8F0); + ASSERT_STRUCT_OFFSET(WeaponDef, dropHintString, 0x8F4); + ASSERT_STRUCT_OFFSET(WeaponDef, iUseHintStringIndex, 0x8F8); + ASSERT_STRUCT_OFFSET(WeaponDef, dropHintStringIndex, 0x8FC); + ASSERT_STRUCT_OFFSET(WeaponDef, horizViewJitter, 0x900); + ASSERT_STRUCT_OFFSET(WeaponDef, vertViewJitter, 0x904); + ASSERT_STRUCT_OFFSET(WeaponDef, szScript, 0x908); + ASSERT_STRUCT_OFFSET(WeaponDef, fOOPosAnimLength, 0x90C); + ASSERT_STRUCT_OFFSET(WeaponDef, minDamage, 0x914); + ASSERT_STRUCT_OFFSET(WeaponDef, minPlayerDamage, 0x918); + ASSERT_STRUCT_OFFSET(WeaponDef, fMaxDamageRange, 0x91C); + ASSERT_STRUCT_OFFSET(WeaponDef, fMinDamageRange, 0x920); + ASSERT_STRUCT_OFFSET(WeaponDef, destabilizationRateTime, 0x924); + ASSERT_STRUCT_OFFSET(WeaponDef, destabilizationCurvatureMax, 0x928); + ASSERT_STRUCT_OFFSET(WeaponDef, destabilizeDistance, 0x92C); + ASSERT_STRUCT_OFFSET(WeaponDef, locNone, 0x930); + ASSERT_STRUCT_OFFSET(WeaponDef, locHelmet, 0x934); + ASSERT_STRUCT_OFFSET(WeaponDef, locHead, 0x938); + ASSERT_STRUCT_OFFSET(WeaponDef, locNeck, 0x93C); + ASSERT_STRUCT_OFFSET(WeaponDef, locTorsoUpper, 0x940); + ASSERT_STRUCT_OFFSET(WeaponDef, locTorsoLower, 0x944); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightArmUpper, 0x948); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftArmUpper, 0x94C); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightArmLower, 0x950); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftArmLower, 0x954); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightHand, 0x958); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftHand, 0x95C); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightLegUpper, 0x960); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftLegUpper, 0x964); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightLegLower, 0x968); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftLegLower, 0x96C); + ASSERT_STRUCT_OFFSET(WeaponDef, locRightFoot, 0x970); + ASSERT_STRUCT_OFFSET(WeaponDef, locLeftFoot, 0x974); + ASSERT_STRUCT_OFFSET(WeaponDef, locGun, 0x978); + ASSERT_STRUCT_OFFSET(WeaponDef, fireRumble, 0x97C); + ASSERT_STRUCT_OFFSET(WeaponDef, meleeImpactRumble, 0x980); + ASSERT_STRUCT_OFFSET(WeaponDef, adsDofStart, 0x984); + ASSERT_STRUCT_OFFSET(WeaponDef, adsDofEnd, 0x988); + ASSERT_STRUCT_OFFSET(WeaponDef, hipDofStart, 0x98C); + ASSERT_STRUCT_OFFSET(WeaponDef, hipDofEnd, 0x990); + ASSERT_STRUCT_OFFSET(WeaponDef, flameTableFirstPerson, 0x994); + ASSERT_STRUCT_OFFSET(WeaponDef, flameTableThirdPerson, 0x998); + ASSERT_STRUCT_OFFSET(WeaponDef, flameTableFirstPersonPtr, 0x99C); + ASSERT_STRUCT_OFFSET(WeaponDef, flameTableThirdPersonPtr, 0x9A0); + ASSERT_STRUCT_OFFSET(WeaponDef, tagFx_preparationEffect, 0x9A4); + ASSERT_STRUCT_OFFSET(WeaponDef, tagFlash_preparationEffect, 0x9A8); + + struct snd_reverb_patch_t + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + float room; //OFS: 0x20 SIZE: 0x4 + float roomHF; //OFS: 0x24 SIZE: 0x4 + float roomRolloffFactor; //OFS: 0x28 SIZE: 0x4 + float decayTime; //OFS: 0x2C SIZE: 0x4 + float decayHFRatio; //OFS: 0x30 SIZE: 0x4 + float reflections; //OFS: 0x34 SIZE: 0x4 + float reflectionsDelay; //OFS: 0x38 SIZE: 0x4 + float reverb; //OFS: 0x3C SIZE: 0x4 + float reverbDelay; //OFS: 0x40 SIZE: 0x4 + float diffusion; //OFS: 0x44 SIZE: 0x4 + float density; //OFS: 0x48 SIZE: 0x4 + float HFReference; //OFS: 0x4C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_reverb_patch_t, 0x50); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, room, 0x20); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, roomHF, 0x24); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, roomRolloffFactor, 0x28); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, decayTime, 0x2C); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, decayHFRatio, 0x30); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, reflections, 0x34); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, reflectionsDelay, 0x38); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, reverb, 0x3C); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, reverbDelay, 0x40); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, diffusion, 0x44); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, density, 0x48); + ASSERT_STRUCT_OFFSET(snd_reverb_patch_t, HFReference, 0x4C); + + struct snd_bus_info_t + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + float volumeMod; //OFS: 0x20 SIZE: 0x4 + int maxVoices; //OFS: 0x24 SIZE: 0x4 + int restricted; //OFS: 0x28 SIZE: 0x4 + int pausable; //OFS: 0x2C SIZE: 0x4 + int stopOnDeath; //OFS: 0x30 SIZE: 0x4 + int isMusic; //OFS: 0x34 SIZE: 0x4 + snd_category_t category; //OFS: 0x38 SIZE: 0x4 + snd_limit_type_t voiceLimitType; //OFS: 0x3C SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_bus_info_t, 0x40); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, volumeMod, 0x20); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, maxVoices, 0x24); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, restricted, 0x28); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, pausable, 0x2C); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, stopOnDeath, 0x30); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, isMusic, 0x34); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, category, 0x38); + ASSERT_STRUCT_OFFSET(snd_bus_info_t, voiceLimitType, 0x3C); + + struct snd_curve_t + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + int pointCount; //OFS: 0x20 SIZE: 0x4 + float points[8][2]; //OFS: 0x24 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(snd_curve_t, 0x64); + ASSERT_STRUCT_OFFSET(snd_curve_t, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_curve_t, pointCount, 0x20); + ASSERT_STRUCT_OFFSET(snd_curve_t, points, 0x24); + + struct snd_speaker_map + { + int input_channel_count; //OFS: 0x0 SIZE: 0x4 + int output_channel_count; //OFS: 0x4 SIZE: 0x4 + float volumes[16]; //OFS: 0x8 SIZE: 0x40 + }; + ASSERT_STRUCT_SIZE(snd_speaker_map, 0x48); + ASSERT_STRUCT_OFFSET(snd_speaker_map, input_channel_count, 0x0); + ASSERT_STRUCT_OFFSET(snd_speaker_map, output_channel_count, 0x4); + ASSERT_STRUCT_OFFSET(snd_speaker_map, volumes, 0x8); + + struct snd_speaker_map_set + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + snd_speaker_map channelMaps[4]; //OFS: 0x20 SIZE: 0x120 + }; + ASSERT_STRUCT_SIZE(snd_speaker_map_set, 0x140); + ASSERT_STRUCT_OFFSET(snd_speaker_map_set, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_speaker_map_set, channelMaps, 0x20); + + struct snd_master_effect_t + { + char name[32]; //OFS: 0x0 SIZE: 0x20 + float masterRingmod; //OFS: 0x20 SIZE: 0x4 + float reverbRingmod; //OFS: 0x24 SIZE: 0x4 + float masterLPRatio; //OFS: 0x28 SIZE: 0x4 + float masterLPDB; //OFS: 0x2C SIZE: 0x4 + float masterHPRatio; //OFS: 0x30 SIZE: 0x4 + float masterHPDB; //OFS: 0x34 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(snd_master_effect_t, 0x38); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, name, 0x0); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, masterRingmod, 0x20); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, reverbRingmod, 0x24); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, masterLPRatio, 0x28); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, masterLPDB, 0x2C); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, masterHPRatio, 0x30); + ASSERT_STRUCT_OFFSET(snd_master_effect_t, masterHPDB, 0x34); + + struct SndDriverGlobals + { + const char* name; //OFS: 0x0 SIZE: 0x4 + snd_reverb_patch_t reverbPatches[64]; //OFS: 0x4 SIZE: 0x1400 + snd_bus_info_t buses[64]; //OFS: 0x1404 SIZE: 0x1000 + snd_curve_t curves[32]; //OFS: 0x2404 SIZE: 0xC80 + snd_speaker_map_set speakerMaps[32]; //OFS: 0x3084 SIZE: 0x2800 + snd_master_effect_t masterEffects[16]; //OFS: 0x5884 SIZE: 0x380 + }; + ASSERT_STRUCT_SIZE(SndDriverGlobals, 0x5C04); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, name, 0x0); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, reverbPatches, 0x4); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, buses, 0x1404); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, curves, 0x2404); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, speakerMaps, 0x3084); + ASSERT_STRUCT_OFFSET(SndDriverGlobals, masterEffects, 0x5884); + + struct FxImpactEntry + { + FxEffectDef* nonflesh[31]; //OFS: 0x0 SIZE: 0x7C + FxEffectDef* flesh[4]; //OFS: 0x7C SIZE: 0x10 + }; + ASSERT_STRUCT_SIZE(FxImpactEntry, 0x8C); + ASSERT_STRUCT_OFFSET(FxImpactEntry, nonflesh, 0x0); + ASSERT_STRUCT_OFFSET(FxImpactEntry, flesh, 0x7C); + + struct FxImpactTable + { + char* name; //OFS: 0x0 SIZE: 0x4 + FxImpactEntry* table; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(FxImpactTable, 0x8); + ASSERT_STRUCT_OFFSET(FxImpactTable, name, 0x0); + ASSERT_STRUCT_OFFSET(FxImpactTable, table, 0x4); + + struct RawFile + { + char* name; //OFS: 0x0 SIZE: 0x4 + int len; //OFS: 0x4 SIZE: 0x4 + char* buffer; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(RawFile, 0xC); + ASSERT_STRUCT_OFFSET(RawFile, name, 0x0); + ASSERT_STRUCT_OFFSET(RawFile, len, 0x4); + ASSERT_STRUCT_OFFSET(RawFile, buffer, 0x8); + + struct StringTableCell + { + const char * string; //OFS: 0x0 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StringTableCell, 0x4); + ASSERT_STRUCT_OFFSET(StringTableCell, string, 0x0); + + struct StringTable + { + char* name; //OFS: 0x0 SIZE: 0x4 + int columnCount; //OFS: 0x4 SIZE: 0x4 + int rowCount; //OFS: 0x8 SIZE: 0x4 + StringTableCell* values; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(StringTable, 0x10); + ASSERT_STRUCT_OFFSET(StringTable, name, 0x0); + ASSERT_STRUCT_OFFSET(StringTable, columnCount, 0x4); + ASSERT_STRUCT_OFFSET(StringTable, rowCount, 0x8); + ASSERT_STRUCT_OFFSET(StringTable, values, 0xC); + + struct PackIndexHeader + { + unsigned int magic; //OFS: 0x0 SIZE: 0x4 + unsigned int timestamp; //OFS: 0x4 SIZE: 0x4 + unsigned int count; //OFS: 0x8 SIZE: 0x4 + unsigned int alignment; //OFS: 0xC SIZE: 0x4 + unsigned int data_start; //OFS: 0x10 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PackIndexHeader, 0x14); + ASSERT_STRUCT_OFFSET(PackIndexHeader, magic, 0x0); + ASSERT_STRUCT_OFFSET(PackIndexHeader, timestamp, 0x4); + ASSERT_STRUCT_OFFSET(PackIndexHeader, count, 0x8); + ASSERT_STRUCT_OFFSET(PackIndexHeader, alignment, 0xC); + ASSERT_STRUCT_OFFSET(PackIndexHeader, data_start, 0x10); + + struct PackIndexEntry + { + unsigned int hash; //OFS: 0x0 SIZE: 0x4 + unsigned int offset; //OFS: 0x4 SIZE: 0x4 + unsigned int size; //OFS: 0x8 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PackIndexEntry, 0xC); + ASSERT_STRUCT_OFFSET(PackIndexEntry, hash, 0x0); + ASSERT_STRUCT_OFFSET(PackIndexEntry, offset, 0x4); + ASSERT_STRUCT_OFFSET(PackIndexEntry, size, 0x8); + + struct PackIndex + { + char* name; //OFS: 0x0 SIZE: 0x4 + PackIndexHeader header; //OFS: 0x4 SIZE: 0x14 + PackIndexEntry* entries; //OFS: 0x18 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(PackIndex, 0x1C); + ASSERT_STRUCT_OFFSET(PackIndex, name, 0x0); + ASSERT_STRUCT_OFFSET(PackIndex, header, 0x4); + ASSERT_STRUCT_OFFSET(PackIndex, entries, 0x18); + + union XAssetHeader + { + XModelPieces* xmodelPieces; //OFS: 0x0 SIZE: 0x4 + PhysPreset* physPreset; //OFS: 0x1 SIZE: 0x4 + PhysConstraints* physConstraints; //OFS: 0x2 SIZE: 0x4 + DestructibleDef* destructibleDef; //OFS: 0x3 SIZE: 0x4 + XAnimParts* parts; //OFS: 0x4 SIZE: 0x4 + XModel* model; //OFS: 0x5 SIZE: 0x4 + Material* material; //OFS: 0x6 SIZE: 0x4 + MaterialPixelShader* pixelShader; //OFS: 0x7 SIZE: 0x4 + MaterialVertexShader* vertexShader; //OFS: 0x8 SIZE: 0x4 + MaterialTechniqueSet* techniqueSet; //OFS: 0x9 SIZE: 0x4 + GfxImage* image; //OFS: 0xA SIZE: 0x4 + clipMap_t* clipMap; //OFS: 0xB SIZE: 0x4 + ComWorld* comWorld; //OFS: 0xC SIZE: 0x4 + GameWorldSp* gameWorldSp; //OFS: 0xD SIZE: 0x4 + GameWorldMp* gameWorldMp; //OFS: 0xE SIZE: 0x4 + MapEnts* mapEnts; //OFS: 0xF SIZE: 0x4 + GfxWorld* gfxWorld; //OFS: 0x10 SIZE: 0x4 + GfxLightDef* lightDef; //OFS: 0x11 SIZE: 0x4 + Font_s* font; //OFS: 0x12 SIZE: 0x4 + MenuList* menuList; //OFS: 0x13 SIZE: 0x4 + menuDef_t* menu; //OFS: 0x14 SIZE: 0x4 + LocalizeEntry* localize; //OFS: 0x15 SIZE: 0x4 + WeaponDef* weapon; //OFS: 0x16 SIZE: 0x4 + SndDriverGlobals* sndDriverGlobals; //OFS: 0x17 SIZE: 0x4 + const FxEffectDef* fx; //OFS: 0x18 SIZE: 0x4 + FxImpactTable* impactFx; //OFS: 0x19 SIZE: 0x4 + RawFile* rawfile; //OFS: 0x1A SIZE: 0x4 + StringTable* stringTable; //OFS: 0x1B SIZE: 0x4 + PackIndex* packIndex; //OFS: 0x1C SIZE: 0x4 + void* data; //OFS: 0x1D SIZE: 0x4 + }; + + struct XAsset + { + XAssetType type; //OFS: 0x0 SIZE: 0x4 + XAssetHeader header; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAsset, 0x8); + ASSERT_STRUCT_OFFSET(XAsset, type, 0x0); + ASSERT_STRUCT_OFFSET(XAsset, header, 0x4); + + struct XAssetEntry + { + XAsset asset; //OFS: 0x0 SIZE: 0x8 + char zoneIndex; //OFS: 0x8 SIZE: 0x1 + bool inuse; //OFS: 0x9 SIZE: 0x1 + unsigned __int16 nextHash; //OFS: 0xA SIZE: 0x2 + unsigned __int16 nextOverride; //OFS: 0xC SIZE: 0x2 + unsigned __int16 usageFrame; //OFS: 0xE SIZE: 0x2 + }; + ASSERT_STRUCT_SIZE(XAssetEntry, 0x10); + ASSERT_STRUCT_OFFSET(XAssetEntry, asset, 0x0); + ASSERT_STRUCT_OFFSET(XAssetEntry, zoneIndex, 0x8); + ASSERT_STRUCT_OFFSET(XAssetEntry, inuse, 0x9); + ASSERT_STRUCT_OFFSET(XAssetEntry, nextHash, 0xA); + ASSERT_STRUCT_OFFSET(XAssetEntry, nextOverride, 0xC); + ASSERT_STRUCT_OFFSET(XAssetEntry, usageFrame, 0xE); + + union XAssetEntryPoolEntry + { + XAssetEntry entry; //OFS: 0x0 SIZE: 0x10 + XAssetEntryPoolEntry * next; //OFS: 0x1 SIZE: 0x4 + }; + + struct ScriptStringList + { + int count; //OFS: 0x0 SIZE: 0x4 + char ** strings; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(ScriptStringList, 0x8); + ASSERT_STRUCT_OFFSET(ScriptStringList, count, 0x0); + ASSERT_STRUCT_OFFSET(ScriptStringList, strings, 0x4); + + struct XAssetList + { + ScriptStringList stringList; //OFS: 0x0 SIZE: 0x8 + int assetCount; //OFS: 0x8 SIZE: 0x4 + XAsset * assets; //OFS: 0xC SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XAssetList, 0x10); + ASSERT_STRUCT_OFFSET(XAssetList, stringList, 0x0); + ASSERT_STRUCT_OFFSET(XAssetList, assetCount, 0x8); + ASSERT_STRUCT_OFFSET(XAssetList, assets, 0xC); + + struct XZoneInfoInternal + { + char name[64]; + int flags; + }; + ASSERT_STRUCT_SIZE(XZoneInfoInternal, 0x44); + ASSERT_STRUCT_OFFSET(XZoneInfoInternal, name, 0x0); + ASSERT_STRUCT_OFFSET(XZoneInfoInternal, flags, 0x40); + + struct XZoneName + { + char name[64]; //OFS: 0x0 SIZE: 0x40 + int flags; //OFS: 0x40 SIZE: 0x4 + int fileSize; //OFS: 0x44 SIZE: 0x4 + FF_DIR dir; //OFS: 0x48 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XZoneName, 0x4C); + ASSERT_STRUCT_OFFSET(XZoneName, name, 0x0); + ASSERT_STRUCT_OFFSET(XZoneName, flags, 0x40); + ASSERT_STRUCT_OFFSET(XZoneName, fileSize, 0x44); + ASSERT_STRUCT_OFFSET(XZoneName, dir, 0x48); + + struct XBlock + { + char * data; //OFS: 0x0 SIZE: 0x4 + unsigned int size; //OFS: 0x4 SIZE: 0x4 + }; + ASSERT_STRUCT_SIZE(XBlock, 0x8); + ASSERT_STRUCT_OFFSET(XBlock, data, 0x0); + ASSERT_STRUCT_OFFSET(XBlock, size, 0x4); + + struct XZone + { + __int16 index; //OFS: 0x0 SIZE: 0x2 + int flags; //OFS: 0x4 SIZE: 0x4 + int allocType; //OFS: 0x8 SIZE: 0x4 + XBlock blocks[7]; //OFS: 0xC SIZE: 0x38 + }; + ASSERT_STRUCT_SIZE(XZone, 0x44); + ASSERT_STRUCT_OFFSET(XZone, index, 0x0); + ASSERT_STRUCT_OFFSET(XZone, flags, 0x4); + ASSERT_STRUCT_OFFSET(XZone, allocType, 0x8); + ASSERT_STRUCT_OFFSET(XZone, blocks, 0xC); + +#ifdef __cplusplus +} +#endif diff --git a/src/stdinc.hpp b/src/stdinc.hpp index a23c34a..416fcf8 100644 --- a/src/stdinc.hpp +++ b/src/stdinc.hpp @@ -56,8 +56,11 @@ #pragma comment(lib, "Crypt32.lib") #include "utils/hexrays_defs.h" + +#include "game/enums.hpp" #include "game/structs.hpp" #include "game/game.hpp" +#include "game/symbols.hpp" #define printf(__fmt__, ...) \ game::Com_Printf(game::CON_CHANNEL_SERVER, __fmt__, __VA_ARGS__)