public interface Turtle
Interface provides access to NetLogo turtles.
Method Summary | |
---|---|
Shape |
cachedShape()
|
void |
cachedShape(Shape shape)
|
Object |
color()
Returns the value of the color variable |
AgentSet |
getBreed()
Returns the breed AgentSet of this turtle, all turtles if the turtle is unbreeded |
int |
getBreedIndex()
Returns the index of this turtle's breed |
Patch |
getPatchHere()
Returns the patch that this turtle is on |
boolean |
hasLabel()
Returns true if the label variable has a non-empty string value |
double |
heading()
Returns the value of the heading variable |
void |
heading(double d)
Sets the value of the heading variable |
boolean |
hidden()
Returns the value of the hidden? |
void |
jump(double distance)
Moves the turtle forward distance as if the command jump were used |
Object |
labelColor()
Returns the value of the label-color variable |
String |
labelString()
Returns the value of the label variable |
double |
lineThickness()
Returns the line-thickness |
double |
xcor()
Returns the value of the xcor variable |
double |
ycor()
Returns the value of the ycor variable |
Methods inherited from interface org.nlogo.api.Agent |
---|
classDisplayName, getVariable, id, setVariable, shape, size, world |
Method Detail |
---|
double xcor()
xcor
variable
double ycor()
ycor
variable
Shape cachedShape()
void cachedShape(Shape shape)
double heading()
heading
variable
void heading(double d)
heading
variable
d
- the new headingboolean hidden()
hidden?
variable
double lineThickness()
line-thickness
boolean hasLabel()
label
variable has a non-empty string value
Object color()
color
variable
String labelString()
label
variable
Object labelColor()
label-color
variable
AgentSet getBreed()
int getBreedIndex()
Patch getPatchHere()
void jump(double distance) throws AgentException
jump
were used
distance
- this amount to jump
AgentException