private void distributePot()
	{	
		// create a map of hand strength of all the involved bots
		HashMap<PokerBot, Integer> botHandStrengths = new HashMap<PokerBot, Integer>();	
		int[] handStrengths = computeHandStrengths(botHands, tableCards);
		for(int i = 0; i < numberOfBots; i++)
			if(handStrengths[i] >= 0)
				botHandStrengths.put(bots.get(i), handStrengths[i]);
		
		int numberOfBotsOnShowdown = botHandStrengths.size();
			
		// retrieve the information about the main pot and side pots and the winning bots per pot part
		Pot.PayoutWinnerInfo winnerInfo = pot.payoutWinners(botHandStrengths);
		ArrayList<Integer> potParts = winnerInfo.getPots();
		ArrayList<ArrayList<PokerBot>> potPartWinners = winnerInfo.getWinnerPerPot();
		
		// divide each pot part among the bots that win them
		int[] winPerBot = new int[numberOfBots];
		for(int i = potParts.size() - 1; i >= 0; i--)
		{
			ArrayList<PokerBot> currentPotWinners = potPartWinners.get(i);
			int currentPotSize = potParts.get(i);
			int numberOfWinners = currentPotWinners.size();
			int amountPerWinner = currentPotSize / numberOfWinners;
			int restChips = currentPotSize - (numberOfWinners*amountPerWinner);
			int currentSeat = (buttonSeat + 1) % numberOfBots;
			
			String potWinnersStr = "[";
			while(true)
			{
				PokerBot currentBot = bots.get(currentSeat);
				if(currentPotWinners.contains(currentBot))
				{
					int currentWinAmount = amountPerWinner;
					if(restChips-- > 0)
						currentWinAmount++;
					
					potWinnersStr += String.format("%s:%d,", currentBot.getName(), currentWinAmount);
					winPerBot[currentSeat] += currentWinAmount;
				}
				currentSeat = (currentSeat + 1) % numberOfBots;
				if(currentSeat == (buttonSeat + 1) % numberOfBots)
					break;
			}
			potWinnersStr = potWinnersStr.substring(0, potWinnersStr.length() - 1);
			potWinnersStr += "]";

			if(i > 0)
				handHistory += String.format("\nResult sidepot%d %s", i, potWinnersStr);
			else
				handHistory += String.format("\nResult pot %s", potWinnersStr);			
		}

		// return the winnings per bot to their stacks and send the information to all the bots
		for(int i = 0; i < numberOfBots; i++)
		{
			botStacks[i] += winPerBot[i];
		}
		sendResultInfo(winPerBot, numberOfBotsOnShowdown > 1);
	}