Closed gumaciel closed 3 years ago
Created a proposal here but don't know for sure if already exists for Android/iOS:
You should be able to use Godot's release
/debug
feature from GDScript with OS.has_feature
.
Thank you! this should work, but theres no way to do that directly on the plugin? If not, it's ok
It should work the same way it does with Godot's source, since plugins are using same compilation flags: https://github.com/godotengine/godot/blob/8f7f5846397297fff6e8a08f89bc60ce658699cc/platform/osx/godot_main_osx.mm#L53-L58
DEBUG_ENABLED
flag is defined for both debug
and release_debug
, so you can use it. You can also define your own flags to separate functionality between specific version of plugin: https://github.com/godotengine/godot-ios-plugins/blob/master/SConstruct#L100-L120
Thank you!
Hi, I was wondering if there was any way to check if you're exporting to
release_debug
or justrelease
, directly from the code, so I could create specific conditions for whether it'srelease_debug
orrelease
Something like this: https://docs.microsoft.com/en-us/cpp/preprocessor/hash-if-hash-elif-hash-else-and-hash-endif-directives-c-cpp?view=msvc-160#preprocessor-operators