xxxxxxxxxx
function setup() {
createCanvas(700, 700);
background(84, 228, 194); //sets light blue background color
noStroke();
fill(84, 190, 194);
rect(0, 0, 800, 800); //rectangle playing area, it is a darker blue to show where the canvas ends
s = new Square(600, 600, 50, 50, 2.5);
e = new Enemy(50, 50, 50, 50, 2.5);
}
function draw() {
s.display(); //tells Square to display
s.move(); // allows Square to move
s.collide(); // collides with opponent
e.display();
e.move();
}