From ce21abe9c4c58d7c7d986fb01824ab107081ad2f Mon Sep 17 00:00:00 2001 From: F1F7Y <64418963+F1F7Y@users.noreply.github.com> Date: Mon, 2 Sep 2024 17:50:37 +0200 Subject: vscript: Move squirrel types to their respective files (#788) Refactor logic to move Squirrel types to their own respective files and extend existing layouts in the process where applicable. Contains additional smaller fixes. --- .../languages/squirrel_re/squirrel/sqstruct.h | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 primedev/vscript/languages/squirrel_re/squirrel/sqstruct.h (limited to 'primedev/vscript/languages/squirrel_re/squirrel/sqstruct.h') diff --git a/primedev/vscript/languages/squirrel_re/squirrel/sqstruct.h b/primedev/vscript/languages/squirrel_re/squirrel/sqstruct.h new file mode 100644 index 00000000..1e357df8 --- /dev/null +++ b/primedev/vscript/languages/squirrel_re/squirrel/sqstruct.h @@ -0,0 +1,24 @@ +#pragma once + +#include "vscript/languages/squirrel_re/include/squirrel.h" +#include "vscript/languages/squirrel_re/squirrel/sqobject.h" + +struct SQStructDef : public SQCollectable +{ + SQObjectType _nameType; + SQString* _name; + unsigned char gap_38[16]; + SQObjectType _variableNamesType; + SQTable* _variableNames; + unsigned char gap_[32]; +}; +static_assert(sizeof(SQStructDef) == 128); + +// NOTE [Fifty]: Variable sized struct +struct SQStructInstance : public SQCollectable +{ + unsigned int size; + BYTE gap_34[4]; + SQObject data[1]; +}; +static_assert(sizeof(SQStructInstance) == 72); -- cgit v1.2.3