public class EmohawkNavigation extends Object
IUT2004PathExecutor, FloydWarshallMap, IUT2004RunStraight and IUT2004GetBackToNavGraph
to handle all possible navigation cases.| Modifier and Type | Field and Description |
|---|---|
protected static int |
ARRIVED_AT_LOCATION_XY_THRESHOLD
Location threshold for checking whether we have arrived on target.
|
protected static int |
ARRIVED_AT_LOCATION_Z_THRESHOLD
Location threshold for checking whether we have arrived on target.
|
static double |
AT_LOCATION
We're managed to get to location
|
static double |
AT_PLAYER
We're managed to get to player
|
protected cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot |
bot
UT2004Bot reference.
|
protected IPathFuture |
currentFuturePath
Current path stored in IPathFuture object.
|
protected ILocated |
currentTarget
Current location target.
|
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player |
currentTargetPlayer
Current target is player (if not null)
|
protected IWorldEventListener<cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.EndMessage> |
endMessageListener |
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
fromNavPoint
Navpoint we're running from (initial position when path executor has been triggered)
|
protected cz.cuni.amis.pogamut.ut2004.agent.navigation.floydwarshall.FloydWarshallMap |
fwMap
FloydWarshallMap that is used for path planning.
|
protected ILocated |
lastTarget
Last location target.
|
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player |
lastTargetPlayer
Last location target.
|
protected LogCategory |
log
Log used by this class.
|
protected boolean |
navigating
Whether navigation is running.
|
protected static int |
NEW_PATH_DISTANCE_THRESHOLD
Location threshold for requesting of a new path or switching a path.
|
protected static double |
PLAYER_DISTANCE_TRASHOLD
When PLAYER is further from currentTarget than this location, recompute the path
|
protected boolean |
runningStraightToPlayer
We're running straight to the player.
|
protected Location |
runningStraightToPlayerFailedAt
Where run-straight failed.
|
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
toNavPoint
Navpoint we're running to, nearest navpoint to currentTarget
|
| Constructor and Description |
|---|
EmohawkNavigation(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot,
Steering steering,
cz.cuni.amis.pogamut.ut2004.agent.navigation.floydwarshall.FloydWarshallMap fwMap)
Here you may specify any custom UT2004Navigation parts.
|
| Modifier and Type | Method and Description |
|---|---|
List<ILocated> |
getCurrentPathCopy() |
List<ILocated> |
getCurrentPathDirect() |
ILocated |
getCurrentTarget() |
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
getCurrentTargetNavPoint() |
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player |
getCurrentTargetPlayer() |
ILocated |
getLastTarget() |
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
getLastTargetNavPoint() |
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
getLastTargetPlayer() |
cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint |
getNearestNavPoint(ILocated location) |
boolean |
isNavigating() |
protected void |
navigate() |
void |
navigate(ILocated target) |
void |
navigate(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player player) |
protected void |
processPathFuture(IPathFuture futurePath)
Checks if last path element is in close distance from our desired target and if not, we
will add our desired target as the last path element.
|
protected void |
reset(boolean stopGetBackToNavGraph) |
void |
setFocus(ILocated located) |
protected void |
startNavigate() |
void |
stopNavigation() |
protected static final int NEW_PATH_DISTANCE_THRESHOLD
protected static final int ARRIVED_AT_LOCATION_XY_THRESHOLD
protected static final int ARRIVED_AT_LOCATION_Z_THRESHOLD
protected static final double PLAYER_DISTANCE_TRASHOLD
public static final double AT_PLAYER
public static final double AT_LOCATION
protected LogCategory log
protected cz.cuni.amis.pogamut.ut2004.agent.navigation.floydwarshall.FloydWarshallMap fwMap
protected cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot
protected IWorldEventListener<cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.EndMessage> endMessageListener
protected ILocated lastTarget
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player lastTargetPlayer
protected ILocated currentTarget
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player currentTargetPlayer
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint fromNavPoint
protected cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint toNavPoint
protected IPathFuture currentFuturePath
protected boolean navigating
protected boolean runningStraightToPlayer
protected Location runningStraightToPlayerFailedAt
public EmohawkNavigation(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot,
Steering steering,
cz.cuni.amis.pogamut.ut2004.agent.navigation.floydwarshall.FloydWarshallMap fwMap)
bot - ut2004PathExecutor - fwMap - getBackOnPath - runStraight - public boolean isNavigating()
public void setFocus(ILocated located)
public void stopNavigation()
public void navigate(ILocated target)
public void navigate(cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player player)
public cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint getNearestNavPoint(ILocated location)
public ILocated getCurrentTarget()
public cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.Player getCurrentTargetPlayer()
public cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint getCurrentTargetNavPoint()
public ILocated getLastTarget()
public cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint getLastTargetPlayer()
public cz.cuni.amis.pogamut.ut2004.communication.messages.gbinfomessages.NavPoint getLastTargetNavPoint()
protected void startNavigate()
protected void navigate()
protected void processPathFuture(IPathFuture futurePath)
futurePath - protected void reset(boolean stopGetBackToNavGraph)
Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.