Skip to content

PlayerAPI

xqwtxon edited this page Mar 3, 2024 · 1 revision

PlayerAPI

PlayerAPI is the data beyond the player. It is data gathered to collect player information to enhance checks, and more...

Getting started with PlayerAPI

To call this instance you have two options:

  1. Calling from Directly through API.
    $playerAPI = PlayerAPI::getAPIPlayer(<pocketmine\player\Player class>);
  2. Calling from PluginAPI
    $playerAPI = API::getPlayer(<string | pocketmine\player\Player class>);

List of all methods

These are the list of public functions of the PlayerAPI code:

  • PlayerAPI->getPlayer() : ?Player
  • PlayerAPI->isCaptcha() : bool
  • PlayerAPI->setCaptcha(bool $data) : void
  • PlayerAPI->isFlagged() : bool
  • PlayerAPI->setFlagged(bool $data) : void
  • PlayerAPI->actionBreakingSpecial() : bool
  • PlayerAPI->setActionBreakingSpecial(bool $data) : void
  • PlayerAPI->actionPlacingSpecial() : bool
  • PlayerAPI->setActionPlacingSpecial(bool $data) : void
  • PlayerAPI->isInventoryOpen() : bool
  • PlayerAPI->setInventoryOpen(bool $data) : void
  • PlayerAPI->isTransactionArmorInventory() : bool
  • PlayerAPI->setTransactionArmorInventory(bool $data) : void
  • PlayerAPI->isUnderBlock() : bool
  • PlayerAPI->setUnderBlock(bool $data) : void
  • PlayerAPI->isOnAdhesion() : bool
  • PlayerAPI->setOnAdhesion(bool $data) : void
  • PlayerAPI->isOnPlant() : bool
  • PlayerAPI->setOnPlant(bool $data) : void
  • PlayerAPI->isOnDoor() : bool
  • PlayerAPI->setOnDoor(bool $data) : void
  • PlayerAPI->isOnCarpet() : bool
  • PlayerAPI->setOnCarpet(bool $data) : void
  • PlayerAPI->isOnPlate() : bool
  • PlayerAPI->setOnPlate(bool $data) : void
  • PlayerAPI->isOnSnow() : bool
  • PlayerAPI->setOnSnow(bool $data) : void
  • PlayerAPI->isSprinting() : bool
  • PlayerAPI->setSprinting(bool $data) : void
  • PlayerAPI->isOnGround() : bool
  • PlayerAPI->setOnGround(bool $data) : void
  • PlayerAPI->isSniffing() : bool
  • PlayerAPI->setSniffing(bool $data) : void
  • PlayerAPI->isInLiquid() : bool
  • PlayerAPI->setInLiquid(bool $data) : void
  • PlayerAPI->isOnStairs() : bool
  • PlayerAPI->setOnStairs(bool $data) : void
  • PlayerAPI->isOnIce() : bool
  • PlayerAPI->setOnIce(bool $data) : void
  • PlayerAPI->isDigging() : bool
  • PlayerAPI->getBlockBreakHandler() : ?SurvivalBlockBreakHandler
  • PlayerAPI->isInWeb() : bool
  • PlayerAPI->isInBoxBlock() : bool
  • PlayerAPI->getLastGroundY() : float
  • PlayerAPI->setlastGroundY(float $data) : void
  • PlayerAPI->getLastNoGroundY() : float
  • PlayerAPI->getLastDelayedMovePacket() : float
  • PlayerAPI->setLastDelayedMovePacket(float $data) : void
  • PlayerAPI->getPing() : float
  • PlayerAPI->getCPS() : int
  • PlayerAPI->setCPS(int $data) : void
  • PlayerAPI->getBlocksBrokeASec() : int
  • PlayerAPI->setBlocksBrokeASec(int $data) : void
  • PlayerAPI->getBlocksPlacedASec() : int
  • PlayerAPI->setBlocksPlacedASec(int $data) : void
  • PlayerAPI->getNumberBlocksAllowBreak() : int
  • PlayerAPI->setNumberBlocksAllowBreak(int $data) : void
  • PlayerAPI->getNumberBlocksAllowPlace() : int
  • PlayerAPI->setNumberBlocksAllowPlace(int $data) : void
  • PlayerAPI->getJoinedAtTheTime() : float
  • PlayerAPI->setJoinedAtTheTime(float $data) : void
  • PlayerAPI->getOnlineTime() : int
  • PlayerAPI->getTeleportTicks() : float
  • PlayerAPI->setTeleportTicks(float $data) : void
  • PlayerAPI->getJumpTicks() : float
  • PlayerAPI->setJumpTicks(float $data) : void
  • PlayerAPI->getAttackTicks() : float
  • PlayerAPI->setAttackTicks(float $data) : void
  • PlayerAPI->getSlimeBlockTicks() : float
  • PlayerAPI->getDeathTicks() : float
  • PlayerAPI->setSlimeBlockTicks(float $data) : void
  • PlayerAPI->getPlacingTicks() : float
  • PlayerAPI->setPlacingTicks(float $data) : void
  • PlayerAPI->getNLocation() : array
  • PlayerAPI->setNLocation(Location $from, Location $to) : void
  • PlayerAPI->getCaptchaCode() : string
  • PlayerAPI->setCaptchaCode(string $data) : void
  • PlayerAPI->setDebug(bool $value = true) : void
  • PlayerAPI->isDebug() : bool
Clone this wiki locally