function finishRound() public {
        require(tokenPrice > tokenStartPrice);
        require(lastBuyBlock + newRoundDelay < block.number);

        lastBuyBlock = block.number;
        address owner = tokenOwner;
        uint price = tokenPrice;
        if (tokenPrice2>tokenPrice) {
            owner = tokenOwner2;
            price = tokenPrice2;
        }
        uint lastPaidPrice = price.mul(50).div(110);
        uint win = this.balance - lastPaidPrice;

        if (highestPrice < lastPaidPrice) {
            richestPlayer = owner;
            highestPrice = lastPaidPrice;
            richestRoundId = getRoundId()-1;
        }

        tokenPrice = tokenStartPrice;
        tokenPrice2 = tokenStartPrice2;
        tokenOwner = address(0);
        tokenOwner2 = address(0);

        payoutRound = getRoundId()-1;
        flips = 0;
        round++;
        NewRound(lastPaidPrice, win / 2, owner);

        contractOwner.transfer((this.balance - (lastPaidPrice + win / 2) - win / 10) * 19 / 20);
        owner.call.value(lastPaidPrice + win / 2).gas(24000)();
        if (richestPlayer!=address(0)) {
            payoutRound = richestRoundId;
            RichestBonus(win / 10, richestPlayer);
            richestPlayer.call.value(win / 10).gas(24000)();
        }
    }