C# Class GameMachine.Core.AsyncTcpClient

Inheritance: Client
Afficher le fichier Open project: gamemachine/gamemachine

Méthodes publiques

Свойство Type Description
entityQueue ConcurrentQueue
running bool

Méthodes publiques

Méthode Description
AsyncTcpClient ( string address, int port, string playerId, int authtoken ) : System
Connect ( ) : void
CreateClientMessage ( ) : io.gamemachine.messages.ClientMessage
Deserialize ( Stream inc ) : io.gamemachine.messages.ClientMessage
GetBytesIn ( ) : long
GetBytesOut ( ) : long
IsRunning ( ) : bool
ReceivedPlayerConnected ( ) : bool
Reconnect ( ) : void
ResetBytes ( ) : void
Send ( byte bytes ) : void
SendEntities ( List entities ) : void
SendEntity ( io.gamemachine.messages.Entity entity ) : void
SendPlayerConnect ( ) : void
SetConnectionType ( int connectionType ) : void
Start ( ) : void
Stop ( ) : void
Write ( byte bytes ) : void

Private Methods

Méthode Description
AsyncTcpClient ( int port ) : System
ConnectCallback ( IAsyncResult result ) : void
Connected ( ) : void
ReadCallback ( IAsyncResult result ) : void
Serialize ( io.gamemachine.messages.ClientMessage message ) : byte[]
WriteCallback ( IAsyncResult result ) : void

Method Details

AsyncTcpClient() public méthode

public AsyncTcpClient ( string address, int port, string playerId, int authtoken ) : System
address string
port int
playerId string
authtoken int
Résultat System

Connect() public méthode

public Connect ( ) : void
Résultat void

CreateClientMessage() public méthode

public CreateClientMessage ( ) : io.gamemachine.messages.ClientMessage
Résultat io.gamemachine.messages.ClientMessage

Deserialize() public méthode

public Deserialize ( Stream inc ) : io.gamemachine.messages.ClientMessage
inc Stream
Résultat io.gamemachine.messages.ClientMessage

GetBytesIn() public méthode

public GetBytesIn ( ) : long
Résultat long

GetBytesOut() public méthode

public GetBytesOut ( ) : long
Résultat long

IsRunning() public méthode

public IsRunning ( ) : bool
Résultat bool

ReceivedPlayerConnected() public méthode

public ReceivedPlayerConnected ( ) : bool
Résultat bool

Reconnect() public méthode

public Reconnect ( ) : void
Résultat void

ResetBytes() public méthode

public ResetBytes ( ) : void
Résultat void

Send() public méthode

public Send ( byte bytes ) : void
bytes byte
Résultat void

SendEntities() public méthode

public SendEntities ( List entities ) : void
entities List
Résultat void

SendEntity() public méthode

public SendEntity ( io.gamemachine.messages.Entity entity ) : void
entity io.gamemachine.messages.Entity
Résultat void

SendPlayerConnect() public méthode

public SendPlayerConnect ( ) : void
Résultat void

SetConnectionType() public méthode

public SetConnectionType ( int connectionType ) : void
connectionType int
Résultat void

Start() public méthode

public Start ( ) : void
Résultat void

Stop() public méthode

public Stop ( ) : void
Résultat void

Write() public méthode

public Write ( byte bytes ) : void
bytes byte
Résultat void

Property Details

entityQueue public_oe static_oe property

public static ConcurrentQueue entityQueue
Résultat ConcurrentQueue

running public_oe property

public bool running
Résultat bool