public class TilePath extends LineSegmentPath
CARDINAL_DIRECTIONS, CCW, CW, DIRECTION_COUNT, DOWN, EAST, EASTNORTHEAST, EASTSOUTHEAST, FINE_DIRECTION_COUNT, HORIZONTAL, LEFT, NONE, NORTH, NORTHEAST, NORTHNORTHEAST, NORTHNORTHWEST, NORTHWEST, RIGHT, SOUTH, SOUTHEAST, SOUTHSOUTHEAST, SOUTHSOUTHWEST, SOUTHWEST, UP, VERTICAL, WEST, WESTNORTHWEST, WESTSOUTHWEST| Constructor and Description |
|---|
TilePath(MisoSceneMetrics metrics,
Sprite sprite,
List<Point> tiles,
int destx,
int desty)
Constructs a tile path.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addNode(int x,
int y,
int dir)
Add a node to the path with the specified destination point and facing direction.
|
long |
getEstimTravelTime()
Returns the estimated number of millis that we'll be traveling
along this path.
|
fastForward, getFinalOrientation, getNode, init, paint, setDuration, setVelocity, size, tick, toString, wasRemovedpublic TilePath(MisoSceneMetrics metrics, Sprite sprite, List<Point> tiles, int destx, int desty)
metrics - the metrics for the scene the with which the path is
associated.sprite - the sprite to follow the path.tiles - the tiles to be traversed during the path.destx - the destination x-position in screen pixel
coordinates.desty - the destination y-position in screen pixel
coordinates.public long getEstimTravelTime()
public void addNode(int x,
int y,
int dir)
LineSegmentPathaddNode in class LineSegmentPathx - the x-position.y - the y-position.dir - the facing direction.Copyright © 2015. All rights reserved.