mirror of
https://github.com/godotengine/godot.git
synced 2025-10-20 00:13:30 +00:00
Leverage java annotations to simplify the logic used to register the Godot plugin methods.
This commit is contained in:
parent
3ddab1c9d1
commit
94df08aae1
9 changed files with 245 additions and 65 deletions
|
@ -201,7 +201,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_setup(JNIEnv *env, jc
|
|||
}
|
||||
|
||||
if (err != OK) {
|
||||
return; //should exit instead and print the error
|
||||
return; // should exit instead and print the error
|
||||
}
|
||||
|
||||
java_class_wrapper = memnew(JavaClassWrapper(godot_java->get_activity()));
|
||||
|
@ -252,9 +252,10 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_step(JNIEnv *env, jcl
|
|||
|
||||
if (step == 1) {
|
||||
if (!Main::start()) {
|
||||
return; //should exit instead and print the error
|
||||
return; // should exit instead and print the error
|
||||
}
|
||||
|
||||
godot_java->on_godot_setup_completed(env);
|
||||
os_android->main_loop_begin();
|
||||
godot_java->on_godot_main_loop_started(env);
|
||||
++step;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue