#exported variable doesn't appear in subclasses in inspector

4 messages · Page 1 of 1 (latest)

hearty remnant
#

I have the following two files:

# baseState.gd
extends Node
class_name State

@export var foo:int
# stateSubclass.gd
Extends State

@export var bar:int

I've attached StateSubclass to a Node in the scene, and I'm expecting to see both foo and bar as variables I can edit in the inspector. However, I only see bar in the inspector.
Is this a known issue? If so, is there a workaround?
Or is this expected behavior and I need to flag foo with some extra value to make it "public" in subclasses?
(Using 4.0 rc 1)

brittle pawn
#

this shouldn't happen, have you tried the latest rc 5?

solid sequoia
#

Yeah I just copy/pasted your code and it works just fine in rc5

#

With the exception that I changed Extends to extends