function claimBonus() nonReentrant external {
    
    
    
    uint roundId = getIsRoundOver(RoundId) ? RoundId.add(1) : RoundId;
    uint previousRoundId = roundId.sub(1);
    bool isBonusClaimed = getIsBonusClaimed(previousRoundId, msg.sender);

    
    if (isBonusClaimed) {
      return;
    }

    
    
    bool isBonusUnlockExempt = getIsBonusUnlockExempt(previousRoundId, msg.sender);
    bool isBonusUnlocked = getPlayerClickCount(roundId, msg.sender) > 0;
    if (!isBonusUnlockExempt && !isBonusUnlocked) {
      return;
    }

    
    Round storage previousRound = Rounds[previousRoundId];
    uint playerClickCount = previousRound.playerClickCounts[msg.sender];
    uint roundClickCount = previousRound.clickCount;
    
    uint bonus = previousRound.totalBonus.mul(playerClickCount).div(roundClickCount);

    
    
    
    if (previousRound.activePlayer == msg.sender) {
      bonus = bonus.add(INITIAL_PRICE);
    }

    previousRound.bonusClaimedList[msg.sender] = true;
    previousRound.claimedBonus = previousRound.claimedBonus.add(bonus);
    sendPayment(msg.sender, bonus);

    
    LogClaimBonus(msg.sender, bonus);
  }