Space Engineers
Classes | Public Member Functions | Properties | List of all members
Sandbox.Game.Replication.MyStreamingEntityStateGroup< T > Class Template Reference
Inheritance diagram for Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >:
VRage.Network.IMyStateGroup VRage.Network.IMyNetObject VRage.Network.IMyEventOwner

Public Member Functions

 MyStreamingEntityStateGroup (T obj)
 
void CreateClientData (MyClientStateBase forClient)
 Called on server new clients starts replicating this group. More...
 
void DestroyClientData (MyClientStateBase forClient)
 Called on server when client stops replicating this group. More...
 
void ClientUpdate (uint timestamp)
 
void Destroy ()
 Called when state group is being destroyed. More...
 
float GetGroupPriority (int frameCountWithoutSync, MyClientInfo forClient)
 Gets priority related to client. When priority is lower than zero, it means the object is not relevant for client. Default priority is 1.0f. More...
 
bool Serialize (VRage.Library.Collections.BitStream stream, EndpointId forClient, uint timestamp, byte packetId, int maxBitPosition)
 
void OnAck (MyClientStateBase forClient, byte packetId, bool delivered)
 Called for each packet id sent to client from this state group. When ACK received, called immediatelly. When several other packets received from client, but some were missing, called for each missing packet. More...
 
void ForceSend (MyClientStateBase clientData)
 
- Public Member Functions inherited from VRage.Network.IMyStateGroup
void ClientUpdate (MyTimeSpan clientTimestamp)
 Update method called on client. More...
 
void Serialize (BitStream stream, EndpointId forClient, MyTimeSpan timestamp, byte packetId, int maxBitPosition)
 (De)serializes group state or it's diff for client. When writing, you can write beyond maxBitPosition, but message won't be sent and ACKs won't be received for it. ReplicationServer will detect, that state group written beyond packet size and revert it. When nothing written, ReplicationServer will detect that and state group won't receive ACK for that packet id. More...
 
void TimestampReset (MyTimeSpan timestamp)
 
bool IsStillDirty (EndpointId forClient)
 

Properties

Instance [get]
 
StateGroupEnum GroupType [get]
 
- Properties inherited from VRage.Network.IMyStateGroup
StateGroupEnum GroupType [get]
 
IMyReplicable Owner [get]
 

Detailed Description

Type Constraints
T :IMyStreamableReplicable 

Definition at line 59 of file MyStreamingEntityStateGroup.cs.

Constructor & Destructor Documentation

Definition at line 69 of file MyStreamingEntityStateGroup.cs.

Member Function Documentation

void Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.ClientUpdate ( uint  timestamp)
inline

Definition at line 138 of file MyStreamingEntityStateGroup.cs.

void Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.CreateClientData ( MyClientStateBase  forClient)
inline

Called on server new clients starts replicating this group.

Implements VRage.Network.IMyStateGroup.

Definition at line 115 of file MyStreamingEntityStateGroup.cs.

Called when state group is being destroyed.

Implements VRage.Network.IMyStateGroup.

Definition at line 143 of file MyStreamingEntityStateGroup.cs.

void Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.DestroyClientData ( MyClientStateBase  forClient)
inline

Called on server when client stops replicating this group.

Implements VRage.Network.IMyStateGroup.

Definition at line 130 of file MyStreamingEntityStateGroup.cs.

void Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.ForceSend ( MyClientStateBase  clientData)
inline

Implements VRage.Network.IMyStateGroup.

Definition at line 498 of file MyStreamingEntityStateGroup.cs.

float Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.GetGroupPriority ( int  frameCountWithoutSync,
MyClientInfo  forClient 
)
inline

Gets priority related to client. When priority is lower than zero, it means the object is not relevant for client. Default priority is 1.0f.

Parameters
frameCountWithoutSyncHow long (in update frame count) has client not received sync of this state group.
forClientClient for whom is the priority get.

Implements VRage.Network.IMyStateGroup.

Definition at line 152 of file MyStreamingEntityStateGroup.cs.

void Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.OnAck ( MyClientStateBase  forClient,
byte  packetId,
bool  delivered 
)
inline

Called for each packet id sent to client from this state group. When ACK received, called immediatelly. When several other packets received from client, but some were missing, called for each missing packet.

Parameters
forClientThe client.
packetIdId of the delivered or lost packet.
deliveredTrue when packet was delivered, false when packet is considered lost.

Implements VRage.Network.IMyStateGroup.

Definition at line 468 of file MyStreamingEntityStateGroup.cs.

bool Sandbox.Game.Replication.MyStreamingEntityStateGroup< T >.Serialize ( VRage.Library.Collections.BitStream  stream,
EndpointId  forClient,
uint  timestamp,
byte  packetId,
int  maxBitPosition 
)
inline

Definition at line 429 of file MyStreamingEntityStateGroup.cs.

Property Documentation

Definition at line 111 of file MyStreamingEntityStateGroup.cs.

Definition at line 65 of file MyStreamingEntityStateGroup.cs.


The documentation for this class was generated from the following file: