Player¶
sealed class
包装原生 endstone::Player 的托管对象(继承 Actor),提供消息、操作、物品、模式、飞行、传送等玩家功能。
命名空间 Endstone.Loader
继承 Mob › Actor › CommandSender › object
属性¶
Address : string¶
{ get; }
AllowFlight : bool¶
{ get; }
DeviceId : string¶
{ get; }
DeviceOS : string¶
{ get; }
EnderChest : Inventory¶
{ get; }
玩家末影箱。
ExpLevel : int¶
{ get; }
ExpProgress : float¶
{ get; }
FlySpeed : float¶
{ get; }
GameMode : GameMode¶
{ get; }
玩家的游戏模式。
GameVersion : string¶
{ get; }
Inventory : PlayerInventory¶
{ get; }
玩家主手背包。
IsFlying : bool¶
{ get; }
IsOp : bool¶
{ get; }
玩家是否为服务器管理员 (OP)。
IsSneaking : bool¶
{ get; }
IsSprinting : bool¶
{ get; }
ItemInHand : ItemStack¶
{ get; }
Locale : string¶
{ get; }
Ping : int¶
{ get; }
SkinCapeId : string¶
{ get; }
SkinId : string¶
{ get; }
TotalExp : int¶
{ get; }
WalkSpeed : float¶
{ get; }
Xuid : string¶
{ get; }
方法¶
void CloseForm()¶
void GiveExp(int amount)¶
void GiveExpLevels(int amount)¶
void Kick(string reason)¶
bool PerformCommand(string command)¶
void PlaySound(Location location, string sound, float volume, float pitch)¶
void ResetTitle()¶
void SendMap(MapView map)¶
Sends the full map rendering (pixels + cursors) to this player. Blocks the server thread while the renderers draw.
void SendPacket(int packetId, System.ReadOnlySpan<byte> payload)¶
void SendPopup(string message)¶
void SendTip(string message)¶
向玩家发送 Tip 悬浮提示。