org.nlogo.agent
Class World3D
java.lang.Object
org.nlogo.agent.World
org.nlogo.agent.World3D
- All Implemented Interfaces:
- World, World3D
public final class World3D
- extends World
- implements World3D
Fields inherited from class org.nlogo.agent.World |
auxRNG, comeUpForAir, inRadiusOrCone, linkBreedShapes, linkManager, mainRNG, ONE, protractor, tickCounter, tieManager, timer, turtleBreedShapes, ZERO |
Method Summary |
void |
changeTopology(boolean xWrapping,
boolean yWrapping)
|
void |
changeTopology(boolean xWrapping,
boolean yWrapping,
boolean zWrapping)
|
void |
clearAll()
|
void |
clearDrawing()
|
void |
createPatches(int minPxcor,
int maxPxcor,
int minPycor,
int maxPycor)
|
void |
createPatches(int minPxcor,
int maxPxcor,
int minPycor,
int maxPycor,
int minPzcor,
int maxPzcor)
|
void |
createPatches(WorldDimensions dim)
|
Turtle |
createTurtle(AgentSet breed)
|
Turtle |
createTurtle(AgentSet breed,
int c,
int h)
|
void |
diffuse4(double param,
int vn)
|
boolean |
equalDimensions(WorldDimensions d)
|
void |
exportWorld(PrintWriter writer,
boolean full)
|
Patch |
fastGetPatchAt(int xc,
int yc)
|
Patch |
fastGetPatchAt(int xc,
int yc,
int zc)
|
double |
followOffsetZ()
|
WorldDimensions |
getDimensions()
|
Object |
getDrawing()
|
Turtle |
getOrCreateTurtle(long id)
|
Patch |
getPatchAt(double x,
double y)
|
Patch3D |
getPatchAt(double x,
double y,
double z)
|
Patch |
getPatchAtWrap(double x,
double y,
double z)
|
double[][][] |
getPatchScratch3d()
|
void |
importWorld(Importer.ErrorHandler errorHandler,
ImporterUser importerUser,
Importer.StringReader stringReader,
BufferedReader reader)
|
boolean |
isDimensionVariable(String variableName)
|
int |
maxPzcor()
|
Double |
maxPzcorBoxed()
|
int |
minPzcor()
|
Double |
minPzcorBoxed()
|
Program |
newProgram()
|
Program |
newProgram(List<String> interfaceGlobals)
|
Protractor3D |
protractor3D()
|
int |
roundZ(double z)
|
boolean |
sendPixels()
|
WorldDimensions |
setDimensionVariable(String variableName,
int value,
WorldDimensions d)
|
double |
shortestPathZ(double z1,
double z2)
|
void |
stamp(Agent agent,
boolean erase)
|
boolean |
validPatchCoordinates(int xc,
int yc,
int zc)
|
int |
worldDepth()
|
Double |
worldDepthBoxed()
|
double |
wrappedObserverZ(double z)
|
boolean |
wrappingAllowedInZ()
|
double |
wrapZ(double z)
|
Methods inherited from class org.nlogo.agent.World |
agentClassToAgentSet, breedOwns, breedsOwnIndexOf, breedsOwnNameAt, checkLinkShapeName, checkTurtleShapeName, clearGlobals, clearLinks, clearPatches, clearTurtles, compareLinkBreeds, defaultEvaluator, diffuse, displayOn, displayOn, followOffsetX, followOffsetY, generateSeed, getBreed, getBreeds, getBreedSingular, getLink, getLinkBreed, getLinkBreeds, getLinkBreedSingular, getLinkShape, getLinkVariablesArraySize, getObserverVariableByName, getOrCreateDummyLink, getOrCreateLink, getOrCreateLink, getPatch, getPatchAtWrap, getPatchScratch, getTurtle, getVariablesArraySize, getVariablesArraySize, getVariablesArraySize, getVariablesArraySize, growMax, growMin, indexOfVariable, indexOfVariable, invalidateTurtleShape, isBreed, isLinkBreed, lineThickness, linkBreedOwns, linkBreedsOwnIndexOf, linkBreedsOwnNameAt, links, linkShapeList, linksOwnIndexOf, linksOwnNameAt, markDrawingClean, markPatchColorsClean, markPatchColorsDirty, maxPxcor, maxPxcorBoxed, maxPycor, maxPycorBoxed, minPxcor, minPxcorBoxed, minPycor, minPycorBoxed, noLinks, noPatches, noTurtles, observer, observerOwnsIndexOf, observerOwnsNameAt, observers, patchColors, patchColorsDirty, patches, patchesAllBlack, patchesOwnIndexOf, patchesOwnNameAt, patchesWithLabels, patchSize, patchSize, program, program, protractor, realloc, rememberOldProgram, removeLineThickness, roundX, roundY, setDefaultEvaluator, setLineThickness, setObserverVariableByName, ticks, trailDrawer, turtles, turtleShapeList, turtlesOwnIndexOf, turtlesOwnNameAt, validPatchCoordinates, worldHeight, worldHeightBoxed, worldWidth, worldWidthBoxed, wrap, wrappedObserverX, wrappedObserverY, wrappingAllowedInX, wrappingAllowedInY, wrapX, wrapY |
Methods inherited from interface org.nlogo.api.World |
breedsOwnNameAt, followOffsetX, followOffsetY, getPatch, getVariablesArraySize, getVariablesArraySize, links, linkShapeList, linksOwnNameAt, markDrawingClean, markPatchColorsClean, markPatchColorsDirty, maxPxcor, maxPycor, minPxcor, minPycor, observer, patchColors, patchColorsDirty, patches, patchesAllBlack, patchesWithLabels, patchSize, program, protractor, ticks, turtles, turtleShapeList, turtlesOwnNameAt, worldHeight, worldWidth, wrap, wrappedObserverX, wrappedObserverY, wrappingAllowedInX, wrappingAllowedInY, wrapX, wrapY |
World3D
public World3D()
protractor3D
public Protractor3D protractor3D()
- Specified by:
protractor3D
in interface World3D
changeTopology
public void changeTopology(boolean xWrapping,
boolean yWrapping)
- Overrides:
changeTopology
in class World
changeTopology
public void changeTopology(boolean xWrapping,
boolean yWrapping,
boolean zWrapping)
shortestPathZ
public double shortestPathZ(double z1,
double z2)
wrappingAllowedInZ
public boolean wrappingAllowedInZ()
wrappedObserverZ
public double wrappedObserverZ(double z)
- Specified by:
wrappedObserverZ
in interface World3D
followOffsetZ
public double followOffsetZ()
- Specified by:
followOffsetZ
in interface World3D
diffuse4
public void diffuse4(double param,
int vn)
- Overrides:
diffuse4
in class World
worldDepth
public int worldDepth()
- Specified by:
worldDepth
in interface World3D
maxPzcor
public int maxPzcor()
- Specified by:
maxPzcor
in interface World3D
minPzcor
public int minPzcor()
- Specified by:
minPzcor
in interface World3D
minPzcorBoxed
public Double minPzcorBoxed()
maxPzcorBoxed
public Double maxPzcorBoxed()
worldDepthBoxed
public Double worldDepthBoxed()
wrapZ
public double wrapZ(double z)
- Specified by:
wrapZ
in interface World3D
roundZ
public int roundZ(double z)
getPatchAtWrap
public Patch getPatchAtWrap(double x,
double y,
double z)
validPatchCoordinates
public boolean validPatchCoordinates(int xc,
int yc,
int zc)
fastGetPatchAt
public Patch fastGetPatchAt(int xc,
int yc,
int zc)
fastGetPatchAt
public Patch fastGetPatchAt(int xc,
int yc)
- Specified by:
fastGetPatchAt
in interface World
- Overrides:
fastGetPatchAt
in class World
createPatches
public void createPatches(WorldDimensions dim)
- Overrides:
createPatches
in class World
createPatches
public void createPatches(int minPxcor,
int maxPxcor,
int minPycor,
int maxPycor)
- Overrides:
createPatches
in class World
newProgram
public Program newProgram()
- Overrides:
newProgram
in class World
newProgram
public Program newProgram(List<String> interfaceGlobals)
- Overrides:
newProgram
in class World
createPatches
public void createPatches(int minPxcor,
int maxPxcor,
int minPycor,
int maxPycor,
int minPzcor,
int maxPzcor)
exportWorld
public void exportWorld(PrintWriter writer,
boolean full)
- Overrides:
exportWorld
in class World
importWorld
public void importWorld(Importer.ErrorHandler errorHandler,
ImporterUser importerUser,
Importer.StringReader stringReader,
BufferedReader reader)
throws IOException
- Overrides:
importWorld
in class World
- Throws:
IOException
getOrCreateTurtle
public Turtle getOrCreateTurtle(long id)
- Overrides:
getOrCreateTurtle
in class World
getPatchScratch3d
public double[][][] getPatchScratch3d()
getDimensions
public WorldDimensions getDimensions()
- Overrides:
getDimensions
in class World
isDimensionVariable
public boolean isDimensionVariable(String variableName)
- Overrides:
isDimensionVariable
in class World
setDimensionVariable
public WorldDimensions setDimensionVariable(String variableName,
int value,
WorldDimensions d)
throws WorldDimensionException
- Overrides:
setDimensionVariable
in class World
- Throws:
WorldDimensionException
equalDimensions
public boolean equalDimensions(WorldDimensions d)
- Overrides:
equalDimensions
in class World
getPatchAt
public Patch getPatchAt(double x,
double y)
throws AgentException
- Specified by:
getPatchAt
in interface World
- Overrides:
getPatchAt
in class World
- Throws:
AgentException
getPatchAt
public Patch3D getPatchAt(double x,
double y,
double z)
throws AgentException
- Specified by:
getPatchAt
in interface World3D
- Throws:
AgentException
createTurtle
public Turtle createTurtle(AgentSet breed)
- Overrides:
createTurtle
in class World
createTurtle
public Turtle createTurtle(AgentSet breed,
int c,
int h)
- Overrides:
createTurtle
in class World
getDrawing
public Object getDrawing()
- Specified by:
getDrawing
in interface World
- Overrides:
getDrawing
in class World
sendPixels
public boolean sendPixels()
- Specified by:
sendPixels
in interface World
- Overrides:
sendPixels
in class World
clearAll
public void clearAll()
- Overrides:
clearAll
in class World
clearDrawing
public void clearDrawing()
- Overrides:
clearDrawing
in class World
stamp
public void stamp(Agent agent,
boolean erase)
- Overrides:
stamp
in class World