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

Export category/group/subgroup with base class name incompatible with that class new #80920

Closed
acgc99 opened this issue Aug 23, 2023 · 1 comment

Comments

@acgc99
Copy link

acgc99 commented Aug 23, 2023

Godot version

v4.1.stable.official [9704596]

System information

Godot v4.1.stable - Windows 10.0.22621 - Vulkan (Forward+) - dedicated NVIDIA GeForce GTX 1050 (NVIDIA; 31.0.15.3667) - Intel(R) Core(TM) i5-8300H CPU @ 2.30GHz (8 Threads)

Issue description

Create an export category/group/subgroup with a name that coincides with a base class and then try to instantiate one instance of that class.

Steps to reproduce

Just this:

extends Control

@export_category("Label")
#@export_group("Label")
#@export_subgroup("Label")
@export var text: String

var label: Label


func _ready():
	label = Label.new()
	label.text = text

When I run the code, I get:

Invalid call. Nonexistent function 'new' in base 'Nil'.

My temporal solution is to do @export_category("Label_") or similar.

Minimal reproduction project

project.zip

@dalexeev
Copy link
Member

@dalexeev dalexeev closed this as not planned Won't fix, can't repro, duplicate, stale Aug 23, 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

2 participants