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

GlobalClass inheriting from abstract non-GlobalClass shows error in Create New Node create_dialog. #83981

Closed
CantyCanadian opened this issue Oct 26, 2023 · 2 comments

Comments

@CantyCanadian
Copy link

CantyCanadian commented Oct 26, 2023

Godot version

v4.1.1.stable.mono.official

System information

Godot v4.1.1.stable.mono - Windows 10.0.22621 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 4090 (NVIDIA; 31.0.15.4584) - AMD Ryzen 7 7700X 8-Core Processor (16 Threads)

Issue description

If I have a class that is marked as a GlobalClass for the purpose of being added as a node in the inspector, and that class inherits from an abstract class that is not marked as a GlobalClass, an error will be shown despite the whole process actually working successfully (derived note shows up and can be created).

image

The issue is logical, the engine has the top-most class showing up in its node list, yet it cannot determine its base class since the attribute is missing and thus the engine has no knowledge of what the base class is. If there was a way to check both a. Is a Node and b. inherit.isEmpty, then we can assume that the engine is missing a class and should show a proper error explaining that.

Steps to reproduce

  1. Create abstract base class inheriting from Node.
  2. Create derived class inheriting from base class.
  3. Make derived class [GlobalClass].
  4. Try to create a child node in the editor.

Minimal reproduction project

This project should show the error if the Create Node window is opened.

Test.zip

@AThousandShips
Copy link
Member

Can you please try this with a supported version, like 4.1.2 (only the latest patch version is supported, and it might already be fixed)

@zaevi
Copy link
Contributor

zaevi commented Oct 30, 2023

It works on 4.2.beta3, might be fixed by #81101.

@akien-mga akien-mga added the bug label Oct 30, 2023
@akien-mga akien-mga added this to the 4.2 milestone Oct 30, 2023
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

4 participants