vfsfitvnm / frida-il2cpp-bridge

A Frida module to dump, trace or hijack any Il2Cpp application at runtime, without needing the global-metadata.dat file.

Home Page:https://github.com/vfsfitvnm/frida-il2cpp-bridge/wiki

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Call from Il2Cpp.Class with instance argument

commonuserlol opened this issue · comments

I have a method which was found in Il2Cpp.Class (e.g. object.class.methods.find(_ => _.name == "name" && _.isGeneric)!.inflate(klass)). How i can invoke it with 1st argument as instance like .invoke(object) but it throws error, so my temp solution is:

//@ts-ignore
.invokeRaw(object) as Il2Cpp.Object;

.withHolder(object).invoke()

Either is fine 😄

.withHolder(object).invoke()

withHolder is internal so i have to disable linter like with .invokeRaw (ts-ignore)

Okay i just replaced finding generic method to object.method<Il2Cpp.Object>("GetComponent").overload("System.Type").invoke(klass.type.object);