protected void paint(Graphics g) { // Pintamos mapa map.paint(g); // Actualizamos el menu // Por ahora no lo hacemos }
public void commandAction(Command c, Displayable d) { if (c == exitCommand) { GolfController.getInstance().endGame(); } else if (c == volverCommand) { GolfController.getInstance().goMain(false); } else if (c == rotateCommand) { map.rotate(); } else if (c == zoominCommand) { map.zoomin(); } else if (c == zoomoutCommand) { map.zoomout(); } else if (c == nozoomCommand) { map.nozoom(); } else if (c == finhoyoCommand) { GolfController.getInstance().getGame().viewCard(); } else if (c == golpeCommand) { GolfController.getInstance().getGame().golpe(); } }
protected void keyPressed(int key) { int action = getGameAction(key); map.keyPressed(action, false); }
protected void keyRepeated(int key) { int action = getGameAction(key); map.keyPressed(action, true); }