File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2424#include " modules/Draw.h"
2525#include " modules/Debug.h"
2626#include " modules/Materials.h"
27+ #include " modules/ScriptDebug.h"
2728#include " modules/camera/FreeCamera.h"
2829
2930#include " cdc/render/PCDeviceManager.h"
@@ -146,6 +147,7 @@ void Hook::RegisterModules()
146147#else
147148 RegisterModule<ScriptLog>();
148149 RegisterModule<Materials>();
150+ RegisterModule<ScriptDebug>();
149151#endif
150152}
151153
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ #include " Symbol.h"
4+
5+ namespace cdc
6+ {
7+ class ScriptType ;
8+ class EnumDecl ;
9+ class StructDecl ;
10+ class StartFunctionInfo ;
11+ class Prototype ;
12+
13+ class DataType
14+ {
15+ public:
16+ enum BaseType
17+ {
18+ DTVOID ,
19+ BOOL ,
20+ INT ,
21+ FLOAT ,
22+ STRING ,
23+ STATE ,
24+ ARRAY ,
25+ DYNARRAY ,
26+ MAP ,
27+ UNKNOWN ,
28+ NATIVE ,
29+ SCRIPT ,
30+ STRUCT ,
31+ STRUCT_REF ,
32+ ENUM ,
33+ NTENUM
34+ };
35+
36+ struct Compound
37+ {
38+ ScriptType* m_script;
39+ DataType* m_subType;
40+ };
41+
42+ unsigned __int32 m_type : 4 ;
43+ unsigned __int32 m_resolved : 1 ;
44+ unsigned __int32 m_compiled : 1 ;
45+ unsigned __int32 m_isGenericArg : 1 ;
46+ unsigned __int32 m_isCompound : 1 ;
47+ unsigned __int32 m_arraySize : 8 ;
48+
49+ Symbol m_userType;
50+
51+ union {
52+ DataType* m_subType;
53+ EnumDecl* m_enum;
54+ StructDecl* m_struct;
55+ ScriptType* m_script;
56+ Compound* m_compound;
57+ };
58+ };
59+ }
Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ namespace cdc
88
99 class NativeScriptType : RCObject
1010 {
11+ public:
1112 const char * m_package;
1213 const char * m_name;
1314 int field_10;
Original file line number Diff line number Diff line change 1+ #include " ScriptManager.h"
2+
3+ cdc::ScriptManager* cdc::ScriptManager::GetInstance ()
4+ {
5+ return *(ScriptManager**)0xCC4F5C ;
6+ }
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ #include " cdc/sys/RCObject.h"
4+ #include " cdc/sys/HashSet.h"
5+ #include " ScriptObject.h"
6+
7+ namespace cdc
8+ {
9+ class ScriptManager : RCObject
10+ {
11+ public:
12+ int field_8;
13+ int field_C;
14+ int field_10;
15+ int field_14;
16+ int field_18;
17+ int field_1C;
18+ int field_20;
19+ int field_24;
20+ int field_28;
21+ int field_2C;
22+ int field_30;
23+ int field_34;
24+ int field_38;
25+ int field_3C;
26+ int field_40;
27+ int field_44;
28+ HashSet<ScriptObject*> m_objects;
29+ int field_4C;
30+ int field_50;
31+ int field_54;
32+ int field_58;
33+ int field_5C;
34+
35+ static ScriptManager* GetInstance ();
36+ };
37+ }
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ #include " ScriptType.h"
4+
5+ namespace cdc
6+ {
7+ class ScriptObject
8+ {
9+ public:
10+ int field_0;
11+ int field_4;
12+ cdc::ScriptType* m_scriptType;
13+ char * m_instance;
14+ int field_10;
15+ int field_14;
16+ char m_updatingSequences;
17+ char field_19;
18+ __int16 field_1A;
19+ };
20+ }
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ namespace cdc
4+ {
5+ class ScriptSymbol
6+ {
7+ public:
8+ const char * m_string;
9+ };
10+ }
Original file line number Diff line number Diff line change 11#pragma once
22
33#include " cdc/sys/RCObject.h"
4+ #include " cdc/sys/SArray.h"
45#include " NativeScriptType.h"
6+ #include " DataType.h"
57#include " ScriptName.h"
68
79namespace cdc
810{
9- class ScriptType ;
11+ class DataMember
12+ {
13+ public:
14+ DataType m_type;
15+ unsigned __int16 m_offset;
16+ Symbol m_name;
17+ int m_init;
18+ };
1019
1120 class ScriptTypeStreamData
1221 {
@@ -20,6 +29,18 @@ namespace cdc
2029 ScriptType* m_superScriptType;
2130 unsigned __int16 m_size;
2231 unsigned __int16 m_align;
32+
33+ SArray<ScriptName> m_states; // 20
34+ SArray<EnumDecl> m_enums; // 24
35+ SArray<StructDecl> m_structs; // 28
36+ SArray<DataMember> m_members; // 2C
37+ SArray<StartFunctionInfo> m_startFunctionList; // 30
38+ SArray<Prototype> m_prototypes; // 34
39+ int field_38; // 38
40+ int field_3C; // 3C
41+ int field_40; // 40
42+ int field_44; // 44
43+ SArray<ScriptType*> m_dependencies; // 48
2344 };
2445
2546 class ScriptType : RCObject
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ #include < utility>
4+
5+ #include " Array.h"
6+
7+ namespace cdc
8+ {
9+ template <typename K, typename V>
10+ class HashTable
11+ {
12+ public:
13+ class Node
14+ {
15+ public:
16+ Node* m_next;
17+ std::pair<K, V> m_data;
18+ };
19+
20+ cdc::Array<Node*> m_buckets;
21+ unsigned int m_size;
22+ };
23+ }
Original file line number Diff line number Diff line change 11#pragma once
22
3- #include < utility>
4-
5- #include " Array.h"
3+ #include " Hash.h"
64
75namespace cdc
86{
97 template <typename K, typename V>
10- class HashTable
8+ class HashMap : public HashTable <K, V>
119 {
12- public:
13- class Node
14- {
15- public:
16- Node* m_next;
17- std::pair<K, V> m_data;
18- };
19-
20- cdc::Array<Node*> m_buckets;
21- unsigned int m_size;
2210 };
2311}
You can’t perform that action at this time.
0 commit comments