Свойство | Тип | Описание | |
---|---|---|---|
Loading | bool | ||
bindings | byte[] | ||
connections | List |
||
disconnected | bool | ||
group | Group | ||
hidden | bool | ||
id | byte | ||
ip | string | ||
isJailed | bool | ||
isJoker | bool | ||
isMuted | bool | ||
lastSeen | DateTime>.Dictionary | ||
left | string>.Dictionary | ||
name | string | ||
players | ThreadedBindingList |
Метод | Описание | |
---|---|---|
Ban ( string name ) : void |
Changes the players rank to banned.
|
|
ChangeRank ( Player p, GroupEnum g ) : void |
Changes a players rank
|
|
ChangeRank ( string name, GroupEnum g ) : void |
Changes the given players rank
|
|
Disconnect ( ) : void |
Handles a player disconnection. Cleans up the player from other players on the server as well as handles cleaning up the player from the system.
|
|
Exists ( byte id ) : bool |
Checks to see if a player exists in the list
|
|
Exists ( string name ) : bool |
Checks to see if a player exists in the list
|
|
Find ( string name ) : Player |
Finds a player in the list
|
|
GZip ( byte bytes ) : byte[] |
Zips an array of bytes using gzip
|
|
GetColor ( string name ) : string |
Gets the color for a given player
|
|
GetGroup ( string name ) : Group |
Get the group of a given player
|
|
GetPlayers ( ) : List |
Returns the list of players.
|
|
GetRank ( string name ) : GroupEnum |
Gets a players rank
|
|
HandleBlockchange ( byte message ) : void |
Handles a player blockchange packet
|
|
HandleLogin ( byte message ) : void |
Handles a player login packet
|
|
IsOnline ( string name ) : bool |
Determines if the user is online
|
|
Kick ( string message ) : void |
Kicks the player with a given message
|
|
Player ( Socket s ) : System |
The main constructor for the player.
|
|
SMPKick ( string message ) : void |
A kick function that works for the new SMP clients. That way they have a friendly way of being removed from the server instead of "Invalid packet id 2"
|
|
SendBlockchange ( ushort x, ushort y, ushort z, byte type ) : void | ||
SendChat ( Player p, string message ) : void | ||
SendDie ( byte id ) : void | ||
SendKick ( string message ) : void | ||
SendMap ( ) : void | ||
SendMessage ( byte id, string message ) : void | ||
SendMessage ( string message ) : void | ||
SendMotd ( ) : void | ||
SendPing ( ) : void | ||
SendPos ( byte id, ushort x, ushort y, ushort z, byte rotx, byte roty ) : void | ||
SendRaw ( byte send ) : void | ||
SendRaw ( int id ) : void | ||
SendRaw ( int id, byte send ) : void | ||
SendSpawn ( byte id, string name, ushort x, ushort y, ushort z, byte rotx, byte roty ) : void | ||
ToString ( ) : string | ||
UpdatePosition ( ) : void | ||
ValidName ( string name ) : bool |
Checks to see if a players name is valid
|
|
initNetworking ( Socket s ) : void |
Initializes the players networking and handles the incoming socket connection.
|
|
loginTimerCallback ( Object sender, ElapsedEventArgs e ) : void |
Handles the login timer callback once it finishes. If the player has not been authenticated then we kick them.
|
Метод | Описание | |
---|---|---|
CheckBlockSpam ( ) : bool |
Detects whether or not a player is spamming blocks around the map
|
|
FreeId ( ) : byte |
Find the next free id available
|
|
HTNO ( short x ) : byte[] |
Converts a short to network byte order
|
|
HTNO ( ushort x ) : byte[] |
Converts a ushort to network byte order
|
|
HandleMessage ( byte buffer ) : byte[] |
Handles messages in the buffer
|
|
NTHO ( byte x, int offset ) : ushort |
Converts a ushort to host byte order
|
|
Receive ( IAsyncResult result ) : void |
Handles network callbacks and adding to the players buffer
|
|
StringFormat ( string str, int size ) : byte[] |
Formats a string
|
|
Wordwrap ( string message ) : List |
Performs wordwrap on a string
|
|
checkOp ( ) : bool |
Checks to see if the player has operator permissions
|
public static Ban ( string name ) : void | ||
name | string | The player's name to ban |
Результат | void |
public static ChangeRank ( Player p, GroupEnum g ) : void | ||
p | Player | The player object to change |
g | GroupEnum | The rank to change the player to |
Результат | void |
public static ChangeRank ( string name, GroupEnum g ) : void | ||
name | string | The name of the player |
g | GroupEnum | The players new rank |
Результат | void |
public static Exists ( byte id ) : bool | ||
id | byte | The id of the player |
Результат | bool |
public static Exists ( string name ) : bool | ||
name | string | the players name |
Результат | bool |
public static Find ( string name ) : Player | ||
name | string | The name of the player |
Результат | Player |
public static GZip ( byte bytes ) : byte[] | ||
bytes | byte | The bytes to zip |
Результат | byte[] |
public static GetColor ( string name ) : string | ||
name | string | The player to get the color for |
Результат | string |
public static GetGroup ( string name ) : Group | ||
name | string | The players name |
Результат | Group |
public static GetRank ( string name ) : GroupEnum | ||
name | string | The player name to get the rank for |
Результат | GroupEnum |
public HandleBlockchange ( byte message ) : void | ||
message | byte | The blockchange packet |
Результат | void |
public HandleLogin ( byte message ) : void | ||
message | byte | The login packet |
Результат | void |
public static IsOnline ( string name ) : bool | ||
name | string | The player's name |
Результат | bool |
public Kick ( string message ) : void | ||
message | string | The reason the player was kicked |
Результат | void |
public Player ( Socket s ) : System | ||
s | Socket | The incoming socket connection for the player to bind to |
Результат | System |
public SMPKick ( string message ) : void | ||
message | string | The message to kick a SMP player with |
Результат | void |
public SendBlockchange ( ushort x, ushort y, ushort z, byte type ) : void | ||
x | ushort | |
y | ushort | |
z | ushort | |
type | byte | |
Результат | void |
public SendChat ( Player p, string message ) : void | ||
p | Player | |
message | string | |
Результат | void |
public SendMessage ( byte id, string message ) : void | ||
id | byte | |
message | string | |
Результат | void |
public SendMessage ( string message ) : void | ||
message | string | |
Результат | void |
public SendPos ( byte id, ushort x, ushort y, ushort z, byte rotx, byte roty ) : void | ||
id | byte | |
x | ushort | |
y | ushort | |
z | ushort | |
rotx | byte | |
roty | byte | |
Результат | void |
public SendRaw ( int id, byte send ) : void | ||
id | int | |
send | byte | |
Результат | void |
public SendSpawn ( byte id, string name, ushort x, ushort y, ushort z, byte rotx, byte roty ) : void | ||
id | byte | |
name | string | |
x | ushort | |
y | ushort | |
z | ushort | |
rotx | byte | |
roty | byte | |
Результат | void |
public static ValidName ( string name ) : bool | ||
name | string | |
Результат | bool |
public initNetworking ( Socket s ) : void | ||
s | Socket | The incoming socket connection |
Результат | void |
public loginTimerCallback ( Object sender, ElapsedEventArgs e ) : void | ||
sender | Object | |
e | ElapsedEventArgs | |
Результат | void |
public static Dictionary |
||
Результат | DateTime>.Dictionary |