import info.gridworld.actor.ActorWorld; //First you need to import all the gridowrld files
import info.gridworld.grid.Grid;
import java.awt.Color;
import info.gridworld.actor.Bug;
import info.gridworld.grid.Location;
public class GWTest {
public static void main(String[] args) {
ActorWorld Overgrown = new ActorWorld(); //This names and creates the world in which the bugs are a part of
Bug Yellow = new Bug(Color.YELLOW); // This creates a bug that is yellow
Yellow.setDirection(Location.SOUTHWEST); // This sets the bug to be pointed in the southwest direction
Location Y = new Location(5,4); // This sets the yellow bug to the grid coordinate (5,4)
Overgrown.add(Y, Yellow); // This adds the yellow bug to the grid
Bug Magenta = new Bug(Color.MAGENTA); // This creates a bug that is yellow
Magenta.setDirection(Location.SOUTHEAST); // This sets the bug to be pointed in the southeast direction
Location M = new Location(5,5); // This sets the magenta bug to the grid coordinate (5,5)
Overgrown.add(M, Magenta); // This adds the magenta bug to the grid
Bug Blue = new Bug(Color.BLUE); // This creates a bug that is blue
Blue.setDirection(Location.NORTHEAST); // This sets the bug to be pointed in the northeast direction
Location B = new Location(4,5); // This sets the blue bug to the grid coordinate (4,5)
Overgrown.add(B, Blue); // This adds the blue bug to the grid
Bug Green = new Bug(Color.GREEN); // This creates a bug that is green
Green.setDirection(Location.NORTHWEST); // This sets the bug to be pointed in the northwest direction
Location G = new Location(4,4); // This sets the freen bug to the frid coordinate (4,4)
Overgrown.add(G, Green); // This adds the green bug to the grid
Overgrown.show(); // THis allows you to view the world
}
}