Examples of SmartClientContext


Examples of org.cspoker.client.common.SmartClientContext

  private void startBot(BotFactory botFactory, final TableId tableId,
      final int buyin) throws LoginException, RemoteException,
      IllegalActionException {
    // Start Bot
    SmartClientContext clientContext = new SmartClientContext(server.login(
        "Bot " + botIndex++, "test"));
    final SmartLobbyContext lobbyContext = clientContext
    .getLobbyContext(new DefaultLobbyListener());
    final PlayerId botId = clientContext.getAccountContext().getPlayerID();
    final SingleThreadRequestExecutor executor = SingleThreadRequestExecutor
    .getInstance();
    bot = botFactory.createBot(botId, tableId, lobbyContext, buyin,
        executor,new DefaultBotListener() {
      @Override
View Full Code Here

Examples of org.cspoker.client.common.SmartClientContext

      botIndex = new int[nbPlayersPerGame];
 
      botLobbies = new SmartLobbyContext[botFactories.length];
      botIDs = new PlayerId[botFactories.length];
     
      SmartClientContext director = new SmartClientContext(cspokerServer
          .login("director", "test"));
      directorLobby = director.getLobbyContext(BotRunner.this);
 
      for (int i = 0; i < botFactories.length; i++) {
        SmartClientContext clientContext = new SmartClientContext(
            cspokerServer.login(botFactories[i].toString(), "test"));
        botLobbies[i] = clientContext.getLobbyContext(new DefaultLobbyListener());
        botIDs[i] = clientContext.getAccountContext().getPlayerID();
      }
 
      executor = SingleThreadRequestExecutor.getInstance();
 
      combinationgenerator = new CombinationGenerator(botFactories.length, nbPlayersPerGame);
View Full Code Here

Examples of org.cspoker.client.common.SmartClientContext

    return new Factory[]{};
  }

  protected void start() throws RemoteException, LoginException, IllegalActionException {
    RemoteServerContext conn = server.login("foobar", "foobar");
    SmartClientContext clientContext = new SmartClientContext(conn);
    final SmartLobbyContext lobbyContext = clientContext.getLobbyContext(new DefaultLobbyListener());
    final PlayerId botId = clientContext.getAccountContext().getPlayerID();
    final SingleThreadRequestExecutor executor = SingleThreadRequestExecutor.getInstance();
    final TableId tableId = new TableId(0);
    bot = botFactory.createBot(botId, tableId, lobbyContext, 200000, executor, new DefaultBotListener() {
      @Override
      public void onSitOut(SitOutEvent sitOutEvent) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.