Class HappyGhastEntity

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

public class HappyGhastEntity extends AnimalEntity implements ClientVehicle
  • Field Details

    • X_OFFSETS

      public static final float[] X_OFFSETS
    • Z_OFFSETS

      public static final float[] Z_OFFSETS
    • CAN_MOVE_PROPERTY

      public static final BooleanProperty CAN_MOVE_PROPERTY
  • Constructor Details

    • HappyGhastEntity

      public HappyGhastEntity(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

    • initializeMetadata

      protected void initializeMetadata()
      Description copied from class: Entity
      Called on entity spawn. Used to populate the entity metadata and flags with default values.
      Overrides:
      initializeMetadata in class AgeableEntity
    • 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.
    • getBabySize

      protected float getBabySize()
      Description copied from class: AgeableEntity
      The scale that should be used when this entity is a baby.
      Overrides:
      getBabySize in class AgeableEntity
    • getAdultSize

      protected float getAdultSize()
      Description copied from class: AgeableEntity
      The scale that should be used when this entity is not a baby.
      Overrides:
      getAdultSize in class AgeableEntity
    • setBaby

      public void setBaby(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.BooleanEntityMetadata entityMetadata)
      Overrides:
      setBaby in class AgeableEntity
    • setStaysStill

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

      protected @NonNull InteractiveTag testMobInteraction(@NonNull org.geysermc.mcprotocollib.protocol.data.game.entity.player.Hand hand, @NonNull GeyserItemStack itemInHand)
      Overrides:
      testMobInteraction in class AnimalEntity
    • mobInteract

      protected @NonNull InteractionResult mobInteract(@NonNull org.geysermc.mcprotocollib.protocol.data.game.entity.player.Hand hand, @NonNull GeyserItemStack itemInHand)
      Overrides:
      mobInteract in class AnimalEntity
    • getVehicleComponent

      public VehicleComponent<?> getVehicleComponent()
      Specified by:
      getVehicleComponent in interface ClientVehicle
    • getRiddenInput

      public org.cloudburstmc.math.vector.Vector3f getRiddenInput(org.cloudburstmc.math.vector.Vector2f input)
      Specified by:
      getRiddenInput in interface ClientVehicle
    • getVehicleSpeed

      public float getVehicleSpeed()
      Specified by:
      getVehicleSpeed in interface ClientVehicle
    • isClientControlled

      public boolean isClientControlled()
      Specified by:
      isClientControlled in interface ClientVehicle
    • updateAttribute

      protected void updateAttribute(org.geysermc.mcprotocollib.protocol.data.game.entity.attribute.Attribute javaAttribute, List<org.cloudburstmc.protocol.bedrock.data.AttributeData> newAttributes)
      Description copied from class: LivingEntity
      Takes the Java attribute and adds it to newAttributes as a Bedrock-formatted attribute
      Overrides:
      updateAttribute in class LivingEntity
    • canUseSlot

      protected boolean canUseSlot(org.geysermc.mcprotocollib.protocol.data.game.entity.EquipmentSlot slot)
      Overrides:
      canUseSlot in class LivingEntity