Interface EntityAccessor

All Known Subinterfaces:
World

public interface EntityAccessor
  • Method Details

    • nearbyEntities

      default List<Entity> nearbyEntities(me.moros.math.Vector3d pos, double radius)
      Collects all entities in a sphere.
      Parameters:
      pos - the center point
      radius - the radius of the sphere
      Returns:
      all collected entities
      See Also:
    • nearbyEntities

      default List<Entity> nearbyEntities(me.moros.math.Vector3d pos, double radius, Predicate<Entity> predicate)
      Collects all entities in a sphere that satisfy the given predicate.
      Parameters:
      pos - the center point
      radius - the radius of the sphere
      predicate - the predicate that needs to be satisfied for every block
      Returns:
      all collected entities
      See Also:
    • nearbyEntities

      default List<Entity> nearbyEntities(me.moros.math.Vector3d pos, double radius, Predicate<Entity> predicate, int limit)
      Collects all entities in a sphere that satisfy the given predicate.

      Note: Limit is only respected if positive. Otherwise, all entities that satisfy the given predicate are collected.

      Parameters:
      pos - the center point
      radius - the radius of the sphere
      predicate - the predicate that needs to be satisfied for every block
      limit - the amount of entities to collect
      Returns:
      all collected entities
      See Also:
    • nearbyEntities

      default List<Entity> nearbyEntities(AABB box)
      Collects all entities inside a bounding box.
      Parameters:
      box - the bounding box to check
      Returns:
      all collected entities
      See Also:
    • nearbyEntities

      default List<Entity> nearbyEntities(AABB box, Predicate<Entity> predicate)
      Collects all entities inside a bounding box that satisfy the given predicate.
      Parameters:
      box - the bounding box to check
      predicate - the predicate that needs to be satisfied for every block
      Returns:
      all collected entities
      See Also:
    • nearbyEntities

      List<Entity> nearbyEntities(AABB box, Predicate<Entity> predicate, int limit)
      Collects all entities inside a bounding box that satisfy the given predicate.

      Note: Limit is only respected if positive. Otherwise, all entities that satisfy the given predicate are collected.

      Parameters:
      box - the bounding box to check
      predicate - the predicate that needs to be satisfied for every block
      limit - the amount of entities to collect
      Returns:
      all collected entities
      See Also: