Extended from EventEmitter NetworkingService¶
This class is used to replicate objects to other clients, for example the player character
Properties¶
number ReplicationPerSecond¶
Specifies the number of replication requests per second to send when using ReplicateOnChange
boolean DestroyObjectsOnLeave¶
If true, destroys replicated objects from other clients when they leave
boolean ServerReplication¶
Boolean that determines if server-side replication is enabled, true by default
table ReplicationTarget¶
Table of objects from other clients currently targeted for replication
{ }
table RequestsCache¶
Cache storing replication requests indexed by client (UserId)
{ }
table PlayersData¶
Dictionary containing the replicated objects for each client (keyed by UserId)
{ }
table Cache¶
Dictionary storing cached object data to optimize replication by detecting changes
{ }
Methods¶
void Replicate(object: BaseObject)¶
Replicates an object to other clients
RBXScriptConnection ReplicateOnChange(object: BaseObject)¶
Replicates an object and each change on it, and returns the connections that detect each change of the object
Events¶
Name |
Description |
|---|---|
| ReplicationRequest | Params -> Request Fired when a request is received by the client |