Class Projectiles

java.lang.Object
com.botwithus.bot.api.entities.Projectiles

public final class Projectiles extends Object
In-flight projectile query facade (v17+). Singleton per GameAPI; obtain via api.projectiles().

Projectiles carry no per-id type definition — the API has no SpotAnimType and NXTCacheLibrary ships no spot-anim decoder — so unlike Npcs / SceneObjects / GroundItems this facade holds no definition cache and EntityQuery.named(String) never matches. Filter on EntityQuery.withId(int) (the graphic id), position, or a predicate.

Queries are anchored on the projectile's impact tile — see the position note on Projectile.

  • Constructor Details

    • Projectiles

      public Projectiles(GameAPI api)
  • Method Details

    • query

      public Projectiles.Query query()
      Start a fluent query.
    • all

      public List<Projectile> all()
      Every in-flight projectile this tick.
    • incoming

      public List<Projectile> incoming()
      Projectiles aimed at the local player. See Projectile.targetsLocalPlayer() for the index-space caveat.
    • nearestIncoming

      public Projectile nearestIncoming()
      The incoming projectile landing nearest the local player, or null when nothing is inbound.