Package org.gnubridge.core

Examples of org.gnubridge.core.Player


      return;
    }
    Deal position = game.duplicate();
    position.playMoves(node.getMoves());

    Player player = position.getNextToPlay();
    node.setPlayerTurn(player.getDirection());
    node.setPosition(position);
    if (position.oneTrickLeft()) {
      node.setCardPlayed(player.getPossibleMoves(position.getCurrentTrick()).get(0));
      position.playMoves(finalMoves);
    }
    for (Card card : player.getPossibleMoves(position.getCurrentTrick())) {
      makeChildNodeForCardPlayed(node, player, card);
    }

    checkDuplicatePositions(node, position);
    if (position.getTricksPlayed() >= maxTricks || position.isDone() || node.hasIdenticalTwin()) {
View Full Code Here


  }

  public void testWhenPlayingHumanRetainsHisCardsFromBidding() throws InterruptedException, InvocationTargetException {
    preInitializeGameWithSingleColorSuits();
    MainController mainController = makeController();
    Player humanInBidding = mainController.getBiddingController().getHuman();
    mainController.getBiddingController().placeBid(7, "NT");
    mainController.playGame();
    Direction humanInPlay = mainController.getGameController().getHuman();
    assertEquals(humanInBidding.getHand(), mainController.getGameController().getGame().getPlayer(humanInPlay)
        .getHand());

  }
View Full Code Here

TOP

Related Classes of org.gnubridge.core.Player

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.