public class SimpleAgent extends BaseObject
Constructor and Description |
---|
SimpleAgent(javax.vecmath.Vector3d pos,
java.lang.String name)
Constructs a SimpleAgent.
|
Modifier and Type | Method and Description |
---|---|
boolean |
anOtherAgentIsVeryNear() |
java.lang.String |
asString()
Returns printable description of the agent.
|
boolean |
collisionDetected()
Returns the state of the geometric collision indicator.
|
ActuatorDevice |
getActuatorDevice(int num)
Returns the actuator device designated by num.
|
java.util.ArrayList<ActuatorDevice> |
getActuatorList() |
void |
getCoords(javax.vecmath.Point3d coord) |
int |
getCounter()
Returns the agent counter.
|
int |
getFramesPerSecond()
Returns the number of behavior step per second, ie the nummber of time the
performBehavior is called per second
|
float |
getHeight()
Returns the agent's height in meters.
|
double |
getLifeTime()
Returns the agent total lifetime since last reset (in seconds).
|
float |
getMass() |
java.lang.String |
getName()
Returns the agent's name.
|
float |
getRadius()
Returns the agent's radius in meters.
|
SensorDevice |
getSensorDevice(int num)
Returns the sensor device designated by num.
|
java.util.ArrayList<SensorDevice> |
getSensorList() |
SimpleAgent |
getVeryNearAgent() |
boolean |
interactionDetected()
Returns true if an interaction has been detected.
|
void |
moveToPosition(double x,
double z)
Go to given XZ position.
|
void |
moveToPosition(javax.vecmath.Vector3d position)
Go to given position.
|
void |
moveToStartPosition()
Go to the start position of the agent.
|
attach, detach, getCanBeTraversed, getRotationTransform, getTranslationTransform, rotateY, setCanBeTraversed, setColor, translateTo
public SimpleAgent(javax.vecmath.Vector3d pos, java.lang.String name)
pos
- the starting position.name
- the name of the agent.public boolean anOtherAgentIsVeryNear()
public java.lang.String asString()
public boolean collisionDetected()
public ActuatorDevice getActuatorDevice(int num)
num
- npublic java.util.ArrayList<ActuatorDevice> getActuatorList()
public void getCoords(javax.vecmath.Point3d coord)
public int getCounter()
public int getFramesPerSecond()
public float getHeight()
public double getLifeTime()
public float getMass()
public java.lang.String getName()
public float getRadius()
public SensorDevice getSensorDevice(int num)
num
- npublic java.util.ArrayList<SensorDevice> getSensorList()
public SimpleAgent getVeryNearAgent()
public boolean interactionDetected()
public void moveToPosition(double x, double z)
x
- the x coordz
- the z coordpublic void moveToPosition(javax.vecmath.Vector3d position)
position
- - the new position.public void moveToStartPosition()