支持v31

This commit is contained in:
Perfare 2024-07-05 17:17:41 +08:00
parent 217f1d4737
commit f21d300861
4 changed files with 8 additions and 1 deletions

View file

@ -52,7 +52,7 @@ namespace Il2CppDumper
{
throw new InvalidDataException("ERROR: Metadata file supplied is not valid metadata file.");
}
if (version < 16 || version > 29)
if (version < 16 || version > 31)
{
throw new NotSupportedException($"ERROR: Metadata file supplied is not a supported version[{version}].");
}

View file

@ -237,6 +237,8 @@ namespace Il2CppDumper
public uint nameIndex;
public int declaringType;
public int returnType;
[Version(Min = 31)]
public int returnParameterToken;
public int parameterStart;
[Version(Max = 24)]
public int customAttributeIndex;

View file

@ -418,6 +418,7 @@ namespace Il2CppDumper
break;
case 29:
case 29.1:
case 31:
sb.Append(HeaderConstants.HeaderV29);
break;
default:

View file

@ -380,6 +380,10 @@ namespace Il2CppDumper
il2Cpp.Position = il2Cpp.MapVATR(refva3 - il2Cpp.PointerSize);
if (il2Cpp.ReadIntPtr() == imageCount)
{
if (il2Cpp.Version >= 31)
{
return refva3 - il2Cpp.PointerSize * 16;
}
if (il2Cpp.Version >= 29)
{
return refva3 - il2Cpp.PointerSize * 14;