SetEntitySyncedData: Difference between revisions
(Created page with "Sets the given data value for the given entity and synchronizes this value to clients. Use SetEntityData if the data should only exist on the server and shouldn't be synch...") |
No edit summary |
||
| Line 1: | Line 1: | ||
Sets the given data value for the given entity and synchronizes this value to clients. Use | Sets the given data value for the given entity and synchronizes this value to clients. Use SetEntityData if the data should only exist on the server and shouldn't be synchronized. Check the Synchronized Types for which types you can synchronize with this.. | ||
==Syntax== | ==Syntax== | ||
Revision as of 01:37, 27 November 2019
Sets the given data value for the given entity and synchronizes this value to clients. Use SetEntityData if the data should only exist on the server and shouldn't be synchronized. Check the Synchronized Types for which types you can synchronize with this..
Syntax
void NAPI.Data.SetEntitySharedData(NetHandle entity, string key, object value);
void NAPI.Data.SetEntitySharedData(NetHandle entity, Dictionary<string, object> valueforstring );
Required Arguments
- entity: parameter input should be in NetHandle type.
1. overload:
- key: parameter input should be in string type.
- value: parameter input should be in any type.
2. overload:
- valueforstring: like 1. overload, but for multiple keys at one time. Parameter input should be in Dictionary<string, object> type.
Usage example(s)
Example Description
NAPI.Data.SetEntitySharedData(entity, key, value);