Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var syncs = node.find_children("*","MultiplayerSynchronizer",true,false)
- if syncs.size()<=0:
- push_warning("Trying to pack node with no sync",node)
- return
- var sync = syncs[0]
- if not sync is MultiplayerSynchronizer:
- push_warning("Trying to pack node with non-sync sync??",node)
- return
- root = sync.root_path
- var root_node = sync.get_node(root)
- var config:SceneReplicationConfig = sync.replication_config
- for property in config.get_properties():
- var property_value = root_node.get_node(property).get_indexed(property.get_as_property_path())
- properties[property] = property_value
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement