Class HoglinEntity

All Implemented Interfaces:
org.geysermc.geyser.api.entity.type.GeyserEntity, Leashable

public class HoglinEntity extends AnimalEntity
  • Constructor Details

    • HoglinEntity

      public HoglinEntity(GeyserSession session, int entityId, long geyserId, UUID uuid, EntityDefinition<?> definition, org.cloudburstmc.math.vector.Vector3f position, org.cloudburstmc.math.vector.Vector3f motion, float yaw, float pitch, float headYaw)
  • Method Details

    • setImmuneToZombification

      public void setImmuneToZombification(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.BooleanEntityMetadata entityMetadata)
    • isShaking

      protected boolean isShaking()
      Description copied from class: Entity
      If true, the entity should be shaking on the client's end.
      Overrides:
      isShaking in class LivingEntity
      Returns:
      whether EntityFlag.SHAKING should be set to true.
    • getFoodTag

      protected @Nullable Tag<Item> getFoodTag()
      Specified by:
      getFoodTag in class AnimalEntity
      Returns:
      the tag associated with this animal for eating food. Null for nothing or different behavior.
    • canBeLeashed

      public boolean canBeLeashed()
      Specified by:
      canBeLeashed in interface Leashable
      Overrides:
      canBeLeashed in class MobEntity
    • isEnemy

      protected boolean isEnemy()
      Description copied from class: MobEntity
      Returns if the entity is hostile. Used to determine if it can be leashed.
      Overrides:
      isEnemy in class MobEntity
    • useArmSwingAttack

      public boolean useArmSwingAttack()
      Description copied from class: LivingEntity
      Called when a SWING_ARM animation packet is received
      Overrides:
      useArmSwingAttack in class LivingEntity
      Returns:
      true if an ATTACK_START event should be used instead