summaryrefslogtreecommitdiff
path: root/hello_signals/demo/addons/hello_signals_plugin
diff options
context:
space:
mode:
Diffstat (limited to 'hello_signals/demo/addons/hello_signals_plugin')
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/.gdignore1
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/HelloSignals.debug.aarbin0 -> 6825 bytes
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/HelloSignals.release.aarbin0 -> 6647 bytes
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/hello_signals_export_plugin.gd16
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/hello_signals_plugin.gd17
-rw-r--r--hello_signals/demo/addons/hello_signals_plugin/plugin.cfg7
6 files changed, 41 insertions, 0 deletions
diff --git a/hello_signals/demo/addons/hello_signals_plugin/.gdignore b/hello_signals/demo/addons/hello_signals_plugin/.gdignore
new file mode 100644
index 0000000..8b13789
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/.gdignore
@@ -0,0 +1 @@
+
diff --git a/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.debug.aar b/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.debug.aar
new file mode 100644
index 0000000..3e445c6
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.debug.aar
Binary files differ
diff --git a/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.release.aar b/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.release.aar
new file mode 100644
index 0000000..6440048
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/HelloSignals.release.aar
Binary files differ
diff --git a/hello_signals/demo/addons/hello_signals_plugin/hello_signals_export_plugin.gd b/hello_signals/demo/addons/hello_signals_plugin/hello_signals_export_plugin.gd
new file mode 100644
index 0000000..afc4162
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/hello_signals_export_plugin.gd
@@ -0,0 +1,16 @@
+@tool
+extends EditorExportPlugin
+
+func _supports_platform(platform):
+ if platform is EditorExportPlatformAndroid:
+ return true
+ return false
+
+func _get_android_libraries(platform, debug):
+ if debug:
+ return PackedStringArray(["hello_signals_plugin/HelloSignals.debug.aar"])
+ else:
+ return PackedStringArray(["hello_signals_plugin/HelloSignals.release.aar"])
+
+func _get_name():
+ return "Hello Signals plugin"
diff --git a/hello_signals/demo/addons/hello_signals_plugin/hello_signals_plugin.gd b/hello_signals/demo/addons/hello_signals_plugin/hello_signals_plugin.gd
new file mode 100644
index 0000000..65d8034
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/hello_signals_plugin.gd
@@ -0,0 +1,17 @@
+@tool
+extends EditorPlugin
+
+# A class member to hold the export plugin during its lifecycle
+var export_plugin : EditorExportPlugin
+
+func _enter_tree():
+ # Initialization of the plugin goes here.
+ export_plugin = preload("hello_signals_export_plugin.gd").new()
+ add_export_plugin(export_plugin)
+ pass
+
+
+func _exit_tree():
+ # Clean-up of the plugin goes here.
+ remove_export_plugin(export_plugin)
+ export_plugin = null
diff --git a/hello_signals/demo/addons/hello_signals_plugin/plugin.cfg b/hello_signals/demo/addons/hello_signals_plugin/plugin.cfg
new file mode 100644
index 0000000..8fb2c37
--- /dev/null
+++ b/hello_signals/demo/addons/hello_signals_plugin/plugin.cfg
@@ -0,0 +1,7 @@
+[plugin]
+
+name="Hello Signals plugin"
+description="Showcases how to package a sample Android plugin"
+author="Fredia Huya-Kouadio"
+version=""
+script="hello_signals_plugin.gd"