Package org.bukkit.entity
Interface Llama
- All Superinterfaces:
AbstractHorse
,Ageable
,Animals
,Attributable
,Audience
,Breedable
,ChestedHorse
,CommandSender
,Creature
,Damageable
,Entity
,Frictional
,HoverEventSource<HoverEvent.ShowEntity>
,InventoryHolder
,LivingEntity
,Lootable
,Metadatable
,Mob
,Nameable
,Permissible
,PersistentDataHolder
,Pointered
,ProjectileSource
,RangedEntity
,ServerOperator
,Sound.Emitter
,Tameable
,Vehicle
- All Known Subinterfaces:
TraderLlama
Represents a Llama.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
Represents the base color that the llama has.Nested classes/interfaces inherited from interface org.bukkit.entity.Entity
Entity.Spigot
-
Method Summary
Modifier and TypeMethodDescriptionGet the llama that this llama is following.Gets the llama that is currently following behind this llama.getColor()
Gets the llama's color.Get the object's inventory.int
Gets the llama's strength.boolean
Checks if another llama is currently following behind this llama.boolean
Checks if this llama is in a caravan.void
joinCaravan
(@NotNull Llama llama) Joins a caravan, with the provided llama being the leader of the caravan.void
Leaves the current caravan that they are in.void
setColor
(@NotNull Llama.Color color) Sets the llama's color.void
setStrength
(int strength) Sets the llama's strength.Methods inherited from interface org.bukkit.entity.AbstractHorse
getDomestication, getJumpStrength, getMaxDomestication, getVariant, isEating, isEatingGrass, isEatingHaystack, isRearing, setDomestication, setEating, setEatingGrass, setEatingHaystack, setJumpStrength, setMaxDomestication, setRearing, setVariant
Methods inherited from interface org.bukkit.entity.Ageable
getAge, isAdult, setAdult, setAge, setBaby
Methods inherited from interface org.bukkit.entity.Animals
getBreedCause, getLoveModeTicks, isBreedItem, isBreedItem, isLoveMode, setBreedCause, setLoveModeTicks
Methods inherited from interface org.bukkit.attribute.Attributable
getAttribute, registerAttribute
Methods inherited from interface net.kyori.adventure.audience.Audience
clearTitle, deleteMessage, deleteMessage, filterAudience, forEachAudience, hideBossBar, openBook, openBook, playSound, playSound, playSound, resetTitle, sendActionBar, sendActionBar, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlayerListFooter, sendPlayerListFooter, sendPlayerListHeader, sendPlayerListHeader, sendPlayerListHeaderAndFooter, sendPlayerListHeaderAndFooter, sendTitlePart, showBossBar, showTitle, stopSound, stopSound
Methods inherited from interface org.bukkit.entity.Breedable
canBreed, getAgeLock, setAgeLock, setBreed
Methods inherited from interface org.bukkit.entity.ChestedHorse
isCarryingChest, setCarryingChest
Methods inherited from interface org.bukkit.command.CommandSender
getName, name, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlainMessage, sendRichMessage
Methods inherited from interface org.bukkit.entity.Damageable
damage, damage, getAbsorptionAmount, getHealth, getMaxHealth, resetMaxHealth, setAbsorptionAmount, setHealth, setMaxHealth
Methods inherited from interface org.bukkit.entity.Entity
addPassenger, addScoreboardTag, asHoverEvent, collidesAt, eject, fromMobSpawner, getBoundingBox, getChunk, getEntityId, getEntitySpawnReason, getFacing, getFallDistance, getFireTicks, getFreezeTicks, getHeight, getLastDamageCause, getLocation, getLocation, getMaxFireTicks, getMaxFreezeTicks, getNearbyEntities, getOrigin, getPassenger, getPassengers, getPistonMoveReaction, getPortalCooldown, getPose, getScheduler, getScoreboardTags, getServer, getSpawnCategory, getSwimHighSpeedSplashSound, getSwimSound, getSwimSplashSound, getTicksLived, getTrackedPlayers, getType, getUniqueId, getVehicle, getWidth, getWorld, hasGravity, isCustomNameVisible, isDead, isEmpty, isFreezeTickingLocked, isFrozen, isGlowing, isInBubbleColumn, isInLava, isInPowderedSnow, isInRain, isInsideVehicle, isInvulnerable, isInWater, isInWaterOrBubbleColumn, isInWaterOrRain, isInWaterOrRainOrBubbleColumn, isOnGround, isPersistent, isSilent, isSneaking, isTicking, isUnderWater, isValid, isVisibleByDefault, isVisualFire, leaveVehicle, lockFreezeTicks, playEffect, remove, removePassenger, removeScoreboardTag, setCustomNameVisible, setFallDistance, setFireTicks, setFreezeTicks, setGlowing, setGravity, setInvulnerable, setLastDamageCause, setPassenger, setPersistent, setPortalCooldown, setRotation, setSilent, setSneaking, setTicksLived, setVisibleByDefault, setVisualFire, spawnAt, spawnAt, spigot, teamDisplayName, teleport, teleport, teleport, teleport, teleport, teleport, teleportAsync, teleportAsync, wouldCollideUsing
Methods inherited from interface io.papermc.paper.entity.Frictional
getFrictionState, setFrictionState
Methods inherited from interface net.kyori.adventure.text.event.HoverEventSource
asHoverEvent
Methods inherited from interface org.bukkit.entity.LivingEntity
addPotionEffect, addPotionEffect, addPotionEffects, attack, broadcastSlotBreak, broadcastSlotBreak, canBreatheUnderwater, clearActiveItem, damageItemStack, damageItemStack, getActiveItem, getActivePotionEffects, getArrowCooldown, getArrowsInBody, getArrowsStuck, getBeeStingerCooldown, getBeeStingersInBody, getBodyYaw, getCanPickupItems, getCategory, getCollidableExemptions, getDeathSound, getDrinkingSound, getEatingSound, getEyeHeight, getEyeHeight, getEyeLocation, getFallDamageSound, getFallDamageSoundBig, getFallDamageSoundSmall, getHandRaised, getHandRaisedTime, getHurtDirection, getHurtSound, getItemUseRemainingTime, getKiller, getLastDamage, getLastTwoTargetBlocks, getLeashHolder, getLineOfSight, getMaximumAir, getMaximumNoDamageTicks, getMemory, getNoDamageTicks, getPotionEffect, getRemainingAir, getRemoveWhenFarAway, getShieldBlockingDelay, getTargetBlock, getTargetBlock, getTargetBlock, getTargetBlockExact, getTargetBlockExact, getTargetBlockFace, getTargetBlockFace, getTargetBlockFace, getTargetBlockInfo, getTargetBlockInfo, getTargetEntity, getTargetEntity, getTargetEntityInfo, getTargetEntityInfo, hasAI, hasLineOfSight, hasLineOfSight, hasPotionEffect, isClimbing, isCollidable, isGliding, isHandRaised, isInvisible, isJumping, isLeashed, isRiptiding, isSleeping, isSwimming, knockback, playPickupItemAnimation, playPickupItemAnimation, rayTraceBlocks, rayTraceBlocks, rayTraceEntities, rayTraceEntities, removePotionEffect, setAI, setArrowCooldown, setArrowsInBody, setArrowsInBody, setArrowsStuck, setBeeStingerCooldown, setBeeStingersInBody, setBodyYaw, setCanPickupItems, setCollidable, setGliding, setHurtDirection, setInvisible, setJumping, setKiller, setLastDamage, setLeashHolder, setMaximumAir, setMaximumNoDamageTicks, setMemory, setNoDamageTicks, setRemainingAir, setRemoveWhenFarAway, setShieldBlockingDelay, setSwimming, swingHand, swingMainHand, swingOffHand
Methods inherited from interface org.bukkit.loot.Lootable
clearLootTable, getLootTable, getSeed, hasLootTable, setLootTable, setLootTable, setSeed
Methods inherited from interface org.bukkit.metadata.Metadatable
getMetadata, hasMetadata, removeMetadata, setMetadata
Methods inherited from interface org.bukkit.entity.Mob
getAmbientSound, getEquipment, getHeadRotationSpeed, getMaxHeadPitch, getPathfinder, getTarget, isAware, isInDaylight, isLeftHanded, lookAt, lookAt, lookAt, lookAt, lookAt, lookAt, setAware, setLeftHanded, setTarget
Methods inherited from interface org.bukkit.Nameable
customName, customName, getCustomName, setCustomName
Methods inherited from interface org.bukkit.permissions.Permissible
addAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, permissionValue, permissionValue, recalculatePermissions, removeAttachment
Methods inherited from interface org.bukkit.persistence.PersistentDataHolder
getPersistentDataContainer
Methods inherited from interface net.kyori.adventure.pointer.Pointered
get, getOrDefault, getOrDefaultFrom, pointers
Methods inherited from interface org.bukkit.projectiles.ProjectileSource
launchProjectile, launchProjectile, launchProjectile
Methods inherited from interface com.destroystokyo.paper.entity.RangedEntity
isChargingAttack, rangedAttack, setChargingAttack
Methods inherited from interface org.bukkit.permissions.ServerOperator
isOp, setOp
Methods inherited from interface org.bukkit.entity.Tameable
getOwner, getOwnerUniqueId, isTamed, setOwner, setTamed
Methods inherited from interface org.bukkit.entity.Vehicle
getVelocity, setVelocity
-
Method Details
-
getColor
Gets the llama's color.- Returns:
- a
Llama.Color
representing the llama's color
-
setColor
Sets the llama's color.- Parameters:
color
- aLlama.Color
for this llama
-
getStrength
int getStrength()Gets the llama's strength. A higher strength llama will have more inventory slots and be more threatening to entities.- Returns:
- llama strength [1,5]
-
setStrength
void setStrength(int strength) Sets the llama's strength. A higher strength llama will have more inventory slots and be more threatening to entities. Inventory slots are equal to strength * 3.- Parameters:
strength
- llama strength [1,5]
-
getInventory
Description copied from interface:InventoryHolder
Get the object's inventory.- Specified by:
getInventory
in interfaceAbstractHorse
- Specified by:
getInventory
in interfaceInventoryHolder
- Returns:
- The inventory.
-
inCaravan
boolean inCaravan()Checks if this llama is in a caravan. This means that this llama is currently following another llama.- Returns:
- is in caravan
-
joinCaravan
Joins a caravan, with the provided llama being the leader of the caravan. This llama will then follow the provided llama.- Parameters:
llama
- head of caravan to join
-
leaveCaravan
void leaveCaravan()Leaves the current caravan that they are in. -
getCaravanHead
Get the llama that this llama is following.Does not necessarily mean the leader of the entire caravan.
- Returns:
- the llama currently being followed
-
hasCaravanTail
boolean hasCaravanTail()Checks if another llama is currently following behind this llama.- Returns:
- true if being followed in the caravan
-
getCaravanTail
Gets the llama that is currently following behind this llama.- Returns:
- the llama following this llama, or null if none is following them
-