├── .gitignore
├── README.md
├── app
├── .gitignore
├── build.gradle
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── cpp
│ ├── CMakeLists.txt
│ ├── Includes
│ │ ├── il2cpp-tabledefs.h
│ │ ├── il2cpp_dump.cpp
│ │ ├── il2cpp_dump.h
│ │ ├── il2cppapi
│ │ │ ├── 2017.1.0f3
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2017.1.3f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2017.2.0f3
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2017.2.1f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2018.1.0f2
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2018.2.0f2
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2018.3.0f2
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2018.3.8f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2019.1.0f2
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2019.3.0f6
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 2019.3.7f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.0f4
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.2f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.3f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.5f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.6f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.3.7f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.4.0f3
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.4.1f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.4.4f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.5.0f3
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ ├── 5.5.1f1
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ │ └── 5.6.0f3
│ │ │ │ ├── il2cpp-api-functions.h
│ │ │ │ └── il2cpp-class.h
│ │ └── log.h
│ └── native-lib.cpp
│ ├── java
│ └── com
│ │ └── il2cpp
│ │ └── dumper
│ │ └── MainActivity.kt
│ └── res
│ ├── drawable-v24
│ └── ic_launcher_foreground.xml
│ ├── drawable
│ └── ic_launcher_background.xml
│ ├── layout
│ └── activity_main.xml
│ ├── mipmap-anydpi-v26
│ ├── ic_launcher.xml
│ └── ic_launcher_round.xml
│ ├── mipmap-hdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-mdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xxhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xxxhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ └── values
│ ├── colors.xml
│ ├── strings.xml
│ └── themes.xml
├── build.gradle
├── gradle.properties
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
└── settings.gradle
/.gitignore:
--------------------------------------------------------------------------------
1 | *.iml
2 | .gradle
3 | /local.properties
4 | /.idea/caches
5 | /.idea/libraries
6 | /.idea/modules.xml
7 | /.idea/workspace.xml
8 | /.idea/navEditor.xml
9 | /.idea/assetWizardSettings.xml
10 | .DS_Store
11 | /build
12 | /captures
13 | .externalNativeBuild
14 | .cxx
15 | local.properties
16 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Auto-Il2cppDumper
2 | This is for helping you get dump.cs from Il2cpp game
3 | hope this will help you >::<
4 |
5 | # Important
6 | This project is modifying version of [Riru-Il2cppDumper](https://github.com/Perfare/Riru-Il2CppDumper)
7 | Credit : [Perfare](https://github.com/Perfare)
8 |
9 | # Usage
10 | - build with Android Studio
11 | - decompile the game
12 | - copy result libnative.so into the decompiled folder apk
13 | - search the main activity of the game
14 | - put this on onCreate function
15 | ```smali
16 | const-string v0, "native-lib"
17 |
18 | invoke-static {v0}, Ljava/lang/System;->loadLibrary(Ljava/lang/String;)V
19 | ```
20 |
21 | - re-compile and run it
22 | - wait 10-30 seconds
23 | - once the dump complete it will auto generate dump.cs in /sdcard/Download
24 |
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | plugins {
2 | id 'com.android.application'
3 | id 'kotlin-android'
4 | }
5 |
6 | android {
7 | compileSdkVersion 30
8 | buildToolsVersion "30.0.3"
9 |
10 | defaultConfig {
11 | applicationId "com.il2cpp.dumper"
12 | minSdkVersion 16
13 | targetSdkVersion 30
14 | versionCode 1
15 | versionName "1.0"
16 |
17 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
18 | externalNativeBuild {
19 | cmake {
20 | cppFlags ""
21 | }
22 | }
23 | }
24 |
25 | buildTypes {
26 | release {
27 | minifyEnabled false
28 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
29 | }
30 | }
31 | externalNativeBuild {
32 | cmake {
33 | path "src/main/cpp/CMakeLists.txt"
34 | version "3.10.2"
35 | }
36 | }
37 | compileOptions {
38 | sourceCompatibility JavaVersion.VERSION_1_8
39 | targetCompatibility JavaVersion.VERSION_1_8
40 | }
41 | kotlinOptions {
42 | jvmTarget = '1.8'
43 | }
44 | }
45 |
46 | dependencies {
47 | implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
48 | implementation 'androidx.core:core-ktx:1.3.2'
49 | }
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/app/src/main/cpp/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.10.2)
2 |
3 | project("Auto-Il2cppDumper")
4 |
5 | add_library(
6 | native-lib
7 | SHARED
8 | native-lib.cpp
9 | Includes/il2cpp_dump.cpp)
10 |
11 | find_library(log-lib log)
12 | target_link_libraries(native-lib ${log-lib})
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cpp-tabledefs.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | /*
4 | * Field Attributes (21.1.5).
5 | */
6 |
7 | #define FIELD_ATTRIBUTE_FIELD_ACCESS_MASK 0x0007
8 | #define FIELD_ATTRIBUTE_COMPILER_CONTROLLED 0x0000
9 | #define FIELD_ATTRIBUTE_PRIVATE 0x0001
10 | #define FIELD_ATTRIBUTE_FAM_AND_ASSEM 0x0002
11 | #define FIELD_ATTRIBUTE_ASSEMBLY 0x0003
12 | #define FIELD_ATTRIBUTE_FAMILY 0x0004
13 | #define FIELD_ATTRIBUTE_FAM_OR_ASSEM 0x0005
14 | #define FIELD_ATTRIBUTE_PUBLIC 0x0006
15 |
16 | #define FIELD_ATTRIBUTE_STATIC 0x0010
17 | #define FIELD_ATTRIBUTE_INIT_ONLY 0x0020
18 | #define FIELD_ATTRIBUTE_LITERAL 0x0040
19 | #define FIELD_ATTRIBUTE_NOT_SERIALIZED 0x0080
20 | #define FIELD_ATTRIBUTE_SPECIAL_NAME 0x0200
21 | #define FIELD_ATTRIBUTE_PINVOKE_IMPL 0x2000
22 |
23 | /* For runtime use only */
24 | #define FIELD_ATTRIBUTE_RESERVED_MASK 0x9500
25 | #define FIELD_ATTRIBUTE_RT_SPECIAL_NAME 0x0400
26 | #define FIELD_ATTRIBUTE_HAS_FIELD_MARSHAL 0x1000
27 | #define FIELD_ATTRIBUTE_HAS_DEFAULT 0x8000
28 | #define FIELD_ATTRIBUTE_HAS_FIELD_RVA 0x0100
29 |
30 | /*
31 | * Method Attributes (22.1.9)
32 | */
33 |
34 | #define METHOD_IMPL_ATTRIBUTE_CODE_TYPE_MASK 0x0003
35 | #define METHOD_IMPL_ATTRIBUTE_IL 0x0000
36 | #define METHOD_IMPL_ATTRIBUTE_NATIVE 0x0001
37 | #define METHOD_IMPL_ATTRIBUTE_OPTIL 0x0002
38 | #define METHOD_IMPL_ATTRIBUTE_RUNTIME 0x0003
39 |
40 | #define METHOD_IMPL_ATTRIBUTE_MANAGED_MASK 0x0004
41 | #define METHOD_IMPL_ATTRIBUTE_UNMANAGED 0x0004
42 | #define METHOD_IMPL_ATTRIBUTE_MANAGED 0x0000
43 |
44 | #define METHOD_IMPL_ATTRIBUTE_FORWARD_REF 0x0010
45 | #define METHOD_IMPL_ATTRIBUTE_PRESERVE_SIG 0x0080
46 | #define METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL 0x1000
47 | #define METHOD_IMPL_ATTRIBUTE_SYNCHRONIZED 0x0020
48 | #define METHOD_IMPL_ATTRIBUTE_NOINLINING 0x0008
49 | #define METHOD_IMPL_ATTRIBUTE_MAX_METHOD_IMPL_VAL 0xffff
50 |
51 | #define METHOD_ATTRIBUTE_MEMBER_ACCESS_MASK 0x0007
52 | #define METHOD_ATTRIBUTE_COMPILER_CONTROLLED 0x0000
53 | #define METHOD_ATTRIBUTE_PRIVATE 0x0001
54 | #define METHOD_ATTRIBUTE_FAM_AND_ASSEM 0x0002
55 | #define METHOD_ATTRIBUTE_ASSEM 0x0003
56 | #define METHOD_ATTRIBUTE_FAMILY 0x0004
57 | #define METHOD_ATTRIBUTE_FAM_OR_ASSEM 0x0005
58 | #define METHOD_ATTRIBUTE_PUBLIC 0x0006
59 |
60 | #define METHOD_ATTRIBUTE_STATIC 0x0010
61 | #define METHOD_ATTRIBUTE_FINAL 0x0020
62 | #define METHOD_ATTRIBUTE_VIRTUAL 0x0040
63 | #define METHOD_ATTRIBUTE_HIDE_BY_SIG 0x0080
64 |
65 | #define METHOD_ATTRIBUTE_VTABLE_LAYOUT_MASK 0x0100
66 | #define METHOD_ATTRIBUTE_REUSE_SLOT 0x0000
67 | #define METHOD_ATTRIBUTE_NEW_SLOT 0x0100
68 |
69 | #define METHOD_ATTRIBUTE_STRICT 0x0200
70 | #define METHOD_ATTRIBUTE_ABSTRACT 0x0400
71 | #define METHOD_ATTRIBUTE_SPECIAL_NAME 0x0800
72 |
73 | #define METHOD_ATTRIBUTE_PINVOKE_IMPL 0x2000
74 | #define METHOD_ATTRIBUTE_UNMANAGED_EXPORT 0x0008
75 |
76 | /*
77 | * For runtime use only
78 | */
79 | #define METHOD_ATTRIBUTE_RESERVED_MASK 0xd000
80 | #define METHOD_ATTRIBUTE_RT_SPECIAL_NAME 0x1000
81 | #define METHOD_ATTRIBUTE_HAS_SECURITY 0x4000
82 | #define METHOD_ATTRIBUTE_REQUIRE_SEC_OBJECT 0x8000
83 |
84 | /*
85 | * Type Attributes (21.1.13).
86 | */
87 | #define TYPE_ATTRIBUTE_VISIBILITY_MASK 0x00000007
88 | #define TYPE_ATTRIBUTE_NOT_PUBLIC 0x00000000
89 | #define TYPE_ATTRIBUTE_PUBLIC 0x00000001
90 | #define TYPE_ATTRIBUTE_NESTED_PUBLIC 0x00000002
91 | #define TYPE_ATTRIBUTE_NESTED_PRIVATE 0x00000003
92 | #define TYPE_ATTRIBUTE_NESTED_FAMILY 0x00000004
93 | #define TYPE_ATTRIBUTE_NESTED_ASSEMBLY 0x00000005
94 | #define TYPE_ATTRIBUTE_NESTED_FAM_AND_ASSEM 0x00000006
95 | #define TYPE_ATTRIBUTE_NESTED_FAM_OR_ASSEM 0x00000007
96 |
97 | #define TYPE_ATTRIBUTE_LAYOUT_MASK 0x00000018
98 | #define TYPE_ATTRIBUTE_AUTO_LAYOUT 0x00000000
99 | #define TYPE_ATTRIBUTE_SEQUENTIAL_LAYOUT 0x00000008
100 | #define TYPE_ATTRIBUTE_EXPLICIT_LAYOUT 0x00000010
101 |
102 | #define TYPE_ATTRIBUTE_CLASS_SEMANTIC_MASK 0x00000020
103 | #define TYPE_ATTRIBUTE_CLASS 0x00000000
104 | #define TYPE_ATTRIBUTE_INTERFACE 0x00000020
105 |
106 | #define TYPE_ATTRIBUTE_ABSTRACT 0x00000080
107 | #define TYPE_ATTRIBUTE_SEALED 0x00000100
108 | #define TYPE_ATTRIBUTE_SPECIAL_NAME 0x00000400
109 |
110 | #define TYPE_ATTRIBUTE_IMPORT 0x00001000
111 | #define TYPE_ATTRIBUTE_SERIALIZABLE 0x00002000
112 |
113 | #define TYPE_ATTRIBUTE_STRING_FORMAT_MASK 0x00030000
114 | #define TYPE_ATTRIBUTE_ANSI_CLASS 0x00000000
115 | #define TYPE_ATTRIBUTE_UNICODE_CLASS 0x00010000
116 | #define TYPE_ATTRIBUTE_AUTO_CLASS 0x00020000
117 |
118 | #define TYPE_ATTRIBUTE_BEFORE_FIELD_INIT 0x00100000
119 | #define TYPE_ATTRIBUTE_FORWARDER 0x00200000
120 |
121 | #define TYPE_ATTRIBUTE_RESERVED_MASK 0x00040800
122 | #define TYPE_ATTRIBUTE_RT_SPECIAL_NAME 0x00000800
123 | #define TYPE_ATTRIBUTE_HAS_SECURITY 0x00040000
124 |
125 | /*
126 | * Flags for Params (22.1.12)
127 | */
128 | #define PARAM_ATTRIBUTE_IN 0x0001
129 | #define PARAM_ATTRIBUTE_OUT 0x0002
130 | #define PARAM_ATTRIBUTE_OPTIONAL 0x0010
131 | #define PARAM_ATTRIBUTE_RESERVED_MASK 0xf000
132 | #define PARAM_ATTRIBUTE_HAS_DEFAULT 0x1000
133 | #define PARAM_ATTRIBUTE_HAS_FIELD_MARSHAL 0x2000
134 | #define PARAM_ATTRIBUTE_UNUSED 0xcfe0
135 |
136 | // Flags for Generic Parameters (II.23.1.7)
137 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_NON_VARIANT 0x00
138 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_COVARIANT 0x01
139 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_CONTRAVARIANT 0x02
140 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_VARIANCE_MASK 0x03
141 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_REFERENCE_TYPE_CONSTRAINT 0x04
142 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_NOT_NULLABLE_VALUE_TYPE_CONSTRAINT 0x08
143 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_DEFAULT_CONSTRUCTOR_CONSTRAINT 0x10
144 | #define IL2CPP_GENERIC_PARAMETER_ATTRIBUTE_SPECIAL_CONSTRAINT_MASK 0x1C
145 |
146 | /**
147 | * 21.5 AssemblyRefs
148 | */
149 | #define ASSEMBLYREF_FULL_PUBLIC_KEY_FLAG 0x00000001
150 | #define ASSEMBLYREF_RETARGETABLE_FLAG 0x00000100
151 | #define ASSEMBLYREF_ENABLEJITCOMPILE_TRACKING_FLAG 0x00008000
152 | #define ASSEMBLYREF_DISABLEJITCOMPILE_OPTIMIZER_FLAG 0x00004000
153 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cpp_dump.cpp:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Perfare on 2020/7/4.
3 | //
4 |
5 | #include "il2cpp_dump.h"
6 | #include
7 | #include
8 | #include
9 | #include
10 | #include
11 | #include
12 | #include
13 | #include
14 | #include "log.h"
15 | #include "il2cpp-tabledefs.h"
16 | #include IL2CPPCLASS
17 |
18 | #define DO_API(r, n, p) r (*n) p
19 |
20 | #include IL2CPPAPI
21 |
22 | #undef DO_API
23 |
24 | static void *il2cpp_handle = nullptr;
25 | static uint64_t il2cpp_base = 0;
26 |
27 | void init_il2cpp_api() {
28 | #define DO_API(r, n, p) n = (r (*) p)dlsym(il2cpp_handle, #n)
29 |
30 | #include IL2CPPAPI
31 |
32 | #undef DO_API
33 | }
34 |
35 | uint64_t get_module_base(const char *module_name) {
36 | uint64_t addr = 0;
37 | char line[1024];
38 | uint64_t start = 0;
39 | uint64_t end = 0;
40 | char flags[5];
41 | char path[PATH_MAX];
42 |
43 | FILE *fp = fopen("/proc/self/maps", "r");
44 | if (fp != nullptr) {
45 | while (fgets(line, sizeof(line), fp)) {
46 | strcpy(path, "");
47 | sscanf(line, "%" PRIx64"-%" PRIx64" %s %*" PRIx64" %*x:%*x %*u %s\n", &start, &end,
48 | flags, path);
49 | if (strstr(path, module_name)) {
50 | addr = start;
51 | break;
52 | }
53 | }
54 | fclose(fp);
55 | }
56 | return addr;
57 | }
58 |
59 | std::string get_method_modifier(uint16_t flags) {
60 | std::stringstream outPut;
61 | auto access = flags & METHOD_ATTRIBUTE_MEMBER_ACCESS_MASK;
62 | switch (access) {
63 | case METHOD_ATTRIBUTE_PRIVATE:
64 | outPut << "private ";
65 | break;
66 | case METHOD_ATTRIBUTE_PUBLIC:
67 | outPut << "public ";
68 | break;
69 | case METHOD_ATTRIBUTE_FAMILY:
70 | outPut << "protected ";
71 | break;
72 | case METHOD_ATTRIBUTE_ASSEM:
73 | case METHOD_ATTRIBUTE_FAM_AND_ASSEM:
74 | outPut << "internal ";
75 | break;
76 | case METHOD_ATTRIBUTE_FAM_OR_ASSEM:
77 | outPut << "protected internal ";
78 | break;
79 | }
80 | if (flags & METHOD_ATTRIBUTE_STATIC) {
81 | outPut << "static ";
82 | }
83 | if (flags & METHOD_ATTRIBUTE_ABSTRACT) {
84 | outPut << "abstract ";
85 | if ((flags & METHOD_ATTRIBUTE_VTABLE_LAYOUT_MASK) == METHOD_ATTRIBUTE_REUSE_SLOT) {
86 | outPut << "override ";
87 | }
88 | } else if (flags & METHOD_ATTRIBUTE_FINAL) {
89 | if ((flags & METHOD_ATTRIBUTE_VTABLE_LAYOUT_MASK) == METHOD_ATTRIBUTE_REUSE_SLOT) {
90 | outPut << "sealed override ";
91 | }
92 | } else if (flags & METHOD_ATTRIBUTE_VIRTUAL) {
93 | if ((flags & METHOD_ATTRIBUTE_VTABLE_LAYOUT_MASK) == METHOD_ATTRIBUTE_NEW_SLOT) {
94 | outPut << "virtual ";
95 | } else {
96 | outPut << "override ";
97 | }
98 | }
99 | if (flags & METHOD_ATTRIBUTE_PINVOKE_IMPL) {
100 | outPut << "extern ";
101 | }
102 | return outPut.str();
103 | }
104 |
105 | std::string dump_method(Il2CppClass *klass) {
106 | std::stringstream outPut;
107 | if (klass->method_count > 0) {
108 | outPut << "\n\t// Methods\n";
109 | void *iter = nullptr;
110 | while (auto method = il2cpp_class_get_methods(klass, &iter)) {
111 | //TODO attribute
112 | if (method->methodPointer) {
113 | outPut << "\t// RVA: 0x";
114 | outPut << std::hex << (uint64_t) method->methodPointer - il2cpp_base;
115 | outPut << " VA: 0x";
116 | outPut << std::hex << (uint64_t) method->methodPointer;
117 | } else {
118 | outPut << "\t// RVA: 0x VA: 0x0";
119 | }
120 | if (method->slot != 65535) {
121 | outPut << " Slot: " << std::dec << method->slot;
122 | }
123 | outPut << "\n\t";
124 | outPut << get_method_modifier(method->flags);
125 | //TODO genericContainerIndex
126 | auto return_type = method->return_type;
127 | if (return_type->byref) {
128 | outPut << "ref ";
129 | }
130 | auto return_class = il2cpp_class_from_type(return_type);
131 | outPut << return_class->name << " " << method->name << "(";
132 | for (int i = 0; i < method->parameters_count; ++i) {
133 | auto parameters = method->parameters[i];
134 | auto parameter_type = parameters.parameter_type;
135 | auto attrs = parameter_type->attrs;
136 | if (parameter_type->byref) {
137 | if (attrs & PARAM_ATTRIBUTE_OUT && !(attrs & PARAM_ATTRIBUTE_IN)) {
138 | outPut << "out ";
139 | } else if (attrs & PARAM_ATTRIBUTE_IN && !(attrs & PARAM_ATTRIBUTE_OUT)) {
140 | outPut << "in ";
141 | } else {
142 | outPut << "ref ";
143 | }
144 | } else {
145 | if (attrs & PARAM_ATTRIBUTE_IN) {
146 | outPut << "[In] ";
147 | }
148 | if (attrs & PARAM_ATTRIBUTE_OUT) {
149 | outPut << "[Out] ";
150 | }
151 | }
152 | auto parameter_class = il2cpp_class_from_type(parameter_type);
153 | outPut << parameter_class->name << " " << parameters.name;
154 | outPut << ", ";
155 | }
156 | if (method->parameters_count > 0) {
157 | outPut.seekp(-2, outPut.cur);
158 | }
159 | outPut << ") { }\n";
160 | //TODO GenericInstMethod
161 | }
162 | }
163 | return outPut.str();
164 | }
165 |
166 | std::string dump_property(Il2CppClass *klass) {
167 | std::stringstream outPut;
168 | if (klass->property_count > 0) {
169 | outPut << "\n\t// Properties\n";
170 | void *iter = nullptr;
171 | while (auto prop = il2cpp_class_get_properties(klass, &iter)) {
172 | //TODO attribute
173 | outPut << "\t";
174 | Il2CppClass *prop_class = nullptr;
175 | if (prop->get) {
176 | outPut << get_method_modifier(prop->get->flags);
177 | prop_class = il2cpp_class_from_type(prop->get->return_type);
178 | } else if (prop->set) {
179 | outPut << get_method_modifier(prop->set->flags);
180 | prop_class = il2cpp_class_from_type(prop->set->parameters[0].parameter_type);
181 | }
182 | outPut << prop_class->name << " " << prop->name << " { ";
183 | if (prop->get) {
184 | outPut << "get; ";
185 | }
186 | if (prop->set) {
187 | outPut << "set; ";
188 | }
189 | outPut << "}\n";
190 | }
191 | }
192 | return outPut.str();
193 | }
194 |
195 | std::string dump_field(Il2CppClass *klass) {
196 | std::stringstream outPut;
197 | if (klass->field_count > 0) {
198 | outPut << "\n\t// Fields\n";
199 | void *iter = nullptr;
200 | while (auto field = il2cpp_class_get_fields(klass, &iter)) {
201 | //TODO attribute
202 | outPut << "\t";
203 | auto attrs = field->type->attrs;
204 | auto access = attrs & FIELD_ATTRIBUTE_FIELD_ACCESS_MASK;
205 | switch (access) {
206 | case FIELD_ATTRIBUTE_PRIVATE:
207 | outPut << "private ";
208 | break;
209 | case FIELD_ATTRIBUTE_PUBLIC:
210 | outPut << "public ";
211 | break;
212 | case FIELD_ATTRIBUTE_FAMILY:
213 | outPut << "protected ";
214 | break;
215 | case FIELD_ATTRIBUTE_ASSEMBLY:
216 | case FIELD_ATTRIBUTE_FAM_AND_ASSEM:
217 | outPut << "internal ";
218 | break;
219 | case FIELD_ATTRIBUTE_FAM_OR_ASSEM:
220 | outPut << "protected internal ";
221 | break;
222 | }
223 | if (attrs & FIELD_ATTRIBUTE_LITERAL) {
224 | outPut << "const ";
225 | } else {
226 | if (attrs & FIELD_ATTRIBUTE_STATIC) {
227 | outPut << "static ";
228 | }
229 | if (attrs & FIELD_ATTRIBUTE_INIT_ONLY) {
230 | outPut << "readonly ";
231 | }
232 | }
233 | auto field_class = il2cpp_class_from_type(field->type);
234 | outPut << field_class->name << " " << field->name;
235 | outPut << "; // 0x" << std::hex << field->offset << "\n";
236 | }
237 | }
238 | return outPut.str();
239 | }
240 |
241 | std::string dump_type(const Il2CppType *type) {
242 | std::stringstream outPut;
243 | auto *klass = il2cpp_class_from_type(type);
244 | outPut << "\n// Namespace: " << klass->namespaze << "\n";
245 | auto flags = klass->flags;
246 | if (flags & TYPE_ATTRIBUTE_SERIALIZABLE) {
247 | outPut << "[Serializable]\n";
248 | }
249 | //TODO attribute
250 | auto visibility = flags & TYPE_ATTRIBUTE_VISIBILITY_MASK;
251 | switch (visibility) {
252 | case TYPE_ATTRIBUTE_PUBLIC:
253 | case TYPE_ATTRIBUTE_NESTED_PUBLIC:
254 | outPut << "public ";
255 | break;
256 | case TYPE_ATTRIBUTE_NOT_PUBLIC:
257 | case TYPE_ATTRIBUTE_NESTED_FAM_AND_ASSEM:
258 | case TYPE_ATTRIBUTE_NESTED_ASSEMBLY:
259 | outPut << "internal ";
260 | break;
261 | case TYPE_ATTRIBUTE_NESTED_PRIVATE:
262 | outPut << "private ";
263 | break;
264 | case TYPE_ATTRIBUTE_NESTED_FAMILY:
265 | outPut << "protected ";
266 | break;
267 | case TYPE_ATTRIBUTE_NESTED_FAM_OR_ASSEM:
268 | outPut << "protected internal ";
269 | break;
270 | }
271 | if (flags & TYPE_ATTRIBUTE_ABSTRACT && flags & TYPE_ATTRIBUTE_SEALED) {
272 | outPut << "static ";
273 | } else if (!(flags & TYPE_ATTRIBUTE_INTERFACE) && flags & TYPE_ATTRIBUTE_ABSTRACT) {
274 | outPut << "abstract ";
275 | } else if (!klass->valuetype && !klass->enumtype && flags & TYPE_ATTRIBUTE_SEALED) {
276 | outPut << "sealed ";
277 | }
278 | if (flags & TYPE_ATTRIBUTE_INTERFACE) {
279 | outPut << "interface ";
280 | } else if (klass->enumtype) {
281 | outPut << "enum ";
282 | } else if (klass->valuetype) {
283 | outPut << "struct ";
284 | } else {
285 | outPut << "class ";
286 | }
287 | outPut << klass->name; //TODO genericContainerIndex
288 | std::vector extends;
289 | if (!klass->valuetype && !klass->enumtype && klass->parent) {
290 | auto parent_type = il2cpp_class_get_type(klass->parent);
291 | if (parent_type->type != IL2CPP_TYPE_OBJECT) {
292 | extends.emplace_back(klass->parent->name);
293 | }
294 | }
295 | if (klass->interfaces_count > 0) {
296 | void *iter = nullptr;
297 | while (auto itf = il2cpp_class_get_interfaces(klass, &iter)) {
298 | extends.emplace_back(itf->name);
299 | }
300 | }
301 | if (!extends.empty()) {
302 | outPut << " : " << extends[0];
303 | for (int i = 1; i < extends.size(); ++i) {
304 | outPut << ", " << extends[i];
305 | }
306 | }
307 | outPut << " // TypeDefIndex: " << type->data.klassIndex << "\n{";
308 | outPut << dump_field(klass);
309 | outPut << dump_property(klass);
310 | outPut << dump_method(klass);
311 | //TODO EventInfo
312 | outPut << "}\n";
313 | return outPut.str();
314 | }
315 |
316 | void il2cpp_dump(void *handle, char *outDir) {
317 | LOGI("UnityVersion: %s", STRINGIFY_MACRO(UnityVersion));
318 | #ifdef VersionAboveV24
319 | LOGI("VersionAboveV24: on");
320 | #else
321 | LOGI("VersionAboveV24: off");
322 | #endif
323 | LOGI("il2cpp_handle: %p", handle);
324 | il2cpp_handle = handle;
325 | init_il2cpp_api();
326 | auto domain = il2cpp_domain_get();
327 | il2cpp_thread_attach(domain);
328 | size_t size;
329 | auto assemblies = il2cpp_domain_get_assemblies(domain, &size);
330 | uint32_t typeDefinitionsCount = 0;
331 | std::stringstream imageOutput;
332 | for (int i = 0; i < size; ++i) {
333 | auto image = il2cpp_assembly_get_image(assemblies[i]);
334 | typeDefinitionsCount += image->typeCount;
335 | imageOutput << "// Image " << i << ": " << image->name << " - " << image->typeStart << "\n";
336 | }
337 | std::vector outPuts(typeDefinitionsCount);
338 | LOGI("typeDefinitionsCount: %i", typeDefinitionsCount);
339 | il2cpp_base = get_module_base("libil2cpp.so");
340 | LOGI("il2cpp_base: %" PRIx64"", il2cpp_base);
341 | #ifdef VersionAboveV24
342 | //使用il2cpp_image_get_class
343 | for (int i = 0; i < size; ++i) {
344 | auto image = il2cpp_assembly_get_image(assemblies[i]);
345 | auto classCount = il2cpp_image_get_class_count(image);
346 | for (int j = 0; j < classCount; ++j) {
347 | auto klass = il2cpp_image_get_class(image, j);
348 | auto type = il2cpp_class_get_type(const_cast(klass));
349 | //LOGD("type name : %s", il2cpp_type_get_name(type));
350 | auto klassIndex = type->data.klassIndex;
351 | if (outPuts[klassIndex].empty()) {
352 | outPuts[klassIndex] = dump_type(type);
353 | }
354 | }
355 | }
356 | #else
357 | //使用反射
358 | auto corlib = il2cpp_get_corlib();
359 | auto assemblyClass = il2cpp_class_from_name(corlib, "System.Reflection", "Assembly");
360 | auto assemblyLoad = il2cpp_class_get_method_from_name(assemblyClass, "Load", 1);
361 | auto assemblyGetTypes = il2cpp_class_get_method_from_name(assemblyClass, "GetTypes", 0);
362 | if (assemblyLoad && assemblyLoad->methodPointer) {
363 | LOGI("Assembly::Load: %p", assemblyLoad->methodPointer);
364 | } else {
365 | LOGI("miss Assembly::Load");
366 | return;
367 | }
368 | if (assemblyGetTypes && assemblyGetTypes->methodPointer) {
369 | LOGI("Assembly::GetTypes: %p", assemblyGetTypes->methodPointer);
370 | } else {
371 | LOGI("miss Assembly::GetTypes");
372 | return;
373 | }
374 | #ifdef VersionAboveV24
375 | typedef void *(*Assembly_Load_ftn)(Il2CppString * , void * );
376 | #else
377 | typedef void *(*Assembly_Load_ftn)(void *, Il2CppString *, void *);
378 | #endif
379 | typedef Il2CppArray *(*Assembly_GetTypes_ftn)(void *, void *);
380 | LOGI("dumping...");
381 | for (int i = 0; i < size; ++i) {
382 | auto image = il2cpp_assembly_get_image(assemblies[i]);
383 | //LOGD("image name : %s", image->name);
384 | auto imageName = std::string(image->name);
385 | auto pos = imageName.rfind('.');
386 | auto imageNameNoExt = imageName.substr(0, pos);
387 | auto assemblyFileName = il2cpp_string_new(imageNameNoExt.c_str());
388 | #ifdef VersionAboveV24
389 | auto reflectionAssembly = ((Assembly_Load_ftn) assemblyLoad->methodPointer)(
390 | assemblyFileName, nullptr);
391 | #else
392 | auto reflectionAssembly = ((Assembly_Load_ftn) assemblyLoad->methodPointer)(nullptr,
393 | assemblyFileName,
394 | nullptr);
395 | #endif
396 | auto reflectionTypes = ((Assembly_GetTypes_ftn) assemblyGetTypes->methodPointer)(
397 | reflectionAssembly, nullptr);
398 | auto items = reflectionTypes->vector;
399 | for (int j = 0; j < reflectionTypes->max_length; ++j) {
400 | auto klass = il2cpp_class_from_system_type((Il2CppReflectionType *) items[j]);
401 | auto type = il2cpp_class_get_type(klass);
402 | //LOGD("type name : %s", il2cpp_type_get_name(type));
403 | auto klassIndex = type->data.klassIndex;
404 | if (outPuts[klassIndex].empty()) {
405 | outPuts[klassIndex] = dump_type(type);
406 | }
407 | }
408 | }
409 | #endif
410 | LOGI("write dump file");
411 | auto outPath = std::string(outDir).append("/dump.cs");
412 | std::ofstream outStream(outPath);
413 | outStream << imageOutput.str();
414 | for (int i = 0; i < typeDefinitionsCount; ++i) {
415 | if (!outPuts[i].empty()) {
416 | outStream << outPuts[i];
417 | } else {
418 | // always missing
419 | //LOGW("miss typeDefinition: %d", i);
420 | }
421 | }
422 | outStream.close();
423 | LOGI("dump done!");
424 | }
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cpp_dump.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Perfare on 2020/7/4.
3 | //
4 |
5 | #ifndef RIRU_IL2CPPDUMPER_IL2CPP_H
6 | #define RIRU_IL2CPPDUMPER_IL2CPP_H
7 |
8 |
9 | #define UnityVersion 2019.3.7f1
10 |
11 | // 2018.3.0f2(v24.1) and up enable it
12 | #define VersionAboveV24
13 | #define STR(x) #x
14 | #define STRINGIFY_MACRO(x) STR(x)
15 | #define EXPAND(x) x
16 | #define IL2CPPHEADER(a, b, c) STRINGIFY_MACRO(EXPAND(a)EXPAND(b)EXPAND(c))
17 | #define IL2CPPAPIDIR il2cppapi/
18 | #define IL2CPPCLASS IL2CPPHEADER(IL2CPPAPIDIR, UnityVersion, /il2cpp-class.h)
19 | #define IL2CPPAPI IL2CPPHEADER(IL2CPPAPIDIR, UnityVersion, /il2cpp-api-functions.h)
20 |
21 | void il2cpp_dump(void *handle, char *outDir);
22 |
23 | #endif //RIRU_IL2CPPDUMPER_IL2CPP_H
24 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/2018.1.0f2/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 | #ifndef DO_API_NO_RETURN
2 | #define DO_API_NO_RETURN(r, n, p) DO_API(r,n,p)
3 | #endif
4 |
5 |
6 | DO_API(void, il2cpp_init, (const char* domain_name));
7 | DO_API(void, il2cpp_init_utf16, (const Il2CppChar * domain_name));
8 | DO_API(void, il2cpp_shutdown, ());
9 | DO_API(void, il2cpp_set_config_dir, (const char *config_path));
10 | DO_API(void, il2cpp_set_data_dir, (const char *data_path));
11 | DO_API(void, il2cpp_set_temp_dir, (const char *temp_path));
12 | DO_API(void, il2cpp_set_commandline_arguments, (int argc, const char* const argv[], const char* basedir));
13 | DO_API(void, il2cpp_set_commandline_arguments_utf16, (int argc, const Il2CppChar * const argv[], const char* basedir));
14 | DO_API(void, il2cpp_set_config_utf16, (const Il2CppChar * executablePath));
15 | DO_API(void, il2cpp_set_config, (const char* executablePath));
16 |
17 | DO_API(void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks * callbacks));
18 | DO_API(const Il2CppImage*, il2cpp_get_corlib, ());
19 | DO_API(void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method));
20 | DO_API(Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name));
21 |
22 | DO_API(void*, il2cpp_alloc, (size_t size));
23 | DO_API(void, il2cpp_free, (void* ptr));
24 |
25 | // array
26 | DO_API(Il2CppClass*, il2cpp_array_class_get, (Il2CppClass * element_class, uint32_t rank));
27 | DO_API(uint32_t, il2cpp_array_length, (Il2CppArray * array));
28 | DO_API(uint32_t, il2cpp_array_get_byte_length, (Il2CppArray * array));
29 | DO_API(Il2CppArray*, il2cpp_array_new, (Il2CppClass * elementTypeInfo, il2cpp_array_size_t length));
30 | DO_API(Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass * arrayTypeInfo, il2cpp_array_size_t length));
31 | DO_API(Il2CppArray*, il2cpp_array_new_full, (Il2CppClass * array_class, il2cpp_array_size_t * lengths, il2cpp_array_size_t * lower_bounds));
32 | DO_API(Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass * element_class, uint32_t rank, bool bounded));
33 | DO_API(int, il2cpp_array_element_size, (const Il2CppClass * array_class));
34 |
35 | // assembly
36 | DO_API(const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly * assembly));
37 |
38 | // class
39 | DO_API(const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass * klass));
40 | DO_API(bool, il2cpp_class_is_generic, (const Il2CppClass * klass));
41 | DO_API(bool, il2cpp_class_is_inflated, (const Il2CppClass * klass));
42 | DO_API(bool, il2cpp_class_is_assignable_from, (Il2CppClass * klass, Il2CppClass * oklass));
43 | DO_API(bool, il2cpp_class_is_subclass_of, (Il2CppClass * klass, Il2CppClass * klassc, bool check_interfaces));
44 | DO_API(bool, il2cpp_class_has_parent, (Il2CppClass * klass, Il2CppClass * klassc));
45 | DO_API(Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType * type));
46 | DO_API(Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage * image, const char* namespaze, const char *name));
47 | DO_API(Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType * type));
48 | DO_API(Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass * klass));
49 | DO_API(const EventInfo*, il2cpp_class_get_events, (Il2CppClass * klass, void* *iter));
50 | DO_API(FieldInfo*, il2cpp_class_get_fields, (Il2CppClass * klass, void* *iter));
51 | DO_API(Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass * klass, void* *iter));
52 | DO_API(Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass * klass, void* *iter));
53 | DO_API(const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass * klass, void* *iter));
54 | DO_API(const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass * klass, const char *name));
55 | DO_API(FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass * klass, const char *name));
56 | DO_API(const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass * klass, void* *iter));
57 | DO_API(const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass * klass, const char* name, int argsCount));
58 | DO_API(const char*, il2cpp_class_get_name, (Il2CppClass * klass));
59 | DO_API(const char*, il2cpp_class_get_namespace, (Il2CppClass * klass));
60 | DO_API(Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass * klass));
61 | DO_API(Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass * klass));
62 | DO_API(int32_t, il2cpp_class_instance_size, (Il2CppClass * klass));
63 | DO_API(size_t, il2cpp_class_num_fields, (const Il2CppClass * enumKlass));
64 | DO_API(bool, il2cpp_class_is_valuetype, (const Il2CppClass * klass));
65 | DO_API(int32_t, il2cpp_class_value_size, (Il2CppClass * klass, uint32_t * align));
66 | DO_API(bool, il2cpp_class_is_blittable, (const Il2CppClass * klass));
67 | DO_API(int, il2cpp_class_get_flags, (const Il2CppClass * klass));
68 | DO_API(bool, il2cpp_class_is_abstract, (const Il2CppClass * klass));
69 | DO_API(bool, il2cpp_class_is_interface, (const Il2CppClass * klass));
70 | DO_API(int, il2cpp_class_array_element_size, (const Il2CppClass * klass));
71 | DO_API(Il2CppClass*, il2cpp_class_from_type, (const Il2CppType * type));
72 | DO_API(const Il2CppType*, il2cpp_class_get_type, (Il2CppClass * klass));
73 | DO_API(uint32_t, il2cpp_class_get_type_token, (Il2CppClass * klass));
74 | DO_API(bool, il2cpp_class_has_attribute, (Il2CppClass * klass, Il2CppClass * attr_class));
75 | DO_API(bool, il2cpp_class_has_references, (Il2CppClass * klass));
76 | DO_API(bool, il2cpp_class_is_enum, (const Il2CppClass * klass));
77 | DO_API(const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass * klass));
78 | DO_API(const char*, il2cpp_class_get_assemblyname, (const Il2CppClass * klass));
79 | DO_API(int, il2cpp_class_get_rank, (const Il2CppClass * klass));
80 |
81 | // testing only
82 | DO_API(size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass * klass));
83 | DO_API(void, il2cpp_class_get_bitmap, (Il2CppClass * klass, size_t * bitmap));
84 |
85 | // stats
86 | DO_API(bool, il2cpp_stats_dump_to_file, (const char *path));
87 | DO_API(uint64_t, il2cpp_stats_get_value, (Il2CppStat stat));
88 |
89 | // domain
90 | DO_API(Il2CppDomain*, il2cpp_domain_get, ());
91 | DO_API(const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain * domain, const char* name));
92 | DO_API(const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain * domain, size_t * size));
93 |
94 | // exception
95 | DO_API_NO_RETURN(void, il2cpp_raise_exception, (Il2CppException*));
96 | DO_API(Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage * image, const char *name_space, const char *name, const char *msg));
97 | DO_API(Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg));
98 | DO_API(void, il2cpp_format_exception, (const Il2CppException * ex, char* message, int message_size));
99 | DO_API(void, il2cpp_format_stack_trace, (const Il2CppException * ex, char* output, int output_size));
100 | DO_API(void, il2cpp_unhandled_exception, (Il2CppException*));
101 |
102 | // field
103 | DO_API(int, il2cpp_field_get_flags, (FieldInfo * field));
104 | DO_API(const char*, il2cpp_field_get_name, (FieldInfo * field));
105 | DO_API(Il2CppClass*, il2cpp_field_get_parent, (FieldInfo * field));
106 | DO_API(size_t, il2cpp_field_get_offset, (FieldInfo * field));
107 | DO_API(const Il2CppType*, il2cpp_field_get_type, (FieldInfo * field));
108 | DO_API(void, il2cpp_field_get_value, (Il2CppObject * obj, FieldInfo * field, void *value));
109 | DO_API(Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo * field, Il2CppObject * obj));
110 | DO_API(bool, il2cpp_field_has_attribute, (FieldInfo * field, Il2CppClass * attr_class));
111 | DO_API(void, il2cpp_field_set_value, (Il2CppObject * obj, FieldInfo * field, void *value));
112 | DO_API(void, il2cpp_field_static_get_value, (FieldInfo * field, void *value));
113 | DO_API(void, il2cpp_field_static_set_value, (FieldInfo * field, void *value));
114 | DO_API(void, il2cpp_field_set_value_object, (Il2CppObject * instance, FieldInfo * field, Il2CppObject * value));
115 |
116 | // gc
117 | DO_API(void, il2cpp_gc_collect, (int maxGenerations));
118 | DO_API(int32_t, il2cpp_gc_collect_a_little, ());
119 | DO_API(void, il2cpp_gc_disable, ());
120 | DO_API(void, il2cpp_gc_enable, ());
121 | DO_API(int64_t, il2cpp_gc_get_used_size, ());
122 | DO_API(int64_t, il2cpp_gc_get_heap_size, ());
123 |
124 | // gchandle
125 | DO_API(uint32_t, il2cpp_gchandle_new, (Il2CppObject * obj, bool pinned));
126 | DO_API(uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject * obj, bool track_resurrection));
127 | DO_API(Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle));
128 | DO_API(void, il2cpp_gchandle_free, (uint32_t gchandle));
129 |
130 | // liveness
131 | DO_API(void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass * filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped));
132 | DO_API(void, il2cpp_unity_liveness_calculation_end, (void* state));
133 | DO_API(void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject * root, void* state));
134 | DO_API(void, il2cpp_unity_liveness_calculation_from_statics, (void* state));
135 |
136 | // method
137 | DO_API(const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo * method));
138 | DO_API(Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo * method));
139 | DO_API(const char*, il2cpp_method_get_name, (const MethodInfo * method));
140 | DO_API(Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo * method, Il2CppClass * refclass));
141 | DO_API(bool, il2cpp_method_is_generic, (const MethodInfo * method));
142 | DO_API(bool, il2cpp_method_is_inflated, (const MethodInfo * method));
143 | DO_API(bool, il2cpp_method_is_instance, (const MethodInfo * method));
144 | DO_API(uint32_t, il2cpp_method_get_param_count, (const MethodInfo * method));
145 | DO_API(const Il2CppType*, il2cpp_method_get_param, (const MethodInfo * method, uint32_t index));
146 | DO_API(Il2CppClass*, il2cpp_method_get_class, (const MethodInfo * method));
147 | DO_API(bool, il2cpp_method_has_attribute, (const MethodInfo * method, Il2CppClass * attr_class));
148 | DO_API(uint32_t, il2cpp_method_get_flags, (const MethodInfo * method, uint32_t * iflags));
149 | DO_API(uint32_t, il2cpp_method_get_token, (const MethodInfo * method));
150 | DO_API(const char*, il2cpp_method_get_param_name, (const MethodInfo * method, uint32_t index));
151 |
152 | // profiler
153 | #if IL2CPP_ENABLE_PROFILER
154 |
155 | DO_API(void, il2cpp_profiler_install, (Il2CppProfiler * prof, Il2CppProfileFunc shutdown_callback));
156 | DO_API(void, il2cpp_profiler_set_events, (Il2CppProfileFlags events));
157 | DO_API(void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave));
158 | DO_API(void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback));
159 | DO_API(void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback));
160 | DO_API(void, il2cpp_profiler_install_fileio, (Il2CppProfileFileIOFunc callback));
161 |
162 | #endif
163 |
164 | // property
165 | DO_API(uint32_t, il2cpp_property_get_flags, (PropertyInfo * prop));
166 | DO_API(const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo * prop));
167 | DO_API(const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo * prop));
168 | DO_API(const char*, il2cpp_property_get_name, (PropertyInfo * prop));
169 | DO_API(Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo * prop));
170 |
171 | // object
172 | DO_API(Il2CppClass*, il2cpp_object_get_class, (Il2CppObject * obj));
173 | DO_API(uint32_t, il2cpp_object_get_size, (Il2CppObject * obj));
174 | DO_API(const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject * obj, const MethodInfo * method));
175 | DO_API(Il2CppObject*, il2cpp_object_new, (const Il2CppClass * klass));
176 | DO_API(void*, il2cpp_object_unbox, (Il2CppObject * obj));
177 |
178 | DO_API(Il2CppObject*, il2cpp_value_box, (Il2CppClass * klass, void* data));
179 |
180 | // monitor
181 | DO_API(void, il2cpp_monitor_enter, (Il2CppObject * obj));
182 | DO_API(bool, il2cpp_monitor_try_enter, (Il2CppObject * obj, uint32_t timeout));
183 | DO_API(void, il2cpp_monitor_exit, (Il2CppObject * obj));
184 | DO_API(void, il2cpp_monitor_pulse, (Il2CppObject * obj));
185 | DO_API(void, il2cpp_monitor_pulse_all, (Il2CppObject * obj));
186 | DO_API(void, il2cpp_monitor_wait, (Il2CppObject * obj));
187 | DO_API(bool, il2cpp_monitor_try_wait, (Il2CppObject * obj, uint32_t timeout));
188 |
189 | // runtime
190 | DO_API(Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo * method, void *obj, void **params, Il2CppException **exc));
191 | DO_API(Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo * method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc));
192 | DO_API(void, il2cpp_runtime_class_init, (Il2CppClass * klass));
193 | DO_API(void, il2cpp_runtime_object_init, (Il2CppObject * obj));
194 |
195 | DO_API(void, il2cpp_runtime_object_init_exception, (Il2CppObject * obj, Il2CppException** exc));
196 |
197 | DO_API(void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value));
198 |
199 | // string
200 | DO_API(int32_t, il2cpp_string_length, (Il2CppString * str));
201 | DO_API(Il2CppChar*, il2cpp_string_chars, (Il2CppString * str));
202 | DO_API(Il2CppString*, il2cpp_string_new, (const char* str));
203 | DO_API(Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length));
204 | DO_API(Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar * text, int32_t len));
205 | DO_API(Il2CppString*, il2cpp_string_new_wrapper, (const char* str));
206 | DO_API(Il2CppString*, il2cpp_string_intern, (Il2CppString * str));
207 | DO_API(Il2CppString*, il2cpp_string_is_interned, (Il2CppString * str));
208 |
209 | // thread
210 | DO_API(Il2CppThread*, il2cpp_thread_current, ());
211 | DO_API(Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain * domain));
212 | DO_API(void, il2cpp_thread_detach, (Il2CppThread * thread));
213 |
214 | DO_API(Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t * size));
215 | DO_API(bool, il2cpp_is_vm_thread, (Il2CppThread * thread));
216 |
217 | // stacktrace
218 | DO_API(void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data));
219 | DO_API(void, il2cpp_thread_walk_frame_stack, (Il2CppThread * thread, Il2CppFrameWalkFunc func, void* user_data));
220 | DO_API(bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo * frame));
221 | DO_API(bool, il2cpp_thread_get_top_frame, (Il2CppThread * thread, Il2CppStackFrameInfo * frame));
222 | DO_API(bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo * frame));
223 | DO_API(bool, il2cpp_thread_get_frame_at, (Il2CppThread * thread, int32_t offset, Il2CppStackFrameInfo * frame));
224 | DO_API(int32_t, il2cpp_current_thread_get_stack_depth, ());
225 | DO_API(int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread * thread));
226 |
227 | // type
228 | DO_API(Il2CppObject*, il2cpp_type_get_object, (const Il2CppType * type));
229 | DO_API(int, il2cpp_type_get_type, (const Il2CppType * type));
230 | DO_API(Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType * type));
231 | DO_API(char*, il2cpp_type_get_name, (const Il2CppType * type));
232 | DO_API(bool, il2cpp_type_is_byref, (const Il2CppType * type));
233 | DO_API(bool, il2cpp_type_equals, (const Il2CppType * type, const Il2CppType * otherType));
234 |
235 | // image
236 | DO_API(const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage * image));
237 | DO_API(const char*, il2cpp_image_get_name, (const Il2CppImage * image));
238 | DO_API(const char*, il2cpp_image_get_filename, (const Il2CppImage * image));
239 | DO_API(const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage * image));
240 |
241 | // Memory information
242 | DO_API(Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, ());
243 | DO_API(void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot * snapshot));
244 |
245 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
246 |
247 | // Logging
248 | DO_API(void, il2cpp_register_log_callback, (Il2CppLogCallback method));
249 |
250 | // Debugger
251 | DO_API(void, il2cpp_debugger_set_agent_options, (const char* options));
252 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/2018.2.0f2/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 | #ifndef DO_API_NO_RETURN
2 | #define DO_API_NO_RETURN(r, n, p) DO_API(r,n,p)
3 | #endif
4 |
5 |
6 | DO_API(void, il2cpp_init, (const char* domain_name));
7 | DO_API(void, il2cpp_init_utf16, (const Il2CppChar * domain_name));
8 | DO_API(void, il2cpp_shutdown, ());
9 | DO_API(void, il2cpp_set_config_dir, (const char *config_path));
10 | DO_API(void, il2cpp_set_data_dir, (const char *data_path));
11 | DO_API(void, il2cpp_set_temp_dir, (const char *temp_path));
12 | DO_API(void, il2cpp_set_commandline_arguments, (int argc, const char* const argv[], const char* basedir));
13 | DO_API(void, il2cpp_set_commandline_arguments_utf16, (int argc, const Il2CppChar * const argv[], const char* basedir));
14 | DO_API(void, il2cpp_set_config_utf16, (const Il2CppChar * executablePath));
15 | DO_API(void, il2cpp_set_config, (const char* executablePath));
16 |
17 | DO_API(void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks * callbacks));
18 | DO_API(const Il2CppImage*, il2cpp_get_corlib, ());
19 | DO_API(void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method));
20 | DO_API(Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name));
21 |
22 | DO_API(void*, il2cpp_alloc, (size_t size));
23 | DO_API(void, il2cpp_free, (void* ptr));
24 |
25 | // array
26 | DO_API(Il2CppClass*, il2cpp_array_class_get, (Il2CppClass * element_class, uint32_t rank));
27 | DO_API(uint32_t, il2cpp_array_length, (Il2CppArray * array));
28 | DO_API(uint32_t, il2cpp_array_get_byte_length, (Il2CppArray * array));
29 | DO_API(Il2CppArray*, il2cpp_array_new, (Il2CppClass * elementTypeInfo, il2cpp_array_size_t length));
30 | DO_API(Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass * arrayTypeInfo, il2cpp_array_size_t length));
31 | DO_API(Il2CppArray*, il2cpp_array_new_full, (Il2CppClass * array_class, il2cpp_array_size_t * lengths, il2cpp_array_size_t * lower_bounds));
32 | DO_API(Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass * element_class, uint32_t rank, bool bounded));
33 | DO_API(int, il2cpp_array_element_size, (const Il2CppClass * array_class));
34 |
35 | // assembly
36 | DO_API(const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly * assembly));
37 |
38 | // class
39 | DO_API(const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass * klass));
40 | DO_API(bool, il2cpp_class_is_generic, (const Il2CppClass * klass));
41 | DO_API(bool, il2cpp_class_is_inflated, (const Il2CppClass * klass));
42 | DO_API(bool, il2cpp_class_is_assignable_from, (Il2CppClass * klass, Il2CppClass * oklass));
43 | DO_API(bool, il2cpp_class_is_subclass_of, (Il2CppClass * klass, Il2CppClass * klassc, bool check_interfaces));
44 | DO_API(bool, il2cpp_class_has_parent, (Il2CppClass * klass, Il2CppClass * klassc));
45 | DO_API(Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType * type));
46 | DO_API(Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage * image, const char* namespaze, const char *name));
47 | DO_API(Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType * type));
48 | DO_API(Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass * klass));
49 | DO_API(const EventInfo*, il2cpp_class_get_events, (Il2CppClass * klass, void* *iter));
50 | DO_API(FieldInfo*, il2cpp_class_get_fields, (Il2CppClass * klass, void* *iter));
51 | DO_API(Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass * klass, void* *iter));
52 | DO_API(Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass * klass, void* *iter));
53 | DO_API(const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass * klass, void* *iter));
54 | DO_API(const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass * klass, const char *name));
55 | DO_API(FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass * klass, const char *name));
56 | DO_API(const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass * klass, void* *iter));
57 | DO_API(const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass * klass, const char* name, int argsCount));
58 | DO_API(const char*, il2cpp_class_get_name, (Il2CppClass * klass));
59 | DO_API(const char*, il2cpp_class_get_namespace, (Il2CppClass * klass));
60 | DO_API(Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass * klass));
61 | DO_API(Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass * klass));
62 | DO_API(int32_t, il2cpp_class_instance_size, (Il2CppClass * klass));
63 | DO_API(size_t, il2cpp_class_num_fields, (const Il2CppClass * enumKlass));
64 | DO_API(bool, il2cpp_class_is_valuetype, (const Il2CppClass * klass));
65 | DO_API(int32_t, il2cpp_class_value_size, (Il2CppClass * klass, uint32_t * align));
66 | DO_API(bool, il2cpp_class_is_blittable, (const Il2CppClass * klass));
67 | DO_API(int, il2cpp_class_get_flags, (const Il2CppClass * klass));
68 | DO_API(bool, il2cpp_class_is_abstract, (const Il2CppClass * klass));
69 | DO_API(bool, il2cpp_class_is_interface, (const Il2CppClass * klass));
70 | DO_API(int, il2cpp_class_array_element_size, (const Il2CppClass * klass));
71 | DO_API(Il2CppClass*, il2cpp_class_from_type, (const Il2CppType * type));
72 | DO_API(const Il2CppType*, il2cpp_class_get_type, (Il2CppClass * klass));
73 | DO_API(uint32_t, il2cpp_class_get_type_token, (Il2CppClass * klass));
74 | DO_API(bool, il2cpp_class_has_attribute, (Il2CppClass * klass, Il2CppClass * attr_class));
75 | DO_API(bool, il2cpp_class_has_references, (Il2CppClass * klass));
76 | DO_API(bool, il2cpp_class_is_enum, (const Il2CppClass * klass));
77 | DO_API(const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass * klass));
78 | DO_API(const char*, il2cpp_class_get_assemblyname, (const Il2CppClass * klass));
79 | DO_API(int, il2cpp_class_get_rank, (const Il2CppClass * klass));
80 |
81 | // testing only
82 | DO_API(size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass * klass));
83 | DO_API(void, il2cpp_class_get_bitmap, (Il2CppClass * klass, size_t * bitmap));
84 |
85 | // stats
86 | DO_API(bool, il2cpp_stats_dump_to_file, (const char *path));
87 | DO_API(uint64_t, il2cpp_stats_get_value, (Il2CppStat stat));
88 |
89 | // domain
90 | DO_API(Il2CppDomain*, il2cpp_domain_get, ());
91 | DO_API(const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain * domain, const char* name));
92 | DO_API(const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain * domain, size_t * size));
93 |
94 | // exception
95 | DO_API_NO_RETURN(void, il2cpp_raise_exception, (Il2CppException*));
96 | DO_API(Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage * image, const char *name_space, const char *name, const char *msg));
97 | DO_API(Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg));
98 | DO_API(void, il2cpp_format_exception, (const Il2CppException * ex, char* message, int message_size));
99 | DO_API(void, il2cpp_format_stack_trace, (const Il2CppException * ex, char* output, int output_size));
100 | DO_API(void, il2cpp_unhandled_exception, (Il2CppException*));
101 |
102 | // field
103 | DO_API(int, il2cpp_field_get_flags, (FieldInfo * field));
104 | DO_API(const char*, il2cpp_field_get_name, (FieldInfo * field));
105 | DO_API(Il2CppClass*, il2cpp_field_get_parent, (FieldInfo * field));
106 | DO_API(size_t, il2cpp_field_get_offset, (FieldInfo * field));
107 | DO_API(const Il2CppType*, il2cpp_field_get_type, (FieldInfo * field));
108 | DO_API(void, il2cpp_field_get_value, (Il2CppObject * obj, FieldInfo * field, void *value));
109 | DO_API(Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo * field, Il2CppObject * obj));
110 | DO_API(bool, il2cpp_field_has_attribute, (FieldInfo * field, Il2CppClass * attr_class));
111 | DO_API(void, il2cpp_field_set_value, (Il2CppObject * obj, FieldInfo * field, void *value));
112 | DO_API(void, il2cpp_field_static_get_value, (FieldInfo * field, void *value));
113 | DO_API(void, il2cpp_field_static_set_value, (FieldInfo * field, void *value));
114 | DO_API(void, il2cpp_field_set_value_object, (Il2CppObject * instance, FieldInfo * field, Il2CppObject * value));
115 |
116 | // gc
117 | DO_API(void, il2cpp_gc_collect, (int maxGenerations));
118 | DO_API(int32_t, il2cpp_gc_collect_a_little, ());
119 | DO_API(void, il2cpp_gc_disable, ());
120 | DO_API(void, il2cpp_gc_enable, ());
121 | DO_API(int64_t, il2cpp_gc_get_used_size, ());
122 | DO_API(int64_t, il2cpp_gc_get_heap_size, ());
123 |
124 | // gchandle
125 | DO_API(uint32_t, il2cpp_gchandle_new, (Il2CppObject * obj, bool pinned));
126 | DO_API(uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject * obj, bool track_resurrection));
127 | DO_API(Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle));
128 | DO_API(void, il2cpp_gchandle_free, (uint32_t gchandle));
129 |
130 | // liveness
131 | DO_API(void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass * filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped));
132 | DO_API(void, il2cpp_unity_liveness_calculation_end, (void* state));
133 | DO_API(void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject * root, void* state));
134 | DO_API(void, il2cpp_unity_liveness_calculation_from_statics, (void* state));
135 |
136 | // method
137 | DO_API(const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo * method));
138 | DO_API(Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo * method));
139 | DO_API(const char*, il2cpp_method_get_name, (const MethodInfo * method));
140 | DO_API(const MethodInfo*, il2cpp_method_get_from_reflection, (const Il2CppReflectionMethod * method));
141 | DO_API(Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo * method, Il2CppClass * refclass));
142 | DO_API(bool, il2cpp_method_is_generic, (const MethodInfo * method));
143 | DO_API(bool, il2cpp_method_is_inflated, (const MethodInfo * method));
144 | DO_API(bool, il2cpp_method_is_instance, (const MethodInfo * method));
145 | DO_API(uint32_t, il2cpp_method_get_param_count, (const MethodInfo * method));
146 | DO_API(const Il2CppType*, il2cpp_method_get_param, (const MethodInfo * method, uint32_t index));
147 | DO_API(Il2CppClass*, il2cpp_method_get_class, (const MethodInfo * method));
148 | DO_API(bool, il2cpp_method_has_attribute, (const MethodInfo * method, Il2CppClass * attr_class));
149 | DO_API(uint32_t, il2cpp_method_get_flags, (const MethodInfo * method, uint32_t * iflags));
150 | DO_API(uint32_t, il2cpp_method_get_token, (const MethodInfo * method));
151 | DO_API(const char*, il2cpp_method_get_param_name, (const MethodInfo * method, uint32_t index));
152 |
153 | // profiler
154 | #if IL2CPP_ENABLE_PROFILER
155 |
156 | DO_API(void, il2cpp_profiler_install, (Il2CppProfiler * prof, Il2CppProfileFunc shutdown_callback));
157 | DO_API(void, il2cpp_profiler_set_events, (Il2CppProfileFlags events));
158 | DO_API(void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave));
159 | DO_API(void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback));
160 | DO_API(void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback));
161 | DO_API(void, il2cpp_profiler_install_fileio, (Il2CppProfileFileIOFunc callback));
162 |
163 | #endif
164 |
165 | // property
166 | DO_API(uint32_t, il2cpp_property_get_flags, (PropertyInfo * prop));
167 | DO_API(const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo * prop));
168 | DO_API(const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo * prop));
169 | DO_API(const char*, il2cpp_property_get_name, (PropertyInfo * prop));
170 | DO_API(Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo * prop));
171 |
172 | // object
173 | DO_API(Il2CppClass*, il2cpp_object_get_class, (Il2CppObject * obj));
174 | DO_API(uint32_t, il2cpp_object_get_size, (Il2CppObject * obj));
175 | DO_API(const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject * obj, const MethodInfo * method));
176 | DO_API(Il2CppObject*, il2cpp_object_new, (const Il2CppClass * klass));
177 | DO_API(void*, il2cpp_object_unbox, (Il2CppObject * obj));
178 |
179 | DO_API(Il2CppObject*, il2cpp_value_box, (Il2CppClass * klass, void* data));
180 |
181 | // monitor
182 | DO_API(void, il2cpp_monitor_enter, (Il2CppObject * obj));
183 | DO_API(bool, il2cpp_monitor_try_enter, (Il2CppObject * obj, uint32_t timeout));
184 | DO_API(void, il2cpp_monitor_exit, (Il2CppObject * obj));
185 | DO_API(void, il2cpp_monitor_pulse, (Il2CppObject * obj));
186 | DO_API(void, il2cpp_monitor_pulse_all, (Il2CppObject * obj));
187 | DO_API(void, il2cpp_monitor_wait, (Il2CppObject * obj));
188 | DO_API(bool, il2cpp_monitor_try_wait, (Il2CppObject * obj, uint32_t timeout));
189 |
190 | // runtime
191 | DO_API(Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo * method, void *obj, void **params, Il2CppException **exc));
192 | DO_API(Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo * method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc));
193 | DO_API(void, il2cpp_runtime_class_init, (Il2CppClass * klass));
194 | DO_API(void, il2cpp_runtime_object_init, (Il2CppObject * obj));
195 |
196 | DO_API(void, il2cpp_runtime_object_init_exception, (Il2CppObject * obj, Il2CppException** exc));
197 |
198 | DO_API(void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value));
199 |
200 | // string
201 | DO_API(int32_t, il2cpp_string_length, (Il2CppString * str));
202 | DO_API(Il2CppChar*, il2cpp_string_chars, (Il2CppString * str));
203 | DO_API(Il2CppString*, il2cpp_string_new, (const char* str));
204 | DO_API(Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length));
205 | DO_API(Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar * text, int32_t len));
206 | DO_API(Il2CppString*, il2cpp_string_new_wrapper, (const char* str));
207 | DO_API(Il2CppString*, il2cpp_string_intern, (Il2CppString * str));
208 | DO_API(Il2CppString*, il2cpp_string_is_interned, (Il2CppString * str));
209 |
210 | // thread
211 | DO_API(Il2CppThread*, il2cpp_thread_current, ());
212 | DO_API(Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain * domain));
213 | DO_API(void, il2cpp_thread_detach, (Il2CppThread * thread));
214 |
215 | DO_API(Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t * size));
216 | DO_API(bool, il2cpp_is_vm_thread, (Il2CppThread * thread));
217 |
218 | // stacktrace
219 | DO_API(void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data));
220 | DO_API(void, il2cpp_thread_walk_frame_stack, (Il2CppThread * thread, Il2CppFrameWalkFunc func, void* user_data));
221 | DO_API(bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo * frame));
222 | DO_API(bool, il2cpp_thread_get_top_frame, (Il2CppThread * thread, Il2CppStackFrameInfo * frame));
223 | DO_API(bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo * frame));
224 | DO_API(bool, il2cpp_thread_get_frame_at, (Il2CppThread * thread, int32_t offset, Il2CppStackFrameInfo * frame));
225 | DO_API(int32_t, il2cpp_current_thread_get_stack_depth, ());
226 | DO_API(int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread * thread));
227 |
228 | // type
229 | DO_API(Il2CppObject*, il2cpp_type_get_object, (const Il2CppType * type));
230 | DO_API(int, il2cpp_type_get_type, (const Il2CppType * type));
231 | DO_API(Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType * type));
232 | DO_API(char*, il2cpp_type_get_name, (const Il2CppType * type));
233 | DO_API(bool, il2cpp_type_is_byref, (const Il2CppType * type));
234 | DO_API(uint32_t, il2cpp_type_get_attrs, (const Il2CppType * type));
235 | DO_API(bool, il2cpp_type_equals, (const Il2CppType * type, const Il2CppType * otherType));
236 | DO_API(char*, il2cpp_type_get_assembly_qualified_name, (const Il2CppType * type));
237 |
238 | // image
239 | DO_API(const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage * image));
240 | DO_API(const char*, il2cpp_image_get_name, (const Il2CppImage * image));
241 | DO_API(const char*, il2cpp_image_get_filename, (const Il2CppImage * image));
242 | DO_API(const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage * image));
243 |
244 | // Memory information
245 | DO_API(Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, ());
246 | DO_API(void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot * snapshot));
247 |
248 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
249 |
250 | // Logging
251 | DO_API(void, il2cpp_register_log_callback, (Il2CppLogCallback method));
252 |
253 | // Debugger
254 | DO_API(void, il2cpp_debugger_set_agent_options, (const char* options));
255 | DO_API(bool, il2cpp_is_debugger_attached, ());
256 |
257 | // TLS module
258 | DO_API(void, il2cpp_unity_install_unitytls_interface, (const void* unitytlsInterfaceStruct));
259 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.0f4/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, methodPointerType method) );
10 | DO_API( methodPointerType, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
42 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
44 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
45 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
47 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
48 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
49 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
51 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
52 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
53 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
54 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
55 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
56 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
58 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
59 | DO_API( Il2CppClass*, il2cpp_class_from_type, (Il2CppType *type) );
60 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
61 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
62 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
63 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
64 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
65 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
66 |
67 | // testing only
68 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
69 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
70 |
71 | // stats
72 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
73 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
74 |
75 | // domain
76 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
77 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
78 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
79 |
80 | // exception
81 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
82 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
83 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
84 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
85 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
86 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
87 |
88 | // field
89 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
90 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
91 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
92 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
93 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
94 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
95 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
96 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
97 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
98 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
100 |
101 | // gc
102 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
103 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
104 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
105 |
106 | // gchandle
107 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
108 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
109 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
110 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
111 |
112 | // liveness
113 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, register_object_callback callback, void* userdata, WorldChangedCallback onWorldStarted, WorldChangedCallback onWorldStopped) );
114 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
115 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
116 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
117 |
118 | // method
119 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
120 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
121 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
122 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
123 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
124 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
125 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
126 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
127 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
128 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
130 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
131 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
132 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
133 |
134 | // profiler
135 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
136 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
137 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
138 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
139 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
140 |
141 | // property
142 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
143 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
144 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
145 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
146 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
147 |
148 | // object
149 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
150 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
151 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
152 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
153 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
154 |
155 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
156 |
157 | // monitor
158 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
159 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
160 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
161 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
162 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
163 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
164 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
165 |
166 | // runtime
167 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppObject **exc) );
168 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppObject **exc) );
169 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
170 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
171 |
172 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppObject** exc) );
173 |
174 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
175 |
176 | // delegate
177 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
178 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
179 |
180 | // string
181 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
182 | DO_API( uint16_t*, il2cpp_string_chars, (Il2CppString* str) );
183 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
184 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
185 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const uint16_t *text, int32_t len) );
186 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
187 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
188 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
189 |
190 | // thread
191 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
192 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
193 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
194 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
195 |
196 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
197 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
198 |
199 | // stacktrace
200 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
201 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
202 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
203 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
204 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
205 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
206 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
207 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
208 |
209 | // type
210 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
211 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
212 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
213 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
214 |
215 | // image
216 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
217 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
218 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
219 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
220 |
221 | // Memory information
222 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
223 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
224 |
225 | #if IL2CPP_DEBUGGER_ENABLED
226 | // debug
227 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
228 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
229 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
230 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
231 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
232 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
233 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
234 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
235 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
236 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
237 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
238 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
239 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
240 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
241 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
242 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
243 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
244 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
245 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
246 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
247 | #endif
248 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.2f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, methodPointerType method) );
10 | DO_API( methodPointerType, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
105 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
106 |
107 | // gchandle
108 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
109 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
110 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
111 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
112 |
113 | // liveness
114 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, register_object_callback callback, void* userdata, WorldChangedCallback onWorldStarted, WorldChangedCallback onWorldStopped) );
115 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
116 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
117 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
118 |
119 | // method
120 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
121 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
122 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
123 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
124 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
125 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
126 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
127 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
128 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
129 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
130 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
131 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
132 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
133 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
134 |
135 | // profiler
136 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
137 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
138 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
139 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
140 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
141 |
142 | // property
143 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
144 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
145 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
146 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
147 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
148 |
149 | // object
150 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
151 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
152 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
153 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
154 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
155 |
156 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
157 |
158 | // monitor
159 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
160 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
161 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
162 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
163 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
164 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
165 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
166 |
167 | // runtime
168 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppObject **exc) );
169 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppObject **exc) );
170 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
171 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
172 |
173 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppObject** exc) );
174 |
175 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
176 |
177 | // delegate
178 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
179 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
180 |
181 | // string
182 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
183 | DO_API( uint16_t*, il2cpp_string_chars, (Il2CppString* str) );
184 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
185 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
186 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const uint16_t *text, int32_t len) );
187 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
188 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
189 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
190 |
191 | // thread
192 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
193 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
194 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
195 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
196 |
197 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
198 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
199 |
200 | // stacktrace
201 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
202 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
203 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
204 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
205 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
206 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
207 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
208 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
209 |
210 | // type
211 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
212 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
213 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
214 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
215 |
216 | // image
217 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
218 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
219 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
220 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
221 |
222 | // Memory information
223 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
224 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
225 |
226 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
227 |
228 | #if IL2CPP_DEBUGGER_ENABLED
229 | // debug
230 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
231 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
232 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
233 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
234 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
235 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
236 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
237 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
238 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
239 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
240 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
241 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
242 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
243 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
244 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
245 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
246 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
247 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
248 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
249 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
250 | #endif
251 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.3f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, methodPointerType method) );
10 | DO_API( methodPointerType, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
105 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
106 |
107 | // gchandle
108 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
109 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
110 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
111 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
112 |
113 | // liveness
114 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, register_object_callback callback, void* userdata, WorldChangedCallback onWorldStarted, WorldChangedCallback onWorldStopped) );
115 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
116 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
117 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
118 |
119 | // method
120 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
121 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
122 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
123 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
124 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
125 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
126 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
127 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
128 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
129 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
130 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
131 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
132 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
133 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
134 |
135 | // profiler
136 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
137 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
138 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
139 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
140 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
141 |
142 | // property
143 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
144 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
145 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
146 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
147 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
148 |
149 | // object
150 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
151 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
152 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
153 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
154 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
155 |
156 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
157 |
158 | // monitor
159 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
160 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
161 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
162 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
163 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
164 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
165 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
166 |
167 | // runtime
168 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppObject **exc) );
169 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppObject **exc) );
170 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
171 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
172 |
173 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppObject** exc) );
174 |
175 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
176 |
177 | // delegate
178 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
179 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
180 |
181 | // string
182 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
183 | DO_API( uint16_t*, il2cpp_string_chars, (Il2CppString* str) );
184 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
185 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
186 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const uint16_t *text, int32_t len) );
187 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
188 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
189 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
190 |
191 | // thread
192 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
193 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
194 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
195 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
196 |
197 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
198 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
199 |
200 | // stacktrace
201 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
202 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
203 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
204 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
205 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
206 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
207 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
208 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
209 |
210 | // type
211 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
212 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
213 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
214 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
215 |
216 | // image
217 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
218 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
219 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
220 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
221 |
222 | // Memory information
223 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
224 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
225 |
226 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
227 |
228 | #if IL2CPP_DEBUGGER_ENABLED
229 | // debug
230 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
231 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
232 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
233 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
234 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
235 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
236 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
237 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
238 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
239 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
240 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
241 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
242 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
243 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
244 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
245 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
246 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
247 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
248 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
249 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
250 | #endif
251 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.5f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( const Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method) );
10 | DO_API( Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (const Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int32_t, il2cpp_gc_collect_a_little, ());
105 | DO_API( void, il2cpp_gc_disable, ());
106 | DO_API( void, il2cpp_gc_enable, () );
107 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
108 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
109 |
110 | // gchandle
111 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
112 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
113 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
114 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
115 |
116 | // liveness
117 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped) );
118 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
119 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
120 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
121 |
122 | // method
123 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
124 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
125 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
126 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
127 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
128 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
130 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
131 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
132 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
133 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
134 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
135 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
136 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
137 |
138 | // profiler
139 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
140 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
141 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
142 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
143 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
144 |
145 | // property
146 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
147 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
148 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
149 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
150 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
151 |
152 | // object
153 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
154 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
155 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
156 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
157 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
158 |
159 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
160 |
161 | // monitor
162 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
163 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
164 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
165 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
166 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
167 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
168 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
169 |
170 | // runtime
171 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppException **exc) );
172 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc) );
173 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
174 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
175 |
176 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppException** exc) );
177 |
178 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
179 |
180 | // delegate
181 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
182 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
183 |
184 | // string
185 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
186 | DO_API( uint16_t*, il2cpp_string_chars, (Il2CppString* str) );
187 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
188 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
189 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const uint16_t *text, int32_t len) );
190 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
191 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
192 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
193 |
194 | // thread
195 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
196 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
197 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
198 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
199 |
200 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
201 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
202 |
203 | // stacktrace
204 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
205 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
206 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
207 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
208 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
209 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
210 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
211 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
212 |
213 | // type
214 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
215 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
216 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
217 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
218 |
219 | // image
220 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
221 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
222 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
223 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
224 |
225 | // Memory information
226 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
227 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
228 |
229 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
230 |
231 | #if IL2CPP_DEBUGGER_ENABLED
232 | // debug
233 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
234 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
235 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
236 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
237 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
238 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
239 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
240 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
241 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
242 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
243 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
244 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
245 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
246 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
247 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
248 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
249 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
250 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
251 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
252 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
253 | #endif
254 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.6f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( const Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method) );
10 | DO_API( Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (const Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int32_t, il2cpp_gc_collect_a_little, ());
105 | DO_API( void, il2cpp_gc_disable, ());
106 | DO_API( void, il2cpp_gc_enable, () );
107 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
108 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
109 |
110 | // gchandle
111 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
112 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
113 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
114 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
115 |
116 | // liveness
117 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped) );
118 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
119 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
120 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
121 |
122 | // method
123 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
124 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
125 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
126 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
127 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
128 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
130 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
131 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
132 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
133 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
134 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
135 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
136 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
137 |
138 | // profiler
139 | #if IL2CPP_ENABLE_PROFILER
140 |
141 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
142 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
143 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
144 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
145 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
146 |
147 | #endif
148 |
149 | // property
150 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
151 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
152 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
153 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
154 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
155 |
156 | // object
157 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
158 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
159 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
160 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
161 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
162 |
163 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
164 |
165 | // monitor
166 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
167 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
168 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
169 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
170 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
171 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
172 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
173 |
174 | // runtime
175 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppException **exc) );
176 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc) );
177 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
178 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
179 |
180 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppException** exc) );
181 |
182 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
183 |
184 | // delegate
185 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
186 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
187 |
188 | // string
189 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
190 | DO_API( Il2CppChar*, il2cpp_string_chars, (Il2CppString* str) );
191 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
192 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
193 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar *text, int32_t len) );
194 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
195 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
196 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
197 |
198 | // thread
199 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
200 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
201 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
202 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
203 |
204 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
205 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
206 |
207 | // stacktrace
208 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
209 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
210 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
211 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
212 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
213 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
214 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
215 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
216 |
217 | // type
218 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
219 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
220 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
221 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
222 |
223 | // image
224 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
225 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
226 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
227 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
228 |
229 | // Memory information
230 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
231 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
232 |
233 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
234 |
235 | #if IL2CPP_DEBUGGER_ENABLED
236 | // debug
237 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
238 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
239 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
240 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
241 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
242 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
243 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
244 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
245 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
246 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
247 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
248 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
249 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
250 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
251 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
252 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
253 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
254 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
255 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
256 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
257 | #endif
258 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.3.7f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( const Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method) );
10 | DO_API( Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (const Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int32_t, il2cpp_gc_collect_a_little, ());
105 | DO_API( void, il2cpp_gc_disable, ());
106 | DO_API( void, il2cpp_gc_enable, () );
107 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
108 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
109 |
110 | // gchandle
111 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
112 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
113 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
114 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
115 |
116 | // liveness
117 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped) );
118 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
119 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
120 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
121 |
122 | // method
123 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
124 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
125 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
126 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
127 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
128 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
130 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
131 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
132 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
133 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
134 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
135 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
136 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
137 |
138 | // profiler
139 | #if IL2CPP_ENABLE_PROFILER
140 |
141 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
142 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
143 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
144 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
145 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
146 |
147 | #endif
148 |
149 | // property
150 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
151 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
152 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
153 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
154 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
155 |
156 | // object
157 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
158 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
159 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
160 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
161 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
162 |
163 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
164 |
165 | // monitor
166 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
167 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
168 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
169 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
170 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
171 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
172 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
173 |
174 | // runtime
175 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppException **exc) );
176 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc) );
177 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
178 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
179 |
180 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppException** exc) );
181 |
182 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
183 |
184 | // delegate
185 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
186 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
187 |
188 | // string
189 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
190 | DO_API( Il2CppChar*, il2cpp_string_chars, (Il2CppString* str) );
191 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
192 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
193 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar *text, int32_t len) );
194 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
195 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
196 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
197 |
198 | // thread
199 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
200 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
201 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
202 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
203 |
204 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
205 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
206 |
207 | // stacktrace
208 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
209 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
210 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
211 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
212 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
213 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
214 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
215 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
216 |
217 | // type
218 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
219 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
220 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
221 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
222 |
223 | // image
224 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
225 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
226 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
227 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
228 |
229 | // Memory information
230 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
231 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
232 |
233 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
234 |
235 | #if IL2CPP_DEBUGGER_ENABLED
236 | // debug
237 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
238 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
239 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
240 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
241 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
242 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
243 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
244 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
245 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
246 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
247 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
248 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
249 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
250 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
251 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
252 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
253 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
254 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
255 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
256 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
257 | #endif
258 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.4.0f3/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( const Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method) );
10 | DO_API( Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (const Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int32_t, il2cpp_gc_collect_a_little, ());
105 | DO_API( void, il2cpp_gc_disable, ());
106 | DO_API( void, il2cpp_gc_enable, () );
107 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
108 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
109 |
110 | // gchandle
111 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
112 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
113 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
114 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
115 |
116 | // liveness
117 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped) );
118 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
119 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
120 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
121 |
122 | // method
123 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
124 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
125 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
126 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
127 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
128 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
130 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
131 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
132 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
133 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
134 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
135 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
136 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
137 |
138 | // profiler
139 | #if IL2CPP_ENABLE_PROFILER
140 |
141 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
142 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
143 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
144 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
145 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
146 |
147 | #endif
148 |
149 | // property
150 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
151 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
152 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
153 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
154 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
155 |
156 | // object
157 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
158 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
159 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
160 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
161 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
162 |
163 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
164 |
165 | // monitor
166 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
167 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
168 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
169 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
170 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
171 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
172 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
173 |
174 | // runtime
175 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppException **exc) );
176 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc) );
177 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
178 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
179 |
180 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppException** exc) );
181 |
182 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
183 |
184 | // delegate
185 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
186 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
187 |
188 | // string
189 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
190 | DO_API( Il2CppChar*, il2cpp_string_chars, (Il2CppString* str) );
191 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
192 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
193 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar *text, int32_t len) );
194 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
195 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
196 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
197 |
198 | // thread
199 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
200 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
201 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
202 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
203 |
204 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
205 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
206 |
207 | // stacktrace
208 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
209 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
210 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
211 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
212 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
213 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
214 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
215 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
216 |
217 | // type
218 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
219 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
220 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
221 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
222 |
223 | // image
224 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
225 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
226 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
227 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
228 |
229 | // Memory information
230 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
231 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
232 |
233 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
234 |
235 | #if IL2CPP_DEBUGGER_ENABLED
236 | // debug
237 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
238 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
239 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
240 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
241 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
242 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
243 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
244 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
245 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
246 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
247 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
248 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
249 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
250 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
251 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
252 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
253 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
254 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
255 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
256 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
257 | #endif
258 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/il2cppapi/5.4.1f1/il2cpp-api-functions.h:
--------------------------------------------------------------------------------
1 |
2 | DO_API( void, il2cpp_init, (const char* domain_name) );
3 | DO_API( void, il2cpp_shutdown, () );
4 | DO_API( void, il2cpp_set_config_dir, (const char *config_path) );
5 | DO_API( void, il2cpp_set_data_dir, (const char *data_path) );
6 | DO_API( void, il2cpp_set_commandline_arguments, (int argc, const char* argv[], const char* basedir) );
7 | DO_API( void, il2cpp_set_memory_callbacks, (Il2CppMemoryCallbacks* callbacks) );
8 | DO_API( const Il2CppImage*, il2cpp_get_corlib, () );
9 | DO_API( void, il2cpp_add_internal_call, (const char* name, Il2CppMethodPointer method) );
10 | DO_API( Il2CppMethodPointer, il2cpp_resolve_icall, (const char* name) );
11 |
12 | DO_API( void*, il2cpp_alloc, (size_t size) );
13 | DO_API( void, il2cpp_free, (void* ptr) );
14 |
15 | // array
16 | DO_API( Il2CppClass*, il2cpp_array_class_get, (Il2CppClass *element_class, uint32_t rank) );
17 | DO_API( uint32_t, il2cpp_array_length, (Il2CppArray* array) );
18 | DO_API( uint32_t, il2cpp_array_get_byte_length, (Il2CppArray *array) );
19 | DO_API( Il2CppArray*, il2cpp_array_new, (Il2CppClass *elementTypeInfo, il2cpp_array_size_t length) );
20 | DO_API( Il2CppArray*, il2cpp_array_new_specific, (Il2CppClass *arrayTypeInfo, il2cpp_array_size_t length) );
21 | DO_API( Il2CppArray*, il2cpp_array_new_full, (Il2CppClass *array_class, il2cpp_array_size_t *lengths, il2cpp_array_size_t *lower_bounds) );
22 | DO_API( Il2CppClass*, il2cpp_bounded_array_class_get, (Il2CppClass *element_class, uint32_t rank, bool bounded) );
23 | DO_API( int, il2cpp_array_element_size, (const Il2CppClass* array_class) );
24 |
25 | // assembly
26 | DO_API( const Il2CppImage*, il2cpp_assembly_get_image, (const Il2CppAssembly *assembly) );
27 |
28 | // class
29 | DO_API( const Il2CppType*, il2cpp_class_enum_basetype, (Il2CppClass *klass) );
30 | DO_API( bool, il2cpp_class_is_generic, (const Il2CppClass *klass) );
31 | DO_API( bool, il2cpp_class_is_inflated, (const Il2CppClass *klass) );
32 | DO_API( bool, il2cpp_class_is_assignable_from, (Il2CppClass *klass, Il2CppClass *oklass) );
33 | DO_API( bool, il2cpp_class_is_subclass_of, (Il2CppClass *klass, Il2CppClass *klassc, bool check_interfaces) );
34 | DO_API( bool, il2cpp_class_has_parent, (Il2CppClass* klass, Il2CppClass* klassc) );
35 | DO_API( Il2CppClass*, il2cpp_class_from_il2cpp_type, (const Il2CppType* type) );
36 | DO_API( Il2CppClass*, il2cpp_class_from_name, (const Il2CppImage* image, const char* namespaze, const char *name) );
37 | DO_API( Il2CppClass*, il2cpp_class_from_system_type, (Il2CppReflectionType *type) );
38 | DO_API( Il2CppClass*, il2cpp_class_get_element_class, (Il2CppClass *klass) );
39 | DO_API( const EventInfo*, il2cpp_class_get_events, (Il2CppClass *klass, void* *iter));
40 | DO_API( FieldInfo*, il2cpp_class_get_fields, (Il2CppClass *klass, void* *iter) );
41 | DO_API( Il2CppClass*, il2cpp_class_get_nested_types, (Il2CppClass *klass, void* *iter) );
42 | DO_API( Il2CppClass*, il2cpp_class_get_interfaces, (Il2CppClass *klass, void* *iter) );
43 | DO_API( const PropertyInfo*, il2cpp_class_get_properties, (Il2CppClass *klass, void* *iter) );
44 | DO_API( const PropertyInfo*, il2cpp_class_get_property_from_name, (Il2CppClass *klass, const char *name) );
45 | DO_API( FieldInfo*, il2cpp_class_get_field_from_name, (Il2CppClass* klass, const char *name) );
46 | DO_API( const MethodInfo*, il2cpp_class_get_methods, (Il2CppClass *klass, void* *iter) );
47 | DO_API( const MethodInfo*, il2cpp_class_get_method_from_name, (Il2CppClass *klass, const char* name, int argsCount) );
48 | DO_API( const char*, il2cpp_class_get_name, (Il2CppClass *klass) );
49 | DO_API( const char*, il2cpp_class_get_namespace, (Il2CppClass *klass) );
50 | DO_API( Il2CppClass*, il2cpp_class_get_parent, (Il2CppClass *klass) );
51 | DO_API( Il2CppClass*, il2cpp_class_get_declaring_type, (Il2CppClass *klass) );
52 | DO_API( int32_t, il2cpp_class_instance_size, (Il2CppClass *klass) );
53 | DO_API( size_t, il2cpp_class_num_fields, (const Il2CppClass* enumKlass) );
54 | DO_API( bool, il2cpp_class_is_valuetype, (const Il2CppClass *klass) );
55 | DO_API( int32_t, il2cpp_class_value_size, (Il2CppClass *klass, uint32_t *align) );
56 | DO_API( int, il2cpp_class_get_flags, (const Il2CppClass *klass) );
57 | DO_API( bool, il2cpp_class_is_abstract, (const Il2CppClass *klass) );
58 | DO_API( bool, il2cpp_class_is_interface, (const Il2CppClass *klass) );
59 | DO_API( int, il2cpp_class_array_element_size, (const Il2CppClass *klass) );
60 | DO_API( Il2CppClass*, il2cpp_class_from_type, (const Il2CppType *type) );
61 | DO_API( const Il2CppType*, il2cpp_class_get_type, (Il2CppClass *klass) );
62 | DO_API( bool, il2cpp_class_has_attribute, (Il2CppClass *klass, Il2CppClass *attr_class) );
63 | DO_API( bool, il2cpp_class_has_references, (Il2CppClass *klass) );
64 | DO_API( bool, il2cpp_class_is_enum, (const Il2CppClass *klass) );
65 | DO_API( const Il2CppImage*, il2cpp_class_get_image, (Il2CppClass* klass) );
66 | DO_API( const char*, il2cpp_class_get_assemblyname, (const Il2CppClass *klass) );
67 |
68 | // testing only
69 | DO_API( size_t, il2cpp_class_get_bitmap_size, (const Il2CppClass *klass) );
70 | DO_API( void, il2cpp_class_get_bitmap, (Il2CppClass *klass, size_t* bitmap) );
71 |
72 | // stats
73 | DO_API( bool, il2cpp_stats_dump_to_file, (const char *path) );
74 | DO_API( uint64_t, il2cpp_stats_get_value, (Il2CppStat stat) );
75 |
76 | // domain
77 | DO_API( Il2CppDomain*, il2cpp_domain_get, () );
78 | DO_API( const Il2CppAssembly*, il2cpp_domain_assembly_open, (Il2CppDomain* domain, const char* name) );
79 | DO_API( const Il2CppAssembly**, il2cpp_domain_get_assemblies, (const Il2CppDomain* domain, size_t* size) );
80 |
81 | // exception
82 | DO_API( void, il2cpp_raise_exception, (Il2CppException*) );
83 | DO_API( Il2CppException*, il2cpp_exception_from_name_msg, (const Il2CppImage* image, const char *name_space, const char *name, const char *msg) );
84 | DO_API( Il2CppException*, il2cpp_get_exception_argument_null, (const char *arg) );
85 | DO_API( void, il2cpp_format_exception, (const Il2CppException* ex, char* message, int message_size) );
86 | DO_API( void, il2cpp_format_stack_trace, (const Il2CppException* ex, char* output, int output_size) );
87 | DO_API( void, il2cpp_unhandled_exception, (Il2CppException*) );
88 |
89 | // field
90 | DO_API( int, il2cpp_field_get_flags, (FieldInfo *field) );
91 | DO_API( const char*, il2cpp_field_get_name, (FieldInfo *field) );
92 | DO_API( Il2CppClass*, il2cpp_field_get_parent, (FieldInfo *field) );
93 | DO_API( size_t, il2cpp_field_get_offset, (FieldInfo *field) );
94 | DO_API( const Il2CppType*, il2cpp_field_get_type, (FieldInfo *field) );
95 | DO_API( void, il2cpp_field_get_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
96 | DO_API( Il2CppObject*, il2cpp_field_get_value_object, (FieldInfo *field, Il2CppObject *obj) );
97 | DO_API( bool, il2cpp_field_has_attribute, (FieldInfo *field, Il2CppClass *attr_class) );
98 | DO_API( void, il2cpp_field_set_value, (Il2CppObject *obj, FieldInfo *field, void *value) );
99 | DO_API( void, il2cpp_field_static_get_value, (FieldInfo *field, void *value) );
100 | DO_API( void, il2cpp_field_static_set_value, (FieldInfo *field, void *value) );
101 |
102 | // gc
103 | DO_API( void, il2cpp_gc_collect, (int maxGenerations) );
104 | DO_API( int32_t, il2cpp_gc_collect_a_little, ());
105 | DO_API( void, il2cpp_gc_disable, ());
106 | DO_API( void, il2cpp_gc_enable, () );
107 | DO_API( int64_t, il2cpp_gc_get_used_size, () );
108 | DO_API( int64_t, il2cpp_gc_get_heap_size, () );
109 |
110 | // gchandle
111 | DO_API( uint32_t, il2cpp_gchandle_new, (Il2CppObject *obj, bool pinned) );
112 | DO_API( uint32_t, il2cpp_gchandle_new_weakref, (Il2CppObject *obj, bool track_resurrection) );
113 | DO_API( Il2CppObject*, il2cpp_gchandle_get_target , (uint32_t gchandle) );
114 | DO_API( void, il2cpp_gchandle_free, (uint32_t gchandle) );
115 |
116 | // liveness
117 | DO_API( void*, il2cpp_unity_liveness_calculation_begin, (Il2CppClass* filter, int max_object_count, il2cpp_register_object_callback callback, void* userdata, il2cpp_WorldChangedCallback onWorldStarted, il2cpp_WorldChangedCallback onWorldStopped) );
118 | DO_API( void, il2cpp_unity_liveness_calculation_end, (void* state) );
119 | DO_API( void, il2cpp_unity_liveness_calculation_from_root, (Il2CppObject* root, void* state) );
120 | DO_API( void, il2cpp_unity_liveness_calculation_from_statics, (void* state) );
121 |
122 | // method
123 | DO_API( const Il2CppType*, il2cpp_method_get_return_type, (const MethodInfo* method) );
124 | DO_API( Il2CppClass*, il2cpp_method_get_declaring_type, (const MethodInfo* method) );
125 | DO_API( const char*, il2cpp_method_get_name, (const MethodInfo *method) );
126 | DO_API( Il2CppReflectionMethod*, il2cpp_method_get_object, (const MethodInfo *method, Il2CppClass *refclass) );
127 | DO_API( bool, il2cpp_method_is_generic, (const MethodInfo *method) );
128 | DO_API( bool, il2cpp_method_is_inflated, (const MethodInfo *method) );
129 | DO_API( bool, il2cpp_method_is_instance, (const MethodInfo *method) );
130 | DO_API( uint32_t, il2cpp_method_get_param_count, (const MethodInfo *method) );
131 | DO_API( const Il2CppType*, il2cpp_method_get_param, (const MethodInfo *method, uint32_t index) );
132 | DO_API( Il2CppClass*, il2cpp_method_get_class, (const MethodInfo *method) );
133 | DO_API( bool, il2cpp_method_has_attribute, (const MethodInfo *method, Il2CppClass *attr_class) );
134 | DO_API( uint32_t, il2cpp_method_get_flags, (const MethodInfo *method, uint32_t *iflags) );
135 | DO_API( uint32_t, il2cpp_method_get_token, (const MethodInfo *method) );
136 | DO_API( const char*, il2cpp_method_get_param_name, (const MethodInfo *method, uint32_t index) );
137 |
138 | // profiler
139 | #if IL2CPP_ENABLE_PROFILER
140 |
141 | DO_API( void, il2cpp_profiler_install, (Il2CppProfiler *prof, Il2CppProfileFunc shutdown_callback) );
142 | DO_API( void, il2cpp_profiler_set_events, (Il2CppProfileFlags events) );
143 | DO_API( void, il2cpp_profiler_install_enter_leave, (Il2CppProfileMethodFunc enter, Il2CppProfileMethodFunc fleave) );
144 | DO_API( void, il2cpp_profiler_install_allocation, (Il2CppProfileAllocFunc callback) );
145 | DO_API( void, il2cpp_profiler_install_gc, (Il2CppProfileGCFunc callback, Il2CppProfileGCResizeFunc heap_resize_callback) );
146 |
147 | #endif
148 |
149 | // property
150 | DO_API( uint32_t, il2cpp_property_get_flags, (PropertyInfo *prop) );
151 | DO_API( const MethodInfo*, il2cpp_property_get_get_method, (PropertyInfo *prop) );
152 | DO_API( const MethodInfo*, il2cpp_property_get_set_method, (PropertyInfo *prop) );
153 | DO_API( const char*, il2cpp_property_get_name, (PropertyInfo *prop) );
154 | DO_API( Il2CppClass*, il2cpp_property_get_parent, (PropertyInfo *prop) );
155 |
156 | // object
157 | DO_API( Il2CppClass*, il2cpp_object_get_class, (Il2CppObject* obj) );
158 | DO_API( uint32_t, il2cpp_object_get_size, (Il2CppObject* obj) );
159 | DO_API( const MethodInfo*, il2cpp_object_get_virtual_method, (Il2CppObject *obj, const MethodInfo *method) );
160 | DO_API( Il2CppObject*, il2cpp_object_new, (const Il2CppClass *klass) );
161 | DO_API( void*, il2cpp_object_unbox, (Il2CppObject* obj) );
162 |
163 | DO_API( Il2CppObject*, il2cpp_value_box, (Il2CppClass *klass, void* data) );
164 |
165 | // monitor
166 | DO_API( void, il2cpp_monitor_enter, (Il2CppObject* obj) );
167 | DO_API( bool, il2cpp_monitor_try_enter, (Il2CppObject* obj, uint32_t timeout) );
168 | DO_API( void, il2cpp_monitor_exit, (Il2CppObject* obj) );
169 | DO_API( void, il2cpp_monitor_pulse, (Il2CppObject* obj) );
170 | DO_API( void, il2cpp_monitor_pulse_all, (Il2CppObject* obj) );
171 | DO_API( void, il2cpp_monitor_wait, (Il2CppObject* obj) );
172 | DO_API( bool, il2cpp_monitor_try_wait, (Il2CppObject* obj, uint32_t timeout) );
173 |
174 | // runtime
175 | DO_API( Il2CppObject*, il2cpp_runtime_invoke, (const MethodInfo *method, void *obj, void **params, Il2CppException **exc) );
176 | DO_API( Il2CppObject*, il2cpp_runtime_invoke_convert_args, (const MethodInfo *method, void *obj, Il2CppObject **params, int paramCount, Il2CppException **exc) );
177 | DO_API( void, il2cpp_runtime_class_init, (Il2CppClass* klass) );
178 | DO_API( void, il2cpp_runtime_object_init, (Il2CppObject* obj) );
179 |
180 | DO_API( void, il2cpp_runtime_object_init_exception, (Il2CppObject* obj, Il2CppException** exc) );
181 |
182 | DO_API( void, il2cpp_runtime_unhandled_exception_policy_set, (Il2CppRuntimeUnhandledExceptionPolicy value) );
183 |
184 | // delegate
185 | DO_API( Il2CppAsyncResult*, il2cpp_delegate_begin_invoke, (Il2CppDelegate* delegate, void** params, Il2CppDelegate* asyncCallback, Il2CppObject* state) );
186 | DO_API( Il2CppObject*, il2cpp_delegate_end_invoke, (Il2CppAsyncResult* asyncResult, void **out_args) );
187 |
188 | // string
189 | DO_API( int32_t, il2cpp_string_length, (Il2CppString* str) );
190 | DO_API( Il2CppChar*, il2cpp_string_chars, (Il2CppString* str) );
191 | DO_API( Il2CppString*, il2cpp_string_new, (const char* str) );
192 | DO_API( Il2CppString*, il2cpp_string_new_len, (const char* str, uint32_t length) );
193 | DO_API( Il2CppString*, il2cpp_string_new_utf16, (const Il2CppChar *text, int32_t len) );
194 | DO_API( Il2CppString*, il2cpp_string_new_wrapper, (const char* str) );
195 | DO_API( Il2CppString*, il2cpp_string_intern, (Il2CppString* str) );
196 | DO_API( Il2CppString*, il2cpp_string_is_interned, (Il2CppString* str) );
197 |
198 | // thread
199 | DO_API( char*, il2cpp_thread_get_name, (Il2CppThread *thread, uint32_t *len) );
200 | DO_API( Il2CppThread*, il2cpp_thread_current, () );
201 | DO_API( Il2CppThread*, il2cpp_thread_attach, (Il2CppDomain *domain) );
202 | DO_API( void, il2cpp_thread_detach, (Il2CppThread *thread) );
203 |
204 | DO_API( Il2CppThread**, il2cpp_thread_get_all_attached_threads, (size_t *size) );
205 | DO_API( bool, il2cpp_is_vm_thread, (Il2CppThread *thread) );
206 |
207 | // stacktrace
208 | DO_API( void, il2cpp_current_thread_walk_frame_stack, (Il2CppFrameWalkFunc func, void* user_data) );
209 | DO_API( void, il2cpp_thread_walk_frame_stack, (Il2CppThread* thread, Il2CppFrameWalkFunc func, void* user_data) );
210 | DO_API( bool, il2cpp_current_thread_get_top_frame, (Il2CppStackFrameInfo& frame) );
211 | DO_API( bool, il2cpp_thread_get_top_frame, (Il2CppThread* thread, Il2CppStackFrameInfo& frame) );
212 | DO_API( bool, il2cpp_current_thread_get_frame_at, (int32_t offset, Il2CppStackFrameInfo& frame) );
213 | DO_API( bool, il2cpp_thread_get_frame_at, (Il2CppThread* thread, int32_t offset, Il2CppStackFrameInfo& frame) );
214 | DO_API( int32_t, il2cpp_current_thread_get_stack_depth, () );
215 | DO_API( int32_t, il2cpp_thread_get_stack_depth, (Il2CppThread *thread) );
216 |
217 | // type
218 | DO_API( Il2CppObject*, il2cpp_type_get_object, (const Il2CppType *type) );
219 | DO_API( int, il2cpp_type_get_type, (const Il2CppType *type) );
220 | DO_API( Il2CppClass*, il2cpp_type_get_class_or_element_class, (const Il2CppType *type) );
221 | DO_API( char*, il2cpp_type_get_name, (const Il2CppType *type) );
222 |
223 | // image
224 | DO_API( const Il2CppAssembly*, il2cpp_image_get_assembly, (const Il2CppImage *image) );
225 | DO_API( const char*, il2cpp_image_get_name, (const Il2CppImage *image) );
226 | DO_API( const char*, il2cpp_image_get_filename, (const Il2CppImage *image) );
227 | DO_API( const MethodInfo*, il2cpp_image_get_entry_point, (const Il2CppImage* image) );
228 |
229 | // Memory information
230 | DO_API( Il2CppManagedMemorySnapshot*, il2cpp_capture_memory_snapshot, () );
231 | DO_API( void, il2cpp_free_captured_memory_snapshot, (Il2CppManagedMemorySnapshot* snapshot) );
232 |
233 | DO_API(void, il2cpp_set_find_plugin_callback, (Il2CppSetFindPlugInCallback method));
234 |
235 | #if IL2CPP_DEBUGGER_ENABLED
236 | // debug
237 | DO_API( const Il2CppDebugTypeInfo*, il2cpp_debug_get_class_info, (const Il2CppClass *klass) );
238 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_class_get_document, (const Il2CppDebugTypeInfo* info) );
239 | DO_API( const char*, il2cpp_debug_document_get_filename, (const Il2CppDebugDocument* document) );
240 | DO_API( const char*, il2cpp_debug_document_get_directory, (const Il2CppDebugDocument* document) );
241 | DO_API( const Il2CppDebugMethodInfo*, il2cpp_debug_get_method_info, (const MethodInfo *method) );
242 | DO_API( const Il2CppDebugDocument*, il2cpp_debug_method_get_document, (const Il2CppDebugMethodInfo* info) );
243 | DO_API( const int32_t*, il2cpp_debug_method_get_offset_table, (const Il2CppDebugMethodInfo* info) );
244 | DO_API( size_t, il2cpp_debug_method_get_code_size, (const Il2CppDebugMethodInfo* info) );
245 | DO_API( void, il2cpp_debug_update_frame_il_offset, (int32_t il_offset) );
246 | DO_API( const Il2CppDebugLocalsInfo**, il2cpp_debug_method_get_locals_info, (const Il2CppDebugMethodInfo* info) );
247 | DO_API( const Il2CppClass*, il2cpp_debug_local_get_type, (const Il2CppDebugLocalsInfo *info) );
248 | DO_API( const char*, il2cpp_debug_local_get_name, (const Il2CppDebugLocalsInfo *info) );
249 | DO_API( uint32_t, il2cpp_debug_local_get_start_offset, (const Il2CppDebugLocalsInfo *info) );
250 | DO_API( uint32_t, il2cpp_debug_local_get_end_offset, (const Il2CppDebugLocalsInfo *info) );
251 | DO_API( Il2CppObject*, il2cpp_debug_method_get_param_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
252 | DO_API( Il2CppObject*, il2cpp_debug_frame_get_local_value, (const Il2CppStackFrameInfo *info, uint32_t position) );
253 | DO_API( void*, il2cpp_debug_method_get_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, int64_t uid, int32_t offset) );
254 | DO_API( void, il2cpp_debug_method_set_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location, void *data) );
255 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data, (const Il2CppDebugMethodInfo* info) );
256 | DO_API( void, il2cpp_debug_method_clear_breakpoint_data_at, (const Il2CppDebugMethodInfo* info, uint64_t location) );
257 | #endif
258 |
--------------------------------------------------------------------------------
/app/src/main/cpp/Includes/log.h:
--------------------------------------------------------------------------------
1 | //
2 | // Created by Perfare on 2020/7/4.
3 | //
4 |
5 | #ifndef RIRU_IL2CPPDUMPER_LOG_H
6 | #define RIRU_IL2CPPDUMPER_LOG_H
7 |
8 | #include
9 |
10 | #define LOG_TAG "DUMPER"
11 | #define LOGD(...) __android_log_print(ANDROID_LOG_DEBUG, LOG_TAG, __VA_ARGS__)
12 | #define LOGW(...) __android_log_print(ANDROID_LOG_WARN, LOG_TAG, __VA_ARGS__)
13 | #define LOGE(...) __android_log_print(ANDROID_LOG_ERROR, LOG_TAG, __VA_ARGS__)
14 | #define LOGI(...) __android_log_print(ANDROID_LOG_INFO, LOG_TAG, __VA_ARGS__)
15 |
16 | #endif //RIRU_IL2CPPDUMPER_LOG_H
17 |
--------------------------------------------------------------------------------
/app/src/main/cpp/native-lib.cpp:
--------------------------------------------------------------------------------
1 | #include
2 | #include
3 | #include
4 | #include
5 | #include
6 | #include "Includes/il2cpp_dump.h"
7 |
8 | bool isLibraryLoaded(const char *libraryName) {
9 | char line[512] = {0};
10 | FILE *fp = fopen("/proc/self/maps", "rt");
11 | if (fp != nullptr) {
12 | while (fgets(line, sizeof(line), fp)) {
13 | if (strstr(line, libraryName)) {
14 | return true;
15 | }
16 | }
17 | fclose(fp);
18 | }
19 | return false;
20 | }
21 | #define libTarget "libil2cpp.so"
22 |
23 | void *hack_thread(void *) {
24 | do {
25 | sleep(1);
26 | } while (!isLibraryLoaded(libTarget));
27 | sleep(10); //waiting libil2cpp.so fully loaded
28 | auto il2cpp_handle = dlopen(libTarget, 4);
29 | il2cpp_dump(il2cpp_handle, "/sdcard/Download");
30 | return nullptr;
31 | }
32 |
33 | __attribute__((constructor))
34 | void lib_main() {
35 | // Create a new thread so it does not block the main thread, means the game would not freeze
36 | pthread_t ptid;
37 | pthread_create(&ptid, nullptr, hack_thread, nullptr);
38 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/il2cpp/dumper/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.il2cpp.dumper
2 |
3 | import android.app.Activity
4 | import android.os.Bundle
5 | import android.os.PersistableBundle
6 |
7 | class MainActivity : Activity() {
8 | override fun onCreate(savedInstanceState: Bundle?, persistentState: PersistableBundle?) {
9 | super.onCreate(savedInstanceState, persistentState)
10 | setContentView(R.layout.activity_main)
11 | }
12 |
13 | companion object {
14 | init {
15 | System.loadLibrary("native-lib")
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/app/src/main/res/drawable-v24/ic_launcher_foreground.xml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
15 |
18 |
21 |
22 |
23 |
24 |
30 |
--------------------------------------------------------------------------------
/app/src/main/res/drawable/ic_launcher_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
10 |
15 |
20 |
25 |
30 |
35 |
40 |
45 |
50 |
55 |
60 |
65 |
70 |
75 |
80 |
85 |
90 |
95 |
100 |
105 |
110 |
115 |
120 |
125 |
130 |
135 |
140 |
145 |
150 |
155 |
160 |
165 |
170 |
171 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #FFBB86FC
4 | #FF6200EE
5 | #FF3700B3
6 | #FF03DAC5
7 | #FF018786
8 | #FF000000
9 | #FFFFFFFF
10 |
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | Auto-Il2cppDumper
3 |
--------------------------------------------------------------------------------
/app/src/main/res/values/themes.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 | buildscript {
3 | ext.kotlin_version = "1.4.32"
4 | repositories {
5 | google()
6 | jcenter()
7 | }
8 | dependencies {
9 | classpath "com.android.tools.build:gradle:4.1.3"
10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
11 |
12 | // NOTE: Do not place your application dependencies here; they belong
13 | // in the individual module build.gradle files
14 | }
15 | }
16 |
17 | allprojects {
18 | repositories {
19 | google()
20 | jcenter()
21 | }
22 | }
23 |
24 | task clean(type: Delete) {
25 | delete rootProject.buildDir
26 | }
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 | # IDE (e.g. Android Studio) users:
3 | # Gradle settings configured through the IDE *will override*
4 | # any settings specified in this file.
5 | # For more details on how to configure your build environment visit
6 | # http://www.gradle.org/docs/current/userguide/build_environment.html
7 | # Specifies the JVM arguments used for the daemon process.
8 | # The setting is particularly useful for tweaking memory settings.
9 | org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
10 | # When configured, Gradle will run in incubating parallel mode.
11 | # This option should only be used with decoupled projects. More details, visit
12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
13 | # org.gradle.parallel=true
14 | # AndroidX package structure to make it clearer which packages are bundled with the
15 | # Android operating system, and which are packaged with your app"s APK
16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn
17 | android.useAndroidX=true
18 | # Automatically convert third-party libraries to use AndroidX
19 | android.enableJetifier=true
20 | # Kotlin code style for this project: "official" or "obsolete":
21 | kotlin.code.style=official
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Avatarchik/Auto-Il2cppDumper/e2c1f99175def5f3a795b71d1e1d9d56ff8b0aaa/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Thu Apr 29 20:48:33 ICT 2021
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-bin.zip
7 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Attempt to set APP_HOME
10 | # Resolve links: $0 may be a link
11 | PRG="$0"
12 | # Need this for relative symlinks.
13 | while [ -h "$PRG" ] ; do
14 | ls=`ls -ld "$PRG"`
15 | link=`expr "$ls" : '.*-> \(.*\)$'`
16 | if expr "$link" : '/.*' > /dev/null; then
17 | PRG="$link"
18 | else
19 | PRG=`dirname "$PRG"`"/$link"
20 | fi
21 | done
22 | SAVED="`pwd`"
23 | cd "`dirname \"$PRG\"`/" >/dev/null
24 | APP_HOME="`pwd -P`"
25 | cd "$SAVED" >/dev/null
26 |
27 | APP_NAME="Gradle"
28 | APP_BASE_NAME=`basename "$0"`
29 |
30 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
31 | DEFAULT_JVM_OPTS=""
32 |
33 | # Use the maximum available, or set MAX_FD != -1 to use that value.
34 | MAX_FD="maximum"
35 |
36 | warn () {
37 | echo "$*"
38 | }
39 |
40 | die () {
41 | echo
42 | echo "$*"
43 | echo
44 | exit 1
45 | }
46 |
47 | # OS specific support (must be 'true' or 'false').
48 | cygwin=false
49 | msys=false
50 | darwin=false
51 | nonstop=false
52 | case "`uname`" in
53 | CYGWIN* )
54 | cygwin=true
55 | ;;
56 | Darwin* )
57 | darwin=true
58 | ;;
59 | MINGW* )
60 | msys=true
61 | ;;
62 | NONSTOP* )
63 | nonstop=true
64 | ;;
65 | esac
66 |
67 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
68 |
69 | # Determine the Java command to use to start the JVM.
70 | if [ -n "$JAVA_HOME" ] ; then
71 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
72 | # IBM's JDK on AIX uses strange locations for the executables
73 | JAVACMD="$JAVA_HOME/jre/sh/java"
74 | else
75 | JAVACMD="$JAVA_HOME/bin/java"
76 | fi
77 | if [ ! -x "$JAVACMD" ] ; then
78 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
79 |
80 | Please set the JAVA_HOME variable in your environment to match the
81 | location of your Java installation."
82 | fi
83 | else
84 | JAVACMD="java"
85 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
86 |
87 | Please set the JAVA_HOME variable in your environment to match the
88 | location of your Java installation."
89 | fi
90 |
91 | # Increase the maximum file descriptors if we can.
92 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
93 | MAX_FD_LIMIT=`ulimit -H -n`
94 | if [ $? -eq 0 ] ; then
95 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
96 | MAX_FD="$MAX_FD_LIMIT"
97 | fi
98 | ulimit -n $MAX_FD
99 | if [ $? -ne 0 ] ; then
100 | warn "Could not set maximum file descriptor limit: $MAX_FD"
101 | fi
102 | else
103 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
104 | fi
105 | fi
106 |
107 | # For Darwin, add options to specify how the application appears in the dock
108 | if $darwin; then
109 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
110 | fi
111 |
112 | # For Cygwin, switch paths to Windows format before running java
113 | if $cygwin ; then
114 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
115 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
116 | JAVACMD=`cygpath --unix "$JAVACMD"`
117 |
118 | # We build the pattern for arguments to be converted via cygpath
119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120 | SEP=""
121 | for dir in $ROOTDIRSRAW ; do
122 | ROOTDIRS="$ROOTDIRS$SEP$dir"
123 | SEP="|"
124 | done
125 | OURCYGPATTERN="(^($ROOTDIRS))"
126 | # Add a user-defined pattern to the cygpath arguments
127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
129 | fi
130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
131 | i=0
132 | for arg in "$@" ; do
133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
135 |
136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
138 | else
139 | eval `echo args$i`="\"$arg\""
140 | fi
141 | i=$((i+1))
142 | done
143 | case $i in
144 | (0) set -- ;;
145 | (1) set -- "$args0" ;;
146 | (2) set -- "$args0" "$args1" ;;
147 | (3) set -- "$args0" "$args1" "$args2" ;;
148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
154 | esac
155 | fi
156 |
157 | # Escape application args
158 | save () {
159 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
160 | echo " "
161 | }
162 | APP_ARGS=$(save "$@")
163 |
164 | # Collect all arguments for the java command, following the shell quoting and substitution rules
165 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
166 |
167 | # by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
168 | if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
169 | cd "$(dirname "$0")"
170 | fi
171 |
172 | exec "$JAVACMD" "$@"
173 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | set DIRNAME=%~dp0
12 | if "%DIRNAME%" == "" set DIRNAME=.
13 | set APP_BASE_NAME=%~n0
14 | set APP_HOME=%DIRNAME%
15 |
16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
17 | set DEFAULT_JVM_OPTS=
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windows variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 |
53 | :win9xME_args
54 | @rem Slurp the command line arguments.
55 | set CMD_LINE_ARGS=
56 | set _SKIP=2
57 |
58 | :win9xME_args_slurp
59 | if "x%~1" == "x" goto execute
60 |
61 | set CMD_LINE_ARGS=%*
62 |
63 | :execute
64 | @rem Setup the command line
65 |
66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
67 |
68 | @rem Execute Gradle
69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
70 |
71 | :end
72 | @rem End local scope for the variables with windows NT shell
73 | if "%ERRORLEVEL%"=="0" goto mainEnd
74 |
75 | :fail
76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
77 | rem the _cmd.exe /c_ return code!
78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
79 | exit /b 1
80 |
81 | :mainEnd
82 | if "%OS%"=="Windows_NT" endlocal
83 |
84 | :omega
85 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 | rootProject.name = "Auto-Il2cppDumper"
--------------------------------------------------------------------------------