Hi
I have a problem with setting up my game.
I have this:
Level01 (Node):
- LevelGrphics
- DoorsAndKeys
- PlayerNode
- Tilemap
- etc
Also I have this
LevelSelector(Node2D):
- Button(ButtonNode)
LevelSelector have script with variables like SCORE and LIVES
My main scene (that loads after F5) is LevelSelector. When I hit the button on that scene my other scene is loaded (Level01.tscn). It works but I'm not sure if I'm doing it correctly ( get_tree().change_scene("res://levels/Level01.tscn") )
I want Level01.tscn to have access to LevelSelector variables (SCORE, LIVES). How Can I do that? I know how to get variables from different nodes in the same scene. But how to access variables between separate scenes?