voidOnTriggerEnter2D(Collider2D col) { if (GameStateManager.GameState == GameState.Playing) { if (col.gameObject.tag == "Pipeblank") //pipeblank is an empty gameobject with a collider between the two pipes { GetComponent<AudioSource>().PlayOneShot(ScoredAudioClip); ScoreManagerScript.Score++; } elseif (col.gameObject.tag == "Pipe") { FlappyDies(); } } }
voidOnCollisionEnter2D(Collision2D col) { if (GameStateManager.GameState == GameState.Playing) { if (col.gameObject.tag == "Floor") { FlappyDies(); } } }
functiondump_class(p) { var off = 48 var namespaze = ptr(p).readPointer().readPointer().readCString() var s = ptr(p).add(off).readPointer().readCString() return namespaze + " " + (s) }
functiondump_method(p, soAddr) { var off = 24 var name = ptr(p).add(off).readPointer().readCString() var k = dump_class(ptr(p).add(off + 4).readPointer()); var method_ptr = ptr(p).add(40).readPointer().sub(soAddr) return k + "." + name + " " + method_ptr; }
functionhook_il2cpp() { var libbase = Module.findBaseAddress("libil2cpp.so"); console.log(libbase);
addr = Module.findExportByName("libil2cpp.so", "il2cpp_runtime_invoke"); var il2cpp_runtime_invoke = new NativeFunction(addr, 'pointer', ['pointer', 'pointer', 'pointer', 'pointer']); Interceptor.replace(addr, new NativeCallback(function (mtd, obj, params, exec) {
if (obj != 0x0 && obj != null) { var method = dump_method(mtd, libbase);