Are you passing the GlobalVariables.instance address itself as argument #1?
The method appears to take 4 arguments, strangely.
And since the third argument is "r8d", I have to assume that's the System.Int32.
So "rcx" must be the GlobalVariables object and "rdx" must be the System.String.
No clue what "r9" is.
Code: Select all
GlobalVariables.SetVariable - 4C 89 4C 24 20 - mov [rsp+20],r9
GameAssembly.dll+23D7525 - 44 89 44 24 18 - mov [rsp+18],r8d
GameAssembly.dll+23D752A - 48 89 54 24 10 - mov [rsp+10],rdx
GameAssembly.dll+23D752F - 48 89 4C 24 08 - mov [rsp+08],rcx
By the way, I just started reading up on the il2cpp stuff because of your comment. Thanks
I got it all working through Lua. Just make sure you're calling the correct GlobalVariables.SetVariable.
Code: Select all
local method = 0x7FFE3C3271B0 -- getAddress("GlobalVariables.SetVariable")
local this = getAddress("[GlobalVariables.instance]")
local object = executeCodeEx(0, nil, getAddress("il2cpp_string_new"), "G_Reputation_PatriarchsMarshals")
executeCodeEx(0, nil, method, this, object, 10, 0)