View Javadoc

1   package erland.game.tetris;
2   /*
3    * Copyright (C) 2003 Erland Isaksson (erland_i@hotmail.com)
4    *
5    * This program is free software; you can redistribute it and/or
6    * modify it under the terms of the GNU General Public License
7    * as published by the Free Software Foundation; either version 2
8    * of the License, or (at your option) any later version.
9    *
10   * This program is distributed in the hope that it will be useful,
11   * but WITHOUT ANY WARRANTY; without even the implied warranty of
12   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13   * GNU General Public License for more details.
14   *
15   * You should have received a copy of the GNU General Public License
16   * along with this program; if not, write to the Free Software
17   * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
18   *
19   */
20  
21  import erland.game.GameEnvironmentInterface;
22  
23  public interface TetrisModelInterface {
24      BlockContainerData getMainContainer();
25      Block getNextBlock();
26      BlockContainerData getOpponentMainContainer();
27      boolean isEnd();
28      boolean isStarted();
29      boolean isCompleted();
30      String getHighScore();
31      String getScore();
32      String getOpponentScore();
33      String getLevel();
34      String getOpponentLevel();
35      boolean isMultiplayer();
36      boolean isOpponentConnected();
37  
38      void init(GameEnvironmentInterface environment);
39      void moveLeft();
40      void moveRight();
41      void rotate();
42      void moveDown();
43      void startGame();
44      void update();
45  }