(method_handle, args_param)
| 78 | } |
| 79 | |
| 80 | function resend_function(method_handle, args_param) { |
| 81 | const method = new Il2Cpp.Method(new NativePointer(method_handle)); |
| 82 | const nativeFunction = new NativeFunction(method.virtualAddress, method.returnType.fridaAlias, method.fridaSignature); |
| 83 | const args = []; |
| 84 | for (let param in args_param) { |
| 85 | args[args_param[param].index] = parseFloat(args_param[param].value) == 'NaN' ? args_param[param].value : parseFloat(args_param[param].value); |
| 86 | } |
| 87 | if (method.isStatic) { |
| 88 | if (Il2Cpp.unityVersionIsBelow201830) { |
| 89 | const env = Java.vm.tryGetEnv(); |
| 90 | if (args.length == 0) { |
| 91 | nativeFunction(env); |
| 92 | } else { |
| 93 | nativeFunction(env, ...args); |
| 94 | } |
| 95 | } else { |
| 96 | if (args.length == 0) { |
| 97 | nativeFunction(); |
| 98 | } else { |
| 99 | nativeFunction(...args); |
| 100 | } |
| 101 | } |
| 102 | } else { |
| 103 | const env = Java.vm.tryGetEnv(); |
| 104 | if (args.length == 0) { |
| 105 | nativeFunction(env); |
| 106 | } else { |
| 107 | nativeFunction(env, ...args); |
| 108 | } |
| 109 | } |
| 110 | } |
| 111 | |
| 112 | function send_function(method_handle, function_return_value, args_param) { |
| 113 | const method = new Il2Cpp.Method(new NativePointer(method_handle)); |
nothing calls this directly
no outgoing calls
no test coverage detected