Package com.svanloon.game.wizard.client.event

Examples of com.svanloon.game.wizard.client.event.NewGameEvent


      message = handleGameOver(event);
    }else if(we instanceof HandDealtEvent) {
      HandDealtEvent event = (HandDealtEvent) we;
      message = handleHandDealt(event);
    }else if(we instanceof NewGameEvent) {
      NewGameEvent event = (NewGameEvent) we;
      message = handleNewGame(event);
    } else if(we instanceof NewRoundEvent) {
      NewRoundEvent event = (NewRoundEvent) we;
      message = handleNewRound(event);
    } else if(we instanceof NewTrickEvent) {
View Full Code Here


      int id = getPlayerId(mps);
      listener.handleHandDealt(new HandDealtEvent(id));
    } else if(mt.equals(MessageType.NEW_GAME)) {
      List<String> playerNames = getPlayerNames(mps);
      List<Integer> ids = getPlayerIds(mps);
      listener.handleNewGame(new NewGameEvent(ids, playerNames));
    } else if(mt.equals(MessageType.NEW_ROUND)) {
      int round = getInt(mps, MessageParamConstants.ROUND);
      listener.handleNewRound(new NewRoundEvent(round));
    } else if(mt.equals(MessageType.NEW_TRICK)) {
      listener.handleNewTrick(new NewTrickEvent());
View Full Code Here

    List<Integer> playerIds = getPlayerId();
    List<String> playerNames = getPlayerNames();
    for (int i = 0; i < playerIds.size(); i++) {
      _game.addPlayer(playerIds.get(i).intValue(),  playerNames.get(i));
    }
    gameEventNotifier.notify(new NewGameEvent(playerIds,playerNames));
    for (int roundId = startRound; roundId < endRound + 1; roundId = roundId + inc) {
      dealer = (dealer + 1)% _playerCollection.size();
      lead = (dealer + 1)% _playerCollection.size();
      gameEventNotifier.notify(new NewRoundEvent(roundId));
      _game.newRound(roundId);
View Full Code Here

TOP

Related Classes of com.svanloon.game.wizard.client.event.NewGameEvent

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.