diff options
author | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2023-10-13 16:43:30 +0200 |
---|---|---|
committer | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2023-10-13 16:53:24 +0200 |
commit | 9d44954a3fdb79ea74d3e7df227ee8b691862e38 (patch) | |
tree | 736526b41b8b4f2fba7b934f5a9ea6319c925f4f | |
parent | 51f81e1c88499f04d2ebdcc0be0b34e73f5e90eb (diff) | |
download | redot-engine-9d44954a3fdb79ea74d3e7df227ee8b691862e38.tar.gz |
[MP] Fix "on change" indexed properties
Watchers were still using Object::get instead of Object::get_indexed.
-rw-r--r-- | modules/multiplayer/multiplayer_synchronizer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/multiplayer/multiplayer_synchronizer.cpp b/modules/multiplayer/multiplayer_synchronizer.cpp index 21f1f86dbf..75520d7919 100644 --- a/modules/multiplayer/multiplayer_synchronizer.cpp +++ b/modules/multiplayer/multiplayer_synchronizer.cpp @@ -382,7 +382,7 @@ Error MultiplayerSynchronizer::_watch_changes(uint64_t p_usec) { bool valid = false; const Object *obj = _get_prop_target(node, prop); ERR_CONTINUE_MSG(!obj, vformat("Node not found for property '%s'.", prop)); - Variant v = obj->get(prop.get_concatenated_subnames(), &valid); + Variant v = obj->get_indexed(prop.get_subnames(), &valid); ERR_CONTINUE_MSG(!valid, vformat("Property '%s' not found.", prop)); Watcher &w = ptr[idx]; if (w.prop != prop) { |