public class HotspotMovement extends MapBasedMovement
backAllowed, FILE_S, lastMapNode, MAP_BASE_MOVEMENT_NS, MAP_SELECT_S, maxPathLength, minPathLength, NROF_FILES_ScomBus, DEF_SPEEDS, DEF_WAIT_TIMES, host, maxSpeed, maxWaitTime, minSpeed, minWaitTime, MOVEMENT_MODEL_NS, rng, RNG_SEED, SPEED, WAIT_TIME, WORLD_SIZE| Constructor and Description |
|---|
HotspotMovement(HotspotMovement h)
Copyconstructor.
|
HotspotMovement(Settings s)
Creates a new movement model based on a Settings object's settings.
|
| Modifier and Type | Method and Description |
|---|---|
Coord |
getInitialLocation()
Returns a (random) coordinate that is between two adjacent MapNodes
|
Coord |
getLastLocation()
Get the last location the getPath() of this movement model has returned
|
Path |
getPath()
Returns a new path by this movement model or null if no new path could
be constructed at the moment (node should wait where it is).
|
HotspotMovement |
replicate()
Creates a replicate of the movement model.
|
void |
setLocation(Coord lastWaypoint)
Tell the movement model what its current location is
|
getMap, getOkMapNodeTypes, isReady, selectRandomOkNodegenerateSpeed, generateWaitTime, getComBus, getHost, getMaxX, getMaxY, isActive, nextPathAvailable, reset, setComBus, setHost, toStringpublic HotspotMovement(Settings s)
s - The Settings object where the settings are read frompublic HotspotMovement(HotspotMovement h)
h - The HotspotMovement prototype to base the new object topublic Path getPath()
MovementModelgetPath in class MapBasedMovementpublic Coord getLastLocation()
SwitchableMovementgetLastLocation in interface SwitchableMovementgetLastLocation in class MapBasedMovementpublic void setLocation(Coord lastWaypoint)
SwitchableMovementsetLocation in interface SwitchableMovementsetLocation in class MapBasedMovementpublic Coord getInitialLocation()
MapBasedMovementgetInitialLocation in class MapBasedMovementpublic HotspotMovement replicate()
MovementModelreplicate in class MapBasedMovement