Package org.cspoker.common.api.lobby.holdemtable.event

Examples of org.cspoker.common.api.lobby.holdemtable.event.WinnerEvent


   
    int gainedChipsValue = pots.getMainPot().getChips().getValue();
    Set<Winner> savedWinner = Collections.singleton(new Winner(winner.getId(), gainedChipsValue));
    pots.getMainPot().getChips().transferAllChipsTo(winner.getStack());
   
    gameMediator.publishWinnerEvent(new WinnerEvent(savedWinner));
  }
View Full Code Here


        PlayerId id = getId(playerChips);
        PlayerState player = getGameState().getPlayer(id);
        if(player!= null && inWinnerZone.get()){
          int prevStack = player.getStack();
          if(prevStack != playerChips.getMoney()){
            dispatch(new WinnerEvent(ImmutableSet.of(new Winner(id,playerChips.getMoney()-prevStack))));
          }
        }

        //refresh state
        player = getGameState().getPlayer(id);
View Full Code Here

        savedWinners.add(winner.getSavedWinner());
        Showdown.logger.info(winner);
        winner.transferGainedChipsToPlayer();
      }
    }
    table.publishWinnerEvent(new WinnerEvent(savedWinners));

  }
View Full Code Here

TOP

Related Classes of org.cspoker.common.api.lobby.holdemtable.event.WinnerEvent

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.