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

Calling "DebugMenu.style" returns "Invalid get index 'style' (on base: 'CanvasLayer')" #20

Closed
Arnklit opened this issue Oct 14, 2023 · 2 comments

Comments

@Arnklit
Copy link

Arnklit commented Oct 14, 2023

The addon is working well with the F3 shortcut, but I tried to make an on screen button to toggle it but calling the DebugMenu.style is for some reason causing the "Invalid get index 'style' (on base: 'CanvasLayer')" error.

The singleton is loaded and everything seems to be working, so why it's retuning a CanvasLayer instead of a script instance is beyond me.

Using Godot 4.1.2.stable. I'll update if I figure out what causes it.

image

@Havasi-Scarlet-5
Copy link

try like this: DebugMenu.get_node("DebugMenu").style = DebugMenu.get_node("DebugMenu").Style.VISIBLE_COMPACT

@Calinou
Copy link
Member

Calinou commented Nov 27, 2023

Thanks for the report! Consolidating in #15, which was fixed by #16 but isn't present in a tagged release yet.

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

No branches or pull requests

3 participants