I'm working on a multiplayer game which uses the high level multiplayer API. The API relies heavily on the names of nodes when using rpc
and related commands. However, in my case, the server is expected to load all active scenes, while the client only needs to load the ones relevant to that client. On both sides, many nodes are initially created programmatically. When the nodes are created, they are automatically given a name like @@2
where 2
is an increasingly incremented number based on the number of nodes created. Unfortunately, this number seems to be based on the number of nodes named automatically in the entire tree. So if the server created 2 sub-scenes which each created 2 nodes, then it has names going up to @@4
, while the client only goes up to @@2
. Now the names in the scene trees may no longer match, and an rpc
call on node @@4
on the server which is suppose to be sent to @@2
on the server will no longer work.
Is there a way I can set the default naming scheme? For example, if it were the same scheme, but having the number based on the number of children for that specific parent node, it would work fine. Of course, I can add in explicit code to always name all nodes in all cases where it's needed, but this global solution would be better in my case. Thanks!