public class PlayerMock extends LivingEntityMock implements org.bukkit.entity.Player, SoundReceiver
| Modifier and Type | Class and Description |
|---|---|
class |
PlayerMock.PlayerSpigotMock |
alive, attributes, health| Constructor and Description |
|---|
PlayerMock(ServerMock server,
java.lang.String name) |
PlayerMock(ServerMock server,
java.lang.String name,
java.util.UUID uuid) |
| Modifier and Type | Method and Description |
|---|---|
void |
abandonConversation(@NotNull org.bukkit.conversations.Conversation conversation) |
void |
abandonConversation(@NotNull org.bukkit.conversations.Conversation conversation,
@NotNull org.bukkit.conversations.ConversationAbandonedEvent details) |
void |
acceptConversationInput(@NotNull java.lang.String input) |
void |
assertGameMode(org.bukkit.GameMode expectedGamemode)
Assert that the player is in a specific gamemode.
|
void |
assertInventoryView(org.bukkit.event.inventory.InventoryType type)
This method is an assertion for the currently open
InventoryView for this Player. |
void |
assertInventoryView(org.bukkit.event.inventory.InventoryType type,
java.util.function.Predicate<org.bukkit.inventory.Inventory> predicate)
This method is an assertion for the currently open
InventoryView for this Player. |
void |
assertInventoryView(java.lang.String message,
org.bukkit.event.inventory.InventoryType type)
This method is an assertion for the currently open
InventoryView for this Player. |
void |
assertInventoryView(java.lang.String message,
org.bukkit.event.inventory.InventoryType type,
java.util.function.Predicate<org.bukkit.inventory.Inventory> predicate)
This method is an assertion for the currently open
InventoryView for this Player. |
void |
attack(@NotNull org.bukkit.entity.Entity target) |
boolean |
beginConversation(@NotNull org.bukkit.conversations.Conversation conversation) |
boolean |
canSee(@NotNull org.bukkit.entity.Player player) |
void |
chat(@NotNull java.lang.String msg) |
void |
closeInventory() |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic) |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType) |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType,
int amount) |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic,
int amount) |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material) |
void |
decrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material,
int amount) |
boolean |
discoverRecipe(@NotNull org.bukkit.NamespacedKey recipe) |
int |
discoverRecipes(@NotNull java.util.Collection<org.bukkit.NamespacedKey> recipes) |
boolean |
dropItem(boolean dropAll) |
double |
getAbsorptionAmount() |
java.net.InetSocketAddress |
getAddress() |
@NotNull org.bukkit.advancement.AdvancementProgress |
getAdvancementProgress(@NotNull org.bukkit.advancement.Advancement advancement) |
boolean |
getAllowFlight() |
float |
getAttackCooldown() |
@NotNull org.bukkit.Location |
getBedLocation() |
@Nullable org.bukkit.Location |
getBedSpawnLocation() |
@NotNull org.bukkit.util.BoundingBox |
getBoundingBox() |
boolean |
getCanPickupItems() |
int |
getClientViewDistance() |
@NotNull java.util.Set<java.util.UUID> |
getCollidableExemptions() |
@NotNull org.bukkit.Location |
getCompassTarget() |
int |
getCooldown(@NotNull org.bukkit.Material material) |
@NotNull java.util.Set<org.bukkit.NamespacedKey> |
getDiscoveredRecipes() |
@NotNull java.lang.String |
getDisplayName() |
@NotNull org.bukkit.inventory.Inventory |
getEnderChest() |
org.bukkit.inventory.EntityEquipment |
getEquipment() |
float |
getExhaustion() |
float |
getExp() |
int |
getExpToLevel() |
double |
getEyeHeight() |
double |
getEyeHeight(boolean ignorePose) |
@NotNull org.bukkit.block.BlockFace |
getFacing() |
long |
getFirstPlayed() |
float |
getFlySpeed() |
int |
getFoodLevel() |
@NotNull org.bukkit.GameMode |
getGameMode() |
double |
getHealthScale() |
@NotNull java.util.List<AudioExperience> |
getHeardSounds()
This returns a
List of every AudioExperience this receiver has received. |
@NotNull org.bukkit.inventory.PlayerInventory |
getInventory() |
@NotNull org.bukkit.inventory.ItemStack |
getItemInHand() |
@NotNull org.bukkit.inventory.ItemStack |
getItemOnCursor() |
org.bukkit.entity.Player |
getKiller() |
double |
getLastDamage() |
long |
getLastPlayed() |
@NotNull java.util.List<org.bukkit.block.Block> |
getLastTwoTargetBlocks(java.util.Set<org.bukkit.Material> transparent,
int maxDistance) |
@NotNull org.bukkit.entity.Entity |
getLeashHolder() |
int |
getLevel() |
@NotNull java.util.List<org.bukkit.block.Block> |
getLineOfSight(java.util.Set<org.bukkit.Material> transparent,
int maxDistance) |
@NotNull java.util.Set<java.lang.String> |
getListeningPluginChannels() |
@NotNull java.lang.String |
getLocale() |
@NotNull org.bukkit.inventory.MainHand |
getMainHand() |
int |
getMaximumNoDamageTicks() |
<T> T |
getMemory(@NotNull org.bukkit.entity.memory.MemoryKey<T> memoryKey) |
int |
getNoDamageTicks() |
@NotNull org.bukkit.inventory.InventoryView |
getOpenInventory() |
int |
getPing() |
org.bukkit.entity.Player |
getPlayer() |
java.lang.String |
getPlayerListFooter() |
java.lang.String |
getPlayerListHeader() |
@NotNull java.lang.String |
getPlayerListName() |
long |
getPlayerTime() |
long |
getPlayerTimeOffset() |
org.bukkit.WeatherType |
getPlayerWeather() |
@NotNull org.bukkit.entity.Pose |
getPose() |
boolean |
getRemoveWhenFarAway() |
int |
getSaturatedRegenRate() |
float |
getSaturation() |
@NotNull org.bukkit.scoreboard.Scoreboard |
getScoreboard() |
org.bukkit.entity.Entity |
getShoulderEntityLeft() |
org.bukkit.entity.Entity |
getShoulderEntityRight() |
int |
getSleepTicks() |
org.bukkit.entity.Entity |
getSpectatorTarget() |
int |
getStarvationRate() |
int |
getStatistic(@NotNull org.bukkit.Statistic statistic) |
int |
getStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType) |
int |
getStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material) |
@NotNull org.bukkit.block.Block |
getTargetBlock(java.util.Set<org.bukkit.Material> transparent,
int maxDistance) |
org.bukkit.block.Block |
getTargetBlockExact(int maxDistance) |
org.bukkit.block.Block |
getTargetBlockExact(int maxDistance,
@NotNull org.bukkit.FluidCollisionMode fluidCollisionMode) |
int |
getTotalExperience() |
@NotNull org.bukkit.entity.EntityType |
getType() |
int |
getUnsaturatedRegenRate() |
float |
getWalkSpeed() |
void |
giveExp(int amount) |
void |
giveExpLevels(int amount) |
boolean |
hasAI() |
boolean |
hasCooldown(@NotNull org.bukkit.Material material) |
boolean |
hasDiscoveredRecipe(@NotNull org.bukkit.NamespacedKey recipe) |
boolean |
hasLineOfSight(@NotNull org.bukkit.entity.Entity other) |
boolean |
hasPlayedBefore() |
void |
hidePlayer(@NotNull org.bukkit.entity.Player player)
Deprecated.
|
void |
hidePlayer(@NotNull org.bukkit.plugin.Plugin plugin,
@NotNull org.bukkit.entity.Player player) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType,
int amount) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic,
int amount) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material) |
void |
incrementStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material,
int amount) |
boolean |
isBanned() |
boolean |
isBlocking() |
boolean |
isCollidable() |
boolean |
isConversing() |
boolean |
isFlying() |
boolean |
isGliding() |
boolean |
isHandRaised() |
boolean |
isHealthScaled() |
boolean |
isLeashed() |
boolean |
isOnline() |
boolean |
isPersistent() |
boolean |
isPlayerTimeRelative() |
boolean |
isRiptiding() |
boolean |
isSleeping() |
boolean |
isSleepingIgnored() |
boolean |
isSneaking() |
boolean |
isSprinting() |
boolean |
isSwimming() |
boolean |
isWhitelisted() |
void |
kickPlayer(java.lang.String message) |
void |
loadData() |
void |
openBook(@NotNull org.bukkit.inventory.ItemStack book) |
org.bukkit.inventory.InventoryView |
openEnchanting(org.bukkit.Location location,
boolean force) |
org.bukkit.inventory.InventoryView |
openInventory(@NotNull org.bukkit.inventory.Inventory inventory) |
void |
openInventory(@NotNull org.bukkit.inventory.InventoryView inventory) |
org.bukkit.inventory.InventoryView |
openMerchant(@NotNull org.bukkit.inventory.Merchant merchant,
boolean force) |
org.bukkit.inventory.InventoryView |
openMerchant(@NotNull org.bukkit.entity.Villager trader,
boolean force) |
org.bukkit.inventory.InventoryView |
openWorkbench(org.bukkit.Location location,
boolean force) |
boolean |
performCommand(@NotNull java.lang.String command) |
void |
playEffect(@NotNull org.bukkit.Location loc,
@NotNull org.bukkit.Effect effect,
int data) |
<T> void |
playEffect(@NotNull org.bukkit.Location loc,
@NotNull org.bukkit.Effect effect,
T data) |
void |
playNote(@NotNull org.bukkit.Location loc,
byte instrument,
byte note)
Deprecated.
|
void |
playNote(@NotNull org.bukkit.Location loc,
@NotNull org.bukkit.Instrument instrument,
@NotNull org.bukkit.Note note) |
void |
playSound(@NotNull org.bukkit.Location location,
@NotNull org.bukkit.Sound sound,
float volume,
float pitch) |
void |
playSound(@NotNull org.bukkit.Location location,
@NotNull org.bukkit.Sound sound,
@NotNull org.bukkit.SoundCategory category,
float volume,
float pitch) |
void |
playSound(@NotNull org.bukkit.Location location,
@NotNull java.lang.String sound,
float volume,
float pitch) |
void |
playSound(@NotNull org.bukkit.Location location,
@NotNull java.lang.String sound,
@NotNull org.bukkit.SoundCategory category,
float volume,
float pitch) |
org.bukkit.util.RayTraceResult |
rayTraceBlocks(double maxDistance) |
org.bukkit.util.RayTraceResult |
rayTraceBlocks(double maxDistance,
@NotNull org.bukkit.FluidCollisionMode fluidCollisionMode) |
void |
resetPlayerTime() |
void |
resetPlayerWeather() |
void |
resetTitle() |
void |
respawn()
This method simulates the
Player respawning and also calls a PlayerRespawnEvent. |
void |
saveData() |
void |
sendBlockChange(@NotNull org.bukkit.Location loc,
@NotNull org.bukkit.block.data.BlockData block) |
void |
sendBlockChange(@NotNull org.bukkit.Location loc,
@NotNull org.bukkit.Material material,
byte data) |
void |
sendBlockDamage(@NotNull org.bukkit.Location loc,
float progress) |
boolean |
sendChunkChange(@NotNull org.bukkit.Location loc,
int sx,
int sy,
int sz,
byte[] data) |
void |
sendExperienceChange(float progress) |
void |
sendExperienceChange(float progress,
int level) |
void |
sendMap(@NotNull org.bukkit.map.MapView map) |
void |
sendPluginMessage(@NotNull org.bukkit.plugin.Plugin source,
@NotNull java.lang.String channel,
byte[] message) |
void |
sendRawMessage(@Nullable java.lang.String message) |
void |
sendRawMessage(@Nullable java.util.UUID sender,
@NotNull java.lang.String message) |
void |
sendSignChange(@NotNull org.bukkit.Location loc,
java.lang.String[] lines) |
void |
sendSignChange(@NotNull org.bukkit.Location loc,
java.lang.String[] lines,
@NotNull org.bukkit.DyeColor dyeColor) |
void |
sendTitle(java.lang.String title,
java.lang.String subtitle) |
void |
sendTitle(java.lang.String title,
java.lang.String subtitle,
int fadeIn,
int stay,
int fadeOut) |
@NotNull java.util.Map<java.lang.String,java.lang.Object> |
serialize() |
void |
setAbsorptionAmount(double amount) |
void |
setAI(boolean ai) |
void |
setAllowFlight(boolean flight) |
void |
setBedSpawnLocation(@Nullable org.bukkit.Location loc) |
void |
setBedSpawnLocation(@Nullable org.bukkit.Location loc,
boolean force) |
void |
setCanPickupItems(boolean pickup) |
void |
setCollidable(boolean collidable) |
void |
setCompassTarget(@NotNull org.bukkit.Location loc) |
void |
setCooldown(@NotNull org.bukkit.Material material,
int ticks) |
void |
setDisplayName(java.lang.String name) |
void |
setExhaustion(float value) |
void |
setExp(float exp) |
void |
setFlying(boolean value) |
void |
setFlySpeed(float value) |
void |
setFoodLevel(int foodLevel) |
void |
setGameMode(@NotNull org.bukkit.GameMode mode) |
void |
setGliding(boolean gliding) |
void |
setHealth(double health) |
void |
setHealthScale(double scale) |
void |
setHealthScaled(boolean scale) |
void |
setItemInHand(org.bukkit.inventory.ItemStack item) |
void |
setItemOnCursor(org.bukkit.inventory.ItemStack item) |
void |
setLastDamage(double damage) |
void |
setLastPlayed(long time) |
boolean |
setLeashHolder(org.bukkit.entity.Entity holder) |
void |
setLevel(int level) |
void |
setMaximumNoDamageTicks(int ticks) |
<T> void |
setMemory(@NotNull org.bukkit.entity.memory.MemoryKey<T> memoryKey,
T memoryValue) |
void |
setNoDamageTicks(int ticks) |
void |
setPersistent(boolean persistent) |
void |
setPlayerListFooter(java.lang.String footer) |
void |
setPlayerListHeader(java.lang.String header) |
void |
setPlayerListHeaderFooter(java.lang.String header,
java.lang.String footer) |
void |
setPlayerListName(java.lang.String name) |
void |
setPlayerTime(long time,
boolean relative) |
void |
setPlayerWeather(@NotNull org.bukkit.WeatherType type) |
void |
setRemoveWhenFarAway(boolean remove) |
void |
setResourcePack(@NotNull java.lang.String url) |
void |
setResourcePack(@NotNull java.lang.String url,
byte[] hash) |
void |
setSaturatedRegenRate(int ticks) |
void |
setSaturation(float value) |
void |
setScoreboard(@NotNull org.bukkit.scoreboard.Scoreboard scoreboard) |
void |
setShoulderEntityLeft(org.bukkit.entity.Entity entity) |
void |
setShoulderEntityRight(org.bukkit.entity.Entity entity) |
void |
setSleepingIgnored(boolean isSleeping) |
void |
setSneaking(boolean sneaking) |
void |
setSpectatorTarget(org.bukkit.entity.Entity entity) |
void |
setSprinting(boolean sprinting) |
void |
setStarvationRate(int ticks) |
void |
setStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.entity.EntityType entityType,
int newValue) |
void |
setStatistic(@NotNull org.bukkit.Statistic statistic,
int newValue) |
void |
setStatistic(@NotNull org.bukkit.Statistic statistic,
@NotNull org.bukkit.Material material,
int newValue) |
void |
setSwimming(boolean swimming) |
void |
setTexturePack(@NotNull java.lang.String url)
Deprecated.
|
void |
setTotalExperience(int exp) |
void |
setUnsaturatedRegenRate(int ticks) |
void |
setWalkSpeed(float value) |
void |
setWhitelisted(boolean value) |
boolean |
setWindowProperty(@NotNull org.bukkit.inventory.InventoryView.Property prop,
int value) |
void |
showPlayer(@NotNull org.bukkit.entity.Player player)
Deprecated.
|
void |
showPlayer(@NotNull org.bukkit.plugin.Plugin plugin,
@NotNull org.bukkit.entity.Player player) |
@Nullable org.bukkit.event.block.BlockBreakEvent |
simulateBlockBreak(org.bukkit.block.Block block)
Simulates the player breaking a block.
|
@Nullable org.bukkit.event.block.BlockDamageEvent |
simulateBlockDamage(org.bukkit.block.Block block)
Simulates the player damaging a block.
|
protected org.bukkit.event.block.BlockDamageEvent |
simulateBlockDamagePure(org.bukkit.block.Block block)
Simulates the player damaging a block just like
simulateBlockDamage(Block). |
@Nullable org.bukkit.event.block.BlockPlaceEvent |
simulateBlockPlace(org.bukkit.Material material,
org.bukkit.Location location)
Simulates the player placing a block.
|
@NotNull org.bukkit.event.player.PlayerMoveEvent |
simulatePlayerMove(@NotNull org.bukkit.Location moveLocation)
This method moves player instantly with respect to PlayerMoveEvent
|
@NotNull org.bukkit.event.player.PlayerToggleSneakEvent |
simulateSneak(boolean sneak) |
@NotNull org.bukkit.event.player.PlayerToggleSprintEvent |
simulateSprint(boolean sprint) |
@NotNull org.bukkit.event.player.PlayerToggleFlightEvent |
simulateToggleFlight(boolean fly) |
boolean |
sleep(@NotNull org.bukkit.Location location,
boolean force) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra,
T data) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
T data) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
T data) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ) |
void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra,
T data) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
T data) |
<T> void |
spawnParticle(@NotNull org.bukkit.Particle particle,
@NotNull org.bukkit.Location location,
int count,
T data) |
@NotNull PlayerMock.PlayerSpigotMock |
spigot() |
void |
stopSound(@NotNull org.bukkit.Sound sound) |
void |
stopSound(@NotNull org.bukkit.Sound sound,
org.bukkit.SoundCategory category) |
void |
stopSound(@NotNull java.lang.String sound) |
void |
stopSound(@NotNull java.lang.String sound,
org.bukkit.SoundCategory category) |
void |
swingMainHand() |
void |
swingOffHand() |
boolean |
teleport(@NotNull org.bukkit.Location location,
org.bukkit.event.player.PlayerTeleportEvent.TeleportCause cause) |
boolean |
undiscoverRecipe(@NotNull org.bukkit.NamespacedKey recipe) |
int |
undiscoverRecipes(@NotNull java.util.Collection<org.bukkit.NamespacedKey> recipes) |
void |
updateCommands() |
void |
updateInventory() |
void |
wakeup(boolean setSpawnLocation) |
addPotionEffect, addPotionEffect, addPotionEffects, damage, damage, getActivePotionEffects, getArrowCooldown, getArrowsInBody, getAttribute, getCategory, getEyeLocation, getHealth, getMaxHealth, getMaximumAir, getPotionEffect, getRemainingAir, hasPotionEffect, isDead, isInvisible, launchProjectile, launchProjectile, removePotionEffect, resetMaxHealth, setArrowCooldown, setArrowsInBody, setInvisible, setMaxHealth, setMaximumAir, setRemainingAiraddAttachment, addAttachment, addAttachment, addAttachment, addPassenger, addScoreboardTag, assertLocation, assertNotTeleported, assertTeleported, clearTeleported, eject, equals, getCustomName, getEffectivePermissions, getEntityId, getFallDistance, getFireTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getMetadata, getName, getNearbyEntities, getPassenger, getPassengers, getPersistentDataContainer, getPistonMoveReaction, getPortalCooldown, getScoreboardTags, getServer, getTeleportCause, getTicksLived, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, hashCode, hasMetadata, hasPermission, hasPermission, hasTeleported, isCustomNameVisible, isEmpty, isGlowing, isInsideVehicle, isInvulnerable, isInWater, isOnGround, isOp, isPermissionSet, isPermissionSet, isSilent, isValid, leaveVehicle, nextMessage, playEffect, recalculatePermissions, remove, removeAttachment, removeMetadata, removePassenger, removeScoreboardTag, sendMessage, sendMessage, sendMessage, sendMessage, setCustomName, setCustomNameVisible, setFallDistance, setFireTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setLocation, setMetadata, setName, setOp, setPassenger, setPortalCooldown, setRotation, setSilent, setTicksLived, setVelocity, teleport, teleport, teleportsendMessage, sendMessage, sendMessage, sendMessageclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitaddPotionEffect, addPotionEffect, addPotionEffects, getActivePotionEffects, getArrowCooldown, getArrowsInBody, getCategory, getEyeLocation, getMaximumAir, getPotionEffect, getRemainingAir, hasPotionEffect, isInvisible, removePotionEffect, setArrowCooldown, setArrowsInBody, setInvisible, setMaximumAir, setRemainingAirdamage, damage, getHealth, getMaxHealth, resetMaxHealth, setMaxHealthaddPassenger, addScoreboardTag, eject, getEntityId, getFallDistance, getFireTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getNearbyEntities, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getScoreboardTags, getServer, getTicksLived, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isGlowing, isInsideVehicle, isInvulnerable, isInWater, isSilent, isValid, leaveVehicle, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPortalCooldown, setRotation, setSilent, setTicksLived, setVelocity, teleport, teleport, teleportgetMetadata, hasMetadata, removeMetadata, setMetadatasendMessage, sendMessage, sendMessage, sendMessageaddAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, recalculatePermissions, removeAttachmentgetPersistentDataContainerlaunchProjectile, launchProjectileaddHeardSound, assertSoundHeard, assertSoundHeard, assertSoundHeard, assertSoundHeard, assertSoundHeard, assertSoundHeard, assertSoundHeard, assertSoundHeard, clearSoundsassertNoMoreSaid, assertSaidpublic PlayerMock(ServerMock server, java.lang.String name)
public PlayerMock(ServerMock server, java.lang.String name, java.util.UUID uuid)
@NotNull public @NotNull org.bukkit.entity.EntityType getType()
getType in interface org.bukkit.entity.Entitypublic void assertGameMode(org.bukkit.GameMode expectedGamemode)
expectedGamemode - The gamemode the player should be in.protected org.bukkit.event.block.BlockDamageEvent simulateBlockDamagePure(org.bukkit.block.Block block)
simulateBlockDamage(Block). However, if
InstaBreak is enabled, it will not automatically fire a BlockBreakEvent. It will also still fire
a BlockDamageEvent even if the player is not in survival mode.block - The block to damage.@Nullable public @Nullable org.bukkit.event.block.BlockDamageEvent simulateBlockDamage(org.bukkit.block.Block block)
InstaBreak is set to true by an event handler, a BlockBreakEvent is immediately fired.
The result will then still be whether or not the BlockDamageEvent was cancelled or not, not the later
BlockBreakEvent.block - The block to damage.null if the player was not in
survival gamemode.@Nullable public @Nullable org.bukkit.event.block.BlockBreakEvent simulateBlockBreak(org.bukkit.block.Block block)
block - The block to break.null if it wasn't or if the player was in adventure mode
or in spectator mode.@Nullable
public @Nullable org.bukkit.event.block.BlockPlaceEvent simulateBlockPlace(org.bukkit.Material material,
org.bukkit.Location location)
material - The material of the location to set tolocation - The location of the material to set tonull if it wasn't or the player was in adventure
mode.public void respawn()
Player respawning and also calls a PlayerRespawnEvent. Should the
Player not be dead (when LivingEntityMock.isDead() returns false) then this will throw an
UnsupportedOperationException. Otherwise, the Location will be set to
Player.getBedSpawnLocation() or World.getSpawnLocation(). Lastly the health of this
Player will be restored and set to the max health.@NotNull
public @NotNull org.bukkit.event.player.PlayerMoveEvent simulatePlayerMove(@NotNull
@NotNull org.bukkit.Location moveLocation)
moveLocation - Location to move player to@NotNull public @NotNull org.bukkit.inventory.PlayerInventory getInventory()
getInventory in interface org.bukkit.entity.HumanEntitygetInventory in interface org.bukkit.inventory.InventoryHolder@NotNull public @NotNull org.bukkit.GameMode getGameMode()
getGameMode in interface org.bukkit.entity.HumanEntitypublic void setGameMode(@NotNull
@NotNull org.bukkit.GameMode mode)
setGameMode in interface org.bukkit.entity.HumanEntitypublic boolean isWhitelisted()
isWhitelisted in interface org.bukkit.OfflinePlayerpublic void setWhitelisted(boolean value)
setWhitelisted in interface org.bukkit.OfflinePlayerpublic org.bukkit.entity.Player getPlayer()
getPlayer in interface org.bukkit.OfflinePlayerpublic boolean isOnline()
isOnline in interface org.bukkit.OfflinePlayerpublic boolean isBanned()
isBanned in interface org.bukkit.OfflinePlayer@NotNull public @NotNull org.bukkit.inventory.InventoryView getOpenInventory()
getOpenInventory in interface org.bukkit.entity.HumanEntitypublic void openInventory(@NotNull
@NotNull org.bukkit.inventory.InventoryView inventory)
openInventory in interface org.bukkit.entity.HumanEntitypublic org.bukkit.inventory.InventoryView openInventory(@NotNull
@NotNull org.bukkit.inventory.Inventory inventory)
openInventory in interface org.bukkit.entity.HumanEntitypublic void closeInventory()
closeInventory in interface org.bukkit.entity.HumanEntitypublic void assertInventoryView(java.lang.String message,
org.bukkit.event.inventory.InventoryType type,
java.util.function.Predicate<org.bukkit.inventory.Inventory> predicate)
InventoryView for this Player. The
Predicate refers to the top inventory, not the PlayerInventory. It uses the method
InventoryView.getTopInventory().message - The message to display upon failuretype - The InventoryType you are expectingpredicate - A custom Predicate to check the opened Inventory.public void assertInventoryView(org.bukkit.event.inventory.InventoryType type,
java.util.function.Predicate<org.bukkit.inventory.Inventory> predicate)
InventoryView for this Player. The
Predicate refers to the top inventory, not the PlayerInventory. It uses the method
InventoryView.getTopInventory().type - The InventoryType you are expectingpredicate - A custom Predicate to check the opened Inventory.public void assertInventoryView(org.bukkit.event.inventory.InventoryType type)
InventoryView for this Player.type - The InventoryType you are expectingpublic void assertInventoryView(java.lang.String message,
org.bukkit.event.inventory.InventoryType type)
InventoryView for this Player.message - The message to display upon failuretype - The InventoryType you are expectingpublic boolean performCommand(@NotNull
@NotNull java.lang.String command)
performCommand in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.inventory.Inventory getEnderChest()
getEnderChest in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull org.bukkit.inventory.MainHand getMainHand()
getMainHand in interface org.bukkit.entity.HumanEntitypublic boolean setWindowProperty(@NotNull
@NotNull org.bukkit.inventory.InventoryView.Property prop,
int value)
setWindowProperty in interface org.bukkit.entity.HumanEntitypublic org.bukkit.inventory.InventoryView openWorkbench(org.bukkit.Location location,
boolean force)
openWorkbench in interface org.bukkit.entity.HumanEntitypublic org.bukkit.inventory.InventoryView openEnchanting(org.bukkit.Location location,
boolean force)
openEnchanting in interface org.bukkit.entity.HumanEntitypublic org.bukkit.inventory.InventoryView openMerchant(@NotNull
@NotNull org.bukkit.entity.Villager trader,
boolean force)
openMerchant in interface org.bukkit.entity.HumanEntitypublic org.bukkit.inventory.InventoryView openMerchant(@NotNull
@NotNull org.bukkit.inventory.Merchant merchant,
boolean force)
openMerchant in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull org.bukkit.inventory.ItemStack getItemInHand()
getItemInHand in interface org.bukkit.entity.HumanEntitypublic void setItemInHand(org.bukkit.inventory.ItemStack item)
setItemInHand in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull org.bukkit.inventory.ItemStack getItemOnCursor()
getItemOnCursor in interface org.bukkit.entity.HumanEntitypublic void setItemOnCursor(org.bukkit.inventory.ItemStack item)
setItemOnCursor in interface org.bukkit.entity.HumanEntitypublic boolean hasCooldown(@NotNull
@NotNull org.bukkit.Material material)
hasCooldown in interface org.bukkit.entity.HumanEntitypublic int getCooldown(@NotNull
@NotNull org.bukkit.Material material)
getCooldown in interface org.bukkit.entity.HumanEntitypublic void setCooldown(@NotNull
@NotNull org.bukkit.Material material,
int ticks)
setCooldown in interface org.bukkit.entity.HumanEntitypublic boolean isSleeping()
isSleeping in interface org.bukkit.entity.LivingEntitypublic int getSleepTicks()
getSleepTicks in interface org.bukkit.entity.HumanEntitypublic boolean isBlocking()
isBlocking in interface org.bukkit.entity.HumanEntitypublic boolean isHandRaised()
isHandRaised in interface org.bukkit.entity.HumanEntitypublic int getExpToLevel()
getExpToLevel in interface org.bukkit.entity.HumanEntitypublic org.bukkit.entity.Entity getShoulderEntityLeft()
getShoulderEntityLeft in interface org.bukkit.entity.HumanEntitypublic void setShoulderEntityLeft(org.bukkit.entity.Entity entity)
setShoulderEntityLeft in interface org.bukkit.entity.HumanEntitypublic org.bukkit.entity.Entity getShoulderEntityRight()
getShoulderEntityRight in interface org.bukkit.entity.HumanEntitypublic void setShoulderEntityRight(org.bukkit.entity.Entity entity)
setShoulderEntityRight in interface org.bukkit.entity.HumanEntitypublic double getEyeHeight()
getEyeHeight in interface org.bukkit.entity.LivingEntitygetEyeHeight in class LivingEntityMockpublic double getEyeHeight(boolean ignorePose)
getEyeHeight in interface org.bukkit.entity.LivingEntitygetEyeHeight in class LivingEntityMock@NotNull
public @NotNull java.util.List<org.bukkit.block.Block> getLineOfSight(java.util.Set<org.bukkit.Material> transparent,
int maxDistance)
getLineOfSight in interface org.bukkit.entity.LivingEntitygetLineOfSight in class LivingEntityMock@NotNull
public @NotNull org.bukkit.block.Block getTargetBlock(java.util.Set<org.bukkit.Material> transparent,
int maxDistance)
getTargetBlock in interface org.bukkit.entity.LivingEntitygetTargetBlock in class LivingEntityMock@NotNull
public @NotNull java.util.List<org.bukkit.block.Block> getLastTwoTargetBlocks(java.util.Set<org.bukkit.Material> transparent,
int maxDistance)
getLastTwoTargetBlocks in interface org.bukkit.entity.LivingEntitygetLastTwoTargetBlocks in class LivingEntityMockpublic int getMaximumNoDamageTicks()
getMaximumNoDamageTicks in interface org.bukkit.entity.LivingEntitygetMaximumNoDamageTicks in class LivingEntityMockpublic void setMaximumNoDamageTicks(int ticks)
setMaximumNoDamageTicks in interface org.bukkit.entity.LivingEntitysetMaximumNoDamageTicks in class LivingEntityMockpublic double getLastDamage()
getLastDamage in interface org.bukkit.entity.LivingEntitygetLastDamage in class LivingEntityMockpublic void setLastDamage(double damage)
setLastDamage in interface org.bukkit.entity.LivingEntitysetLastDamage in class LivingEntityMockpublic int getNoDamageTicks()
getNoDamageTicks in interface org.bukkit.entity.LivingEntitygetNoDamageTicks in class LivingEntityMockpublic void setNoDamageTicks(int ticks)
setNoDamageTicks in interface org.bukkit.entity.LivingEntitysetNoDamageTicks in class LivingEntityMockpublic org.bukkit.entity.Player getKiller()
getKiller in interface org.bukkit.entity.LivingEntitygetKiller in class LivingEntityMockpublic boolean hasLineOfSight(@NotNull
@NotNull org.bukkit.entity.Entity other)
hasLineOfSight in interface org.bukkit.entity.LivingEntityhasLineOfSight in class LivingEntityMockpublic boolean getRemoveWhenFarAway()
getRemoveWhenFarAway in interface org.bukkit.entity.LivingEntitygetRemoveWhenFarAway in class LivingEntityMockpublic void setRemoveWhenFarAway(boolean remove)
setRemoveWhenFarAway in interface org.bukkit.entity.LivingEntitysetRemoveWhenFarAway in class LivingEntityMockpublic org.bukkit.inventory.EntityEquipment getEquipment()
getEquipment in interface org.bukkit.entity.LivingEntitypublic void setCanPickupItems(boolean pickup)
setCanPickupItems in interface org.bukkit.entity.LivingEntitysetCanPickupItems in class LivingEntityMockpublic boolean getCanPickupItems()
getCanPickupItems in interface org.bukkit.entity.LivingEntitygetCanPickupItems in class LivingEntityMockpublic boolean isLeashed()
isLeashed in interface org.bukkit.entity.LivingEntityisLeashed in class LivingEntityMock@NotNull public @NotNull org.bukkit.entity.Entity getLeashHolder()
getLeashHolder in interface org.bukkit.entity.LivingEntitygetLeashHolder in class LivingEntityMockpublic boolean setLeashHolder(org.bukkit.entity.Entity holder)
setLeashHolder in interface org.bukkit.entity.LivingEntitysetLeashHolder in class LivingEntityMockpublic boolean isGliding()
isGliding in interface org.bukkit.entity.LivingEntityisGliding in class LivingEntityMockpublic void setGliding(boolean gliding)
setGliding in interface org.bukkit.entity.LivingEntitysetGliding in class LivingEntityMockpublic void setAI(boolean ai)
setAI in interface org.bukkit.entity.LivingEntitysetAI in class LivingEntityMockpublic boolean hasAI()
hasAI in interface org.bukkit.entity.LivingEntityhasAI in class LivingEntityMockpublic void setCollidable(boolean collidable)
setCollidable in interface org.bukkit.entity.LivingEntitysetCollidable in class LivingEntityMockpublic boolean isCollidable()
isCollidable in interface org.bukkit.entity.LivingEntityisCollidable in class LivingEntityMockpublic boolean isConversing()
isConversing in interface org.bukkit.conversations.Conversablepublic void acceptConversationInput(@NotNull
@NotNull java.lang.String input)
acceptConversationInput in interface org.bukkit.conversations.Conversablepublic boolean beginConversation(@NotNull
@NotNull org.bukkit.conversations.Conversation conversation)
beginConversation in interface org.bukkit.conversations.Conversablepublic void abandonConversation(@NotNull
@NotNull org.bukkit.conversations.Conversation conversation)
abandonConversation in interface org.bukkit.conversations.Conversablepublic void abandonConversation(@NotNull
@NotNull org.bukkit.conversations.Conversation conversation,
@NotNull
@NotNull org.bukkit.conversations.ConversationAbandonedEvent details)
abandonConversation in interface org.bukkit.conversations.Conversablepublic long getFirstPlayed()
getFirstPlayed in interface org.bukkit.OfflinePlayerpublic long getLastPlayed()
getLastPlayed in interface org.bukkit.OfflinePlayerpublic boolean hasPlayedBefore()
hasPlayedBefore in interface org.bukkit.OfflinePlayerpublic void setLastPlayed(long time)
@NotNull public @NotNull java.util.Map<java.lang.String,java.lang.Object> serialize()
serialize in interface org.bukkit.configuration.serialization.ConfigurationSerializablepublic void sendPluginMessage(@NotNull
@NotNull org.bukkit.plugin.Plugin source,
@NotNull
@NotNull java.lang.String channel,
byte[] message)
sendPluginMessage in interface org.bukkit.plugin.messaging.PluginMessageRecipient@NotNull public @NotNull java.util.Set<java.lang.String> getListeningPluginChannels()
getListeningPluginChannels in interface org.bukkit.plugin.messaging.PluginMessageRecipient@NotNull public @NotNull java.lang.String getDisplayName()
getDisplayName in interface org.bukkit.entity.Playerpublic void setDisplayName(java.lang.String name)
setDisplayName in interface org.bukkit.entity.Player@NotNull public @NotNull java.lang.String getPlayerListName()
getPlayerListName in interface org.bukkit.entity.Playerpublic void setPlayerListName(java.lang.String name)
setPlayerListName in interface org.bukkit.entity.Playerpublic void setCompassTarget(@NotNull
@NotNull org.bukkit.Location loc)
setCompassTarget in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.Location getCompassTarget()
getCompassTarget in interface org.bukkit.entity.Playerpublic java.net.InetSocketAddress getAddress()
getAddress in interface org.bukkit.entity.Playerpublic void sendRawMessage(@Nullable
@Nullable java.lang.String message)
sendRawMessage in interface org.bukkit.conversations.ConversablesendRawMessage in interface org.bukkit.entity.Playerpublic void sendRawMessage(@Nullable
@Nullable java.util.UUID sender,
@NotNull
@NotNull java.lang.String message)
sendRawMessage in interface org.bukkit.conversations.Conversablepublic void kickPlayer(java.lang.String message)
kickPlayer in interface org.bukkit.entity.Playerpublic void chat(@NotNull
@NotNull java.lang.String msg)
chat in interface org.bukkit.entity.Playerpublic boolean isSneaking()
isSneaking in interface org.bukkit.entity.Playerpublic void setSneaking(boolean sneaking)
setSneaking in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.event.player.PlayerToggleSneakEvent simulateSneak(boolean sneak)
public boolean isSprinting()
isSprinting in interface org.bukkit.entity.Playerpublic void setSprinting(boolean sprinting)
setSprinting in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.event.player.PlayerToggleSprintEvent simulateSprint(boolean sprint)
public void saveData()
saveData in interface org.bukkit.entity.Playerpublic void loadData()
loadData in interface org.bukkit.entity.Playerpublic void setSleepingIgnored(boolean isSleeping)
setSleepingIgnored in interface org.bukkit.entity.Playerpublic boolean isSleepingIgnored()
isSleepingIgnored in interface org.bukkit.entity.Player@Deprecated
public void playNote(@NotNull
@NotNull org.bukkit.Location loc,
byte instrument,
byte note)
playNote in interface org.bukkit.entity.Playerpublic void playNote(@NotNull
@NotNull org.bukkit.Location loc,
@NotNull
@NotNull org.bukkit.Instrument instrument,
@NotNull
@NotNull org.bukkit.Note note)
playNote in interface org.bukkit.entity.Playerpublic void playSound(@NotNull
@NotNull org.bukkit.Location location,
@NotNull
@NotNull java.lang.String sound,
float volume,
float pitch)
playSound in interface org.bukkit.entity.Playerpublic void playSound(@NotNull
@NotNull org.bukkit.Location location,
@NotNull
@NotNull org.bukkit.Sound sound,
float volume,
float pitch)
playSound in interface org.bukkit.entity.Playerpublic void playSound(@NotNull
@NotNull org.bukkit.Location location,
@NotNull
@NotNull java.lang.String sound,
@NotNull
@NotNull org.bukkit.SoundCategory category,
float volume,
float pitch)
playSound in interface org.bukkit.entity.Playerpublic void playSound(@NotNull
@NotNull org.bukkit.Location location,
@NotNull
@NotNull org.bukkit.Sound sound,
@NotNull
@NotNull org.bukkit.SoundCategory category,
float volume,
float pitch)
playSound in interface org.bukkit.entity.Player@NotNull public @NotNull java.util.List<AudioExperience> getHeardSounds()
SoundReceiverList of every AudioExperience this receiver has received.getHeardSounds in interface SoundReceiverList containing every heard sound.public void stopSound(@NotNull
@NotNull org.bukkit.Sound sound)
stopSound in interface org.bukkit.entity.Playerpublic void stopSound(@NotNull
@NotNull java.lang.String sound)
stopSound in interface org.bukkit.entity.Playerpublic void stopSound(@NotNull
@NotNull org.bukkit.Sound sound,
org.bukkit.SoundCategory category)
stopSound in interface org.bukkit.entity.Playerpublic void stopSound(@NotNull
@NotNull java.lang.String sound,
org.bukkit.SoundCategory category)
stopSound in interface org.bukkit.entity.Playerpublic void playEffect(@NotNull
@NotNull org.bukkit.Location loc,
@NotNull
@NotNull org.bukkit.Effect effect,
int data)
playEffect in interface org.bukkit.entity.Playerpublic <T> void playEffect(@NotNull
@NotNull org.bukkit.Location loc,
@NotNull
@NotNull org.bukkit.Effect effect,
T data)
playEffect in interface org.bukkit.entity.Playerpublic void sendBlockChange(@NotNull
@NotNull org.bukkit.Location loc,
@NotNull
@NotNull org.bukkit.Material material,
byte data)
sendBlockChange in interface org.bukkit.entity.Playerpublic boolean sendChunkChange(@NotNull
@NotNull org.bukkit.Location loc,
int sx,
int sy,
int sz,
byte[] data)
sendChunkChange in interface org.bukkit.entity.Playerpublic void sendSignChange(@NotNull
@NotNull org.bukkit.Location loc,
java.lang.String[] lines)
sendSignChange in interface org.bukkit.entity.Playerpublic void sendMap(@NotNull
@NotNull org.bukkit.map.MapView map)
sendMap in interface org.bukkit.entity.Playerpublic void updateInventory()
updateInventory in interface org.bukkit.entity.Playerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
int amount)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
int amount)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic void setStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
int newValue)
setStatistic in interface org.bukkit.OfflinePlayerpublic int getStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic)
getStatistic in interface org.bukkit.OfflinePlayerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic int getStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material)
getStatistic in interface org.bukkit.OfflinePlayerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material,
int amount)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material,
int amount)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic void setStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.Material material,
int newValue)
setStatistic in interface org.bukkit.OfflinePlayerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic int getStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType)
getStatistic in interface org.bukkit.OfflinePlayerpublic void incrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType,
int amount)
incrementStatistic in interface org.bukkit.OfflinePlayerpublic void decrementStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType,
int amount)
decrementStatistic in interface org.bukkit.OfflinePlayerpublic void setStatistic(@NotNull
@NotNull org.bukkit.Statistic statistic,
@NotNull
@NotNull org.bukkit.entity.EntityType entityType,
int newValue)
setStatistic in interface org.bukkit.OfflinePlayerpublic void setPlayerTime(long time,
boolean relative)
setPlayerTime in interface org.bukkit.entity.Playerpublic long getPlayerTime()
getPlayerTime in interface org.bukkit.entity.Playerpublic long getPlayerTimeOffset()
getPlayerTimeOffset in interface org.bukkit.entity.Playerpublic boolean isPlayerTimeRelative()
isPlayerTimeRelative in interface org.bukkit.entity.Playerpublic void resetPlayerTime()
resetPlayerTime in interface org.bukkit.entity.Playerpublic void setPlayerWeather(@NotNull
@NotNull org.bukkit.WeatherType type)
setPlayerWeather in interface org.bukkit.entity.Playerpublic org.bukkit.WeatherType getPlayerWeather()
getPlayerWeather in interface org.bukkit.entity.Playerpublic void resetPlayerWeather()
resetPlayerWeather in interface org.bukkit.entity.Playerpublic void giveExp(int amount)
giveExp in interface org.bukkit.entity.Playerpublic void giveExpLevels(int amount)
giveExpLevels in interface org.bukkit.entity.Playerpublic float getExp()
getExp in interface org.bukkit.entity.Playerpublic void setExp(float exp)
setExp in interface org.bukkit.entity.Playerpublic int getLevel()
getLevel in interface org.bukkit.entity.Playerpublic void setLevel(int level)
setLevel in interface org.bukkit.entity.Playerpublic int getTotalExperience()
getTotalExperience in interface org.bukkit.entity.Playerpublic void setTotalExperience(int exp)
setTotalExperience in interface org.bukkit.entity.Playerpublic float getExhaustion()
getExhaustion in interface org.bukkit.entity.HumanEntitypublic void setExhaustion(float value)
setExhaustion in interface org.bukkit.entity.HumanEntitypublic float getSaturation()
getSaturation in interface org.bukkit.entity.HumanEntitypublic void setSaturation(float value)
setSaturation in interface org.bukkit.entity.HumanEntitypublic int getFoodLevel()
getFoodLevel in interface org.bukkit.entity.HumanEntitypublic void setFoodLevel(int foodLevel)
setFoodLevel in interface org.bukkit.entity.HumanEntity@Nullable public @Nullable org.bukkit.Location getBedSpawnLocation()
getBedSpawnLocation in interface org.bukkit.entity.PlayergetBedSpawnLocation in interface org.bukkit.OfflinePlayerpublic void setBedSpawnLocation(@Nullable
@Nullable org.bukkit.Location loc)
setBedSpawnLocation in interface org.bukkit.entity.Playerpublic void setBedSpawnLocation(@Nullable
@Nullable org.bukkit.Location loc,
boolean force)
setBedSpawnLocation in interface org.bukkit.entity.Playerpublic boolean getAllowFlight()
getAllowFlight in interface org.bukkit.entity.Playerpublic void setAllowFlight(boolean flight)
setAllowFlight in interface org.bukkit.entity.Player@Deprecated
public void hidePlayer(@NotNull
@NotNull org.bukkit.entity.Player player)
hidePlayer in interface org.bukkit.entity.Playerpublic void hidePlayer(@NotNull
@NotNull org.bukkit.plugin.Plugin plugin,
@NotNull
@NotNull org.bukkit.entity.Player player)
hidePlayer in interface org.bukkit.entity.Player@Deprecated
public void showPlayer(@NotNull
@NotNull org.bukkit.entity.Player player)
showPlayer in interface org.bukkit.entity.Playerpublic void showPlayer(@NotNull
@NotNull org.bukkit.plugin.Plugin plugin,
@NotNull
@NotNull org.bukkit.entity.Player player)
showPlayer in interface org.bukkit.entity.Playerpublic boolean canSee(@NotNull
@NotNull org.bukkit.entity.Player player)
canSee in interface org.bukkit.entity.Playerpublic boolean isFlying()
isFlying in interface org.bukkit.entity.Playerpublic void setFlying(boolean value)
setFlying in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.event.player.PlayerToggleFlightEvent simulateToggleFlight(boolean fly)
public void setFlySpeed(float value)
setFlySpeed in interface org.bukkit.entity.Playerpublic void setWalkSpeed(float value)
setWalkSpeed in interface org.bukkit.entity.Playerpublic float getFlySpeed()
getFlySpeed in interface org.bukkit.entity.Playerpublic float getWalkSpeed()
getWalkSpeed in interface org.bukkit.entity.Player@Deprecated
public void setTexturePack(@NotNull
@NotNull java.lang.String url)
setTexturePack in interface org.bukkit.entity.Playerpublic void setResourcePack(@NotNull
@NotNull java.lang.String url)
setResourcePack in interface org.bukkit.entity.Playerpublic void setResourcePack(@NotNull
@NotNull java.lang.String url,
byte[] hash)
setResourcePack in interface org.bukkit.entity.Player@NotNull public @NotNull org.bukkit.scoreboard.Scoreboard getScoreboard()
getScoreboard in interface org.bukkit.entity.Playerpublic void setScoreboard(@NotNull
@NotNull org.bukkit.scoreboard.Scoreboard scoreboard)
setScoreboard in interface org.bukkit.entity.Playerpublic void setHealth(double health)
setHealth in interface org.bukkit.entity.DamageablesetHealth in class LivingEntityMockpublic boolean isHealthScaled()
isHealthScaled in interface org.bukkit.entity.Playerpublic void setHealthScaled(boolean scale)
setHealthScaled in interface org.bukkit.entity.Playerpublic void setHealthScale(double scale)
setHealthScale in interface org.bukkit.entity.Playerpublic double getHealthScale()
getHealthScale in interface org.bukkit.entity.Playerpublic org.bukkit.entity.Entity getSpectatorTarget()
getSpectatorTarget in interface org.bukkit.entity.Playerpublic void setSpectatorTarget(org.bukkit.entity.Entity entity)
setSpectatorTarget in interface org.bukkit.entity.Playerpublic void sendTitle(java.lang.String title,
java.lang.String subtitle)
sendTitle in interface org.bukkit.entity.Playerpublic void sendTitle(java.lang.String title,
java.lang.String subtitle,
int fadeIn,
int stay,
int fadeOut)
sendTitle in interface org.bukkit.entity.Playerpublic void resetTitle()
resetTitle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count)
spawnParticle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count,
T data)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
T data)
spawnParticle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ)
spawnParticle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
T data)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
T data)
spawnParticle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra)
spawnParticle in interface org.bukkit.entity.Playerpublic void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
@NotNull
@NotNull org.bukkit.Location location,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra,
T data)
spawnParticle in interface org.bukkit.entity.Playerpublic <T> void spawnParticle(@NotNull
@NotNull org.bukkit.Particle particle,
double x,
double y,
double z,
int count,
double offsetX,
double offsetY,
double offsetZ,
double extra,
T data)
spawnParticle in interface org.bukkit.entity.Player@NotNull
public @NotNull org.bukkit.advancement.AdvancementProgress getAdvancementProgress(@NotNull
@NotNull org.bukkit.advancement.Advancement advancement)
getAdvancementProgress in interface org.bukkit.entity.Player@NotNull public @NotNull java.lang.String getLocale()
getLocale in interface org.bukkit.entity.Playerpublic boolean isSwimming()
isSwimming in interface org.bukkit.entity.LivingEntityisSwimming in class LivingEntityMockpublic void setSwimming(boolean swimming)
setSwimming in interface org.bukkit.entity.LivingEntitysetSwimming in class LivingEntityMockpublic boolean isRiptiding()
isRiptiding in interface org.bukkit.entity.LivingEntityisRiptiding in class LivingEntityMockpublic boolean isPersistent()
isPersistent in interface org.bukkit.entity.EntityisPersistent in class EntityMockpublic void setPersistent(boolean persistent)
setPersistent in interface org.bukkit.entity.EntitysetPersistent in class EntityMockpublic java.lang.String getPlayerListHeader()
getPlayerListHeader in interface org.bukkit.entity.Playerpublic java.lang.String getPlayerListFooter()
getPlayerListFooter in interface org.bukkit.entity.Playerpublic void setPlayerListHeader(java.lang.String header)
setPlayerListHeader in interface org.bukkit.entity.Playerpublic void setPlayerListFooter(java.lang.String footer)
setPlayerListFooter in interface org.bukkit.entity.Playerpublic void setPlayerListHeaderFooter(java.lang.String header,
java.lang.String footer)
setPlayerListHeaderFooter in interface org.bukkit.entity.Playerpublic void sendBlockChange(@NotNull
@NotNull org.bukkit.Location loc,
@NotNull
@NotNull org.bukkit.block.data.BlockData block)
sendBlockChange in interface org.bukkit.entity.Playerpublic void updateCommands()
updateCommands in interface org.bukkit.entity.Playerpublic boolean discoverRecipe(@NotNull
@NotNull org.bukkit.NamespacedKey recipe)
discoverRecipe in interface org.bukkit.entity.HumanEntitypublic int discoverRecipes(@NotNull
@NotNull java.util.Collection<org.bukkit.NamespacedKey> recipes)
discoverRecipes in interface org.bukkit.entity.HumanEntitypublic boolean undiscoverRecipe(@NotNull
@NotNull org.bukkit.NamespacedKey recipe)
undiscoverRecipe in interface org.bukkit.entity.HumanEntitypublic int undiscoverRecipes(@NotNull
@NotNull java.util.Collection<org.bukkit.NamespacedKey> recipes)
undiscoverRecipes in interface org.bukkit.entity.HumanEntitypublic org.bukkit.block.Block getTargetBlockExact(int maxDistance)
getTargetBlockExact in interface org.bukkit.entity.LivingEntitygetTargetBlockExact in class LivingEntityMockpublic org.bukkit.block.Block getTargetBlockExact(int maxDistance,
@NotNull
@NotNull org.bukkit.FluidCollisionMode fluidCollisionMode)
getTargetBlockExact in interface org.bukkit.entity.LivingEntitygetTargetBlockExact in class LivingEntityMockpublic org.bukkit.util.RayTraceResult rayTraceBlocks(double maxDistance)
rayTraceBlocks in interface org.bukkit.entity.LivingEntityrayTraceBlocks in class LivingEntityMockpublic org.bukkit.util.RayTraceResult rayTraceBlocks(double maxDistance,
@NotNull
@NotNull org.bukkit.FluidCollisionMode fluidCollisionMode)
rayTraceBlocks in interface org.bukkit.entity.LivingEntityrayTraceBlocks in class LivingEntityMock@NotNull public @NotNull org.bukkit.util.BoundingBox getBoundingBox()
getBoundingBox in interface org.bukkit.entity.EntitygetBoundingBox in class EntityMock@NotNull public @NotNull org.bukkit.block.BlockFace getFacing()
getFacing in interface org.bukkit.entity.EntitygetFacing in class EntityMockpublic int getClientViewDistance()
getClientViewDistance in interface org.bukkit.entity.Playerpublic boolean sleep(@NotNull
@NotNull org.bukkit.Location location,
boolean force)
sleep in interface org.bukkit.entity.HumanEntitypublic void wakeup(boolean setSpawnLocation)
wakeup in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull org.bukkit.Location getBedLocation()
getBedLocation in interface org.bukkit.entity.HumanEntitypublic <T> T getMemory(@NotNull
@NotNull org.bukkit.entity.memory.MemoryKey<T> memoryKey)
getMemory in interface org.bukkit.entity.LivingEntitypublic <T> void setMemory(@NotNull
@NotNull org.bukkit.entity.memory.MemoryKey<T> memoryKey,
T memoryValue)
setMemory in interface org.bukkit.entity.LivingEntitypublic double getAbsorptionAmount()
getAbsorptionAmount in interface org.bukkit.entity.Damageablepublic void setAbsorptionAmount(double amount)
setAbsorptionAmount in interface org.bukkit.entity.Damageable@NotNull public @NotNull org.bukkit.entity.Pose getPose()
getPose in interface org.bukkit.entity.EntitygetPose in class EntityMockpublic void sendSignChange(@NotNull
@NotNull org.bukkit.Location loc,
java.lang.String[] lines,
@NotNull
@NotNull org.bukkit.DyeColor dyeColor)
throws java.lang.IllegalArgumentException
sendSignChange in interface org.bukkit.entity.Playerjava.lang.IllegalArgumentExceptionpublic void openBook(@NotNull
@NotNull org.bukkit.inventory.ItemStack book)
openBook in interface org.bukkit.entity.Playerpublic void attack(@NotNull
@NotNull org.bukkit.entity.Entity target)
attack in interface org.bukkit.entity.LivingEntitypublic void swingMainHand()
swingMainHand in interface org.bukkit.entity.LivingEntitypublic void swingOffHand()
swingOffHand in interface org.bukkit.entity.LivingEntitypublic void sendExperienceChange(float progress)
sendExperienceChange in interface org.bukkit.entity.Playerpublic void sendExperienceChange(float progress,
int level)
sendExperienceChange in interface org.bukkit.entity.Playerpublic float getAttackCooldown()
getAttackCooldown in interface org.bukkit.entity.HumanEntitypublic boolean hasDiscoveredRecipe(@NotNull
@NotNull org.bukkit.NamespacedKey recipe)
hasDiscoveredRecipe in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull java.util.Set<org.bukkit.NamespacedKey> getDiscoveredRecipes()
getDiscoveredRecipes in interface org.bukkit.entity.HumanEntitypublic boolean dropItem(boolean dropAll)
dropItem in interface org.bukkit.entity.HumanEntity@NotNull public @NotNull java.util.Set<java.util.UUID> getCollidableExemptions()
getCollidableExemptions in interface org.bukkit.entity.LivingEntitypublic void sendBlockDamage(@NotNull
@NotNull org.bukkit.Location loc,
float progress)
sendBlockDamage in interface org.bukkit.entity.Playerpublic int getSaturatedRegenRate()
getSaturatedRegenRate in interface org.bukkit.entity.HumanEntitypublic void setSaturatedRegenRate(int ticks)
setSaturatedRegenRate in interface org.bukkit.entity.HumanEntitypublic int getUnsaturatedRegenRate()
getUnsaturatedRegenRate in interface org.bukkit.entity.HumanEntitypublic void setUnsaturatedRegenRate(int ticks)
setUnsaturatedRegenRate in interface org.bukkit.entity.HumanEntitypublic int getStarvationRate()
getStarvationRate in interface org.bukkit.entity.HumanEntitypublic void setStarvationRate(int ticks)
setStarvationRate in interface org.bukkit.entity.HumanEntitypublic int getPing()
getPing in interface org.bukkit.entity.Playerpublic boolean teleport(@NotNull
@NotNull org.bukkit.Location location,
@NotNull
org.bukkit.event.player.PlayerTeleportEvent.TeleportCause cause)
teleport in interface org.bukkit.entity.Entityteleport in class EntityMock@NotNull public @NotNull PlayerMock.PlayerSpigotMock spigot()
spigot in interface org.bukkit.command.CommandSenderspigot in interface org.bukkit.entity.Entityspigot in interface org.bukkit.entity.Playerspigot in class EntityMock