Closed TheTrope closed 6 years ago
I was fighting the same issue - and did not understand why for a (too) long time. It is only a typo :
In https://github.com/godotengine/godot-demo-projects/blob/master/misc/android_iap/iap.gd
if Engine.has_singleton("GodotPayment"):
payment = Engine.get_singleton("GodotPayments")
should obviously be:
if Engine.has_singleton("GodotPayments"):
payment = Engine.get_singleton("GodotPayments")
(missing "s")
Oh right ! Typo error, ohhhhhh Thank you, I'll have a try this evening !
But then, I was thinking it was a common issue with the one I had, trying to use Firebase android module (https://github.com/FrogSquare/GodotFireBase/issues) with my custom build and templates
I've been following the steps closely, and I got the module loaded
LOADING MODULE: org/godotengine/godot/FireBase without error in adb
but then :
Engine.has_singleton('FireBase') -> is False
What would be the issue in this case? Maybe It's possible to display/debug the list of existing singletons? Thanks
I still have the same problem, fixing the typo didn't help.
Logcat gives this error. It looks like a parsing error, but the scripts seem fine to me (they're the standard ones from the example, with the typo fix).
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/Adreno-GSL: <gsl_memory_alloc_pure:2207>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **SCRIPT ERROR**: Parse Error: Unexpected token: ':':Control
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: res://iap_demo.gdc:2:GDScript::load_byte_code() - Parse Error: Unexpected token: ':':Control
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Method/Function Failed, returning: ERR_PARSE_ERROR
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: modules/gdscript/gdscript.cpp:771:load_byte_code() - Method/Function Failed, returning: ERR_PARSE_ERROR
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Condition ' err != OK ' is true. returned: RES()
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: modules/gdscript/gdscript.cpp:2115:load() - Condition ' err != OK ' is true. returned: RES()
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Failed loading resource: res://iap_demo.gdc
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: core/io/resource_loader.cpp:192:_load() - Method/Function Failed, returning: RES()
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: res://main.tscn:3 - Parse Error: [ext_resource] referenced nonexistent resource at: res://iap_demo.gd
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: scene/resources/scene_format_text.cpp:439:poll() - res://main.tscn:3 - Parse Error: [ext_resource] referenced nonexistent resource at: res://iap_demo.gd
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Condition ' err != OK ' is true. returned: RES()
2018-11-16 21:21:38.212 18129-18181/org.godotengine.androidiap E/godot: At: core/io/resource_loader.cpp:155:load() - Condition ' err != OK ' is true. returned: RES()
2018-11-16 21:21:38.213 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Failed loading resource: res://main.tscn
2018-11-16 21:21:38.213 18129-18181/org.godotengine.androidiap E/godot: At: core/io/resource_loader.cpp:192:_load() - Method/Function Failed, returning: RES()
2018-11-16 21:21:38.213 18129-18181/org.godotengine.androidiap E/godot: **ERROR**: Failed loading scene: res://main.tscn
2018-11-16 21:21:38.213 18129-18181/org.godotengine.androidiap E/godot: At: main/main.cpp:1670:start() - Condition ' !scene ' is true. returned: false
2018-11-16 21:21:38.216 1060-3067/? E/AudioFlinger: open /proc/18129/cmdline error
2018-11-16 21:21:38.361 2546-2546/? E/PropertyValuesHolder: java.lang.reflect.InvocationTargetException
2018-11-16 21:21:38.361 2546-2546/? E/PropertyValuesHolder: java.lang.reflect.InvocationTargetException
2018-11-16 21:21:38.544 684-732/? E/ANDR-PERF-OPTSHANDLER: perf_lock_rel: updated /sys/class/scsi_host/host0/../../../clkscale_enable with 1
return value 2
2018-11-16 21:21:54.764 18249-18249/? E/wet: Sync is not initialized yet
@jabcross The log sounds like you're using Android templates which don't match your editor version. You need templates built from the same git commit. The assert failure in the editor is normal, the singleton is only available on Android.
Thanks, I really had a dirty template.
Tried again, with fresh install of Godot and demo-projects.
On Android, the game freezes on the Godot game engine splash screen.
Output of logcat:
2018-11-21 14:25:14.988 1261-1261/? E/MSM-irqbalance: IRQ 79 not found in internal structure or should be ignored
2018-11-21 14:25:16.318 684-732/? E/ANDR-PERF-REQUEST: Failed to set timer
2018-11-21 14:25:17.896 1652-1708/? E/ANDR-PERF-JNI: com_qualcomm_qtiperformance_native_perf_io_prefetch_start
2018-11-21 14:25:17.896 683-683/? E/ANDR-IOP: IOP HAL: Received pkg_name = org.godotengine.androidiap pid = -1
2018-11-21 14:25:17.900 1652-1708/? E/ActivityTrigger: activityStartTrigger: not whiteListedorg.godotengine.androidiap/org.godotengine.godot.Godot/1
2018-11-21 14:25:17.901 1652-1708/? E/ActivityTrigger: activityResumeTrigger: not whiteListedorg.godotengine.androidiap/org.godotengine.godot.Godot/1
2018-11-21 14:25:17.910 683-744/? E/ANDR-IOP: is_in_recent_list is TRUE
2018-11-21 14:25:17.910 683-744/? E/ANDR-IOP: io prefetch is deactivate
2018-11-21 14:25:17.929 1652-1708/? E/ActivityTrigger: activityResumeTrigger: not whiteListedorg.godotengine.androidiap/org.godotengine.godot.Godot/1
2018-11-21 14:25:18.078 2546-2546/? E/PropertyValuesHolder: java.lang.reflect.InvocationTargetException
2018-11-21 14:25:18.078 2546-2546/? E/PropertyValuesHolder: java.lang.reflect.InvocationTargetException
2018-11-21 14:25:18.309 1060-6682/? E/AudioFlinger: open /proc/25485/cmdline error
2018-11-21 14:25:18.310 660-3070/? E/msm8974_platform: platform_check_backends_match: Invalid snd_device =
2018-11-21 14:25:18.310 660-3070/? E/ACDB-LOADER: Error: ACDB AudProc vol returned = -19
2018-11-21 14:25:18.311 660-3070/? E/ACDB-LOADER: Error: ACDB_CMD_GET_AFE_COMMON_TABLE_SIZE Returned = -19
2018-11-21 14:25:18.311 660-3070/? E/ACDB-LOADER: Error: ACDB AFE returned = -19
2018-11-21 14:25:18.543 1652-1869/? E/WindowManager: Performed 6 layouts in a row. Skipping
2018-11-21 14:25:18.546 1652-1742/? E/ANDR-PERF-JNI: com_qualcomm_qtiperformance_native_perf_io_prefetch_start
2018-11-21 14:25:18.546 683-683/? E/ANDR-IOP: IOP HAL: Received pkg_name = org.godotengine.androidiap pid = 25485
2018-11-21 14:25:18.547 683-744/? E/ANDR-IOP: io prefetch Capture is deactivated
2018-11-21 14:25:19.908 684-732/? E/ANDR-PERF-OPTSHANDLER: perf_lock_rel: updated /sys/class/scsi_host/host0/../../../clkscale_enable with 1
return value 2
2018-11-21 14:25:19.984 1261-1261/? E/MSM-irqbalance: IRQ 79 not found in internal structure or should be ignored
2018-11-21 14:25:24.985 1261-1261/? E/MSM-irqbalance: IRQ 79 not found in internal structure or should be ignored
2018-11-21 14:25:29.988 1261-1261/? E/MSM-irqbalance: IRQ 79 not found in internal structure or should be ignored
2018-11-21 14:25:34.988 1261-1261/? E/MSM-irqbalance: IRQ 79 not found in internal structure or should be ignored
Should be re-opened. I landed here because I tested an empty android template with an empty Godot project and scrutinized the content of the 500kB apk. I noticed that Godot Payment is included, without any module option. If it helps, here's what I see with 3.1beta1:
I don't see how that relates to this issue? Yes, GodotPayments
is part of the base package, and that's why it's available.
Merci Rémi, Where is the base package doc page located? I'm trying to disable all modules to understand what is base, what is mandatory (png, freetype so far), what is optional, what does what.
There's no doc about it, but you can disable only what is exposed in scons --help
. Anything further requires modifying the engine.
Thx. It raises some many questions. Making another ticket
use community channels for a question though...
Hi,
I'm trying to use android modules in godot, I.e GodotPayment, or community modules At first, I first tried to install GodotFireBase module by using a custom build and templates, it was not working, after being stuck for hours, thinking I was doing something wrong during the build process. I had the idea to give a try using GodotPayment with official build and templates (3.0.6 stable).
I tried the godot iap demo from https://github.com/godotengine/godot-demo-projects/tree/master/misc/android_iap
Godot version: 3.0.6 stable
OS/device including version: windows editor + (live debug) Huawei p20 lite w/ android 8
The godot IAP demo does not work on my side, I got
-> so
But suprisingly, there is no issue at loading the modules according to the adb logs (So I guess modules are correctly compiled and present in the android app)
here are my adb logs:
It's really hard to find out if the issue come from Godot, my android device, or my setup Do you have any idea?