Interface AbstractHorse
- All Superinterfaces:
- Ageable,- Animals,- Attributable,- Audience,- Breedable,- CommandSender,- Creature,- Damageable,- Entity,- Frictional,- HoverEventSource<HoverEvent.ShowEntity>,- InventoryHolder,- LivingEntity,- Lootable,- Metadatable,- Mob,- Nameable,- Permissible,- PersistentDataHolder,- Pointered,- ProjectileSource,- ServerOperator,- Sound.Emitter,- Tameable,- Vehicle
- All Known Subinterfaces:
- Camel,- ChestedHorse,- Donkey,- Horse,- Llama,- Mule,- SkeletonHorse,- TraderLlama,- ZombieHorse
- 
Nested Class SummaryNested classes/interfaces inherited from interface org.bukkit.entity.EntityEntity.Spigot
- 
Method SummaryModifier and TypeMethodDescriptionintGets the domestication level of this horse.Get the object's inventory.doubleGets the jump strength of this horse.intGets the maximum domestication level of this horse.Deprecated.different variants are different classesbooleanisEating()Gets if a horse is in their eating animation.booleanGets if a horse is in their eating grass animation.booleanDeprecated.useisEatingGrass(), this name is incorrectbooleanGets if a horse is in their rearing animation.voidsetDomestication(int level) Sets the domestication level of this horse.voidsetEating(boolean eating) Sets if a horse is in their eating animation.voidsetEatingGrass(boolean eating) Sets if a horse is in their eating grass animation.voidsetEatingHaystack(boolean eatingHaystack) Deprecated.usesetEatingGrass(boolean), this name is incorrectvoidsetJumpStrength(double strength) Sets the jump strength of this horse.voidsetMaxDomestication(int level) Sets the maximum domestication level of this horse.voidsetRearing(boolean rearing) Sets if a horse is in their rearing animation.voidsetVariant(Horse.Variant variant) Deprecated.you are required to spawn a different entityMethods inherited from interface org.bukkit.entity.AgeablegetAge, isAdult, setAdult, setAge, setBabyMethods inherited from interface org.bukkit.entity.AnimalsgetBreedCause, getLoveModeTicks, isBreedItem, isBreedItem, isLoveMode, setBreedCause, setLoveModeTicksMethods inherited from interface org.bukkit.attribute.AttributablegetAttribute, registerAttributeMethods inherited from interface net.kyori.adventure.audience.AudienceclearTitle, 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, stopSoundMethods inherited from interface org.bukkit.entity.BreedablecanBreed, getAgeLock, setAgeLock, setBreedMethods inherited from interface org.bukkit.command.CommandSendergetName, name, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlainMessage, sendRichMessageMethods inherited from interface org.bukkit.entity.Damageabledamage, damage, getAbsorptionAmount, getHealth, getMaxHealth, resetMaxHealth, setAbsorptionAmount, setHealth, setMaxHealthMethods inherited from interface org.bukkit.entity.EntityaddPassenger, 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, 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, wouldCollideUsingMethods inherited from interface io.papermc.paper.entity.FrictionalgetFrictionState, setFrictionStateMethods inherited from interface net.kyori.adventure.text.event.HoverEventSourceasHoverEventMethods inherited from interface org.bukkit.entity.LivingEntityaddPotionEffect, 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, swingOffHandMethods inherited from interface org.bukkit.loot.LootableclearLootTable, getLootTable, getSeed, hasLootTable, setLootTable, setLootTable, setSeedMethods inherited from interface org.bukkit.metadata.MetadatablegetMetadata, hasMetadata, removeMetadata, setMetadataMethods inherited from interface org.bukkit.entity.MobgetAmbientSound, getEquipment, getHeadRotationSpeed, getMaxHeadPitch, getPathfinder, getPossibleExperienceReward, getTarget, isAware, isInDaylight, isLeftHanded, lookAt, lookAt, lookAt, lookAt, lookAt, lookAt, setAware, setLeftHanded, setTargetMethods inherited from interface org.bukkit.NameablecustomName, customName, getCustomName, setCustomNameMethods inherited from interface org.bukkit.permissions.PermissibleaddAttachment, addAttachment, addAttachment, addAttachment, getEffectivePermissions, hasPermission, hasPermission, isPermissionSet, isPermissionSet, permissionValue, permissionValue, recalculatePermissions, removeAttachmentMethods inherited from interface org.bukkit.persistence.PersistentDataHoldergetPersistentDataContainerMethods inherited from interface net.kyori.adventure.pointer.Pointeredget, getOrDefault, getOrDefaultFrom, pointersMethods inherited from interface org.bukkit.projectiles.ProjectileSourcelaunchProjectile, launchProjectile, launchProjectileMethods inherited from interface org.bukkit.permissions.ServerOperatorisOp, setOpMethods inherited from interface org.bukkit.entity.TameablegetOwner, getOwnerUniqueId, isTamed, setOwner, setTamedMethods inherited from interface org.bukkit.entity.VehiclegetVelocity, setVelocity
- 
Method Details- 
getVariantDeprecated.different variants are different classesGets the horse's variant.A horse's variant defines its physical appearance and capabilities. Whether a horse is a regular horse, donkey, mule, or other kind of horse is determined using the variant. - Returns:
- a Horse.Variantrepresenting the horse's variant
 
- 
setVariantDeprecated.you are required to spawn a different entity- Parameters:
- variant- variant
 
- 
getDomesticationint getDomestication()Gets the domestication level of this horse.A higher domestication level indicates that the horse is closer to becoming tame. As the domestication level gets closer to the max domestication level, the chance of the horse becoming tame increases. - Returns:
- domestication level
 
- 
setDomesticationvoid setDomestication(int level) Sets the domestication level of this horse.Setting the domestication level to a high value will increase the horse's chances of becoming tame. Domestication level must be greater than zero and no greater than the max domestication level of the horse, determined with getMaxDomestication()- Parameters:
- level- domestication level
 
- 
getMaxDomesticationint getMaxDomestication()Gets the maximum domestication level of this horse.The higher this level is, the longer it will likely take for the horse to be tamed. - Returns:
- the max domestication level
 
- 
setMaxDomesticationvoid setMaxDomestication(int level) Sets the maximum domestication level of this horse.Setting a higher max domestication will increase the amount of domesticating (feeding, riding, etc.) necessary in order to tame it, while setting a lower max value will have the opposite effect. Maximum domestication must be greater than zero. - Parameters:
- level- the max domestication level
 
- 
getJumpStrengthdouble getJumpStrength()Gets the jump strength of this horse.Jump strength defines how high the horse can jump. A higher jump strength increases how high a jump will go. - Returns:
- the horse's jump strength
 
- 
setJumpStrengthvoid setJumpStrength(double strength) Sets the jump strength of this horse.A higher jump strength increases how high a jump will go. Setting a jump strength to 0 will result in no jump. You cannot set a jump strength to a value below 0 or above 2. - Parameters:
- strength- jump strength for this horse
 
- 
isEatingHaystackDeprecated.useisEatingGrass(), this name is incorrectGets whether the horse is currently grazing hay.- Returns:
- true if eating hay
 
- 
setEatingHaystackDeprecated.usesetEatingGrass(boolean), this name is incorrectSets whether the horse is grazing hay.- Parameters:
- eatingHaystack- new hay grazing status
 
- 
getInventoryDescription copied from interface:InventoryHolderGet the object's inventory.- Specified by:
- getInventoryin interface- InventoryHolder
- Returns:
- The inventory.
 
- 
isEatingGrassboolean isEatingGrass()Gets if a horse is in their eating grass animation.- Returns:
- eating grass animation is active
 
- 
setEatingGrassvoid setEatingGrass(boolean eating) Sets if a horse is in their eating grass animation.When true, the horse will lower its neck. - Parameters:
- eating- eating grass animation is active
 
- 
isRearingboolean isRearing()Gets if a horse is in their rearing animation.- Returns:
- rearing animation is active
 
- 
setRearingvoid setRearing(boolean rearing) Sets if a horse is in their rearing animation.When true, the horse will stand on its hind legs. - Parameters:
- rearing- rearing animation is active
 
- 
isEatingboolean isEating()Gets if a horse is in their eating animation.- Returns:
- eating animation is active
 
- 
setEatingvoid setEating(boolean eating) Sets if a horse is in their eating animation.When true, the horse will bob its head. - Parameters:
- eating- eating animation is active
 
 
-