Go: Players¶
Functions¶
PlayerByName¶
| Go | |
|---|---|
PlayerByName is the player with this name. A decision about permissions, money or ownership uses PlayerByXuid: a name can change hands.
- Parameters:
- name :
string
- name :
- Return type:
Player
PlayerByXuid¶
| Go | |
|---|---|
PlayerByXuid is the player with this xuid.
- Parameters:
- xuid :
string
- xuid :
- Return type:
Player
PlayerByUuid¶
| Go | |
|---|---|
PlayerByUuid is the player with this uuid.
- Parameters:
- uuid :
string
- uuid :
- Return type:
Player
Broadcast¶
| Go | |
|---|---|
Broadcast sends a message to every online player.
- Parameters:
- msg :
string
- msg :
- Return type:
error - Slots:
broadcast_message
ListPlayers¶
| Go | |
|---|---|
ListPlayers lists the online players. An entry that does not parse is skipped with a warning, so one bad entry does not make who is online unanswerable.
- Return type:
([]PlayerInfo, error) - Slots:
list_players,log
ByName¶
| Go | |
|---|---|
ByName selects a player by name.
- Parameters:
- name :
string
- name :
- Return type:
PlayerSel
ByXuid¶
| Go | |
|---|---|
ByXuid selects a player by xuid.
- Parameters:
- xuid :
string
- xuid :
- Return type:
PlayerSel
ByUuid¶
| Go | |
|---|---|
ByUuid selects a player by uuid.
- Parameters:
- uuid :
string
- uuid :
- Return type:
PlayerSel
Player¶
Player is one player, named by a selector. Most of its methods are generated from the constant tables of abi.h, one per property and verb; the rest are below.
Player.Resolve¶
| Go | |
|---|---|
Resolve is the player's actor. An error means nobody matches the selector.
- Return type:
(Entity, error) - Slots:
player_resolve
Player.IsOnline¶
| Go | |
|---|---|
IsOnline reports whether the selector matches an online player. Every ABI v2 host has the slot it asks, so false means nobody matches.
- Return type:
bool - Slots:
player_resolve
Player.SendMessage¶
| Go | |
|---|---|
SendMessage sends a chat line to the player.
- Parameters:
- msg :
string
- msg :
- Return type:
error - Slots:
player_send_message
Player.SendMessageTyped¶
| Go | |
|---|---|
SendMessageTyped sends a message of a given TextPacket type to the player.
- Parameters:
- msg :
string - kind :
int32
- msg :
- Return type:
error - Slots:
player_send_message_typed
Player.SendTitle¶
| Go | |
|---|---|
SendTitle shows a title: slot 0 title, 1 subtitle, 2 action bar; the times are in ticks.
- Parameters:
- slot :
int32 - text :
string - fadeIn :
int32 - stay :
int32 - fadeOut :
int32
- slot :
- Return type:
error - Slots:
player_send_title
Player.Disconnect¶
| Go | |
|---|---|
Disconnect removes the player from the server with a reason.
- Parameters:
- reason :
string
- reason :
- Return type:
error - Slots:
player_disconnect
Player.SetGameType¶
| Go | |
|---|---|
SetGameType sets the player's game mode, the value GameType reads.
- Parameters:
- mode :
int32
- mode :
- Return type:
error - Slots:
player_set_gamemode
Player.Teleport¶
| Go | |
|---|---|
Teleport moves the player to a position of any registered dimension.
- Parameters:
- dim :
int32 - x :
float64 - y :
float64 - z :
float64
- dim :
- Return type:
error - Slots:
player_teleport
Player.CarriedItem¶
| Go | |
|---|---|
CarriedItem is the item in the player's hand.
- Return type:
(Item, error) - Slots:
player_get_carried_item
Player.InventoryItem¶
| Go | |
|---|---|
InventoryItem is the item in one inventory slot.
- Parameters:
- slot :
int32
- slot :
- Return type:
(Item, error) - Slots:
player_get_item
Player.SetInventoryItem¶
| Go | |
|---|---|
SetInventoryItem puts an item into one inventory slot.
- Parameters:
- slot :
int32 - item :
Item
- slot :
- Return type:
error - Slots:
player_set_item
Player.ConnID¶
| Go | |
|---|---|
ConnID is the player's network connection id.
- Return type:
(uint64, error) - Slots:
player_conn_id
Player.Inventory¶
| Go | |
|---|---|
Inventory is the player's inventory as a container.
- Return type:
Container
Player.EnderChest¶
| Go | |
|---|---|
EnderChest is the player's ender chest as a container.
- Return type:
Container
Player.Armor¶
| Go | |
|---|---|
Armor is the player's armor slots as a container.
- Return type:
Container
Player.Offhand¶
| Go | |
|---|---|
Offhand is the player's offhand slot as a container.
- Return type:
Container
Player.GameType¶
| Go | |
|---|---|
GameType reads PIER_PPROP_GAME_TYPE: (G) Player::getPlayerGameType; write via player_set_gamemode
- Return type:
(float64, error) - Slots:
player_get_num
Player.Level¶
| Go | |
|---|---|
Level reads PIER_PPROP_LEVEL: (S) attribute Player::LEVEL()
- Return type:
(float64, error) - Slots:
player_get_num
Player.SetLevel¶
| Go | |
|---|---|
SetLevel writes PIER_PPROP_LEVEL: (S) attribute Player::LEVEL()
- Parameters:
- v :
float64
- v :
- Return type:
error - Slots:
player_set_num
Player.Experience¶
| Go | |
|---|---|
Experience reads PIER_PPROP_EXPERIENCE: (S) attribute Player::EXPERIENCE() (progress 0..1)
- Return type:
(float64, error) - Slots:
player_get_num
Player.SetExperience¶
| Go | |
|---|---|
SetExperience writes PIER_PPROP_EXPERIENCE: (S) attribute Player::EXPERIENCE() (progress 0..1)
- Parameters:
- v :
float64
- v :
- Return type:
error - Slots:
player_set_num
Player.Hunger¶
| Go | |
|---|---|
Hunger reads PIER_PPROP_HUNGER: (S) attribute Player::HUNGER()
- Return type:
(float64, error) - Slots:
player_get_num
Player.SetHunger¶
| Go | |
|---|---|
SetHunger writes PIER_PPROP_HUNGER: (S) attribute Player::HUNGER()
- Parameters:
- v :
float64
- v :
- Return type:
error - Slots:
player_set_num
Player.Saturation¶
| Go | |
|---|---|
Saturation reads PIER_PPROP_SATURATION: (S) attribute Player::SATURATION()
- Return type:
(float64, error) - Slots:
player_get_num
Player.SetSaturation¶
| Go | |
|---|---|
SetSaturation writes PIER_PPROP_SATURATION: (S) attribute Player::SATURATION()
- Parameters:
- v :
float64
- v :
- Return type:
error - Slots:
player_set_num
Player.Exhaustion¶
| Go | |
|---|---|
Exhaustion reads PIER_PPROP_EXHAUSTION: (S) attribute Player::EXHAUSTION()
- Return type:
(float64, error) - Slots:
player_get_num
Player.SetExhaustion¶
| Go | |
|---|---|
SetExhaustion writes PIER_PPROP_EXHAUSTION: (S) attribute Player::EXHAUSTION()
- Parameters:
- v :
float64
- v :
- Return type:
error - Slots:
player_set_num
Player.XpNeededNextLevel¶
| Go | |
|---|---|
XpNeededNextLevel reads PIER_PPROP_XP_NEEDED_NEXT_LEVEL: (G) Player::getXpNeededForNextLevel
- Return type:
(float64, error) - Slots:
player_get_num
Player.Luck¶
| Go | |
|---|---|
Luck reads PIER_PPROP_LUCK: (G) Player::getLuck
- Return type:
(float64, error) - Slots:
player_get_num
Player.SelectedSlot¶
| Go | |
|---|---|
SelectedSlot reads PIER_PPROP_SELECTED_SLOT: (G) Player::getSelectedItemSlot; set via PIER_PACT_SET_SELECTED_SLOT
- Return type:
(float64, error) - Slots:
player_get_num
Player.IsOperator¶
| Go | |
|---|---|
IsOperator reads PIER_PPROP_IS_OPERATOR: (G) Player::isOperator
- Return type:
(bool, error) - Slots:
player_get_num
Player.CanUseOperatorBlocks¶
| Go | |
|---|---|
CanUseOperatorBlocks reads PIER_PPROP_CAN_USE_OPERATOR_BLOCKS: (G) Player::canUseOperatorBlocks
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsFlying¶
| Go | |
|---|---|
IsFlying reads PIER_PPROP_IS_FLYING: (G) Player::isFlying
- Return type:
(bool, error) - Slots:
player_get_num
Player.CanJump¶
| Go | |
|---|---|
CanJump reads PIER_PPROP_CAN_JUMP: (G) Player::canJump
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsEmoting¶
| Go | |
|---|---|
IsEmoting reads PIER_PPROP_IS_EMOTING: (G) Player::isEmoting
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsInRaid¶
| Go | |
|---|---|
IsInRaid reads PIER_PPROP_IS_IN_RAID: (G) Player::isInRaid
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsHurt¶
| Go | |
|---|---|
IsHurt reads PIER_PPROP_IS_HURT: (G) Player::isHurt
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsScoping¶
| Go | |
|---|---|
IsScoping reads PIER_PPROP_IS_SCOPING: (G) Player::isScoping
- Return type:
(bool, error) - Slots:
player_get_num
Player.CanSleep¶
| Go | |
|---|---|
CanSleep reads PIER_PPROP_CAN_SLEEP: (G) Player::canSleep
- Return type:
(bool, error) - Slots:
player_get_num
Player.HasRespawnPosition¶
| Go | |
|---|---|
HasRespawnPosition reads PIER_PPROP_HAS_RESPAWN_POSITION: (G) Player::hasRespawnPosition
- Return type:
(bool, error) - Slots:
player_get_num
Player.ClientSubId¶
| Go | |
|---|---|
ClientSubId reads PIER_PPROP_CLIENT_SUB_ID: (G) Player::getClientSubId
- Return type:
(float64, error) - Slots:
player_get_num
Player.CanUseAbility¶
| Go | |
|---|---|
CanUseAbility reads PIER_PPROP_CAN_USE_ABILITY: (G) Player::canUseAbility; the ability index is passed through the player_action GET path, see PIER_PACT_CAN_USE_ABILITY
- Return type:
(bool, error) - Slots:
player_get_num
Player.Direction¶
| Go | |
|---|---|
Direction reads PIER_PPROP_DIRECTION: (G) Player::getDirection (0=S,1=W,2=N,3=E)
- Return type:
(float64, error) - Slots:
player_get_num
Player.ChunkRadius¶
| Go | |
|---|---|
ChunkRadius reads PIER_PPROP_CHUNK_RADIUS: (G) Player::getChunkRadius
- Return type:
(float64, error) - Slots:
player_get_num
Player.NetworkRtt¶
| Go | |
|---|---|
NetworkRtt reads PIER_PPROP_NETWORK_RTT: (G) getNetworkStatus().mPing (ms)
- Return type:
(float64, error) - Slots:
player_get_num
Player.Platform¶
| Go | |
|---|---|
Platform reads PIER_PPROP_PLATFORM: (G) Player::getPlatform
- Return type:
(float64, error) - Slots:
player_get_num
Player.EnchantmentSeed¶
| Go | |
|---|---|
EnchantmentSeed reads PIER_PPROP_ENCHANTMENT_SEED: (G) Player::getEnchantmentSeed
- Return type:
(float64, error) - Slots:
player_get_num
Player.IsUsingItem¶
| Go | |
|---|---|
IsUsingItem reads PIER_PPROP_IS_USING_ITEM: (G) Player::isUsingItem
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsBlocking¶
| Go | |
|---|---|
IsBlocking reads PIER_PPROP_IS_BLOCKING: (G) Player::isBlocking
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsGliding¶
| Go | |
|---|---|
IsGliding reads PIER_PPROP_IS_GLIDING: (G) Player::isGliding
- Return type:
(bool, error) - Slots:
player_get_num
Player.IsSwimming¶
| Go | |
|---|---|
IsSwimming reads PIER_PPROP_IS_SWIMMING: (G) Player::isSwimming
- Return type:
(bool, error) - Slots:
player_get_num
Player.PermissionLevel¶
| Go | |
|---|---|
PermissionLevel reads PIER_PPROP_PERMISSION_LEVEL: (G) Player::getPlayerPermissionLevel
- Return type:
(float64, error) - Slots:
player_get_num
Player.Score¶
| Go | |
|---|---|
Score reads PIER_PPROP_SCORE: (G) Player::getScore
- Return type:
(float64, error) - Slots:
player_get_num
Player.FallDistance¶
| Go | |
|---|---|
FallDistance reads PIER_PPROP_FALL_DISTANCE: (G) Actor::getFallDistance
- Return type:
(float64, error) - Slots:
player_get_num
Player.IsDead¶
| Go | |
|---|---|
IsDead reads PIER_PPROP_IS_DEAD: (G) Actor::isDead
- Return type:
(bool, error) - Slots:
player_get_num
Player.HasDiedBefore¶
| Go | |
|---|---|
HasDiedBefore reads PIER_PPROP_HAS_DIED_BEFORE: (G) Player::hasDiedBefore
- Return type:
(bool, error) - Slots:
player_get_num
Player.Dimension¶
| Go | |
|---|---|
Dimension reads PIER_PPROP_DIMENSION: (G) Actor::getDimensionId
- Return type:
(float64, error) - Slots:
player_get_num
Player.RealName¶
| Go | |
|---|---|
RealName reads PIER_PSTR_REAL_NAME: Player::getRealName
- Return type:
(string, error) - Slots:
player_get_str
Player.Uuid¶
| Go | |
|---|---|
Uuid reads PIER_PSTR_UUID: Player::getUuid().asString()
- Return type:
(string, error) - Slots:
player_get_str
Player.Xuid¶
| Go | |
|---|---|
Xuid reads PIER_PSTR_XUID: Player::getXuid
- Return type:
(string, error) - Slots:
player_get_str
Player.IpAndPort¶
| Go | |
|---|---|
IpAndPort reads PIER_PSTR_IP_AND_PORT: Player::getIPAndPort
- Return type:
(string, error) - Slots:
player_get_str
Player.LocaleCode¶
| Go | |
|---|---|
LocaleCode reads PIER_PSTR_LOCALE_CODE: Player::getLocaleCode
- Return type:
(string, error) - Slots:
player_get_str
Player.NameTag¶
| Go | |
|---|---|
NameTag reads PIER_PSTR_NAME_TAG: Actor::getNameTag (display name)
- Return type:
(string, error) - Slots:
player_get_str
Player.LastDeathPos¶
| Go | |
|---|---|
LastDeathPos reads PIER_PSTR_LAST_DEATH_POS: SNBT {x,y,z} or "" if none
- Return type:
(string, error) - Slots:
player_get_str
Player.LastDeathDimension¶
| Go | |
|---|---|
LastDeathDimension reads PIER_PSTR_LAST_DEATH_DIMENSION: dimension id as string
- Return type:
(string, error) - Slots:
player_get_str
Player.NetworkStatus¶
| Go | |
|---|---|
NetworkStatus reads PIER_PSTR_NETWORK_STATUS: SNBT {ping,avg_ping,packet_loss,max_ping}
- Return type:
(string, error) - Slots:
player_get_str
Player.PlatformOnlineId¶
| Go | |
|---|---|
PlatformOnlineId reads PIER_PSTR_PLATFORM_ONLINE_ID: Player::getPlatformOnlineId
- Return type:
(string, error) - Slots:
player_get_str
Player.RespawnPos¶
| Go | |
|---|---|
RespawnPos reads PIER_PSTR_RESPAWN_POS: SNBT {x,y,z,dim}: where this player would respawn. Never empty; a player with no bed reports the world spawn, and the two are not distinguishable.
- Return type:
(string, error) - Slots:
player_get_str
Player.SetAbility¶
| Go | |
|---|---|
SetAbility runs PIER_PACT_SET_ABILITY: a=AbilitiesIndex, b=0/1 (bool slots) or float (FlySpeed etc.). Restores PlayerPermissionLevel to its pre-write value afterwards: the engine's LayeredAbilities::setAbility is the "switch to custom permissions" path and pushes the player to Custom, and that level ships to the client inside UpdateAbilitiesPacket together with the ability layer. To change the level, use PIER_PACT_SET_PERMISSION_LEVEL. Refused (false) until the player has finished joining (Player::isPlayerInitialized): an ability written while the client is still loading desynchronizes until the player rejoins. Simulated players are exempt.
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.CanUseAbilityAction¶
| Go | |
|---|---|
CanUseAbilityAction runs PIER_PACT_CAN_USE_ABILITY: a=AbilitiesIndex β out "0"/"1" Player::canUseAbility
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetSelectedSlot¶
| Go | |
|---|---|
SetSelectedSlot runs PIER_PACT_SET_SELECTED_SLOT: a=slot Player::setSelectedSlot
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.GiveItem¶
| Go | |
|---|---|
GiveItem runs PIER_PACT_GIVE_ITEM: sarg=item SNBT ItemStack::fromTag + Player::addAndRefresh
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetSpawnPoint¶
| Go | |
|---|---|
SetSpawnPoint runs PIER_PACT_SET_SPAWN_POINT: a,b,c=pos, sarg=dim id (any registered dim); native Player::setRespawnPosition
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.ClearTitle¶
| Go | |
|---|---|
ClearTitle runs PIER_PACT_CLEAR_TITLE: native SetTitlePacket(Clear)
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetTitle¶
| Go | |
|---|---|
SetTitle runs PIER_PACT_SET_TITLE: sarg=text, a=slot(0 title,1 subtitle,2 actionbar); native SetTitlePacket, text sent verbatim
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.AddExperience¶
| Go | |
|---|---|
AddExperience runs PIER_PACT_ADD_EXPERIENCE: a=xp Player::addExperience
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.AddLevels¶
| Go | |
|---|---|
AddLevels runs PIER_PACT_ADD_LEVELS: a=levels Player::addLevels
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.StartCooldown¶
| Go | |
|---|---|
StartCooldown runs PIER_PACT_START_COOLDOWN: sarg=item name, a=ticks Player::startItemCooldown
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.StartRiding¶
| Go | |
|---|---|
StartRiding runs PIER_PACT_START_RIDING: a=vehicle ActorUniqueID (lower 64b) Player::startRiding
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.StopRiding¶
| Go | |
|---|---|
StopRiding runs PIER_PACT_STOP_RIDING: Player::stopRiding
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.Attack¶
| Go | |
|---|---|
Attack runs PIER_PACT_ATTACK: a=target ActorUniqueID (lower 64b) Player::attack
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.Drop¶
| Go | |
|---|---|
Drop runs PIER_PACT_DROP: sarg=item SNBT, a=random(0/1) Player::drop
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.Interact¶
| Go | |
|---|---|
Interact runs PIER_PACT_INTERACT: a=target ActorUniqueID Player::interact
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.StartUsingItem¶
| Go | |
|---|---|
StartUsingItem runs PIER_PACT_START_USING_ITEM: sarg=item SNBT, a=duration Player::startUsingItem
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.StopUsingItem¶
| Go | |
|---|---|
StopUsingItem runs PIER_PACT_STOP_USING_ITEM: Player::stopUsingItem
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetChunkRadius¶
| Go | |
|---|---|
SetChunkRadius runs PIER_PACT_SET_CHUNK_RADIUS: a=radius Player::setChunkRadius
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetEnchantmentSeed¶
| Go | |
|---|---|
SetEnchantmentSeed runs PIER_PACT_SET_ENCHANTMENT_SEED: a=seed Player::setEnchantmentSeed
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.RegisterTrackedBoss¶
| Go | |
|---|---|
RegisterTrackedBoss runs PIER_PACT_REGISTER_TRACKED_BOSS: a=boss ActorUniqueID Player::registerTrackedBoss
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.UnregisterTrackedBoss¶
| Go | |
|---|---|
UnregisterTrackedBoss runs PIER_PACT_UNREGISTER_TRACKED_BOSS: a=boss ActorUniqueID Player::unRegisterTrackedBoss
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.PlayEmote¶
| Go | |
|---|---|
PlayEmote runs PIER_PACT_PLAY_EMOTE: sarg=piece id Player::playEmote
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.ResendAllChunks¶
| Go | |
|---|---|
ResendAllChunks runs PIER_PACT_RESEND_ALL_CHUNKS: Player::resendAllChunks
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.OpenInventory¶
| Go | |
|---|---|
OpenInventory runs PIER_PACT_OPEN_INVENTORY: Player::openInventory
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SidebarSet¶
| Go | |
|---|---|
SidebarSet runs PIER_PACT_SIDEBAR_SET: sarg="obj\ntitle\nlineβ¦" per-player sidebar
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SidebarClear¶
| Go | |
|---|---|
SidebarClear runs PIER_PACT_SIDEBAR_CLEAR: sarg=objective RemoveObjectivePacket
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
Player.SetPermissionLevel¶
| Go | |
|---|---|
SetPermissionLevel runs PIER_PACT_SET_PERMISSION_LEVEL: a=PlayerPermissionLevel (0 Visitor, 1 Member, 2 Operator, 3 Custom). LayeredAbilities::setPlayerPermissions plus UpdateAbilitiesPacket. The read side is PIER_PPROP_PERMISSION_LEVEL. Refused until the player has finished joining, like PIER_PACT_SET_ABILITY.
The output, when the verb has one, is returned; abi.h names each argument.
- Parameters:
- sarg :
string - a :
float64 - b :
float64 - c :
float64
- sarg :
- Return type:
(string, error) - Slots:
player_action
PlayerInfo¶
| Go | |
|---|---|
PlayerInfo is one online player as ListPlayers reports it. Dim and the position are read only when present, and HasDim and HasPos say whether they were.
SelKind¶
| Go | |
|---|---|
SelKind says how a PlayerSel names its player.
| Name | Value | Description |
|---|---|---|
SelName |
0 |
|
SelXuid |
1 |
|
SelUuid |
2 |
PlayerSel¶
PlayerSel names one player by name, xuid or uuid.
PlayerPos¶
PlayerPos is where a player is; Found is false when nobody matched.
PProp*¶
| Name | Value | Description |
|---|---|---|
PPropGameType |
0 |
PPropGameType is PIER_PPROP_GAME_TYPE: (G) Player::getPlayerGameType; write via player_set_gamemode |
PPropLevel |
1 |
PPropLevel is PIER_PPROP_LEVEL: (S) attribute Player::LEVEL() |
PPropExperience |
2 |
PPropExperience is PIER_PPROP_EXPERIENCE: (S) attribute Player::EXPERIENCE() (progress 0..1) |
PPropHunger |
3 |
PPropHunger is PIER_PPROP_HUNGER: (S) attribute Player::HUNGER() |
PPropSaturation |
4 |
PPropSaturation is PIER_PPROP_SATURATION: (S) attribute Player::SATURATION() |
PPropExhaustion |
5 |
PPropExhaustion is PIER_PPROP_EXHAUSTION: (S) attribute Player::EXHAUSTION() |
PPropXpNeededNextLevel |
6 |
PPropXpNeededNextLevel is PIER_PPROP_XP_NEEDED_NEXT_LEVEL: (G) Player::getXpNeededForNextLevel |
PPropLuck |
7 |
PPropLuck is PIER_PPROP_LUCK: (G) Player::getLuck |
PPropSelectedSlot |
8 |
PPropSelectedSlot is PIER_PPROP_SELECTED_SLOT: (G) Player::getSelectedItemSlot; set via PIER_PACT_SET_SELECTED_SLOT |
PPropIsOperator |
9 |
PPropIsOperator is PIER_PPROP_IS_OPERATOR: (G) Player::isOperator |
PPropCanUseOperatorBlocks |
10 |
PPropCanUseOperatorBlocks is PIER_PPROP_CAN_USE_OPERATOR_BLOCKS: (G) Player::canUseOperatorBlocks |
PPropIsFlying |
11 |
PPropIsFlying is PIER_PPROP_IS_FLYING: (G) Player::isFlying |
PPropCanJump |
12 |
PPropCanJump is PIER_PPROP_CAN_JUMP: (G) Player::canJump |
PPropIsEmoting |
13 |
PPropIsEmoting is PIER_PPROP_IS_EMOTING: (G) Player::isEmoting |
PPropIsInRaid |
14 |
PPropIsInRaid is PIER_PPROP_IS_IN_RAID: (G) Player::isInRaid |
PPropIsHurt |
15 |
PPropIsHurt is PIER_PPROP_IS_HURT: (G) Player::isHurt |
PPropIsScoping |
16 |
PPropIsScoping is PIER_PPROP_IS_SCOPING: (G) Player::isScoping |
PPropCanSleep |
17 |
PPropCanSleep is PIER_PPROP_CAN_SLEEP: (G) Player::canSleep |
PPropHasRespawnPosition |
18 |
PPropHasRespawnPosition is PIER_PPROP_HAS_RESPAWN_POSITION: (G) Player::hasRespawnPosition |
PPropClientSubId |
19 |
PPropClientSubId is PIER_PPROP_CLIENT_SUB_ID: (G) Player::getClientSubId |
PPropCanUseAbility |
20 |
PPropCanUseAbility is PIER_PPROP_CAN_USE_ABILITY: (G) Player::canUseAbility; the ability index is passed through the player_action GET path, see PIER_PACT_CAN_USE_ABILITY |
PPropDirection |
21 |
PPropDirection is PIER_PPROP_DIRECTION: (G) Player::getDirection (0=S,1=W,2=N,3=E) |
PPropChunkRadius |
22 |
PPropChunkRadius is PIER_PPROP_CHUNK_RADIUS: (G) Player::getChunkRadius |
PPropNetworkRtt |
23 |
PPropNetworkRtt is PIER_PPROP_NETWORK_RTT: (G) getNetworkStatus().mPing (ms) |
PPropPlatform |
24 |
PPropPlatform is PIER_PPROP_PLATFORM: (G) Player::getPlatform |
PPropEnchantmentSeed |
25 |
PPropEnchantmentSeed is PIER_PPROP_ENCHANTMENT_SEED: (G) Player::getEnchantmentSeed |
PPropIsUsingItem |
26 |
PPropIsUsingItem is PIER_PPROP_IS_USING_ITEM: (G) Player::isUsingItem |
PPropIsBlocking |
27 |
PPropIsBlocking is PIER_PPROP_IS_BLOCKING: (G) Player::isBlocking |
PPropIsGliding |
28 |
PPropIsGliding is PIER_PPROP_IS_GLIDING: (G) Player::isGliding |
PPropIsSwimming |
29 |
PPropIsSwimming is PIER_PPROP_IS_SWIMMING: (G) Player::isSwimming |
PPropPermissionLevel |
30 |
PPropPermissionLevel is PIER_PPROP_PERMISSION_LEVEL: (G) Player::getPlayerPermissionLevel |
PPropScore |
31 |
PPropScore is PIER_PPROP_SCORE: (G) Player::getScore |
PPropFallDistance |
32 |
PPropFallDistance is PIER_PPROP_FALL_DISTANCE: (G) Actor::getFallDistance |
PPropIsDead |
33 |
PPropIsDead is PIER_PPROP_IS_DEAD: (G) Actor::isDead |
PPropHasDiedBefore |
34 |
PPropHasDiedBefore is PIER_PPROP_HAS_DIED_BEFORE: (G) Player::hasDiedBefore |
PPropDimension |
35 |
PPropDimension is PIER_PPROP_DIMENSION: (G) Actor::getDimensionId |
PStr*¶
| Name | Value | Description |
|---|---|---|
PStrRealName |
0 |
PStrRealName is PIER_PSTR_REAL_NAME: Player::getRealName |
PStrUuid |
1 |
PStrUuid is PIER_PSTR_UUID: Player::getUuid().asString() |
PStrXuid |
2 |
PStrXuid is PIER_PSTR_XUID: Player::getXuid |
PStrIpAndPort |
3 |
PStrIpAndPort is PIER_PSTR_IP_AND_PORT: Player::getIPAndPort |
PStrLocaleCode |
4 |
PStrLocaleCode is PIER_PSTR_LOCALE_CODE: Player::getLocaleCode |
PStrNameTag |
5 |
PStrNameTag is PIER_PSTR_NAME_TAG: Actor::getNameTag (display name) |
PStrLastDeathPos |
6 |
PStrLastDeathPos is PIER_PSTR_LAST_DEATH_POS: SNBT {x,y,z} or "" if none |
PStrLastDeathDimension |
7 |
PStrLastDeathDimension is PIER_PSTR_LAST_DEATH_DIMENSION: dimension id as string |
PStrNetworkStatus |
8 |
PStrNetworkStatus is PIER_PSTR_NETWORK_STATUS: SNBT {ping,avg_ping,packet_loss,max_ping} |
PStrPlatformOnlineId |
9 |
PStrPlatformOnlineId is PIER_PSTR_PLATFORM_ONLINE_ID: Player::getPlatformOnlineId |
PStrRespawnPos |
10 |
PStrRespawnPos is PIER_PSTR_RESPAWN_POS: SNBT {x,y,z,dim}: where this player would respawn. Never empty; a player with no bed reports the world spawn, and the two are not distinguishable. |
PAct*¶
| Name | Value | Description |
|---|---|---|
PActSetAbility |
0 |
PActSetAbility is PIER_PACT_SET_ABILITY: a=AbilitiesIndex, b=0/1 (bool slots) or float (FlySpeed etc.). Restores PlayerPermissionLevel to its pre-write value afterwards: the engine's LayeredAbilities::setAbility is the "switch to custom permissions" path and pushes the player to Custom, and that level ships to the client inside UpdateAbilitiesPacket together with the ability layer. To change the level, use PIER_PACT_SET_PERMISSION_LEVEL. Refused (false) until the player has finished joining (Player::isPlayerInitialized): an ability written while the client is still loading desynchronizes until the player rejoins. Simulated players are exempt. |
PActCanUseAbility |
1 |
PActCanUseAbility is PIER_PACT_CAN_USE_ABILITY: a=AbilitiesIndex β out "0"/"1" Player::canUseAbility |
PActSetSelectedSlot |
2 |
PActSetSelectedSlot is PIER_PACT_SET_SELECTED_SLOT: a=slot Player::setSelectedSlot |
PActGiveItem |
3 |
PActGiveItem is PIER_PACT_GIVE_ITEM: sarg=item SNBT ItemStack::fromTag + Player::addAndRefresh |
PActSetSpawnPoint |
4 |
PActSetSpawnPoint is PIER_PACT_SET_SPAWN_POINT: a,b,c=pos, sarg=dim id (any registered dim); native Player::setRespawnPosition |
PActClearTitle |
5 |
PActClearTitle is PIER_PACT_CLEAR_TITLE: native SetTitlePacket(Clear) |
PActSetTitle |
6 |
PActSetTitle is PIER_PACT_SET_TITLE: sarg=text, a=slot(0 title,1 subtitle,2 actionbar); native SetTitlePacket, text sent verbatim |
PActAddExperience |
7 |
PActAddExperience is PIER_PACT_ADD_EXPERIENCE: a=xp Player::addExperience |
PActAddLevels |
8 |
PActAddLevels is PIER_PACT_ADD_LEVELS: a=levels Player::addLevels |
PActStartCooldown |
9 |
PActStartCooldown is PIER_PACT_START_COOLDOWN: sarg=item name, a=ticks Player::startItemCooldown |
PActStartRiding |
10 |
PActStartRiding is PIER_PACT_START_RIDING: a=vehicle ActorUniqueID (lower 64b) Player::startRiding |
PActStopRiding |
11 |
PActStopRiding is PIER_PACT_STOP_RIDING: Player::stopRiding |
PActAttack |
12 |
PActAttack is PIER_PACT_ATTACK: a=target ActorUniqueID (lower 64b) Player::attack |
PActDrop |
13 |
PActDrop is PIER_PACT_DROP: sarg=item SNBT, a=random(0/1) Player::drop |
PActInteract |
14 |
PActInteract is PIER_PACT_INTERACT: a=target ActorUniqueID Player::interact |
PActStartUsingItem |
15 |
PActStartUsingItem is PIER_PACT_START_USING_ITEM: sarg=item SNBT, a=duration Player::startUsingItem |
PActStopUsingItem |
16 |
PActStopUsingItem is PIER_PACT_STOP_USING_ITEM: Player::stopUsingItem |
PActSetChunkRadius |
17 |
PActSetChunkRadius is PIER_PACT_SET_CHUNK_RADIUS: a=radius Player::setChunkRadius |
PActSetEnchantmentSeed |
18 |
PActSetEnchantmentSeed is PIER_PACT_SET_ENCHANTMENT_SEED: a=seed Player::setEnchantmentSeed |
PActRegisterTrackedBoss |
19 |
PActRegisterTrackedBoss is PIER_PACT_REGISTER_TRACKED_BOSS: a=boss ActorUniqueID Player::registerTrackedBoss |
PActUnregisterTrackedBoss |
20 |
PActUnregisterTrackedBoss is PIER_PACT_UNREGISTER_TRACKED_BOSS: a=boss ActorUniqueID Player::unRegisterTrackedBoss |
PActPlayEmote |
21 |
PActPlayEmote is PIER_PACT_PLAY_EMOTE: sarg=piece id Player::playEmote |
PActResendAllChunks |
22 |
PActResendAllChunks is PIER_PACT_RESEND_ALL_CHUNKS: Player::resendAllChunks |
PActOpenInventory |
23 |
PActOpenInventory is PIER_PACT_OPEN_INVENTORY: Player::openInventory |
PActSidebarSet |
24 |
PActSidebarSet is PIER_PACT_SIDEBAR_SET: sarg="obj\ntitle\nlineβ¦" per-player sidebar |
PActSidebarClear |
25 |
PActSidebarClear is PIER_PACT_SIDEBAR_CLEAR: sarg=objective RemoveObjectivePacket |
PActSetPermissionLevel |
26 |
PActSetPermissionLevel is PIER_PACT_SET_PERMISSION_LEVEL: a=PlayerPermissionLevel (0 Visitor, 1 Member, 2 Operator, 3 Custom). LayeredAbilities::setPlayerPermissions plus UpdateAbilitiesPacket. The read side is PIER_PPROP_PERMISSION_LEVEL. Refused until the player has finished joining, like PIER_PACT_SET_ABILITY. |