I have a class named UnitDeckCard. It inherits from DeckCard, which inherits from TextureRect. My issue is that, in the UnitDeckCard, I'm trying to define an onready var with a node from the scene:
onready var cost_label = $CostLabel
But then I received an error The method "get_node" isn't declared in the current class
I thought that, since, by inheritance, UnitDeckCard inherits from a Control class (TextureRect class), get_node method would be available, as Control inherits from Node (get_node is a Node method). As I undestand, my case would be something like that:
UnitDeckCard < DeckCard < TextureRect < Control < CanvasItem < Node < Object.
Why can't I use get_node method in UnitDeckCard?