Class MobEntity

    • Field Detail

      • DATA_MOB_FLAGS_ID

        private static final DataParameter<java.lang.Byte> DATA_MOB_FLAGS_ID
      • ambientSoundTime

        public int ambientSoundTime
      • xpReward

        protected int xpReward
      • bodyRotationControl

        private final BodyController bodyRotationControl
      • handDropChances

        protected final float[] handDropChances
      • armorDropChances

        protected final float[] armorDropChances
      • canPickUpLoot

        private boolean canPickUpLoot
      • persistenceRequired

        private boolean persistenceRequired
      • pathfindingMalus

        private final java.util.Map<PathNodeType,​java.lang.Float> pathfindingMalus
      • lootTableSeed

        private long lootTableSeed
      • leashHolder

        @Nullable
        private Entity leashHolder
      • delayedLeashHolderId

        private int delayedLeashHolderId
      • leashInfoTag

        @Nullable
        private CompoundNBT leashInfoTag
      • restrictCenter

        private BlockPos restrictCenter
      • restrictRadius

        private float restrictRadius
    • Method Detail

      • registerGoals

        protected void registerGoals()
      • shouldPassengersInheritMalus

        protected boolean shouldPassengersInheritMalus()
      • getPathfindingMalus

        public float getPathfindingMalus​(PathNodeType p_184643_1_)
      • setPathfindingMalus

        public void setPathfindingMalus​(PathNodeType p_184644_1_,
                                        float p_184644_2_)
      • canCutCorner

        public boolean canCutCorner​(PathNodeType p_233660_1_)
      • setTarget

        public void setTarget​(@Nullable
                              LivingEntity p_70624_1_)
      • canFireProjectileWeapon

        public boolean canFireProjectileWeapon​(ShootableItem p_230280_1_)
      • ate

        public void ate()
      • getAmbientSoundInterval

        public int getAmbientSoundInterval()
      • playAmbientSound

        public void playAmbientSound()
      • resetAmbientSoundTime

        private void resetAmbientSoundTime()
      • spawnAnim

        public void spawnAnim()
      • updateControlFlags

        protected void updateControlFlags()
      • tickHeadTurn

        protected float tickHeadTurn​(float p_110146_1_,
                                     float p_110146_2_)
        Overrides:
        tickHeadTurn in class LivingEntity
      • getAmbientSound

        @Nullable
        protected SoundEvent getAmbientSound()
      • setZza

        public void setZza​(float p_191989_1_)
      • setYya

        public void setYya​(float p_70657_1_)
      • setXxa

        public void setXxa​(float p_184646_1_)
      • pickUpItem

        protected void pickUpItem​(ItemEntity p_175445_1_)
      • equipItemIfPossible

        public boolean equipItemIfPossible​(ItemStack p_233665_1_)
      • setItemSlotAndDropWhenKilled

        protected void setItemSlotAndDropWhenKilled​(EquipmentSlotType p_233657_1_,
                                                    ItemStack p_233657_2_)
      • setGuaranteedDrop

        public void setGuaranteedDrop​(EquipmentSlotType p_233663_1_)
      • canReplaceCurrentItem

        protected boolean canReplaceCurrentItem​(ItemStack p_208003_1_,
                                                ItemStack p_208003_2_)
      • canReplaceEqualItem

        public boolean canReplaceEqualItem​(ItemStack p_233659_1_,
                                           ItemStack p_233659_2_)
      • canHoldItem

        public boolean canHoldItem​(ItemStack p_175448_1_)
      • wantsToPickUp

        public boolean wantsToPickUp​(ItemStack p_230293_1_)
      • removeWhenFarAway

        public boolean removeWhenFarAway​(double p_213397_1_)
      • requiresCustomPersistence

        public boolean requiresCustomPersistence()
      • shouldDespawnInPeaceful

        protected boolean shouldDespawnInPeaceful()
      • sendDebugPackets

        protected void sendDebugPackets()
      • customServerAiStep

        protected void customServerAiStep()
      • getMaxHeadXRot

        public int getMaxHeadXRot()
      • getMaxHeadYRot

        public int getMaxHeadYRot()
      • getHeadRotSpeed

        public int getHeadRotSpeed()
      • lookAt

        public void lookAt​(Entity p_70625_1_,
                           float p_70625_2_,
                           float p_70625_3_)
      • rotlerp

        private float rotlerp​(float p_70663_1_,
                              float p_70663_2_,
                              float p_70663_3_)
      • checkSpawnRules

        public boolean checkSpawnRules​(IWorld p_213380_1_,
                                       SpawnReason p_213380_2_)
      • checkSpawnObstruction

        public boolean checkSpawnObstruction​(IWorldReader p_205019_1_)
      • getMaxSpawnClusterSize

        public int getMaxSpawnClusterSize()
      • isMaxGroupSizeReached

        public boolean isMaxGroupSizeReached​(int p_204209_1_)
      • getEquipmentDropChance

        protected float getEquipmentDropChance​(EquipmentSlotType p_205712_1_)
      • populateDefaultEquipmentSlots

        protected void populateDefaultEquipmentSlots​(DifficultyInstance p_180481_1_)
      • getEquipmentForSlot

        @Nullable
        public static Item getEquipmentForSlot​(EquipmentSlotType p_184636_0_,
                                               int p_184636_1_)
      • populateDefaultEquipmentEnchantments

        protected void populateDefaultEquipmentEnchantments​(DifficultyInstance p_180483_1_)
      • enchantSpawnedWeapon

        protected void enchantSpawnedWeapon​(float p_241844_1_)
      • enchantSpawnedArmor

        protected void enchantSpawnedArmor​(float p_242289_1_,
                                           EquipmentSlotType p_242289_2_)
      • canBeControlledByRider

        public boolean canBeControlledByRider()
      • setPersistenceRequired

        public void setPersistenceRequired()
      • setDropChance

        public void setDropChance​(EquipmentSlotType p_184642_1_,
                                  float p_184642_2_)
      • canPickUpLoot

        public boolean canPickUpLoot()
      • setCanPickUpLoot

        public void setCanPickUpLoot​(boolean p_98053_1_)
      • isPersistenceRequired

        public boolean isPersistenceRequired()
      • onOffspringSpawnedFromEgg

        protected void onOffspringSpawnedFromEgg​(PlayerEntity p_213406_1_,
                                                 MobEntity p_213406_2_)
      • isWithinRestriction

        public boolean isWithinRestriction()
      • isWithinRestriction

        public boolean isWithinRestriction​(BlockPos p_213389_1_)
      • restrictTo

        public void restrictTo​(BlockPos p_213390_1_,
                               int p_213390_2_)
      • getRestrictCenter

        public BlockPos getRestrictCenter()
      • getRestrictRadius

        public float getRestrictRadius()
      • hasRestriction

        public boolean hasRestriction()
      • convertTo

        @Nullable
        public <T extends MobEntity> T convertTo​(EntityType<T> p_233656_1_,
                                                 boolean p_233656_2_)
      • tickLeash

        protected void tickLeash()
      • dropLeash

        public void dropLeash​(boolean p_110160_1_,
                              boolean p_110160_2_)
      • canBeLeashed

        public boolean canBeLeashed​(PlayerEntity p_184652_1_)
      • isLeashed

        public boolean isLeashed()
      • getLeashHolder

        @Nullable
        public Entity getLeashHolder()
      • setLeashedTo

        public void setLeashedTo​(Entity p_110162_1_,
                                 boolean p_110162_2_)
      • setDelayedLeashHolderId

        public void setDelayedLeashHolderId​(int p_213381_1_)
      • startRiding

        public boolean startRiding​(Entity p_184205_1_,
                                   boolean p_184205_2_)
        Overrides:
        startRiding in class Entity
      • restoreLeashFromSave

        private void restoreLeashFromSave()
      • setSlot

        public boolean setSlot​(int p_174820_1_,
                               ItemStack p_174820_2_)
        Overrides:
        setSlot in class Entity
      • setNoAi

        public void setNoAi​(boolean p_94061_1_)
      • setLeftHanded

        public void setLeftHanded​(boolean p_184641_1_)
      • setAggressive

        public void setAggressive​(boolean p_213395_1_)
      • isNoAi

        public boolean isNoAi()
      • isLeftHanded

        public boolean isLeftHanded()
      • isAggressive

        public boolean isAggressive()
      • setBaby

        public void setBaby​(boolean p_82227_1_)
      • isSunBurnTick

        protected boolean isSunBurnTick()