Skip to content

Separate plugin into 2 sub-plugins#584

Open
BenjaTK wants to merge 2 commits intogaea-godot:2.0from
BenjaTK:subplugins
Open

Separate plugin into 2 sub-plugins#584
BenjaTK wants to merge 2 commits intogaea-godot:2.0from
BenjaTK:subplugins

Conversation

@BenjaTK
Copy link
Collaborator

@BenjaTK BenjaTK commented Feb 18, 2026

Closes #521
This PR separates the plugin into editor and runtime sub-plugins, making it more organized. It also adds a very simple export plugin which removes the whole editor sub-plugin from game exports. Exports don't work yet because of #573, but that's being worked on.

@BenjaTK BenjaTK requested review from Zehir and cullumi February 18, 2026 14:19
@BenjaTK BenjaTK added ✨ enhancement New feature or request ‼️breaking A change that could break already existing projects. organization Movement of code around, refactoring, removal of code. labels Feb 18, 2026

EditorInterface.get_file_system_dock().resource_removed.connect(_on_resource_removed)
EditorInterface.get_file_system_dock().file_removed.connect(_on_file_removed)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing an empty line here

Copy link
Collaborator

@Zehir Zehir left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The graph_nodes directory is present twice;
res://addons/gaea/runtime/graph_nodes/graph_nodes/root/
Image

In the file root_nodes_testing the NODES_PATH const should be res://addons/gaea/runtime/graph_nodes/root/

@@ -1,7 +1,7 @@
[gd_scene format=3 uid="uid://b2rceqo8rtr88"]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This scene should be in the editor directory instead

extends EditorPlugin


func _enable_plugin() -> void:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can remove all functions as they do nothing but keep the file

@@ -0,0 +1,22 @@
@tool
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe rename the file to runtime-plugin.gd ?



func _export_file(path: String, _type: String, _features: PackedStringArray) -> void:
if path.begins_with("res://addons/gaea/editor/"):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What if the directory is moved ? we could have some kind of path resolve



func _export_file(path: String, _type: String, _features: PackedStringArray) -> void:
if path.begins_with("res://addons/gaea/editor/"):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You also need to exclude the file addons/gaea/gaea.gd

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

‼️breaking A change that could break already existing projects. ✨ enhancement New feature or request organization Movement of code around, refactoring, removal of code.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Separate the addon into sub-addons

2 participants