Skip to content

Commit

Permalink
fixed #798
Browse files Browse the repository at this point in the history
  • Loading branch information
Perfare committed Jul 6, 2024
1 parent f21d300 commit 8a521b9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
12 changes: 12 additions & 0 deletions Il2CppDumper/Il2Cpp/Il2Cpp.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,18 @@ protected bool AutoPlusInit(ulong codeRegistration, ulong metadataRegistration)
if (Version >= 24.2)
{
pCodeRegistration = MapVATR<Il2CppCodeRegistration>(codeRegistration);
if (Version == 31)
{
if (pCodeRegistration.genericMethodPointersCount > limit)
{
codeRegistration -= PointerSize * 2;
}
else
{
Version = 29;
Console.WriteLine($"Change il2cpp version to: {Version}");
}
}
if (Version == 29)
{
if (pCodeRegistration.genericMethodPointersCount > limit)
Expand Down
4 changes: 0 additions & 4 deletions Il2CppDumper/Utils/SectionHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,6 @@ private ulong FindCodeRegistration2019(List<SearchSection> secs)
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;
Expand Down

0 comments on commit 8a521b9

Please sign in to comment.