Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[GDExtension] EditorPlugin Tool #640

Closed
CornLizard opened this issue Oct 4, 2021 · 2 comments · Fixed by godotengine/godot#77010 or #1114
Closed

[GDExtension] EditorPlugin Tool #640

CornLizard opened this issue Oct 4, 2021 · 2 comments · Fixed by godotengine/godot#77010 or #1114
Labels
discussion topic:gdextension This relates to the new Godot 4 extension implementation
Milestone

Comments

@CornLizard
Copy link

Godot version

v4.0.dev.custom_build [ed5267f69]

System information

Manjaro 21 KDE, 1950x threadripper, 1080 TI, Vulkan, 16GB Memory

Issue description

My problem isn't really an error more or less a missing feature? I'm unable to find a solution to using tool. I found some posts about using the old GDNative and modules. I cannot find the equivalent in GDExtensions if there is any.

Module solution

EditorPlugins::add_by_type<MyPlugin>();

GDNative solution

register_tool_class<MyPlugin>();

@CornLizard CornLizard changed the title EditorPlugin Tool [GDExtension] EditorPlugin Tool Oct 4, 2021
@Zylann
Copy link
Collaborator

Zylann commented Nov 13, 2021

I thought in GDExtension all classes were tool? (just like every class in the Godot core source code. tool is only a feature of scripts, and GDExtensions are not scripts)

@Zylann
Copy link
Collaborator

Zylann commented Nov 13, 2021

Although there seem to be confusion between two things on this issue:

  1. Yes, I think GDExtension classes are all "tool" in the sense that they will run in editor if nodes are added to scene tree.
  2. No, GDExtension does not seem to have any way to register EditorPlugins like modules can. This is an issue that needs solving.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion topic:gdextension This relates to the new Godot 4 extension implementation
Projects
None yet
4 participants