MCPcopy Create free account
hub / github.com/Redot-Engine/redot-engine / set_state

Method set_state

modules/multiplayer/multiplayer_synchronizer.cpp:181–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

179}
180
181Error MultiplayerSynchronizer::set_state(const List<NodePath> &p_properties, Object *p_obj, const Vector<Variant> &p_state) {
182 ERR_FAIL_NULL_V(p_obj, ERR_INVALID_PARAMETER);
183 int i = 0;
184 for (const NodePath &prop : p_properties) {
185 Object *obj = _get_prop_target(p_obj, prop);
186 ERR_FAIL_NULL_V(obj, FAILED);
187 obj->set_indexed(prop.get_subnames(), p_state[i]);
188 i += 1;
189 }
190 return OK;
191}
192
193bool MultiplayerSynchronizer::is_visibility_public() const {
194 return peer_visibility.has(0);

Callers

nothing calls this directly

Calls 2

set_indexedMethod · 0.80
get_subnamesMethod · 0.80

Tested by

no test coverage detected