public interface Tameable extends Entity
Entity.Spigot
Modifier and Type | Method and Description |
---|---|
AnimalTamer |
getOwner()
Gets the current owning AnimalTamer
|
UUID |
getOwnerUniqueId()
Gets the owners UUID
|
boolean |
isTamed()
Check if this is tamed
|
void |
setOwner(AnimalTamer tamer)
Set this to be owned by given AnimalTamer.
|
void |
setTamed(boolean tame)
Sets if this has been tamed.
|
addPassenger, addScoreboardTag, eject, fromMobSpawner, getChunk, getEntityId, getFallDistance, getFireTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getNearbyEntities, getOrigin, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getScoreboardTags, getServer, getTicksLived, getType, getUniqueId, getVehicle, getVelocity, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isGlowing, isInsideVehicle, isInvulnerable, isOnGround, isSilent, isValid, leaveVehicle, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPortalCooldown, setSilent, setTicksLived, setVelocity, spigot, teleport, teleport, teleport, teleport
getMetadata, hasMetadata, removeMetadata, setMetadata
getName, sendMessage, sendMessage, sendMessage, sendMessage
addAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, recalculatePermissions, removeAttachment
isOp, setOp
getCustomName, setCustomName
boolean isTamed()
If something is tamed then a player can not tame it through normal methods, even if it does not belong to anyone in particular.
void setTamed(boolean tame)
If something is tamed then a player can not tame it through normal methods, even if it does not belong to anyone in particular.
tame
- true if tameUUID getOwnerUniqueId()
AnimalTamer getOwner()
Recommended to use UUID version instead of this for performance.
This method will cause OfflinePlayer to be loaded from disk if the owner is not online.
void setOwner(AnimalTamer tamer)
If the owner is not null, this will be tamed and will have any current path it is following removed. If the owner is set to null, this will be untamed, and the current owner removed.
tamer
- the AnimalTamer who should own thisCopyright © 2021. All rights reserved.