public class WallFollowingSteer extends Object implements ISteering, IRaysFlagChanged
Modifier and Type | Field and Description |
---|---|
protected static String |
NFRONT |
protected static String |
NLEFT |
protected static String |
NLEFTFRONT |
protected static String |
NRIGHT |
protected static String |
NRIGHTFRONT |
Constructor and Description |
---|
WallFollowingSteer(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot,
RaycastingManager rayManager) |
WallFollowingSteer(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot,
RaycastingManager rayManager,
SteeringProperties newProperties) |
Modifier and Type | Method and Description |
---|---|
void |
flagRaysChanged() |
WallFollowingProperties |
getProperties() |
javax.vecmath.Vector3d |
run(javax.vecmath.Vector3d scaledActualVelocity,
RefBoolean wantsToGoFaster,
RefBoolean wantsToStop,
cz.cuni.amis.pogamut.base3d.worldview.object.Location focus)
When called, the bot starts steering, when possible, he walks straight, he steers away from obstacles though, when necessary.
|
void |
setProperties(SteeringProperties newProperties)
The steering manager will set to the steering his steering properties.
|
protected static final String NLEFTFRONT
protected static final String NLEFT
protected static final String NRIGHTFRONT
protected static final String NRIGHT
protected static final String NFRONT
public WallFollowingSteer(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot, RaycastingManager rayManager, SteeringProperties newProperties)
bot
- Instance of the steered bot.rayManager
- Raycasting manager of the steered bot.newProperties
- Sets the steering properties.public WallFollowingSteer(cz.cuni.amis.pogamut.ut2004.bot.impl.UT2004Bot bot, RaycastingManager rayManager)
bot
- Instance of the steered bot.rayManager
- Raycasting manager of the steered bot.public void flagRaysChanged()
flagRaysChanged
in interface IRaysFlagChanged
public javax.vecmath.Vector3d run(javax.vecmath.Vector3d scaledActualVelocity, RefBoolean wantsToGoFaster, RefBoolean wantsToStop, cz.cuni.amis.pogamut.base3d.worldview.object.Location focus)
run
in interface ISteering
scaledActualVelocity
- This is the force of the last velocity, scaled by its weight. The steering can use this vector to create the decelerating force.wantsToGoFaster
- The steering should set this ref parameter, whether is possible to enlarge the velocity (wantsToGoFaster=true), or not.wantsToStop
- If steering want's to stop the agent, he can set this ref parameter to true.focus
- If the wantsToStop is true, steering can set the focus Location, which means the orientation of the stopped agent. (Agent will rotate to this location.)public void setProperties(SteeringProperties newProperties)
ISteering
setProperties
in interface ISteering
newProperties
- the new steering propertiespublic WallFollowingProperties getProperties()
Copyright © 2012 AMIS research group, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic. All Rights Reserved.