You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: LibCpp2IL/BinaryStructures/Il2CppMetadataRegistration.cs
+11-2Lines changed: 11 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -15,8 +15,8 @@ public class Il2CppMetadataRegistration : ReadableClass
15
15
* Regardless of how we do it, the fact of the matter is that the count fields are (as well as the pointers which of course are) in practice [pointer size] bytes before the next field, not always 4,
16
16
* so when calculating the total size of this struct, we need to take that into account.
17
17
*/
18
-
publicstaticintGetStructSize(boolisBinary32Bit)
19
-
=>(NumIntFields+NumPointerFields)*(isBinary32Bit?sizeof(int):sizeof(long));//On 32-bit platforms, all pointers (represented in fields by long/ulong) are 32-bit. If this struct is updated, update the number of fields above.
=>(NumIntFields+NumPointerFields+(metadataMetadataVersion>=106.1f?2:0))*(isBinary32Bit?sizeof(int):sizeof(long));//On 32-bit platforms, all pointers (represented in fields by long/ulong) are 32-bit. If this struct is updated, update the number of fields above.
20
20
21
21
publiclonggenericClassesCount;
22
22
publiculonggenericClasses;
@@ -36,6 +36,9 @@ public static int GetStructSize(bool isBinary32Bit)
36
36
publiculongtypeDefinitionsSizes;
37
37
publiculongmetadataUsagesCount;//this one, and only this one, is defined as size_t. The rest of the counts are int32_t.
0 commit comments