Correctly process 64-bit data structures in IL2CPP binaries

This commit is contained in:
Katy Coe
2019-10-23 03:37:01 +02:00
parent 79b62e2566
commit 7e3777dddd
7 changed files with 94 additions and 85 deletions

View File

@@ -27,7 +27,7 @@ namespace Il2CppInspector.Reflection
public Assembly GetAssembly(TypeInfo type) => Assemblies.FirstOrDefault(x => x.DefinedTypes.Contains(type));
// Get a type from its IL2CPP type index
public TypeInfo GetTypeFromIndex(int typeIndex) => Assemblies.SelectMany(x => x.DefinedTypes).FirstOrDefault(x => x.Index == typeIndex);
public TypeInfo GetTypeFromIndex(long typeIndex) => Assemblies.SelectMany(x => x.DefinedTypes).FirstOrDefault(x => x.Index == typeIndex);
// Get or generate a type from its IL2CPP binary type usage reference
// (field, return type, generic type parameter etc.)