Class EntityPredicates

java.lang.Object
net.minecraft.predicate.entity.EntityPredicates

public final class EntityPredicates
extends Object
  • Field Details

    • VALID_ENTITY

      public static final Predicate<Entity> VALID_ENTITY
      Tests if an entity is valid.

      An entity is valid when the entity is alive.

      See Also:
      Entity.isAlive()
    • VALID_LIVING_ENTITY

      public static final Predicate<LivingEntity> VALID_LIVING_ENTITY
      Tests if a living entity is valid.

      A living entity is valid when the entity is alive.

      See Also:
      LivingEntity.isAlive()
    • NOT_MOUNTED

      public static final Predicate<Entity> NOT_MOUNTED
      Tests if an entity is not mounted.

      An entity is not mounted when:

      • The entity is alive
      • The entity has no passengers
      • The entity is not in a vehicle
    • VALID_INVENTORIES

      public static final Predicate<Entity> VALID_INVENTORIES
      Tests if an entity has a valid inventory.

      An entity has a valid inventory when:

      • The entity is alive
      • The entity implements Inventory
      See Also:
      StorageMinecartEntity
    • EXCEPT_CREATIVE_OR_SPECTATOR

      public static final Predicate<Entity> EXCEPT_CREATIVE_OR_SPECTATOR
    • EXCEPT_CREATIVE_SPECTATOR_OR_PEACEFUL

      public static final Predicate<Entity> EXCEPT_CREATIVE_SPECTATOR_OR_PEACEFUL
    • EXCEPT_SPECTATOR

      public static final Predicate<Entity> EXCEPT_SPECTATOR
  • Constructor Details

    • EntityPredicates

      public EntityPredicates()
  • Method Details