Class mazeWorld

java.lang.Object
  extended by greenfoot.World
      extended by mazeWorld

public class mazeWorld
extends greenfoot.World

This is an example of one way to create a maze, or barriers. The andt can not cross into or through the barrier walls. This is done by using a square image object called "wallRect" that does nothing. The effect of being impassible is actually created by in the Ant class where when trying to move the keyboard controlled ant, it is not allowed to move into a rectangle. See the tryMove() code in the Ant class.

Version:
(July 2007)
Author:
(Scott)

Constructor Summary
mazeWorld()
          Constructor for objects of class mazeWorld.
 
Method Summary
 
Methods inherited from class greenfoot.World
addObject, getBackground, getCellSize, getColorAt, getHeight, getObjects, getObjectsAt, getWidth, isTiled, removeObject, removeObjects, repaint, setBackground, setBackground, setPaintOrder, setTiled
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

mazeWorld

public mazeWorld()
Constructor for objects of class mazeWorld.