Package com.antonytrupe.server.games

Examples of com.antonytrupe.server.games.GameEngine$Persistence


  private static GameEngine ge;

  @Before
  public void before() {
    ge = new GameEngine(new String[] { "/com/antonytrupe/tend/Resource.js",
        "/com/antonytrupe/tend/ResourceGroup.js",
        "/com/antonytrupe/tend/Point.js",
        "/com/antonytrupe/tend/Board.js",
        "/com/antonytrupe/tend/Player.js",
        "/com/antonytrupe/tend/Trade.js",
View Full Code Here


    ScriptableObject board = api.createBoard();
    assertEquals(32, board.get("size"));

    assertEquals(null, board.get("id"));

    GameEngine ge = new GameEngine(new String[] {
        "/com/antonytrupe/tend/Resource.js",
        "/com/antonytrupe/tend/ResourceGroup.js",
        "/com/antonytrupe/tend/Point.js",
        "/com/antonytrupe/tend/Board.js",
        "/com/antonytrupe/tend/Player.js",
        "/com/antonytrupe/tend/Trade.js",
        "/com/antonytrupe/tend/Settlement.js" });
    ge.invoke(board, "update", new String[] { "{\"board\":"
        + "{\"id\":1,\"players\":{}}" + "}" });
    assertEquals(1, board.get("id"));
  }
View Full Code Here

TOP

Related Classes of com.antonytrupe.server.games.GameEngine$Persistence

Copyright © 2018 www.massapicom. 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.