This commit is contained in:
Perfare 2021-11-25 06:59:41 +08:00
parent e50ea93aab
commit f25ad7a612
2 changed files with 9 additions and 1 deletions

View file

@ -283,7 +283,11 @@ namespace Il2CppDumper
public Il2CppType GetIl2CppType(ulong pointer)
{
return typeDic[pointer];
if (!typeDic.TryGetValue(pointer, out var type))
{
return null;
}
return type;
}
public ulong GetMethodPointer(string imageName, Il2CppMethodDefinition methodDef)

View file

@ -275,6 +275,10 @@ namespace Il2CppDumper
if (il2Cpp.Version >= 27)
{
var il2CppType = il2Cpp.GetIl2CppType(genericClass.type);
if (il2CppType == null)
{
return null;
}
return GetTypeDefinitionFromIl2CppType(il2CppType);
}
if (genericClass.typeDefinitionIndex == 4294967295 || genericClass.typeDefinitionIndex == -1)