public abstract class AbstractHorse extends EntityAnimal implements IInventoryChangedListener, IJumpingMount
Modifier and Type | Field and Description |
---|---|
protected boolean |
canGallop |
protected int |
gallopTime |
protected ContainerHorseChest |
horseChest |
protected boolean |
horseJumping |
protected static IAttribute |
JUMP_STRENGTH |
protected float |
jumpPower |
int |
sprintCounter |
int |
tailCounter |
protected int |
temper |
spawnableBlock
forcedAge, forcedAgeTimer, growingAge
experienceValue, inventoryArmorDropChances, inventoryHandsDropChances, jumpHelper, livingSoundTime, lookHelper, moveHelper, navigator, targetTasks, tasks
activeItemStack, activeItemStackUseCount, arrowHitTimer, attackedAtYaw, attackingPlayer, cameraPitch, dead, deathTime, field_208001_bq, field_208002_br, hurtTime, idleTime, interpTargetPitch, interpTargetX, interpTargetY, interpTargetYaw, interpTargetZ, isJumping, isSwingInProgress, jumpMovementFactor, lastDamage, limbSwing, limbSwingAmount, LIVING_FLAGS, maxHurtResistantTime, maxHurtTime, movedDistance, moveForward, moveStrafing, moveVertical, NAMETAG_DISTANCE, newPosRotationIncrements, onGroundSpeedFactor, prevCameraPitch, prevLimbSwingAmount, prevMovedDistance, prevOnGroundSpeedFactor, prevRenderYawOffset, prevRotationYawHead, prevSwingProgress, randomUnused1, randomUnused2, randomYawVelocity, recentlyHit, renderYawOffset, rotationYawHead, scoreValue, spinAttackDuration, SWIM_SPEED, swingingHand, swingProgress, swingProgressInt, ticksElytraFlying, ticksSinceLastSwing, unused180
addedToChunk, cachedUniqueIdString, chunkCoordX, chunkCoordY, chunkCoordZ, collided, collidedHorizontally, collidedVertically, dataManager, dimension, distanceWalkedModified, distanceWalkedOnStepModified, entityCollisionReduction, entityUniqueID, eyesInWater, fallDistance, firstUpdate, FLAGS, forceSpawn, glowing, height, hurtResistantTime, ignoreFrustumCheck, inPortal, inWater, isAirBorne, isImmuneToFire, isInWeb, lastPortalPos, lastPortalVec, lastTickPosX, lastTickPosY, lastTickPosZ, motionX, motionY, motionZ, noClip, onGround, portalCounter, posX, posY, posZ, prevDistanceWalkedModified, preventEntitySpawning, prevPosX, prevPosY, prevPosZ, prevRotationPitch, prevRotationYaw, rand, removed, rideCooldown, rotationPitch, rotationYaw, serverPosX, serverPosY, serverPosZ, stepHeight, submergedHeight, teleportDirection, ticksExisted, timeUntilPortal, velocityChanged, width, world
Modifier | Constructor and Description |
---|---|
protected |
AbstractHorse(EntityType<?> type,
World p_i48563_2_) |
Modifier and Type | Method and Description |
---|---|
boolean |
attackEntityFrom(DamageSource source,
float amount) |
boolean |
canBeLeashedTo(EntityPlayer player) |
boolean |
canBePushed() |
boolean |
canBeSaddled() |
boolean |
canBeSteered() |
boolean |
canEatGrass() |
boolean |
canJump() |
protected boolean |
canMate() |
boolean |
canMateWith(EntityAnimal otherAnimal) |
EntityAgeable |
createChild(EntityAgeable ageable) |
void |
fall(float distance,
float damageMultiplier) |
protected void |
followMother() |
protected void |
func_205714_dM() |
protected void |
func_205715_ee() |
protected SoundEvent |
getAmbientSound() |
protected SoundEvent |
getAngrySound() |
<T> LazyOptional<T> |
getCapability(Capability<T> capability,
EnumFacing facing)
Retrieves the Optional handler for the capability requested on the specific side.
|
protected AbstractHorse |
getClosestHorse(Entity entityIn,
double distance) |
Entity |
getControllingPassenger() |
protected SoundEvent |
getDeathSound() |
float |
getEyeHeight() |
float |
getGrassEatingAmount(float p_110258_1_) |
double |
getHorseJumpStrength() |
float |
getHorseSize() |
protected boolean |
getHorseWatchableBoolean(int p_110233_1_) |
protected SoundEvent |
getHurtSound(DamageSource damageSourceIn) |
protected int |
getInventorySize() |
int |
getMaxSpawnedInChunk() |
int |
getMaxTemper() |
protected double |
getModifiedJumpStrength() |
protected float |
getModifiedMaxHealth() |
protected double |
getModifiedMovementSpeed() |
float |
getMouthOpennessAngle(float p_110201_1_) |
java.util.UUID |
getOwnerUniqueId() |
float |
getRearingAmount(float p_110223_1_) |
protected float |
getSoundVolume() |
int |
getTalkInterval() |
int |
getTemper() |
protected boolean |
handleEating(EntityPlayer player,
ItemStack stack) |
void |
handleStartJump(int p_184775_1_) |
void |
handleStatusUpdate(byte id) |
void |
handleStopJump() |
int |
increaseTemper(int p_110198_1_) |
protected void |
initEntityAI() |
protected void |
initHorseChest() |
boolean |
isArmor(ItemStack stack) |
boolean |
isBreeding() |
boolean |
isBreedingItem(ItemStack stack) |
boolean |
isEatingHaystack() |
boolean |
isHorseJumping() |
boolean |
isHorseSaddled() |
protected boolean |
isMovementBlocked() |
boolean |
isOnLadder() |
boolean |
isRearing() |
boolean |
isTame() |
void |
livingTick() |
void |
makeMad() |
protected void |
mountTo(EntityPlayer player) |
void |
onDeath(DamageSource cause) |
IEntityLivingData |
onInitialSpawn(DifficultyInstance difficulty,
IEntityLivingData entityLivingData,
NBTTagCompound itemNbt) |
void |
onInventoryChanged(IInventory invBasic) |
protected void |
onLeashDistance(float p_142017_1_) |
void |
openGUI(EntityPlayer playerEntity) |
protected void |
playGallopSound(SoundType p_190680_1_) |
protected void |
playStepSound(BlockPos pos,
IBlockState blockIn) |
void |
readAdditional(NBTTagCompound compound) |
protected void |
registerAttributes() |
protected void |
registerData() |
void |
remove(boolean keepData) |
boolean |
replaceItemInInventory(int inventorySlot,
ItemStack itemStackIn) |
void |
setBreeding(boolean breeding) |
void |
setEatingHaystack(boolean p_110227_1_) |
void |
setHorseJumping(boolean jumping) |
void |
setHorseSaddled(boolean saddled) |
void |
setHorseTamed(boolean tamed) |
protected void |
setHorseWatchableBoolean(int p_110208_1_,
boolean p_110208_2_) |
void |
setJumpPower(int jumpPowerIn) |
protected void |
setOffspringAttributes(EntityAgeable p_190681_1_,
AbstractHorse p_190681_2_) |
void |
setOwnerUniqueId(java.util.UUID uniqueId) |
void |
setRearing(boolean rearing) |
void |
setScaleForAge(boolean child) |
boolean |
setTamedBy(EntityPlayer player) |
void |
setTemper(int temperIn) |
protected void |
spawnHorseParticles(boolean p_110216_1_) |
void |
tick() |
void |
travel(float strafe,
float vertical,
float forward) |
protected void |
updateHorseSlots() |
void |
updatePassenger(Entity passenger) |
boolean |
wearsArmor() |
void |
writeAdditional(NBTTagCompound compound) |
canBreed, canDespawn, canSpawn, consumeItemFromStack, func_204700_e, getBlockPathWeight, getExperiencePoints, getLoveCause, getYOffset, isInLove, processInteract, resetInLove, setInLove, updateAITasks
addGrowth, ageUp, getGrowingAge, isChild, notifyDataManagerChange, onGrowingAdult, setGrowingAge, setScale, setSize
detachHome, followLeashSpeed, getBlockPathWeight, getHomePosition, getMaximumHomeDistance, hasHome, hasPath, isWithinHomeDistanceCurrentPosition, isWithinHomeDistanceFromPosition, setHomePosAndDistance, updateLeashedState
attackEntityAsMob, baseTick, canAttackClass, canEquipItem, canPassengerSteer, canPickUpLoot, checkDespawn, clearLeashed, createBodyHelper, createNavigator, dropEquipment, dropFewItems, dropLoot, eatGrassBonus, enablePersistence, faceEntity, func_204209_c, getArmorByChance, getArmorInventoryList, getAttackTarget, getDropChance, getDropItem, getEntitySenses, getHeldEquipment, getHorizontalFaceSpeed, getItemStackFromSlot, getJumpHelper, getLeashed, getLeashHolder, getLookHelper, getLootTable, getMaxFallHeight, getMoveHelper, getNavigator, getPathPriority, getPrimaryHand, getRenderSizeModifier, getSlotForItemStack, getVerticalFaceSpeed, handleFluidJump, isAIDisabled, isInDaylight, isItemStackInSlot, isLeftHanded, isNoDespawnRequired, isNotColliding, isNotColliding, isServerWorld, playAmbientSound, playHurtSound, processInitialInteract, setAIMoveSpeed, setAttackTarget, setCanPickUpLoot, setDropChance, setEnchantmentBasedOnDifficulty, setEquipmentBasedOnDifficulty, setItemStackToSlot, setLeashHolder, setLeftHanded, setMoveForward, setMoveStrafing, setMoveVertical, setNoAI, setPathPriority, shouldExchangeEquipment, spawnExplosionParticle, startRiding, updateDistance, updateEntityActionState, updateEquipmentIfNeeded
addPotionEffect, applyArmorCalculations, applyPotionDamageCalculations, areAllPotionsAmbient, attackable, attemptTeleport, blockUsingShield, canBeCollidedWith, canBeHitWithPotion, canBeRiddenInWater, canBreatheUnderwater, canDropLoot, canEntityBeSeen, collideWithEntity, collideWithNearbyEntities, curePotionEffects, damageArmor, damageEntity, damageShield, decreaseAirSupply, determineNextAir, dismountEntity, frostWalk, func_195061_cb, func_203010_cG, getAbsorptionAmount, getActiveHand, getActiveItemStack, getActivePotionEffect, getActivePotionEffects, getActivePotionMap, getAIMoveSpeed, getAlwaysRenderNameTagForRender, getArrowCountInEntity, getAttackingEntity, getAttribute, getAttributeMap, getCombatTracker, getCreatureAttribute, getFallSound, getHealth, getHeldItem, getHeldItemMainhand, getHeldItemOffhand, getIdleTime, getItemInUseCount, getItemInUseMaxCount, getJumpUpwardsMotion, getLastAttackedEntity, getLastAttackedEntityTime, getLastDamageSource, getMaxHealth, getRevengeTarget, getRevengeTimer, getRNG, getRotationYawHead, getSoundPitch, getSwimAnimation, getSwingProgress, getTicksElytraFlying, getTotalArmorValue, getWaterSlowDown, getYaw, hasItemInSlot, heal, isActiveItemStackBlocking, isAlive, isElytraFlying, isEntityUndead, isHandActive, isPlayer, isPlayerSleeping, isPotionActive, isPotionApplicable, isSpinAttacking, jump, knockBack, lerp, lookAt, markPotionsDirty, markVelocityChanged, moveRelative, onChangedPotionEffect, onDeathUpdate, onFinishedPotionEffect, onItemPickup, onItemUseFinish, onKillCommand, onNewPotionEffect, outOfWorld, performHurtAnimation, playEquipSound, removeActivePotionEffect, removePotionEffect, renderBrokenItemStack, resetActiveHand, resetPotionEffectMetadata, sendEndCombat, sendEnterCombat, setAbsorptionAmount, setActiveHand, setArrowCountInEntity, setHeadRotation, setHealth, setHeldItem, setJumping, setLastAttackedEntity, setLivingFlag, setPartying, setPositionAndRotationDirect, setRenderYawOffset, setRevengeTarget, setRotationYawHead, setSprinting, shouldRiderFaceForward, spinAttack, startSpinAttack, stopActiveHand, stopRiding, swingArm, updateActiveHand, updateArmSwingProgress, updateFallState, updateItemUse, updatePotionEffects, updatePotionMetadata, updateRidden, updateSpinAttack
addPassenger, addTag, addTrackingPlayer, addVelocity, allowLogging, applyEnchantments, applyEntityCollision, applyOrientationToEntity, applyPlayerInteraction, areEyesInFluid, awardKillScore, canBeAttackedWithItem, canBeRidden, canExplosionDestroyBlock, canFitPassenger, canRenderOnFire, canSwim, canTrample, canTriggerWalking, canUpdate, canUpdate, captureDrops, captureDrops, changeDimension, copyDataFromOld, copyLocationAndAnglesFrom, createRunningParticles, dealFireDamage, decrementTimeUntilPortal, determineNextStepDistance, doBlockCollisions, doesEntityNotTriggerPressurePlate, doWaterSplashEffect, entityDropItem, entityDropItem, entityDropItem, entityDropItem, equals, extinguish, fillCrashReport, func_212321_a, getAdjustedHorizontalFacing, getAir, getBoundingBox, getBrightness, getBrightnessForRender, getCachedUniqueIdString, getCollisionBorderSize, getCollisionBoundingBox, getCollisionBox, getCommandSource, getCustomName, getDataManager, getDisplayName, getDistance, getDistance, getDistanceSq, getDistanceSq, getDistanceSq, getDistanceSq, getDistanceSqToCenter, getEntityData, getEntityId, getEntityString, getEntityWorld, getEquipmentAndArmor, getExplosionResistance, getEyePosition, getFireImmuneTicks, getFlag, getForward, getHighspeedSplashSound, getHorizontalFacing, getHoverEvent, getLastPortalVec, getLook, getLookVec, getLowestRidingEntity, getMaxAir, getMaxInPortalTime, getMirroredYaw, getMountedYOffset, getName, getParts, getPassengers, getPermissionLevel, getPitch, getPitchYaw, getPortalCooldown, getPosition, getPositionVector, getPushReaction, getRecursivePassengers, getRenderBoundingBox, getRenderDistanceWeight, getRidingEntity, getRotatedYaw, getScoreboardName, getServer, getSoundCategory, getSplashSound, getSubmergedHeight, getSwimSound, getTags, getTeam, getTeleportDirection, getType, getUniqueID, getVectorForRotation, handleFluidAcceleration, handleWaterMovement, hasCustomName, hashCode, hasNoGravity, hasPermissionLevel, hitByEntity, ignoreItemEntityData, isAddedToWorld, isBeingRidden, isBurning, isCustomNameVisible, isEntityEqual, isEntityInsideOpaqueBlock, isGlowing, isImmuneToExplosions, isImmuneToFire, isInLava, isInRangeToRender3d, isInRangeToRenderDist, isInvisible, isInvisibleToPlayer, isInvulnerable, isInvulnerableTo, isInWater, isInWaterOrBubbleColumn, isInWaterRainOrBubbleColumn, isLiving, isNonBoss, isOffsetPositionInLiquid, isOnePlayerRiding, isOnSameTeam, isOnScoreboardTeam, isOutsideBorder, isPassenger, isPassenger, isPassenger, isPushedByWater, isRidingOrBeingRiddenBy, isRidingSameEntity, isSilent, isSneaking, isSpectatedByPlayer, isSprinting, isSwimming, isWet, makeFlySound, move, moveToBlockPosAndAngles, newDoubleNBTList, newFloatNBTList, onAddedToWorld, onCollideWithPlayer, onEnterBubbleColumn, onEnterBubbleColumnWithAirAbove, onInsideBlock, onKillEntity, onRemovedFromWorld, onStruckByLightning, playFlySound, playSound, playSwimSound, preparePlayerToSpawn, pushOutOfBlocks, rayTrace, read, remove, removePassenger, removePassengers, removeTag, removeTrackingPlayer, resetPositionToBB, revive, rotateTowards, sendMessage, setAir, setBoundingBox, setCustomName, setCustomNameVisible, setDropItemsWhenDead, setEntityId, setFire, setFlag, setGlowing, setInvisible, setInvulnerable, setInWeb, setLocationAndAngles, setNoGravity, setOnFireFromLava, setOutsideBorder, setPortal, setPosition, setPositionAndRotation, setPositionAndUpdate, setPositionNonDirty, setRenderDistanceWeight, setRotation, setSilent, setSneaking, setSwimming, setUniqueId, setVelocity, setWorld, shouldReceiveErrors, shouldReceiveFeedback, shouldSetPosAfterLoading, spawnRunningParticles, startRiding, toString, updateSwimming, writeUnlessPassenger, writeUnlessRemoved, writeWithoutTypeId
areCapsCompatible, areCapsCompatible, deserializeCaps, gatherCapabilities, gatherCapabilities, getCapabilities, invalidateCaps, reviveCaps, serializeCaps
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
canBeRiddenInWater, canRiderInteract, deserializeNBT, getEntity, getPickedResult, isCreatureType, serializeNBT, shouldRenderInPass, shouldRiderSit
getCapability
protected static final IAttribute JUMP_STRENGTH
public int tailCounter
public int sprintCounter
protected boolean horseJumping
protected ContainerHorseChest horseChest
protected int temper
protected float jumpPower
protected boolean canGallop
protected int gallopTime
protected AbstractHorse(EntityType<?> type, World p_i48563_2_)
protected void initEntityAI()
initEntityAI
in class EntityLiving
protected void func_205714_dM()
protected void registerData()
registerData
in class EntityAgeable
protected boolean getHorseWatchableBoolean(int p_110233_1_)
protected void setHorseWatchableBoolean(int p_110208_1_, boolean p_110208_2_)
public boolean isTame()
@Nullable public java.util.UUID getOwnerUniqueId()
public void setOwnerUniqueId(@Nullable java.util.UUID uniqueId)
public float getHorseSize()
public void setScaleForAge(boolean child)
setScaleForAge
in class EntityAgeable
public boolean isHorseJumping()
public void setHorseTamed(boolean tamed)
public void setHorseJumping(boolean jumping)
public boolean canBeLeashedTo(EntityPlayer player)
canBeLeashedTo
in class EntityLiving
protected void onLeashDistance(float p_142017_1_)
onLeashDistance
in class EntityCreature
public boolean isEatingHaystack()
public boolean isRearing()
public boolean isBreeding()
public void setBreeding(boolean breeding)
public void setHorseSaddled(boolean saddled)
public int getTemper()
public void setTemper(int temperIn)
public int increaseTemper(int p_110198_1_)
public boolean attackEntityFrom(DamageSource source, float amount)
attackEntityFrom
in class EntityAnimal
public boolean canBePushed()
canBePushed
in class EntityLivingBase
public void fall(float distance, float damageMultiplier)
fall
in class EntityLivingBase
protected int getInventorySize()
protected void initHorseChest()
protected void updateHorseSlots()
public void onInventoryChanged(IInventory invBasic)
onInventoryChanged
in interface IInventoryChangedListener
@Nullable protected AbstractHorse getClosestHorse(Entity entityIn, double distance)
public double getHorseJumpStrength()
@Nullable protected SoundEvent getDeathSound()
getDeathSound
in class EntityLivingBase
@Nullable protected SoundEvent getHurtSound(DamageSource damageSourceIn)
getHurtSound
in class EntityLivingBase
@Nullable protected SoundEvent getAmbientSound()
getAmbientSound
in class EntityLiving
public boolean canBeSaddled()
public boolean isHorseSaddled()
@Nullable protected SoundEvent getAngrySound()
protected void playStepSound(BlockPos pos, IBlockState blockIn)
playStepSound
in class Entity
protected void playGallopSound(SoundType p_190680_1_)
protected void registerAttributes()
registerAttributes
in class EntityLiving
public int getMaxSpawnedInChunk()
getMaxSpawnedInChunk
in class EntityLiving
public int getMaxTemper()
protected float getSoundVolume()
getSoundVolume
in class EntityLivingBase
public int getTalkInterval()
getTalkInterval
in class EntityAnimal
public void openGUI(EntityPlayer playerEntity)
protected boolean handleEating(EntityPlayer player, ItemStack stack)
protected void mountTo(EntityPlayer player)
protected boolean isMovementBlocked()
isMovementBlocked
in class EntityLivingBase
public boolean isBreedingItem(ItemStack stack)
isBreedingItem
in class EntityAnimal
public void onDeath(DamageSource cause)
onDeath
in class EntityLivingBase
public void livingTick()
livingTick
in class EntityAnimal
protected void followMother()
public boolean canEatGrass()
public void tick()
tick
in class EntityLiving
public void setEatingHaystack(boolean p_110227_1_)
public void setRearing(boolean rearing)
public void makeMad()
public boolean setTamedBy(EntityPlayer player)
public void travel(float strafe, float vertical, float forward)
travel
in class EntityLivingBase
protected void func_205715_ee()
public void writeAdditional(NBTTagCompound compound)
writeAdditional
in class EntityAnimal
public void readAdditional(NBTTagCompound compound)
readAdditional
in class EntityAnimal
public boolean canMateWith(EntityAnimal otherAnimal)
canMateWith
in class EntityAnimal
protected boolean canMate()
@Nullable public EntityAgeable createChild(EntityAgeable ageable)
createChild
in class EntityAgeable
protected void setOffspringAttributes(EntityAgeable p_190681_1_, AbstractHorse p_190681_2_)
public boolean canBeSteered()
canBeSteered
in class EntityLiving
public float getGrassEatingAmount(float p_110258_1_)
public float getRearingAmount(float p_110223_1_)
public float getMouthOpennessAngle(float p_110201_1_)
public void setJumpPower(int jumpPowerIn)
setJumpPower
in interface IJumpingMount
public boolean canJump()
canJump
in interface IJumpingMount
public void handleStartJump(int p_184775_1_)
handleStartJump
in interface IJumpingMount
public void handleStopJump()
handleStopJump
in interface IJumpingMount
protected void spawnHorseParticles(boolean p_110216_1_)
public void handleStatusUpdate(byte id)
handleStatusUpdate
in class EntityAnimal
public void updatePassenger(Entity passenger)
updatePassenger
in class Entity
protected float getModifiedMaxHealth()
protected double getModifiedJumpStrength()
protected double getModifiedMovementSpeed()
public boolean isOnLadder()
isOnLadder
in class EntityLivingBase
public float getEyeHeight()
getEyeHeight
in class Entity
public boolean wearsArmor()
public boolean isArmor(ItemStack stack)
public boolean replaceItemInInventory(int inventorySlot, ItemStack itemStackIn)
replaceItemInInventory
in class EntityLiving
@Nullable public Entity getControllingPassenger()
getControllingPassenger
in class Entity
@Nullable public IEntityLivingData onInitialSpawn(DifficultyInstance difficulty, @Nullable IEntityLivingData entityLivingData, @Nullable NBTTagCompound itemNbt)
onInitialSpawn
in class EntityLiving
public <T> LazyOptional<T> getCapability(Capability<T> capability, @Nullable EnumFacing facing)
ICapabilityProvider
getCapability
in interface ICapabilityProvider
getCapability
in class EntityLivingBase
public void remove(boolean keepData)
remove
in class EntityLivingBase