+1 vote

Hello and sorry for My poor English.
Is it possible to write custom EditorImportPlugin as external NativeScript plugin?

I wish to make EditorImporterPlugin for custom file type, written in C++ as Native Plugin.
Used godot::register_tool_class< MyCustomPluginClass >( ) to register EditorPlugin
however when editor changes focus EditorImportPlugin prints :

**ERROR**: Condition ' !(get_script_instance() && get_script_instance()->has_method("get_recognized_extensions")) ' is true.
   At: editor/import/editor_import_plugin.cpp:48:get_recognized_extensions() - Condition ' !(get_script_instance() && get_script_instance()->has_method("get_recognized_extensions")) ' is true.

**ERROR**: Condition ' !(get_script_instance() && get_script_instance()->has_method("get_importer_name")) ' is true. returned: ""
   At: editor/import/editor_import_plugin.cpp:38:get_importer_name() - Condition ' !(get_script_instance() && get_script_instance()->has_method("get_importer_name")) ' is true. returned: ""

add_import_plugin is called from _enter_tree( ) in working EditorPlugin, yet overrited get_recognized_extensions( ) not printing output.

in Engine by (25 points)

I am encountering this issue also. Did you ever figure it out?

I just wrote it in gdscript. Also troublesome was gdlib's option 'Reloadable',
when set to 'true'. When it is set to 'false', it 's not reloading ever focus change
so editor doesn't crash. My current Godot version is 3.3.2.

I am also using 3.3.2. Thanks for telling me about the 'Reloadable' option issue. For now, I'm going to try to bypass needing a EditorImportPlugin by writing the logic for my screen in Rust.

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.