C# Class ManicDigger.NetworkClientMinecraft

Inheritance: INetworkClient
显示文件 Open project: henon/manic_digger Class Usage Examples

Public Properties

Property Type Description
ENABLE_CHATLOG bool
ENABLE_FORTRESS bool
LocalPlayerId int
gamepathlogs string
mapreceivedsizex int
mapreceivedsizey int
mapreceivedsizez int
receivedMapStream System.IO.MemoryStream

Public Methods

Method Description
Connect ( string serverAddress, int port, string username, string auth ) : void
ConnectedPlayers ( ) : IEnumerable
Disconnect ( ) : void
Dispose ( ) : void
Process ( ) : void

This function should be called in program main loop. It exits immediately.

SendChat ( string s ) : void
SendPacket ( byte packet ) : void
SendPosition ( Vector3 position, Vector3 orientation ) : void
SendSetBlock ( Vector3 position, BlockSetMode mode, int type, int materialslot ) : void

Private Methods

Method Description
ChatLog ( string p ) : void
CreateLoginPacket ( string username, string verificationKey ) : byte[]
InvalidPlayerWarning ( byte playerid ) : void
InvokeMapLoadingProgress ( int progressPercent, int progressBytes ) : void
MakeValidFileName ( string name ) : string
ReadAndUpdatePlayerPosition ( BinaryReader br, byte playerid ) : void
TryReadPacket ( ) : int
UpdatePositionDiff ( byte playerid, Vector3 v ) : void

Method Details

Connect() public method

public Connect ( string serverAddress, int port, string username, string auth ) : void
serverAddress string
port int
username string
auth string
return void

ConnectedPlayers() public method

public ConnectedPlayers ( ) : IEnumerable
return IEnumerable

Disconnect() public method

public Disconnect ( ) : void
return void

Dispose() public method

public Dispose ( ) : void
return void

Process() public method

This function should be called in program main loop. It exits immediately.
public Process ( ) : void
return void

SendChat() public method

public SendChat ( string s ) : void
s string
return void

SendPacket() public method

public SendPacket ( byte packet ) : void
packet byte
return void

SendPosition() public method

public SendPosition ( Vector3 position, Vector3 orientation ) : void
position Vector3
orientation Vector3
return void

SendSetBlock() public method

public SendSetBlock ( Vector3 position, BlockSetMode mode, int type, int materialslot ) : void
position Vector3
mode BlockSetMode
type int
materialslot int
return void

Property Details

ENABLE_CHATLOG public_oe property

public bool ENABLE_CHATLOG
return bool

ENABLE_FORTRESS public_oe property

public bool ENABLE_FORTRESS
return bool

LocalPlayerId public_oe property

public int LocalPlayerId
return int

gamepathlogs public_oe property

public string gamepathlogs
return string

mapreceivedsizex public_oe property

public int mapreceivedsizex
return int

mapreceivedsizey public_oe property

public int mapreceivedsizey
return int

mapreceivedsizez public_oe property

public int mapreceivedsizez
return int

receivedMapStream public_oe property

public MemoryStream,System.IO receivedMapStream
return System.IO.MemoryStream