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

Editor macros such as EDITOR_GET and EDSCALE are not available #1619

Open
aaronfranke opened this issue Oct 9, 2024 · 0 comments
Open

Editor macros such as EDITOR_GET and EDSCALE are not available #1619

aaronfranke opened this issue Oct 9, 2024 · 0 comments
Labels
enhancement This is an enhancement on the current functionality

Comments

@aaronfranke
Copy link
Member

aaronfranke commented Oct 9, 2024

Godot version

Godot 4.3-stable (but this problem happens just with compiling a godot-cpp project)

godot-cpp version

master 6facde3

System information

macOS 14.6.1 arm64

Issue description

The EDITOR_GET macro defined in the engine's editor/editor_settings.h is not available in godot-cpp.

#define EDITOR_GET(m_var) _EDITOR_GET(m_var)
Variant _EDITOR_GET(const String &p_setting);

Meaning that this line of editor code will compile in an engine module, but not in godot-cpp:

const real_t zoom_inertia = EDITOR_GET("editors/3d/navigation_feel/zoom_inertia");

Other editor-specific macros are also missing, such as EDSCALE, TTR, ERR_THREAD_GUARD, and functions such as get_editor_theme_icon, and more.

Steps to reproduce

Add EDITOR_GET or EDSCALE into a godot-cpp project and notice that they are missing, no matter what you include. Another option is to just do a search in godot-cpp and you will not find these strings anywhere in it.

Minimal reproduction project

I'm not gonna bother including a minimal reproduction project since it can be reproduced by pasting one line of code into an empty GDExtension project.

@aaronfranke aaronfranke added the enhancement This is an enhancement on the current functionality label Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement This is an enhancement on the current functionality
Projects
None yet
Development

No branches or pull requests

1 participant