Hi,
So I am trying to do a name selector that if you write a certain name it changes the sprite.
But I don’t know how to have access of the variable of the name because the naming process is in another scene. And even if I try to put it in the same scene it gives me:
Invalid access to property or key’text’ on a base object of type ‘null instance’
The variable is the line_edit.text because I want the variable to be the input of the name.
Thank you ! I tried to do it but it still gives me the same error since i think it is because it isnt
I am assigning the variable in a node 2d and not a line_edit.
And i am assigning the line_edit variable in a 2d node
From the pic you added i can see why this not works, because unique node names has the same scene limitation, so you can’t get your node like you’re doing now.
You can try use get_parent().get_parent().get_node("LineEdit") for get your line edit or add the line edit node to a group from the editor, select the node and do this: