I am designing a system for switching characters during gameplay, and as such need a single source of truth for the Player that stores the current character being used as it changes throughout gameplay. Other nodes or scripts can then access this single source of truth to get important data to stay synchronized during gameplay.
The naive approach would be to simple have a node in a scene for each Player, and store the data there using some kind of interface describing the shape the data needs. However, I feel like this can get messy because other nodes will need to know where the Player nodes are in order to get the data from them.
Is there any way for any node to request data from any other node without requiring knowledge of its position in the hierarchy tree?