Class EndermanMock

All Implemented Interfaces:
MessageTarget, io.papermc.paper.entity.Frictional, net.kyori.adventure.audience.Audience, net.kyori.adventure.pointer.Pointered, net.kyori.adventure.sound.Sound.Emitter, net.kyori.adventure.text.event.HoverEventSource<net.kyori.adventure.text.event.HoverEvent.ShowEntity>, org.bukkit.attribute.Attributable, org.bukkit.command.CommandSender, org.bukkit.entity.Creature, org.bukkit.entity.Damageable, org.bukkit.entity.Enderman, org.bukkit.entity.Enemy, org.bukkit.entity.Entity, org.bukkit.entity.LivingEntity, org.bukkit.entity.Mob, org.bukkit.entity.Monster, org.bukkit.loot.Lootable, org.bukkit.metadata.Metadatable, org.bukkit.Nameable, org.bukkit.permissions.Permissible, org.bukkit.permissions.ServerOperator, org.bukkit.persistence.PersistentDataHolder, org.bukkit.projectiles.ProjectileSource

public class EndermanMock extends MonsterMock implements org.bukkit.entity.Enderman
Mock implementation of an Enderman.
See Also:
  • Constructor Details

    • EndermanMock

      public EndermanMock(@NotNull @NotNull ServerMock server, @NotNull @NotNull UUID uuid)
      Constructs a new EndermanMock on the provided ServerMock with a specified UUID.
      Parameters:
      server - The server to create the entity on.
      uuid - The UUID of the entity.
  • Method Details

    • teleportRandomly

      public boolean teleportRandomly()
      We're not implementing this as this would randomly fail tests. This is not a bug, it's a feature.
      Specified by:
      teleportRandomly in interface org.bukkit.entity.Enderman
    • getCarriedMaterial

      @Deprecated(since="1.18") @NotNull public @NotNull org.bukkit.material.MaterialData getCarriedMaterial()
      Deprecated.
      Specified by:
      getCarriedMaterial in interface org.bukkit.entity.Enderman
    • setCarriedMaterial

      @Deprecated(since="1.18") public void setCarriedMaterial(@NotNull @NotNull org.bukkit.material.MaterialData material)
      Deprecated.
      Specified by:
      setCarriedMaterial in interface org.bukkit.entity.Enderman
    • getCarriedBlock

      @Nullable public @Nullable org.bukkit.block.data.BlockData getCarriedBlock()
      Specified by:
      getCarriedBlock in interface org.bukkit.entity.Enderman
    • setCarriedBlock

      public void setCarriedBlock(@Nullable @Nullable org.bukkit.block.data.BlockData blockData)
      Specified by:
      setCarriedBlock in interface org.bukkit.entity.Enderman
    • teleport

      public boolean teleport()
      Specified by:
      teleport in interface org.bukkit.entity.Enderman
    • teleportTowards

      public boolean teleportTowards(@NotNull @NotNull org.bukkit.entity.Entity entity)
      Specified by:
      teleportTowards in interface org.bukkit.entity.Enderman
    • isScreaming

      public boolean isScreaming()
      Specified by:
      isScreaming in interface org.bukkit.entity.Enderman
    • setScreaming

      public void setScreaming(boolean screaming)
      Specified by:
      setScreaming in interface org.bukkit.entity.Enderman
    • hasBeenStaredAt

      public boolean hasBeenStaredAt()
      Specified by:
      hasBeenStaredAt in interface org.bukkit.entity.Enderman
    • setHasBeenStaredAt

      public void setHasBeenStaredAt(boolean hasBeenStaredAt)
      Specified by:
      setHasBeenStaredAt in interface org.bukkit.entity.Enderman
    • assertHasBlock

      public void assertHasBlock()
      Asserts that this Enderman is holding a block.
    • getEntityState

      protected EntityState getEntityState()
      Description copied from class: EntityMock
      Get the current state of this entity
      Overrides:
      getEntityState in class EntityMock
      Returns:
      The current state of this entity
    • getType

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