C
- The collision enum type used.R
- The resource enum type used.T
- The tile type used.public abstract class MapTileRts<C extends java.lang.Enum<C>,R extends java.lang.Enum<R>,T extends TileRts<C,R>>
extends com.b3dgs.lionengine.game.map.MapTileGame<C,T>
implements com.b3dgs.lionengine.game.pathfinding.map.MapTilePath<C,T>
Constructor and Description |
---|
MapTileRts(int tileWidth,
int tileHeight)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
create(int widthInTile,
int heightInTile) |
com.b3dgs.lionengine.game.CoordTile |
getClosestAvailableTile(int sx,
int sy,
int radius,
int dx,
int dy) |
com.b3dgs.lionengine.game.CoordTile |
getClosestAvailableTile(com.b3dgs.lionengine.game.Tiled from,
int radius,
com.b3dgs.lionengine.game.Tiled to) |
com.b3dgs.lionengine.game.CoordTile |
getClosestTile(com.b3dgs.lionengine.game.Tiled from,
com.b3dgs.lionengine.game.Tiled to,
C collision,
int radius)
Get the closest tile location around the area.
|
double |
getCost(com.b3dgs.lionengine.game.pathfinding.Pathfindable mover,
int sx,
int sy,
int tx,
int ty) |
com.b3dgs.lionengine.game.CoordTile |
getFreeTileAround(EntityRts entity,
int radius)
Search a free area from this area.
|
com.b3dgs.lionengine.game.CoordTile |
getFreeTileAround(int tx,
int ty,
int radius) |
java.lang.Integer |
getRef(int tx,
int ty) |
T |
getTile(com.b3dgs.lionengine.game.Tiled tiled) |
boolean |
isAreaAvailable(int tx,
int ty,
int w,
int h,
int ignoreRef) |
boolean |
isBlocked(com.b3dgs.lionengine.game.pathfinding.Pathfindable mover,
int dx,
int dy,
boolean ignoreRef) |
void |
loadCollisions(com.b3dgs.lionengine.core.Media media) |
void |
setRef(int tx,
int ty,
java.lang.Integer id) |
append, clear, createMiniMap, createTile, getCollisionFrom, getHeightInTile, getMiniMap, getNumberPatterns, getNumberTiles, getPattern, getPatterns, getPatternsDirectory, getTile, getTileHeight, getTileWidth, getWidthInTile, load, loadPatterns, loadTile, render, renderMiniMap, save, setTile
public MapTileRts(int tileWidth, int tileHeight)
tileWidth
- The tile width.tileHeight
- The tile height.public com.b3dgs.lionengine.game.CoordTile getFreeTileAround(EntityRts entity, int radius)
entity
- The entity to search around.radius
- The search size.public com.b3dgs.lionengine.game.CoordTile getClosestTile(com.b3dgs.lionengine.game.Tiled from, com.b3dgs.lionengine.game.Tiled to, C collision, int radius)
from
- The tiled reference.to
- The tiled reference.collision
- The collision to searchradius
- The search size.public void create(int widthInTile, int heightInTile)
public void loadCollisions(com.b3dgs.lionengine.core.Media media)
public T getTile(com.b3dgs.lionengine.game.Tiled tiled)
public boolean isBlocked(com.b3dgs.lionengine.game.pathfinding.Pathfindable mover, int dx, int dy, boolean ignoreRef)
public double getCost(com.b3dgs.lionengine.game.pathfinding.Pathfindable mover, int sx, int sy, int tx, int ty)
public void setRef(int tx, int ty, java.lang.Integer id)
public java.lang.Integer getRef(int tx, int ty)
public com.b3dgs.lionengine.game.CoordTile getFreeTileAround(int tx, int ty, int radius)
public com.b3dgs.lionengine.game.CoordTile getClosestAvailableTile(com.b3dgs.lionengine.game.Tiled from, int radius, com.b3dgs.lionengine.game.Tiled to)
public com.b3dgs.lionengine.game.CoordTile getClosestAvailableTile(int sx, int sy, int radius, int dx, int dy)