Package com.gardeneaters.game_v0.rules

Source Code of com.gardeneaters.game_v0.rules.Play

package com.gardeneaters.game_v0.rules;

import com.gardeneaters.game_v0.playingfield.Garden;
import com.google.gwt.canvas.dom.client.Context2d;

public class Play {

  Garden garden;
  Path path;
  Level level;
 
  public Play(Context2d context) {
    garden = new Garden(context);
    path = new Path(garden.getHexagons());
    level = new Level(garden.getHexagons());
  }

  public void resize() {
    garden.createGarden();
   
  }

  public void update() {
    garden.draw();
    path.update();
    level.play();
  }

  public void click(int mouseStartX, int mouseStartY, int mouseEndX, int mouseEndY) {
    garden.click(mouseStartX, mouseStartY, mouseEndX, mouseEndY);
    //path.temp();
  }

}
TOP

Related Classes of com.gardeneaters.game_v0.rules.Play

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.