Class AbstractPiglin

All Implemented Interfaces:
CommandSource, Attackable, Enemy, Targeting, EntityAccess, Nameable, ScoreHolder, ICapabilityProvider, ICapabilityProviderImpl<Entity>, ICapabilitySerializable<CompoundTag>, IForgeEntity, IForgeLivingEntity, INBTSerializable<CompoundTag>
Direct Known Subclasses:
Piglin, PiglinBrute

public abstract class AbstractPiglin extends Monster
  • Field Details

    • DATA_IMMUNE_TO_ZOMBIFICATION

      protected static final EntityDataAccessor<Boolean> DATA_IMMUNE_TO_ZOMBIFICATION
    • CONVERSION_TIME

      protected static final int CONVERSION_TIME
      See Also:
    • PIGLIN_EYE_HEIGHT

      protected static final float PIGLIN_EYE_HEIGHT
      See Also:
    • timeInOverworld

      protected int timeInOverworld
  • Constructor Details

  • Method Details

    • applyOpenDoorsAbility

      private void applyOpenDoorsAbility()
    • getStandingEyeHeight

      protected float getStandingEyeHeight(Pose p_259213_, EntityDimensions p_259279_)
      Overrides:
      getStandingEyeHeight in class LivingEntity
    • ridingOffset

      protected float ridingOffset(Entity p_298545_)
      Overrides:
      ridingOffset in class Entity
    • getPassengerAttachmentPoint

      protected org.joml.Vector3f getPassengerAttachmentPoint(Entity p_297937_, EntityDimensions p_301042_, float p_299996_)
      Overrides:
      getPassengerAttachmentPoint in class Entity
    • canHunt

      protected abstract boolean canHunt()
    • setImmuneToZombification

      public void setImmuneToZombification(boolean p_34671_)
    • isImmuneToZombification

      protected boolean isImmuneToZombification()
    • defineSynchedData

      protected void defineSynchedData()
      Overrides:
      defineSynchedData in class Mob
    • addAdditionalSaveData

      public void addAdditionalSaveData(CompoundTag p_34661_)
      Overrides:
      addAdditionalSaveData in class Mob
    • readAdditionalSaveData

      public void readAdditionalSaveData(CompoundTag p_34659_)
      Overrides:
      readAdditionalSaveData in class Mob
    • customServerAiStep

      protected void customServerAiStep()
      Overrides:
      customServerAiStep in class Mob
    • isConverting

      public boolean isConverting()
    • finishConversion

      protected void finishConversion(ServerLevel p_34663_)
    • isAdult

      public boolean isAdult()
    • getArmPose

      public abstract PiglinArmPose getArmPose()
    • getTarget

      @Nullable public LivingEntity getTarget()
      Specified by:
      getTarget in interface Targeting
      Overrides:
      getTarget in class Mob
    • isHoldingMeleeWeapon

      protected boolean isHoldingMeleeWeapon()
    • playAmbientSound

      public void playAmbientSound()
      Overrides:
      playAmbientSound in class Mob
    • sendDebugPackets

      protected void sendDebugPackets()
      Overrides:
      sendDebugPackets in class Mob
    • playConvertedSound

      protected abstract void playConvertedSound()