Class GlowPlayer

All Implemented Interfaces:
com.destroystokyo.paper.network.NetworkClient, net.kyori.adventure.audience.Audience, net.kyori.adventure.identity.Identified, net.kyori.adventure.text.event.HoverEventSource<net.kyori.adventure.text.event.HoverEvent.ShowEntity>, org.bukkit.attribute.Attributable, org.bukkit.command.CommandSender, org.bukkit.configuration.serialization.ConfigurationSerializable, org.bukkit.conversations.Conversable, org.bukkit.entity.AnimalTamer, org.bukkit.entity.Damageable, org.bukkit.entity.Entity, org.bukkit.entity.HumanEntity, org.bukkit.entity.LivingEntity, org.bukkit.entity.Player, org.bukkit.inventory.InventoryHolder, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.OfflinePlayer, org.bukkit.permissions.Permissible, org.bukkit.permissions.ServerOperator, org.bukkit.persistence.PersistentDataHolder, org.bukkit.plugin.messaging.PluginMessageRecipient, org.bukkit.projectiles.ProjectileSource

public class GlowPlayer extends GlowHumanEntity implements org.bukkit.entity.Player
Represents an in-game player.
  • Field Details

    • HOOK_MAX_DISTANCE

      public static final int HOOK_MAX_DISTANCE
      Max distance of a fishing hook.
      See Also:
    • teleportedTo

      public org.bukkit.Location teleportedTo
    • affectsSpawning

      public boolean affectsSpawning
  • Constructor Details

    • GlowPlayer

      public GlowPlayer(GlowSession session, GlowPlayerProfile profile, PlayerDataService.PlayerReader reader)
      Creates a new player and adds it to the world.
      Parameters:
      session - The player's session.
      profile - The player's profile with name and UUID information.
      reader - The PlayerReader to be used to initialize the player.
  • Method Details

    • hasJoined

      public boolean hasJoined()
    • getCurrentFishingHook

      public GlowFishingHook getCurrentFishingHook()
      Returns the current fishing hook.
      Returns:
      the current fishing hook, or null if not fishing
    • setCurrentFishingHook

      public void setCurrentFishingHook(GlowFishingHook fishingHook)
      Removes the current fishing hook, if any, and sets a new one.
      Parameters:
      fishingHook - the new fishing hook, or null to stop fishing
    • join

      public void join(GlowSession session, PlayerDataService.PlayerReader reader)
      Loads the player's state and sends the messages that are necessary on login.
      Parameters:
      session - the player's session
      reader - the source of the player's saved state
    • toString

      public String toString()
      Overrides:
      toString in class GlowEntity
    • damage

      public void damage(double amount)
      Specified by:
      damage in interface org.bukkit.entity.Damageable
      Overrides:
      damage in class GlowEntity
    • damage

      public void damage(double amount, org.bukkit.entity.Entity cause)
      Specified by:
      damage in interface org.bukkit.entity.Damageable
      Overrides:
      damage in class GlowEntity
    • damage

      public void damage(double amount, org.bukkit.entity.Entity source, @NotNull @NotNull org.bukkit.event.entity.EntityDamageEvent.DamageCause cause)
      Specified by:
      damage in interface org.bukkit.entity.Damageable
      Overrides:
      damage in class GlowLivingEntity
    • damage

      public void damage(double amount, org.bukkit.event.entity.EntityDamageEvent.DamageCause cause)
      Specified by:
      damage in interface org.bukkit.entity.Damageable
      Overrides:
      damage in class GlowEntity
    • canTakeDamage

      public boolean canTakeDamage(org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause)
      Description copied from class: GlowLivingEntity
      Get whether this entity should take damage from the specified source.

      Usually used to check environmental sources such as drowning.

      Overrides:
      canTakeDamage in class GlowHumanEntity
      Parameters:
      damageCause - the damage source to check
      Returns:
      whether this entity can take damage from the source
    • remove

      public void remove()
      Kicks this player.
      Specified by:
      remove in interface org.bukkit.entity.Entity
      Overrides:
      remove in class GlowEntity
    • remove

      public void remove(boolean async)
      Handle player disconnection.
      Parameters:
      async - if true, the player's data is saved asynchronously
    • shouldSave

      public boolean shouldSave()
      Description copied from class: GlowEntity
      Checks whether this entity should be saved as part of the world.
      Overrides:
      shouldSave in class GlowEntity
      Returns:
      True if the entity should be saved.
    • pulse

      public void pulse()
      Description copied from class: GlowEntity
      Called every game cycle. Subclasses should implement this to implement periodic functionality e.g. mob AI.
      Overrides:
      pulse in class GlowHumanEntity
    • pulsePhysics

      protected void pulsePhysics()
      Overrides:
      pulsePhysics in class GlowLivingEntity
    • jump

      protected void jump()
      Overrides:
      jump in class GlowLivingEntity
    • respawn

      public void respawn()
      Respawn the player after they have died.
    • canSeeChunk

      public boolean canSeeChunk(GlowChunk.Key chunk)
      Checks whether the player can see the given chunk.
      Parameters:
      chunk - The chunk to check.
      Returns:
      If the chunk is known to the player's client.
    • canSeeEntity

      public boolean canSeeEntity(GlowEntity entity)
      Checks whether the player can see the given entity.
      Parameters:
      entity - The entity to check.
      Returns:
      If the entity is known to the player's client.
    • openSignEditor

      public void openSignEditor(org.bukkit.Location loc)
      Open the sign editor interface at the specified location.
      Parameters:
      loc - The location to open the editor at
    • checkSignLocation

      public boolean checkSignLocation(org.bukkit.Location loc)
      Check that the specified location matches that of the last opened sign editor, and if so, clears the last opened sign editor.
      Parameters:
      loc - The location to check
      Returns:
      Whether the location matched.
    • getUserListEntry

      public UserListItemMessage.Entry getUserListEntry()
      Get a UserListItemMessage entry representing adding this player.
      Returns:
      The entry (action ADD_PLAYER) with this player's information.
    • setVelocity

      public void setVelocity(org.bukkit.util.Vector velocity)
      Specified by:
      setVelocity in interface org.bukkit.entity.Entity
      Overrides:
      setVelocity in class GlowEntity
    • getBoundingBox

      @NotNull public @NotNull org.bukkit.util.BoundingBox getBoundingBox()
      Specified by:
      getBoundingBox in interface org.bukkit.entity.Entity
      Overrides:
      getBoundingBox in class GlowEntity
    • setRotation

      public void setRotation(float yaw, float pitch)
      Specified by:
      setRotation in interface org.bukkit.entity.Entity
      Overrides:
      setRotation in class GlowEntity
    • setSettings

      public void setSettings(ClientSettings settings)
      Set this player's client settings.
      Parameters:
      settings - The settings to set.
    • serialize

      public Map<String,Object> serialize()
      Specified by:
      serialize in interface org.bukkit.configuration.serialization.ConfigurationSerializable
    • getType

      public org.bukkit.entity.EntityType getType()
      Specified by:
      getType in interface org.bukkit.entity.Entity
      Overrides:
      getType in class GlowEntity
    • getAddress

      public InetSocketAddress getAddress()
      Specified by:
      getAddress in interface com.destroystokyo.paper.network.NetworkClient
      Specified by:
      getAddress in interface org.bukkit.entity.Player
    • getProtocolVersion

      public int getProtocolVersion()
      Specified by:
      getProtocolVersion in interface com.destroystokyo.paper.network.NetworkClient
    • getVirtualHost

      @Nullable public InetSocketAddress getVirtualHost()
      Specified by:
      getVirtualHost in interface com.destroystokyo.paper.network.NetworkClient
    • isOnline

      public boolean isOnline()
      Specified by:
      isOnline in interface org.bukkit.OfflinePlayer
    • isBanned

      public boolean isBanned()
      Specified by:
      isBanned in interface org.bukkit.OfflinePlayer
    • isWhitelisted

      public boolean isWhitelisted()
      Specified by:
      isWhitelisted in interface org.bukkit.OfflinePlayer
    • setWhitelisted

      public void setWhitelisted(boolean value)
      Specified by:
      setWhitelisted in interface org.bukkit.OfflinePlayer
    • hasDefaultLandingBehavior

      protected boolean hasDefaultLandingBehavior()
      Description copied from class: GlowEntity
      If true, GlowEntity.setRawLocation(Location, boolean) with fall true will call GlowEntity.setOnGround(boolean) according to whether or not our location is inside a solid block.
      Overrides:
      hasDefaultLandingBehavior in class GlowEntity
      Returns:
      true to call GlowEntity.setOnGround(boolean) from GlowEntity.setRawLocation(Location, boolean); false otherwise
    • getPlayer

      public org.bukkit.entity.Player getPlayer()
      Specified by:
      getPlayer in interface org.bukkit.OfflinePlayer
    • hasPlayedBefore

      public boolean hasPlayedBefore()
      Specified by:
      hasPlayedBefore in interface org.bukkit.OfflinePlayer
    • isOp

      public boolean isOp()
      Description copied from class: GlowHumanEntity
      Whether this human is considered an op.
      Specified by:
      isOp in interface org.bukkit.permissions.ServerOperator
      Overrides:
      isOp in class GlowHumanEntity
    • setOp

      public void setOp(boolean value)
      Description copied from class: GlowEntity
      Whether this entity has operator permissions.
      Specified by:
      setOp in interface org.bukkit.permissions.ServerOperator
      Overrides:
      setOp in class GlowHumanEntity
    • createSpawnMessage

      public List<com.flowpowered.network.Message> createSpawnMessage()
      Description copied from class: GlowEntity
      Creates a list of Messages which can be sent to a client to spawn this entity. Implementations in concrete subclasses may return a shallowly immutable list.
      Overrides:
      createSpawnMessage in class GlowHumanEntity
      Returns:
      A list of messages which can spawn this entity.
    • displayName

      @NotNull public @NotNull net.kyori.adventure.text.Component displayName()
      Specified by:
      displayName in interface org.bukkit.entity.Player
    • displayName

      public void displayName(@Nullable @Nullable net.kyori.adventure.text.Component component)
      Specified by:
      displayName in interface org.bukkit.entity.Player
    • getDisplayName

      public String getDisplayName()
      Specified by:
      getDisplayName in interface org.bukkit.entity.Player
    • setDisplayName

      public void setDisplayName(String name)
      Specified by:
      setDisplayName in interface org.bukkit.entity.Player
    • playerListName

      public void playerListName(@Nullable @Nullable net.kyori.adventure.text.Component component)
      Specified by:
      playerListName in interface org.bukkit.entity.Player
    • playerListName

      @Nullable public @Nullable net.kyori.adventure.text.Component playerListName()
      Specified by:
      playerListName in interface org.bukkit.entity.Player
    • playerListHeader

      @Nullable public @Nullable net.kyori.adventure.text.Component playerListHeader()
      Specified by:
      playerListHeader in interface org.bukkit.entity.Player
    • playerListFooter

      @Nullable public @Nullable net.kyori.adventure.text.Component playerListFooter()
      Specified by:
      playerListFooter in interface org.bukkit.entity.Player
    • getPlayerListName

      public String getPlayerListName()
      Specified by:
      getPlayerListName in interface org.bukkit.entity.Player
    • setPlayerListName

      public void setPlayerListName(String name)
      Specified by:
      setPlayerListName in interface org.bukkit.entity.Player
    • setCompassTarget

      public void setCompassTarget(org.bukkit.Location loc)
      Specified by:
      setCompassTarget in interface org.bukkit.entity.Player
    • getBedSpawnLocation

      public org.bukkit.Location getBedSpawnLocation()
      Specified by:
      getBedSpawnLocation in interface org.bukkit.OfflinePlayer
      Specified by:
      getBedSpawnLocation in interface org.bukkit.entity.Player
    • setBedSpawnLocation

      public void setBedSpawnLocation(org.bukkit.Location bedSpawn)
      Specified by:
      setBedSpawnLocation in interface org.bukkit.entity.Player
    • setBedSpawnLocation

      public void setBedSpawnLocation(org.bukkit.Location location, boolean force)
      Specified by:
      setBedSpawnLocation in interface org.bukkit.entity.Player
    • getLastLogin

      public long getLastLogin()
      Specified by:
      getLastLogin in interface org.bukkit.OfflinePlayer
    • getLastSeen

      public long getLastSeen()
      Specified by:
      getLastSeen in interface org.bukkit.OfflinePlayer
    • sleep

      public boolean sleep(@NotNull @NotNull org.bukkit.Location location, boolean force)
      Specified by:
      sleep in interface org.bukkit.entity.HumanEntity
    • wakeup

      public void wakeup(boolean setSpawnLocation)
      Specified by:
      wakeup in interface org.bukkit.entity.HumanEntity
    • getBedLocation

      @NotNull public @NotNull org.bukkit.Location getBedLocation()
      Specified by:
      getBedLocation in interface org.bukkit.entity.HumanEntity
    • isSleepingIgnored

      public boolean isSleepingIgnored()
      Specified by:
      isSleepingIgnored in interface org.bukkit.entity.Player
    • setSleepingIgnored

      public void setSleepingIgnored(boolean isSleeping)
      Specified by:
      setSleepingIgnored in interface org.bukkit.entity.Player
    • setGameMode

      public void setGameMode(org.bukkit.GameMode mode)
      Description copied from class: GlowHumanEntity
      The player's active game mode.
      Specified by:
      setGameMode in interface org.bukkit.entity.HumanEntity
      Overrides:
      setGameMode in class GlowHumanEntity
    • getActiveItem

      public org.bukkit.inventory.ItemStack getActiveItem()
      Specified by:
      getActiveItem in interface org.bukkit.entity.LivingEntity
      Overrides:
      getActiveItem in class GlowLivingEntity
    • setUsageTime

      public void setUsageTime(int usageTime)
    • getItemUseRemainingTime

      public int getItemUseRemainingTime()
      Specified by:
      getItemUseRemainingTime in interface org.bukkit.entity.LivingEntity
      Overrides:
      getItemUseRemainingTime in class GlowLivingEntity
    • getHandRaisedTime

      public int getHandRaisedTime()
      Specified by:
      getHandRaisedTime in interface org.bukkit.entity.LivingEntity
      Overrides:
      getHandRaisedTime in class GlowLivingEntity
    • isHandRaised

      public boolean isHandRaised()
      Specified by:
      isHandRaised in interface org.bukkit.entity.HumanEntity
      Specified by:
      isHandRaised in interface org.bukkit.entity.LivingEntity
      Overrides:
      isHandRaised in class GlowLivingEntity
    • isSneaking

      public boolean isSneaking()
      Specified by:
      isSneaking in interface org.bukkit.entity.Player
    • setSneaking

      public void setSneaking(boolean sneak)
      Specified by:
      setSneaking in interface org.bukkit.entity.Player
    • isSprinting

      public boolean isSprinting()
      Specified by:
      isSprinting in interface org.bukkit.entity.Player
    • setSprinting

      public void setSprinting(boolean sprinting)
      Specified by:
      setSprinting in interface org.bukkit.entity.Player
    • getEyeHeight

      public double getEyeHeight()
      Specified by:
      getEyeHeight in interface org.bukkit.entity.LivingEntity
      Overrides:
      getEyeHeight in class GlowLivingEntity
    • getEyeHeight

      public double getEyeHeight(boolean ignoreSneaking)
      Specified by:
      getEyeHeight in interface org.bukkit.entity.LivingEntity
      Overrides:
      getEyeHeight in class GlowLivingEntity
    • getAllowFlight

      public boolean getAllowFlight()
      Specified by:
      getAllowFlight in interface org.bukkit.entity.Player
    • setAllowFlight

      public void setAllowFlight(boolean flight)
      Specified by:
      setAllowFlight in interface org.bukkit.entity.Player
    • setFlying

      public void setFlying(boolean value)
      Specified by:
      setFlying in interface org.bukkit.entity.Player
    • setFlySpeed

      public void setFlySpeed(float value) throws IllegalArgumentException
      Specified by:
      setFlySpeed in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • setWalkSpeed

      public void setWalkSpeed(float value) throws IllegalArgumentException
      Specified by:
      setWalkSpeed in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • setLevel

      public void setLevel(int level)
      Specified by:
      setLevel in interface org.bukkit.entity.Player
    • setTotalExperience

      public void setTotalExperience(int exp)
      Specified by:
      setTotalExperience in interface org.bukkit.entity.Player
    • sendExperienceChange

      public void sendExperienceChange(float v)
      Specified by:
      sendExperienceChange in interface org.bukkit.entity.Player
    • sendExperienceChange

      public void sendExperienceChange(float v, int i)
      Specified by:
      sendExperienceChange in interface org.bukkit.entity.Player
    • giveExp

      public void giveExp(int xp)
      Specified by:
      giveExp in interface org.bukkit.entity.Player
    • giveExp

      public void giveExp(int xp, boolean applyMending)
      Specified by:
      giveExp in interface org.bukkit.entity.Player
    • applyMending

      public int applyMending(int amount)
      Specified by:
      applyMending in interface org.bukkit.entity.Player
    • giveExpLevels

      public void giveExpLevels(int amount)
      Specified by:
      giveExpLevels in interface org.bukkit.entity.Player
    • setExp

      public void setExp(float percentToLevel)
      Specified by:
      setExp in interface org.bukkit.entity.Player
    • getExpToLevel

      public int getExpToLevel()
      Specified by:
      getExpToLevel in interface org.bukkit.entity.HumanEntity
      Overrides:
      getExpToLevel in class GlowHumanEntity
    • getAttackCooldown

      public float getAttackCooldown()
      Specified by:
      getAttackCooldown in interface org.bukkit.entity.HumanEntity
    • discoverRecipe

      public boolean discoverRecipe(@NotNull @NotNull org.bukkit.NamespacedKey recipe)
      Specified by:
      discoverRecipe in interface org.bukkit.entity.HumanEntity
    • discoverRecipes

      public int discoverRecipes(@NotNull @NotNull Collection<org.bukkit.NamespacedKey> recipes)
      Specified by:
      discoverRecipes in interface org.bukkit.entity.HumanEntity
    • undiscoverRecipe

      public boolean undiscoverRecipe(@NotNull @NotNull org.bukkit.NamespacedKey recipe)
      Specified by:
      undiscoverRecipe in interface org.bukkit.entity.HumanEntity
    • undiscoverRecipes

      public int undiscoverRecipes(@NotNull @NotNull Collection<org.bukkit.NamespacedKey> recipes)
      Specified by:
      undiscoverRecipes in interface org.bukkit.entity.HumanEntity
    • hasDiscoveredRecipe

      public boolean hasDiscoveredRecipe(@NotNull @NotNull org.bukkit.NamespacedKey namespacedKey)
      Specified by:
      hasDiscoveredRecipe in interface org.bukkit.entity.HumanEntity
    • getDiscoveredRecipes

      @NotNull public @NotNull Set<org.bukkit.NamespacedKey> getDiscoveredRecipes()
      Specified by:
      getDiscoveredRecipes in interface org.bukkit.entity.HumanEntity
    • dropItem

      public boolean dropItem(boolean b)
      Specified by:
      dropItem in interface org.bukkit.entity.HumanEntity
    • getUnlockedRecipes

      public Collection<org.bukkit.inventory.Recipe> getUnlockedRecipes()
      Recipes this player has unlocked.
      Returns:
      An immutable list of unlocked recipes.
    • learnRecipe

      public boolean learnRecipe(org.bukkit.inventory.Recipe recipe, boolean notify)
      Teach the player a new recipe.
      Parameters:
      recipe - The recipe to be added to learnt recipes
      notify - If the player should be notified of the recipes learnt
      Returns:
      If this recipe was not learned already.
    • unlearnRecipe

      public boolean unlearnRecipe(org.bukkit.inventory.Recipe recipe)
      Remove a recipe from the player's known recipes.
      Parameters:
      recipe - The recipe to be removed from learnt recipes
      Returns:
      If this recipe was learned before it was removed.
    • knowsRecipe

      public boolean knowsRecipe(org.bukkit.inventory.Recipe recipe)
      Checks to see if the player knows this recipe.
      Parameters:
      recipe - The recipe to check
      Returns:
      If the player knows the recipe
    • setHealth

      public void setHealth(double health)
      Specified by:
      setHealth in interface org.bukkit.entity.Damageable
      Overrides:
      setHealth in class GlowLivingEntity
    • setMaxHealth

      public void setMaxHealth(double health)
      Specified by:
      setMaxHealth in interface org.bukkit.entity.Damageable
      Overrides:
      setMaxHealth in class GlowLivingEntity
    • setHealthScaled

      public void setHealthScaled(boolean scale)
      Specified by:
      setHealthScaled in interface org.bukkit.entity.Player
    • setHealthScale

      public void setHealthScale(double scale) throws IllegalArgumentException
      Specified by:
      setHealthScale in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • getSpectatorTarget

      public org.bukkit.entity.Entity getSpectatorTarget()
      Specified by:
      getSpectatorTarget in interface org.bukkit.entity.Player
    • setSpectatorTarget

      public void setSpectatorTarget(org.bukkit.entity.Entity entity)
      Specified by:
      setSpectatorTarget in interface org.bukkit.entity.Player
    • setFoodLevelAndSaturation

      public void setFoodLevelAndSaturation(int food, float saturation)
      Updates the hunger bar and hunger saturation.
      Parameters:
      food - the amount of food (in half-icons on the hunger bar)
      saturation - the amount of food saturation (in half-icons of food it will save)
    • setFoodLevel

      public void setFoodLevel(int food)
      Specified by:
      setFoodLevel in interface org.bukkit.entity.HumanEntity
    • getSaturatedRegenRate

      public int getSaturatedRegenRate()
      Specified by:
      getSaturatedRegenRate in interface org.bukkit.entity.HumanEntity
    • setSaturatedRegenRate

      public void setSaturatedRegenRate(int i)
      Specified by:
      setSaturatedRegenRate in interface org.bukkit.entity.HumanEntity
    • getUnsaturatedRegenRate

      public int getUnsaturatedRegenRate()
      Specified by:
      getUnsaturatedRegenRate in interface org.bukkit.entity.HumanEntity
    • setUnsaturatedRegenRate

      public void setUnsaturatedRegenRate(int i)
      Specified by:
      setUnsaturatedRegenRate in interface org.bukkit.entity.HumanEntity
    • getStarvationRate

      public int getStarvationRate()
      Specified by:
      getStarvationRate in interface org.bukkit.entity.HumanEntity
    • setStarvationRate

      public void setStarvationRate(int i)
      Specified by:
      setStarvationRate in interface org.bukkit.entity.HumanEntity
    • addExhaustion

      public void addExhaustion(float exhaustion)
      Increases the exhaustion counter, but applies the maximum.
      Parameters:
      exhaustion - the amount of exhaustion to add
    • addMoveExhaustion

      public void addMoveExhaustion(org.bukkit.Location move)
      Add the exhaustion for sprinting from the given location to the current location, if this player is sprinting.
      Parameters:
      move - the previous location
    • setSaturation

      public void setSaturation(float value)
      Specified by:
      setSaturation in interface org.bukkit.entity.HumanEntity
    • teleport

      public boolean teleport(org.bukkit.Location location)
      Teleport the player.
      Specified by:
      teleport in interface org.bukkit.entity.Entity
      Overrides:
      teleport in class GlowEntity
      Parameters:
      location - The destination to teleport to.
      Returns:
      Whether the teleport was a success.
    • teleport

      public boolean teleport(org.bukkit.Location location, org.bukkit.event.player.PlayerTeleportEvent.TeleportCause cause)
      Specified by:
      teleport in interface org.bukkit.entity.Entity
      Overrides:
      teleport in class GlowEntity
    • endTeleport

      public void endTeleport()
      Finishes the teleport process.
    • teleportToSpawn

      protected boolean teleportToSpawn()
      Description copied from class: GlowEntity
      Teleport this entity to the spawn point of the main world. This is used to teleport out of the End.
      Overrides:
      teleportToSpawn in class GlowEntity
      Returns:
      true if the teleport was successful.
    • teleportToEnd

      protected boolean teleportToEnd()
      Description copied from class: GlowEntity
      Teleport this entity to the End. If no End world is loaded this does nothing.
      Overrides:
      teleportToEnd in class GlowEntity
      Returns:
      true if the teleport was successful.
    • enterBed

      public void enterBed(GlowBlock block)
      This player enters the specified bed and is marked as sleeping.
      Parameters:
      block - the bed
    • leaveBed

      public void leaveBed(boolean setSpawn)
      This player leaves their bed causing them to quit sleeping.
      Parameters:
      setSpawn - Whether to set the bed spawn of the player
    • sendMessage

      public void sendMessage(@NotNull @NotNull String message)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Overrides:
      sendMessage in class GlowEntity
    • sendMessage

      public void sendMessage(String[] messages)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Overrides:
      sendMessage in class GlowEntity
    • sendMessage

      public void sendMessage(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent component)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Specified by:
      sendMessage in interface org.bukkit.entity.Player
    • sendMessage

      public void sendMessage(net.md_5.bungee.api.chat.BaseComponent... components)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Specified by:
      sendMessage in interface org.bukkit.entity.Player
    • sendMessage

      public void sendMessage(net.md_5.bungee.api.ChatMessageType type, net.md_5.bungee.api.chat.BaseComponent... components)
      Specified by:
      sendMessage in interface org.bukkit.entity.Player
    • sendMessage

      public void sendMessage(@Nullable UUID sender, @NotNull @NotNull String message)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Overrides:
      sendMessage in class GlowEntity
    • sendMessage

      public void sendMessage(@Nullable UUID sender, @NotNull @NotNull String[] messages)
      Specified by:
      sendMessage in interface org.bukkit.command.CommandSender
      Overrides:
      sendMessage in class GlowEntity
    • sendMessages

      public void sendMessages(UUID sender, String... messages)
    • sendRawMessages

      public void sendRawMessages(net.md_5.bungee.api.ChatMessageType type, String... messages)
    • sendRawMessages

      public void sendRawMessages(String senderName, String... messages)
    • sendRawMessage

      public void sendRawMessage(@NotNull @NotNull String message)
      Specified by:
      sendRawMessage in interface org.bukkit.conversations.Conversable
      Specified by:
      sendRawMessage in interface org.bukkit.entity.Player
    • sendRawMessage

      public void sendRawMessage(@Nullable UUID sender, @NotNull @NotNull String message)
      Specified by:
      sendRawMessage in interface org.bukkit.conversations.Conversable
    • sendActionBar

      public void sendActionBar(@NotNull @NotNull String message)
      Specified by:
      sendActionBar in interface org.bukkit.entity.Player
    • sendActionBar

      public void sendActionBar(char alternateChar, String message)
      Specified by:
      sendActionBar in interface org.bukkit.entity.Player
    • sendActionBar

      public void sendActionBar(@NotNull @NotNull net.md_5.bungee.api.chat.BaseComponent... components)
      Specified by:
      sendActionBar in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count, double offsetX, double offsetY, double offsetZ)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count, double offsetX, double offsetY, double offsetZ, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count, double offsetX, double offsetY, double offsetZ, double extra)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, org.bukkit.Location location, int count, double offsetX, double offsetY, double offsetZ, double extra, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • spawnParticle

      public <T> void spawnParticle(org.bukkit.Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data)
      Specified by:
      spawnParticle in interface org.bukkit.entity.Player
    • getAdvancementProgress

      public org.bukkit.advancement.AdvancementProgress getAdvancementProgress(org.bukkit.advancement.Advancement advancement)
      Specified by:
      getAdvancementProgress in interface org.bukkit.entity.Player
    • getClientViewDistance

      public int getClientViewDistance()
      Specified by:
      getClientViewDistance in interface org.bukkit.entity.Player
    • locale

      @NotNull public @NotNull Locale locale()
      Specified by:
      locale in interface org.bukkit.entity.Player
    • getPing

      public int getPing()
      Specified by:
      getPing in interface org.bukkit.entity.Player
    • getLocale

      public String getLocale()
      Specified by:
      getLocale in interface org.bukkit.entity.Player
    • getAffectsSpawning

      public boolean getAffectsSpawning()
      Specified by:
      getAffectsSpawning in interface org.bukkit.entity.Player
    • updateCommands

      public void updateCommands()
      Specified by:
      updateCommands in interface org.bukkit.entity.Player
    • openBook

      public void openBook(@NotNull @NotNull org.bukkit.inventory.ItemStack itemStack)
      Specified by:
      openBook in interface org.bukkit.entity.Player
    • getViewDistance

      public int getViewDistance()
      Specified by:
      getViewDistance in interface org.bukkit.entity.Player
    • setViewDistance

      public void setViewDistance(int viewDistance)
      Specified by:
      setViewDistance in interface org.bukkit.entity.Player
    • kickPlayer

      public void kickPlayer(String message)
      Specified by:
      kickPlayer in interface org.bukkit.entity.Player
    • kickPlayer

      public void kickPlayer(String message, boolean async)
    • kick

      public void kick(@Nullable @Nullable net.kyori.adventure.text.Component component)
      Specified by:
      kick in interface org.bukkit.entity.Player
    • performCommand

      public boolean performCommand(String command)
      Specified by:
      performCommand in interface org.bukkit.entity.Player
    • chat

      public void chat(String text)
      Specified by:
      chat in interface org.bukkit.entity.Player
    • chat

      public void chat(String text, boolean async)
      Says a message (or runs a command).
      Parameters:
      text - message sent by the player.
      async - whether the message was received asynchronously.
    • saveData

      public void saveData()
      Specified by:
      saveData in interface org.bukkit.entity.Player
    • saveData

      public void saveData(boolean async)
      Saves the players current location, health, inventory, motion, and other information into the username.dat file, in the world/player folder.
      Parameters:
      async - if true, save asynchronously; if false, block until saved
    • loadData

      public void loadData()
      Specified by:
      loadData in interface org.bukkit.entity.Player
    • setTexturePack

      @Deprecated public void setTexturePack(String url)
      Deprecated.
      Specified by:
      setTexturePack in interface org.bukkit.entity.Player
    • setResourcePack

      public void setResourcePack(String url)
      Specified by:
      setResourcePack in interface org.bukkit.entity.Player
    • setResourcePack

      public void setResourcePack(String url, byte[] hash)
      Specified by:
      setResourcePack in interface org.bukkit.entity.Player
    • setResourcePack

      public void setResourcePack(String url, String hash)
      Specified by:
      setResourcePack in interface org.bukkit.entity.Player
    • getResourcePackStatus

      public org.bukkit.event.player.PlayerResourcePackStatusEvent.Status getResourcePackStatus()
      Specified by:
      getResourcePackStatus in interface org.bukkit.entity.Player
    • setResourcePackStatus

      public void setResourcePackStatus(org.bukkit.event.player.PlayerResourcePackStatusEvent.Status status)
    • getResourcePackHash

      public String getResourcePackHash()
      Specified by:
      getResourcePackHash in interface org.bukkit.entity.Player
    • hasResourcePack

      public boolean hasResourcePack()
      Specified by:
      hasResourcePack in interface org.bukkit.entity.Player
    • getPlayerProfile

      public com.destroystokyo.paper.profile.PlayerProfile getPlayerProfile()
      Specified by:
      getPlayerProfile in interface org.bukkit.entity.Player
    • setPlayerProfile

      public void setPlayerProfile(com.destroystokyo.paper.profile.PlayerProfile playerProfile)
      Specified by:
      setPlayerProfile in interface org.bukkit.entity.Player
    • getCooldownPeriod

      public float getCooldownPeriod()
      Specified by:
      getCooldownPeriod in interface org.bukkit.entity.Player
    • getCooledAttackStrength

      public float getCooledAttackStrength(float adjustTicks)
      Specified by:
      getCooledAttackStrength in interface org.bukkit.entity.Player
    • resetCooldown

      public void resetCooldown()
      Specified by:
      resetCooldown in interface org.bukkit.entity.Player
    • getClientOption

      @NotNull public <T> T getClientOption(@NotNull @NotNull com.destroystokyo.paper.ClientOption<T> clientOption)
      Specified by:
      getClientOption in interface org.bukkit.entity.Player
    • boostElytra

      @Nullable public @Nullable org.bukkit.entity.Firework boostElytra(@NotNull @NotNull org.bukkit.inventory.ItemStack itemStack)
      Specified by:
      boostElytra in interface org.bukkit.entity.Player
    • sendOpLevel

      public void sendOpLevel(byte b)
      Specified by:
      sendOpLevel in interface org.bukkit.entity.Player
    • getTrackedPlayers

      @NotNull public @NotNull Set<org.bukkit.entity.Player> getTrackedPlayers()
      Specified by:
      getTrackedPlayers in interface org.bukkit.entity.Player
    • getClientBrandName

      @Nullable public @Nullable String getClientBrandName()
      Specified by:
      getClientBrandName in interface org.bukkit.entity.Player
    • playNote

      public void playNote(org.bukkit.Location loc, org.bukkit.Instrument instrument, org.bukkit.Note note)
      Specified by:
      playNote in interface org.bukkit.entity.Player
    • playNote

      public void playNote(org.bukkit.Location loc, byte instrument, byte note)
      Specified by:
      playNote in interface org.bukkit.entity.Player
    • playEffect

      public void playEffect(org.bukkit.Location loc, org.bukkit.Effect effect, int data)
      Specified by:
      playEffect in interface org.bukkit.entity.Player
    • playEffect

      public <T> void playEffect(org.bukkit.Location loc, org.bukkit.Effect effect, T data)
      Specified by:
      playEffect in interface org.bukkit.entity.Player
    • playSound

      public void playSound(org.bukkit.Location location, org.bukkit.Sound sound, float volume, float pitch)
      Specified by:
      playSound in interface org.bukkit.entity.Player
    • playSound

      public void playSound(org.bukkit.Location location, String sound, float volume, float pitch)
      Specified by:
      playSound in interface org.bukkit.entity.Player
    • playSound

      public void playSound(org.bukkit.Location location, String sound, org.bukkit.SoundCategory category, float volume, float pitch)
      Specified by:
      playSound in interface org.bukkit.entity.Player
    • playSound

      public void playSound(org.bukkit.Location location, org.bukkit.Sound sound, org.bukkit.SoundCategory category, float volume, float pitch)
      Specified by:
      playSound in interface org.bukkit.entity.Player
    • stopSound

      public void stopSound(org.bukkit.Sound sound)
      Specified by:
      stopSound in interface org.bukkit.entity.Player
    • stopSound

      public void stopSound(org.bukkit.Sound sound, org.bukkit.SoundCategory soundCategory)
      Specified by:
      stopSound in interface org.bukkit.entity.Player
    • stopSound

      public void stopSound(String sound, org.bukkit.SoundCategory category)
      Specified by:
      stopSound in interface org.bukkit.entity.Player
    • stopSound

      public void stopSound(org.bukkit.SoundCategory category, org.bukkit.Sound sound)
    • stopSound

      public void stopSound(String sound)
      Specified by:
      stopSound in interface org.bukkit.entity.Player
    • spigot

      public org.bukkit.entity.Player.Spigot spigot()
      Specified by:
      spigot in interface org.bukkit.command.CommandSender
      Specified by:
      spigot in interface org.bukkit.entity.Entity
      Specified by:
      spigot in interface org.bukkit.entity.Player
      Overrides:
      spigot in class GlowEntity
    • getEntitySpawnReason

      public @NotNull org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason getEntitySpawnReason()
      Specified by:
      getEntitySpawnReason in interface org.bukkit.entity.Entity
      Overrides:
      getEntitySpawnReason in class GlowEntity
    • showParticle

      public void showParticle(org.bukkit.Location loc, org.bukkit.Effect particle, org.bukkit.material.MaterialData material, float offsetX, float offsetY, float offsetZ, float speed, int amount)
      Sends a PlayParticleMessage to display the given particle.
      Parameters:
      loc - the location
      particle - the particle type
      material - the item or block data
      offsetX - TODO: document this parameter
      offsetY - TODO: document this parameter
      offsetZ - TODO: document this parameter
      speed - TODO: document this parameter
      amount - the number of particles
    • sendBlockChange

      public void sendBlockChange(@NotNull @NotNull org.bukkit.Location loc, org.bukkit.Material type, byte data)
      Specified by:
      sendBlockChange in interface org.bukkit.entity.Player
    • sendBlockChange

      public void sendBlockChange(@NotNull @NotNull org.bukkit.Location loc, @NotNull @NotNull org.bukkit.block.data.BlockData blockData)
      Specified by:
      sendBlockChange in interface org.bukkit.entity.Player
    • sendBlockChange

      public void sendBlockChange(BlockChangeMessage message)
      Sends the given BlockChangeMessage if it's in a chunk this player can see.
      Parameters:
      message - the message to send
    • sendBlockChangeForce

      @Deprecated public void sendBlockChangeForce(BlockChangeMessage message)
      Deprecated.
    • sendBlockDamage

      public void sendBlockDamage(@NotNull @NotNull org.bukkit.Location location, float v)
      Specified by:
      sendBlockDamage in interface org.bukkit.entity.Player
    • sendChunkChange

      public boolean sendChunkChange(org.bukkit.Location loc, int sx, int sy, int sz, byte[] data)
      Specified by:
      sendChunkChange in interface org.bukkit.entity.Player
    • sendSignChange

      public void sendSignChange(@NotNull @NotNull org.bukkit.Location location, @Nullable @Nullable List<net.kyori.adventure.text.Component> list) throws IllegalArgumentException
      Specified by:
      sendSignChange in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • sendSignChange

      public void sendSignChange(@NotNull @NotNull org.bukkit.Location location, @Nullable @Nullable List<net.kyori.adventure.text.Component> list, @NotNull @NotNull org.bukkit.DyeColor dyeColor) throws IllegalArgumentException
      Specified by:
      sendSignChange in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • sendSignChange

      public void sendSignChange(org.bukkit.Location location, String[] lines) throws IllegalArgumentException
      Specified by:
      sendSignChange in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • sendSignChange

      public void sendSignChange(@NotNull @NotNull org.bukkit.Location location, @Nullable @Nullable String[] strings, @NotNull @NotNull org.bukkit.DyeColor dyeColor) throws IllegalArgumentException
      Specified by:
      sendSignChange in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
    • sendSignChange

      public void sendSignChange(SignEntity sign, org.bukkit.Location location, TextMessage[] lines) throws IllegalArgumentException
      Send a sign change, similar to sendSignChange(Location, String[]), but using complete TextMessages instead of strings.
      Parameters:
      sign - the sign
      location - the location of the sign
      lines - the new text on the sign or null to clear it
      Throws:
      IllegalArgumentException - if location is null
      IllegalArgumentException - if lines is non-null and has a length less than 4
    • sendBlockEntityChange

      public void sendBlockEntityChange(org.bukkit.Location location, GlowBlockEntity type, CompoundTag nbt)
      Send a block entity change to the given location.
      Parameters:
      location - The location of the block entity.
      type - The type of block entity being sent.
      nbt - The NBT structure to send to the client.
    • sendMap

      public void sendMap(org.bukkit.map.MapView map)
      Specified by:
      sendMap in interface org.bukkit.entity.Player
    • setPlayerListHeaderFooter

      public void setPlayerListHeaderFooter(@Nullable String header, @Nullable String footer)
      Specified by:
      setPlayerListHeaderFooter in interface org.bukkit.entity.Player
    • setPlayerListHeaderFooter

      public void setPlayerListHeaderFooter(net.md_5.bungee.api.chat.BaseComponent[] header, net.md_5.bungee.api.chat.BaseComponent[] footer)
      Specified by:
      setPlayerListHeaderFooter in interface org.bukkit.entity.Player
    • setPlayerListHeaderFooter

      public void setPlayerListHeaderFooter(net.md_5.bungee.api.chat.BaseComponent header, net.md_5.bungee.api.chat.BaseComponent footer)
      Specified by:
      setPlayerListHeaderFooter in interface org.bukkit.entity.Player
    • setTitleTimes

      public void setTitleTimes(int fadeInTicks, int stayTicks, int fadeOutTicks)
      Specified by:
      setTitleTimes in interface org.bukkit.entity.Player
    • setSubtitle

      public void setSubtitle(net.md_5.bungee.api.chat.BaseComponent[] subtitle)
      Specified by:
      setSubtitle in interface org.bukkit.entity.Player
    • setSubtitle

      public void setSubtitle(net.md_5.bungee.api.chat.BaseComponent subtitle)
      Specified by:
      setSubtitle in interface org.bukkit.entity.Player
    • showTitle

      public void showTitle(net.md_5.bungee.api.chat.BaseComponent[] title)
      Specified by:
      showTitle in interface org.bukkit.entity.Player
    • showTitle

      public void showTitle(net.md_5.bungee.api.chat.BaseComponent title)
      Specified by:
      showTitle in interface org.bukkit.entity.Player
    • showTitle

      public void showTitle(net.md_5.bungee.api.chat.BaseComponent[] title, net.md_5.bungee.api.chat.BaseComponent[] subtitle, int fadeInTicks, int stayTicks, int fadeOutTicks)
      Specified by:
      showTitle in interface org.bukkit.entity.Player
    • showTitle

      public void showTitle(net.md_5.bungee.api.chat.BaseComponent title, net.md_5.bungee.api.chat.BaseComponent subtitle, int fadeInTicks, int stayTicks, int fadeOutTicks)
      Specified by:
      showTitle in interface org.bukkit.entity.Player
    • sendTitle

      public void sendTitle(com.destroystokyo.paper.Title title)
      Specified by:
      sendTitle in interface org.bukkit.entity.Player
    • sendTitle

      public void sendTitle(String title, String subtitle)
      Specified by:
      sendTitle in interface org.bukkit.entity.Player
    • sendTitle

      public void sendTitle(String title, String subtitle, int fadeIn, int stay, int fadeOut)
      Specified by:
      sendTitle in interface org.bukkit.entity.Player
    • sendTitle

      public void sendTitle(com.destroystokyo.paper.Title.Builder title)
      Send the player a title base on a Title.Builder.
      Parameters:
      title - the Title.Builder to send the player
    • sendTitle

      public void sendTitle()
      Send the player their current title.
    • updateTitle

      public void updateTitle(com.destroystokyo.paper.Title title)
      Specified by:
      updateTitle in interface org.bukkit.entity.Player
    • updateTitle

      public void updateTitle(TitleMessage.Action action, Object... value)
      Update a specific attribute of the player's title.
      Parameters:
      action - the attribute to update
      value - the value of the attribute
    • hideTitle

      public void hideTitle()
      Specified by:
      hideTitle in interface org.bukkit.entity.Player
    • getStatistic

      public int getStatistic(org.bukkit.Statistic statistic) throws IllegalArgumentException
      Specified by:
      getStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • getStatistic

      public int getStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material) throws IllegalArgumentException
      Specified by:
      getStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • getStatistic

      public int getStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType) throws IllegalArgumentException
      Specified by:
      getStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • setStatistic

      public void setStatistic(org.bukkit.Statistic statistic, int newValue) throws IllegalArgumentException
      Specified by:
      setStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • setStatistic

      public void setStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material, int newValue) throws IllegalArgumentException
      Specified by:
      setStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • setStatistic

      public void setStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType, int newValue)
      Specified by:
      setStatistic in interface org.bukkit.OfflinePlayer
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic)
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic, int amount)
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material)
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material, int amount)
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType) throws IllegalArgumentException
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • incrementStatistic

      public void incrementStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType, int amount) throws IllegalArgumentException
      Specified by:
      incrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic) throws IllegalArgumentException
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic, int amount) throws IllegalArgumentException
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material) throws IllegalArgumentException
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic, org.bukkit.Material material, int amount) throws IllegalArgumentException
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType) throws IllegalArgumentException
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
      Throws:
      IllegalArgumentException
    • decrementStatistic

      public void decrementStatistic(org.bukkit.Statistic statistic, org.bukkit.entity.EntityType entityType, int amount)
      Specified by:
      decrementStatistic in interface org.bukkit.OfflinePlayer
    • getStatisticMap

      public StatisticMap getStatisticMap()
    • sendStats

      public void sendStats()
    • updateInventory

      public void updateInventory()
      Specified by:
      updateInventory in interface org.bukkit.entity.Player
    • sendItemChange

      public void sendItemChange(int slot, org.bukkit.inventory.ItemStack item)
      Sends a SetWindowSlotMessage to update the contents of an inventory slot.
      Parameters:
      slot - the slot ID
      item - the new contents
    • setItemOnCursor

      public void setItemOnCursor(org.bukkit.inventory.ItemStack item)
      Description copied from class: GlowHumanEntity
      The item the player has on their cursor.
      Specified by:
      setItemOnCursor in interface org.bukkit.entity.HumanEntity
      Overrides:
      setItemOnCursor in class GlowHumanEntity
    • hasCooldown

      public boolean hasCooldown(org.bukkit.Material material)
      Specified by:
      hasCooldown in interface org.bukkit.entity.HumanEntity
    • getCooldown

      public int getCooldown(org.bukkit.Material material)
      Specified by:
      getCooldown in interface org.bukkit.entity.HumanEntity
    • setCooldown

      public void setCooldown(org.bukkit.Material material, int ticks)
      Specified by:
      setCooldown in interface org.bukkit.entity.HumanEntity
    • isDeeplySleeping

      public boolean isDeeplySleeping()
      Specified by:
      isDeeplySleeping in interface org.bukkit.entity.HumanEntity
    • getPotentialBedLocation

      @Nullable public @Nullable org.bukkit.Location getPotentialBedLocation()
      Specified by:
      getPotentialBedLocation in interface org.bukkit.entity.HumanEntity
    • getMainHand

      public org.bukkit.inventory.MainHand getMainHand()
      Specified by:
      getMainHand in interface org.bukkit.entity.HumanEntity
    • setWindowProperty

      public boolean setWindowProperty(org.bukkit.inventory.InventoryView.Property prop, int value)
      Specified by:
      setWindowProperty in interface org.bukkit.entity.HumanEntity
      Overrides:
      setWindowProperty in class GlowHumanEntity
    • openInventory

      public void openInventory(org.bukkit.inventory.InventoryView view)
      Specified by:
      openInventory in interface org.bukkit.entity.HumanEntity
      Overrides:
      openInventory in class GlowHumanEntity
    • openMerchant

      public org.bukkit.inventory.InventoryView openMerchant(org.bukkit.entity.Villager villager, boolean b)
      Specified by:
      openMerchant in interface org.bukkit.entity.HumanEntity
    • openMerchant

      public org.bukkit.inventory.InventoryView openMerchant(org.bukkit.inventory.Merchant merchant, boolean b)
      Specified by:
      openMerchant in interface org.bukkit.entity.HumanEntity
    • openAnvil

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openAnvil(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openAnvil in interface org.bukkit.entity.HumanEntity
    • openCartographyTable

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openCartographyTable(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openCartographyTable in interface org.bukkit.entity.HumanEntity
    • openGrindstone

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openGrindstone(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openGrindstone in interface org.bukkit.entity.HumanEntity
    • openLoom

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openLoom(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openLoom in interface org.bukkit.entity.HumanEntity
    • openSmithingTable

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openSmithingTable(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openSmithingTable in interface org.bukkit.entity.HumanEntity
    • openStonecutter

      @Nullable public @Nullable org.bukkit.inventory.InventoryView openStonecutter(@Nullable @Nullable org.bukkit.Location location, boolean b)
      Specified by:
      openStonecutter in interface org.bukkit.entity.HumanEntity
    • drop

      public GlowItem drop(org.bukkit.inventory.ItemStack stack)
      Description copied from class: GlowHumanEntity
      Spawns a new GlowItem in the world, as if this HumanEntity had dropped it.

      Note that this does NOT remove the item from the inventory.

      Overrides:
      drop in class GlowHumanEntity
      Parameters:
      stack - The item to drop
      Returns:
      the GlowItem that was generated, or null if the spawning was cancelled
    • setPlayerTime

      public void setPlayerTime(long time, boolean relative)
      Specified by:
      setPlayerTime in interface org.bukkit.entity.Player
    • getPlayerTime

      public long getPlayerTime()
      Specified by:
      getPlayerTime in interface org.bukkit.entity.Player
    • getPlayerTimeOffset

      public long getPlayerTimeOffset()
      Specified by:
      getPlayerTimeOffset in interface org.bukkit.entity.Player
    • resetPlayerTime

      public void resetPlayerTime()
      Specified by:
      resetPlayerTime in interface org.bukkit.entity.Player
    • sendTime

      public void sendTime()
      Sends a TimeMessage with the time of day.
    • getPlayerWeather

      public org.bukkit.WeatherType getPlayerWeather()
      Specified by:
      getPlayerWeather in interface org.bukkit.entity.Player
    • setPlayerWeather

      public void setPlayerWeather(org.bukkit.WeatherType type)
      Specified by:
      setPlayerWeather in interface org.bukkit.entity.Player
    • resetPlayerWeather

      public void resetPlayerWeather()
      Specified by:
      resetPlayerWeather in interface org.bukkit.entity.Player
    • sendWeather

      public void sendWeather()
      Sends a StateChangeMessage with the current weather.
    • sendRainDensity

      public void sendRainDensity()
    • sendSkyDarkness

      public void sendSkyDarkness()
    • hidePlayer

      public void hidePlayer(org.bukkit.entity.Player player)
      Specified by:
      hidePlayer in interface org.bukkit.entity.Player
    • hidePlayer

      public void hidePlayer(org.bukkit.plugin.Plugin plugin, org.bukkit.entity.Player player)
      Specified by:
      hidePlayer in interface org.bukkit.entity.Player
    • showPlayer

      public void showPlayer(org.bukkit.entity.Player player)
      Specified by:
      showPlayer in interface org.bukkit.entity.Player
    • showPlayer

      public void showPlayer(org.bukkit.plugin.Plugin plugin, org.bukkit.entity.Player player)
      Specified by:
      showPlayer in interface org.bukkit.entity.Player
    • canSee

      public boolean canSee(org.bukkit.entity.Player player)
      Specified by:
      canSee in interface org.bukkit.entity.Player
    • stopHidingDisconnectedPlayer

      public void stopHidingDisconnectedPlayer(org.bukkit.entity.Player player)
      Called when a player hidden to this player disconnects. This is necessary so the player is visible again after they reconnected.
      Parameters:
      player - The disconnected player
    • getScoreboard

      public org.bukkit.scoreboard.Scoreboard getScoreboard()
      Specified by:
      getScoreboard in interface org.bukkit.entity.Player
    • setScoreboard

      public void setScoreboard(org.bukkit.scoreboard.Scoreboard scoreboard) throws IllegalArgumentException, IllegalStateException
      Specified by:
      setScoreboard in interface org.bukkit.entity.Player
      Throws:
      IllegalArgumentException
      IllegalStateException
    • isConversing

      public boolean isConversing()
      Specified by:
      isConversing in interface org.bukkit.conversations.Conversable
    • acceptConversationInput

      public void acceptConversationInput(String input)
      Specified by:
      acceptConversationInput in interface org.bukkit.conversations.Conversable
    • beginConversation

      public boolean beginConversation(org.bukkit.conversations.Conversation conversation)
      Specified by:
      beginConversation in interface org.bukkit.conversations.Conversable
    • abandonConversation

      public void abandonConversation(org.bukkit.conversations.Conversation conversation)
      Specified by:
      abandonConversation in interface org.bukkit.conversations.Conversable
    • abandonConversation

      public void abandonConversation(org.bukkit.conversations.Conversation conversation, org.bukkit.conversations.ConversationAbandonedEvent details)
      Specified by:
      abandonConversation in interface org.bukkit.conversations.Conversable
    • sendPluginMessage

      public void sendPluginMessage(org.bukkit.plugin.Plugin source, String channel, byte[] message)
      Specified by:
      sendPluginMessage in interface org.bukkit.plugin.messaging.PluginMessageRecipient
    • getListeningPluginChannels

      public Set<String> getListeningPluginChannels()
      Specified by:
      getListeningPluginChannels in interface org.bukkit.plugin.messaging.PluginMessageRecipient
    • addChannel

      public void addChannel(String channel)
      Add a listening channel to this player.
      Parameters:
      channel - The channel to add.
    • removeChannel

      public void removeChannel(String channel)
      Remove a listening channel from this player.
      Parameters:
      channel - The channel to remove.
    • enchanted

      public void enchanted(int clicked)
      Updates level after enchanting.
      Parameters:
      clicked - the enchanting-table slot used: 0 for top, 1 for middle, 2 for bottom
    • getTitle

      public com.destroystokyo.paper.Title getTitle()
    • clearTitle

      public void clearTitle()
      Specified by:
      clearTitle in interface net.kyori.adventure.audience.Audience
    • setOnGround

      public void setOnGround(boolean onGround)
      Description copied from class: GlowEntity
      Sets the on-ground flag and clears fall distance.
      Overrides:
      setOnGround in class GlowLivingEntity
      Parameters:
      onGround - true if this entity is now on the ground; false otherwise
    • resetTitle

      public void resetTitle()
      Specified by:
      resetTitle in interface net.kyori.adventure.audience.Audience
      Specified by:
      resetTitle in interface org.bukkit.entity.Player
    • setDigging

      public void setDigging(GlowBlock block)
      Starts breaking a block.
      Parameters:
      block - the block to start breaking
    • isInWater

      public boolean isInWater()
      Returns true if the player is inside a water block.
      Specified by:
      isInWater in interface org.bukkit.entity.Entity
      Overrides:
      isInWater in class GlowEntity
      Returns:
      True if entity is in water.
    • playAnimationToSelf

      public void playAnimationToSelf(org.bukkit.EntityAnimation animation)
      Specified by:
      playAnimationToSelf in interface org.bukkit.entity.Player
    • addBossBar

      public void addBossBar(org.bukkit.boss.BossBar bar)
      Add a boss bar.
      Parameters:
      bar - the boss bar to add
    • removeBossBar

      public void removeBossBar(org.bukkit.boss.BossBar bar)
      Remove a boss bar.
      Parameters:
      bar - the boss bar to remove
    • getBossBars

      public Collection<org.bukkit.boss.BossBar> getBossBars()
      Returns a collection of the boss bars this player sees.
      Returns:
      the boss bars this player sees
    • getOpenWindowId

      public int getOpenWindowId()
      Gets the currently open window ID.
      Returns:
      the currently open window ID, -1 if there is no open window
    • getSession

      public GlowSession getSession()
      The network session attached to this player.
      Returns:
      The GlowSession of the player.
    • getFirstPlayed

      public long getFirstPlayed()
      The time the player first played, or 0 if unknown.
      Specified by:
      getFirstPlayed in interface org.bukkit.OfflinePlayer
    • getLastPlayed

      public long getLastPlayed()
      The time the player last played, or 0 if unknown.
      Specified by:
      getLastPlayed in interface org.bukkit.OfflinePlayer
    • getRecipeMonitor

      public PlayerRecipeMonitor getRecipeMonitor()
    • setAffectsSpawning

      public void setAffectsSpawning(boolean affectsSpawning)
      Specified by:
      setAffectsSpawning in interface org.bukkit.entity.Player
    • getJoinTime

      public long getJoinTime()
      The time the player joined, in milliseconds, to be saved as last played time.
      Returns:
      The player's join time.
    • getTotalExperience

      public int getTotalExperience()
      Cumulative amount of experience points the player has collected.
      Specified by:
      getTotalExperience in interface org.bukkit.entity.Player
    • getLevel

      public int getLevel()
      The current level (or skill point amount) of the player.
      Specified by:
      getLevel in interface org.bukkit.entity.Player
    • getExp

      public float getExp()
      The progress made to the next level, from 0 to 1.
      Specified by:
      getExp in interface org.bukkit.entity.Player
    • getFoodLevel

      public int getFoodLevel()
      The human entity's current food level.
      Specified by:
      getFoodLevel in interface org.bukkit.entity.HumanEntity
    • getExhaustion

      public float getExhaustion()
      The player's current exhaustion level.
      Specified by:
      getExhaustion in interface org.bukkit.entity.HumanEntity
    • setExhaustion

      public void setExhaustion(float exhaustion)
      The player's current exhaustion level.
      Specified by:
      setExhaustion in interface org.bukkit.entity.HumanEntity
    • getSaturation

      public float getSaturation()
      The player's current saturation level.
      Specified by:
      getSaturation in interface org.bukkit.entity.HumanEntity
    • isHealthScaled

      public boolean isHealthScaled()
      Whether to perform special scaling of the player's health.
      Specified by:
      isHealthScaled in interface org.bukkit.entity.Player
    • getHealthScale

      public double getHealthScale()
      The scale at which to display the player's health.
      Specified by:
      getHealthScale in interface org.bukkit.entity.Player
    • isSeenCredits

      public boolean isSeenCredits()
      If this player has seen the end credits.
    • setSeenCredits

      public void setSeenCredits(boolean seenCredits)
      If this player has seen the end credits.
    • isPlayerTimeRelative

      public boolean isPlayerTimeRelative()
      Whether the time offset is relative.
      Specified by:
      isPlayerTimeRelative in interface org.bukkit.entity.Player
    • getCompassTarget

      public org.bukkit.Location getCompassTarget()
      The player's compass target.
      Specified by:
      getCompassTarget in interface org.bukkit.entity.Player
    • isBedSpawnForced

      public boolean isBedSpawnForced()
      Whether to use the bed spawn even if there is no bed block.
      Returns:
      Whether the player is forced to spawn at their bed.
    • getHurtDirection

      public float getHurtDirection()
      Description copied from class: GlowLivingEntity
      The entity's hurt direction (angle).
      Specified by:
      getHurtDirection in interface org.bukkit.entity.LivingEntity
      Overrides:
      getHurtDirection in class GlowLivingEntity
    • setHurtDirection

      public void setHurtDirection(float hurtDirection)
      Description copied from class: GlowLivingEntity
      The entity's hurt direction (angle).
      Specified by:
      setHurtDirection in interface org.bukkit.entity.LivingEntity
      Overrides:
      setHurtDirection in class GlowLivingEntity
    • isFlying

      public boolean isFlying()
      Whether the player is currently flying.
      Specified by:
      isFlying in interface org.bukkit.entity.Player
    • getFlySpeed

      public float getFlySpeed()
      The player's base flight speed.
      Specified by:
      getFlySpeed in interface org.bukkit.entity.Player
    • getWalkSpeed

      public float getWalkSpeed()
      The player's base walking speed.
      Specified by:
      getWalkSpeed in interface org.bukkit.entity.Player
    • getDigging

      public GlowBlock getDigging()
      The one block the player is currently digging.
    • getUsageItem

      public org.bukkit.inventory.ItemStack getUsageItem()
      The one itemstack the player is currently usage and associated time.
    • setUsageItem

      public void setUsageItem(org.bukkit.inventory.ItemStack usageItem)
      The one itemstack the player is currently usage and associated time.
    • getUsageTime

      public int getUsageTime()
    • getStartingUsageTime

      public int getStartingUsageTime()
    • getEnderPearlCooldown

      public int getEnderPearlCooldown()
      The player's ender pearl cooldown game tick counter. 1 second, or 20 game ticks by default. The player can use ender pearl again if equals 0.
    • setEnderPearlCooldown

      public void setEnderPearlCooldown(int enderPearlCooldown)
      The player's ender pearl cooldown game tick counter. 1 second, or 20 game ticks by default. The player can use ender pearl again if equals 0.
    • getPlayerListHeader

      @Nullable public String getPlayerListHeader()
      Specified by:
      getPlayerListHeader in interface org.bukkit.entity.Player
    • setPlayerListHeader

      public void setPlayerListHeader(@Nullable String playerListHeader)
      Specified by:
      setPlayerListHeader in interface org.bukkit.entity.Player
    • getPlayerListFooter

      @Nullable public String getPlayerListFooter()
      Specified by:
      getPlayerListFooter in interface org.bukkit.entity.Player
    • setPlayerListFooter

      public void setPlayerListFooter(@Nullable String playerListFooter)
      Specified by:
      setPlayerListFooter in interface org.bukkit.entity.Player