Package net.storm.api.entities
Interface ITileObjects
- All Superinterfaces:
EntityProvider<ITileObject>,SceneEntityProvider<ITileObject>,TileEntityProvider<ITileObject>
Provides access to all tile objects in the loaded scene.
This interface extends TileEntityProvider to provide tile object-specific
querying capabilities. Tile objects are static objects placed on tiles in the game
world, and include various types of game objects.
Tile objects encompass several categories:
- Game Objects - Interactive objects like trees, rocks, doors, and furnaces
- Wall Objects - Walls, fences, and boundary objects
- Ground Objects - Floor decorations and ground-level objects
- Decorative Objects - Visual decorations attached to walls or tiles
The provider maintains a cache that is updated when objects spawn, despawn, or change. Large game objects that span multiple tiles are accessible from any tile they occupy.
Example usage:
ITileObjects tileObjects = Static.getTileObjects();
// Find the nearest bank booth
ITileObject booth = tileObjects.getNearest("Bank booth");
// Get all trees in the area
List<ITileObject> trees = tileObjects.getAll("Tree", "Oak tree", "Willow tree");
// Find objects at a specific location
ITileObject door = tileObjects.getFirstAt(worldPoint, "Door");
// Get all objects within a radius
List<ITileObject> nearby = tileObjects.getSurrounding(myLocation, 10, obj -> true);
// Search within a defined area
List<ITileObject> ores = tileObjects.getIn(miningArea, "Rocks");
- See Also:
-
Method Summary
Methods inherited from interface net.storm.api.entities.SceneEntityProvider
getAll, getAll, getAll, getNearest, getNearest, getNearest, getNearest, getNearest, getNearestMethods inherited from interface net.storm.api.entities.TileEntityProvider
getAll, getAt, getAt, getAt, getAt, getAt, getAt, getFirstAt, getFirstAt, getFirstAt, getFirstAt, getFirstAt, getFirstAt, getFirstIn, getFirstIn, getFirstIn, getFirstIn, getFirstSurrounding, getFirstSurrounding, getFirstSurrounding, getFirstSurrounding, getFirstSurrounding, getFirstSurrounding, getIn, getIn, getIn, getNearestIn, getNearestIn, getNearestIn, getSurrounding, getSurrounding, getSurrounding, getSurrounding, getSurrounding, getSurrounding