Contract 0xf1cF07Fe21b7dC6cf8b196Fe978ec94ed0c106a5 1

 
Txn Hash Method
Block
From
To
Value [Txn Fee]
0x4dbb9a1a8cdab1b089fdec6b6135041d6134366c62a15e05c15d87686fe3f607Withdraw111238362021-09-22 2:03:5224 days 9 hrs ago0xdff9f2cd9f64472b7543560403121863add22cd2 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00054386
0x144bbef169854158ef708ba310ce837d09b4349dfeddbe59c044a0e5923832eeWithdraw107557992021-09-09 5:45:0937 days 6 hrs ago0x5072376e418cb1c4bf0695db8943db79ff661879 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00054392
0x4d5e25cbab0d3e4314ad332867b1e6632ac3374c509200299f51e9e2995fcaacWithdraw106003152021-09-03 19:03:5642 days 16 hrs ago0xf29108e59c8155b8856321e94aaeb9c3def7c7a0 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00020134
0x3c009dd2513aefe5f30f52cdc93d79c3c9f756c21f7b10944d1a51c09b1bdc37Withdraw105995472021-09-03 18:25:1942 days 17 hrs ago0xf29108e59c8155b8856321e94aaeb9c3def7c7a0 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00035122
0xe00c173509435749689056a367f588c45a4dead802a7fca6d132e37c1f0eecc9Withdraw105995062021-09-03 18:23:1642 days 17 hrs ago0xf29108e59c8155b8856321e94aaeb9c3def7c7a0 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00042622
0xbe8afc020d6ee0373156373534bb98b594a4c9d9711f0c1e4d2cfaa9109beeb2Deposit105987872021-09-03 17:47:1942 days 18 hrs ago0xf29108e59c8155b8856321e94aaeb9c3def7c7a0 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000594155
0x7d95650e686e8620c114d83099046c8b3b157ef7c8538ba6803beed9e2d0b133Withdraw105853572021-09-03 6:22:0743 days 5 hrs ago0x2a00123c263b240a57435d5394977d0adaca1113 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00027634
0x565218492bdb59098758bbe68f963e00e1f7849c76e604cfd5642613b649e00dWithdraw105588682021-09-02 8:02:2944 days 3 hrs ago0x095d2fd1dd2fc5cd48b4e0da2e13041587b8ff3d IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00054386
0xafc36edbcead9b0f1b24467c7f28e365bde13db955a254fc0e10cb28f154f375Deposit105548022021-09-02 4:36:3344 days 7 hrs ago0x2a00123c263b240a57435d5394977d0adaca1113 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000594155
0xd59c6dfc4422886e51dc14749fe0b8b7b1e3f8b3f830c96fe03c500f4060f144Deposit104630012021-08-29 22:54:5547 days 13 hrs ago0x81db2e41e0292bfcf68676dfba91ac7bf47c62b4 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00043078
0x6cf5ebf93980772f69a7d63fe1cdb714ecf458ee1768525f292d9d9ab8f60d6aWithdraw104008292021-08-27 18:44:2249 days 17 hrs ago0xc6e8d130aea5e814c02b44045766d2a344a3445f IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00027634
0xd7ce227dfde83318a005dfc62f073adb014de0ed24e6ad749e6636ee575ca262Withdraw103994212021-08-27 17:33:0949 days 18 hrs ago0xd39c8350b1e6a28e81ece14abb855cd9ff942cb4 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.0002764
0xf2e4050ce73765d4f1c44dff81db83e78e3cedc943a116888dd533d70461c3b5Withdraw103989712021-08-27 17:10:3849 days 18 hrs ago0xfa616976ddc05af4690e44448d41ec696f03f7ad IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00011287
0x7fd346043e9a89896e21e52519a8a07645867dfe848fb60d6a2831533eb7ff65Withdraw103989702021-08-27 17:10:3549 days 18 hrs ago0xfa616976ddc05af4690e44448d41ec696f03f7ad IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000394395
0xb0b37bc2d03c6ef733edda709c6392efba2fe41c2de021a969740b2bc71047b5Deposit103946872021-08-27 12:45:4549 days 23 hrs ago0xd39c8350b1e6a28e81ece14abb855cd9ff942cb4 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000594215
0x5035ce7bf54ebdaaaa41958ce8c334c63df562e0799abd266615eb3989d6ed06Withdraw103868322021-08-27 6:09:2150 days 5 hrs ago0x7cff8e17a167d4d37e1c8f06cb2ea30db857f05d IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.0002764
0x10b4ee80c61d5d6f1fe09caa9a3d9d03a4559f92d319b44c2a860e7c846a659cDeposit103677632021-08-26 14:15:3750 days 21 hrs ago0xc6e8d130aea5e814c02b44045766d2a344a3445f IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000594155
0x2367c31ea77ae258aec6a2fd58222f5fba0104cff6c953eef1f9a64b7ca6d1b0Withdraw101753822021-08-19 21:02:3057 days 14 hrs ago0xb08fb03042c0ed26bb6f6787c44653b27b6d3c33 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.0002764
0xe9d48eceafe068aac143a1017f86145a7cb506050b852ceb13146397db399753Withdraw101753242021-08-19 20:59:3657 days 14 hrs ago0xc645702daf9cc74b8456172606961e8411c0ad83 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.0002014
0x52ac3ee93b4c6b6cfb3ed09a25e4317a0f7ac3b0ab8596ee2560d03dd22520fdDeposit101751992021-08-19 20:53:2157 days 15 hrs ago0xc645702daf9cc74b8456172606961e8411c0ad83 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00035578
0x11b459f753c460b6d44a1e31366a0a849cc2ca2512381cad416afe8083d1047bWithdraw101672482021-08-19 14:13:0857 days 21 hrs ago0x43bd06e6e905805fa126627bcef910112aa8b3d4 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00027622
0xb5a8204d9b53603e24bae03a57005bc236d12b4405fb6f4dc803be20309f2e3dDeposit101672302021-08-19 14:12:1457 days 21 hrs ago0x43bd06e6e905805fa126627bcef910112aa8b3d4 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00043078
0x3d29ed23eea3fb3357e3a33e7a01c275e5269ac02b30b40b480840c6ef1e7accDeposit101605122021-08-19 8:28:5058 days 3 hrs ago0xb08fb03042c0ed26bb6f6787c44653b27b6d3c33 IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00035578
0xa970f6dedc32c0dc0db3efc9663486cfaf0dd90a8182bd0858410f3d7c184f04Withdraw101375032021-08-18 13:13:5458 days 22 hrs ago0xdb5ff533930ffc4f5b9a73ca902d61a470cb0f7c IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.00027628
0xfabbcd50c6bd0bd893f6aca668a4ab60dfd2e958123677402b4fb98a856b60b3Deposit101374482021-08-18 13:11:0958 days 22 hrs ago0xdb5ff533930ffc4f5b9a73ca902d61a470cb0f7c IN  0xf1cf07fe21b7dc6cf8b196fe978ec94ed0c106a50 BNB0.000669095
[ Download CSV Export 
Parent Txn Hash Block From To Value
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
CommunityReward

Compiler Version
v0.8.4+commit.c7e474f2

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity Standard Json-Input format)

File 1 of 7 : CommunityReward.sol
pragma solidity ^0.8.0;
import '@openzeppelin/contracts/access/Ownable.sol';
import '@openzeppelin/contracts/utils/math/SafeMath.sol';
import './interfaces/IBEP20.sol';
import "./libraries/SafeBEP20.sol";

//  referral
interface CssReferral {
    function setCssReferral(address farmer, address referrer) external;

    function getCssReferral(address farmer) external view returns (address);
}

contract CommunityReward is Ownable {
    using SafeBEP20 for IBEP20;
    using SafeMath for uint256;

    // Info of each user.
    struct UserInfo {
        uint256 amount;     // How many LP tokens the user has provided.
        uint256 rewardDebt; // Reward debt. See explanation below.
    }

    // Info of each pool.
    struct PoolInfo {
        IBEP20 stakeToken;         // Address of LP token contract.
        uint256 lastRewardBlock;  // Last block number that RewardToken distribution occurs.
        uint256 accRewardTokenPerShare; // Accumulated RewardToken per share, times 1e12. See below.
    }

    // The StakeToken! (this can be also an CS-LP token)
    IBEP20 public immutable stakeToken;

    // Token that will be used as a reward for Staking.
    IBEP20 public immutable rewardToken;

    // Token reward created per block.
    uint256 public immutable rewardPerBlock;

    // Info of pool.
    PoolInfo public poolInfo;
    // Info of each user that stakes LP/Tokens.
    mapping (address => UserInfo) public userInfo;
    // The block number when StakeToken mining starts.
    uint256 public immutable startBlock;
    // The block number when StakeToken mining ends.
    uint256 public immutable endBlock;

    // Burn address
    address public burnAddress;
    // Treasury address
    address public divPoolAddress;

    // Referral fee that is fixed on 15%
    uint256 public constant DIV_REFERRAL_FEE = 1500;

    //Fees to burn and treasury
    uint256 public immutable divPoolFee;
    uint256 public immutable divBurnFee;

    // Referral contract address
    address public rewardReferral;

    event Deposit(address indexed user, uint256 amount);
    event Withdraw(address indexed user, uint256 amount);
    event EmergencyWithdraw(address indexed user, uint256 amount);
    event RewardWithdraw(address indexed user, uint256 amount);
    event StopReward(address indexed user, uint256 _endBlock);
    event RewardPaid(address indexed user, uint256 reward);
    event ReferralPaid(address indexed user, address indexed userTo, uint256 reward);
    event SetRewardReferralAddress(address indexed sender, address indexed referralAddress);
    event SetDevPoolAddress(address indexed sender, address indexed divPoolAddress);
    event SetBurnAddress(address indexed sender, address indexed burnAddress);

    constructor(
        IBEP20 _stakeToken, //token which will be staked
        IBEP20 _rewardToken, //token which will be a reward for staking
        address _burnAddress, //address for burn fee
        address _divPoolAddress, //address for treasury fee
        uint256 _rewardPerBlock, //number of token rewards per block
        uint256 _startBlock, //when the pool will start
        uint256 _endBlock, // when the pool will end
        uint256 _divPoolFee, //fee to treasury on deposit
        uint256 _divBurnFee //fee to burn tokens
    ) {
        require(_divPoolFee.add(_divBurnFee) <= 500, 'Total fee cannot be higher than 5%');
        stakeToken = _stakeToken;
        rewardToken = _rewardToken;
        burnAddress = _burnAddress;
        divPoolAddress = _divPoolAddress;
        rewardPerBlock = _rewardPerBlock;
        startBlock = _startBlock;
        endBlock = _endBlock;
        divPoolFee = _divPoolFee;
        divBurnFee = _divBurnFee;

        // staking pool
        poolInfo = PoolInfo({
            stakeToken: _stakeToken,
            lastRewardBlock: _startBlock,
            accRewardTokenPerShare: 0
        });
    }

    // Return reward multiplier over the given _from to _to block.
    function getMultiplierForBlocks(uint256 _from, uint256 _to) public view returns (uint256) {
        if (_to <= endBlock) {
            return _to.sub(_from);
        } else if (_from >= endBlock) {
            return 0;
        } else {
            return endBlock.sub(_from);
        }
    }

    // View function to see pending Reward on frontend.
    function pendingReward(address _user) external view returns (uint256) {
        PoolInfo storage pool = poolInfo;
        UserInfo storage user = userInfo[_user];
        uint256 accRewardTokenPerShare = pool.accRewardTokenPerShare;
        uint256 stakeTokenSupply = pool.stakeToken.balanceOf(address(this));
        if (block.number > pool.lastRewardBlock && stakeTokenSupply != 0) {
            uint256 multiplier = getMultiplierForBlocks(pool.lastRewardBlock, block.number);
            uint256 rewardTokenReward = multiplier.mul(rewardPerBlock);
            accRewardTokenPerShare = accRewardTokenPerShare.add(rewardTokenReward.mul(1e12).div(stakeTokenSupply));
        }
        return user.amount.mul(accRewardTokenPerShare).div(1e12).sub(user.rewardDebt);
    }

    // Update reward variables of the given pool to be up-to-date.
    function updatePool() public {
        PoolInfo storage pool = poolInfo;
        if (block.number <= pool.lastRewardBlock) {
            return;
        }
        uint256 stakeTokenSupply = pool.stakeToken.balanceOf(address(this));
        if (stakeTokenSupply == 0) {
            pool.lastRewardBlock = block.number;
            return;
        }
        uint256 multiplier = getMultiplierForBlocks(pool.lastRewardBlock, block.number);
        uint256 rewardTokenReward = multiplier.mul(rewardPerBlock);
        pool.accRewardTokenPerShare = pool.accRewardTokenPerShare.add(rewardTokenReward.mul(1e12).div(stakeTokenSupply));
        pool.lastRewardBlock = block.number;
    }

    // Stake StakeToken and Harvest rewardTokens to CommunityReward
    function deposit(uint256 _amount, address referrer) public {
        PoolInfo storage pool = poolInfo;
        UserInfo storage user = userInfo[msg.sender];

        // anti -backdoor
        require((block.number >= pool.lastRewardBlock || _amount == 0), "pool didnt start yet");

        updatePool();
        if (_amount > 0 && rewardReferral != address(0) && referrer != address(0)) {
            CssReferral(rewardReferral).setCssReferral(msg.sender, referrer);
        }

        if (user.amount > 0) {
            uint256 pending = user.amount.mul(pool.accRewardTokenPerShare).div(1e12).sub(user.rewardDebt);
            if(pending > 0) {
                payRefFees(pending);

                rewardToken.safeTransfer(address(msg.sender), pending);
                emit RewardPaid(msg.sender, pending);
            }
        }

        if(_amount > 0) {
            pool.stakeToken.safeTransferFrom(address(msg.sender), address(this), _amount);
            // if divPoolFee = 375 ==>  375 * 1/10000 = 3,75% fee
            uint256 treasuryFee = _amount.mul(divPoolFee).div(10000);
            pool.stakeToken.safeTransfer(divPoolAddress, treasuryFee);

            // if divBurnFee = 125 ==>  125 * 1/10000 = 1,25% fee
            uint256 burnFee = _amount.mul(divBurnFee).div(10000);
            pool.stakeToken.safeTransfer(burnAddress, burnFee);

            user.amount = user.amount.add(_amount).sub(treasuryFee).sub(burnFee);
        }
        user.rewardDebt = user.amount.mul(pool.accRewardTokenPerShare).div(1e12);

        emit Deposit(msg.sender, _amount);
    }


    // Withdraw StakeToken tokens from farm.
    function withdraw(uint256 _amount) external {
        PoolInfo storage pool = poolInfo;
        UserInfo storage user = userInfo[msg.sender];
        require(user.amount >= _amount, "withdraw: not good");
        updatePool();
        uint256 pending = user.amount.mul(pool.accRewardTokenPerShare).div(1e12).sub(user.rewardDebt);
        if(pending > 0) {
            payRefFees(pending);

            rewardToken.safeTransfer(address(msg.sender), pending);
            emit RewardPaid(msg.sender, pending);
        }
        if(_amount > 0) {
            user.amount = user.amount.sub(_amount);
            pool.stakeToken.safeTransfer(address(msg.sender), _amount);
        }
        user.rewardDebt = user.amount.mul(pool.accRewardTokenPerShare).div(1e12);

        emit Withdraw(msg.sender, _amount);
    }

    // Pay referrals equal to the 15% of pending amount
    function payRefFees(uint256 pending) internal
    {
        // 15%
        uint256 toReferral = pending.mul(DIV_REFERRAL_FEE).div(10000);

        address referrer = address(0);
        if (rewardReferral != address(0)) {
            referrer = CssReferral(rewardReferral).getCssReferral(msg.sender);
        }

        if (referrer != address(0)) {// send commission to referrer
            rewardToken.safeTransfer(referrer, toReferral);
            emit ReferralPaid(msg.sender, referrer, toReferral);
        }
    }


    // Withdraw without caring about rewards. EMERGENCY ONLY.
    function emergencyWithdraw() public {
        PoolInfo storage pool = poolInfo;
        UserInfo storage user = userInfo[msg.sender];
        pool.stakeToken.safeTransfer(address(msg.sender), user.amount);
        emit EmergencyWithdraw(msg.sender, user.amount);
        user.amount = 0;
        user.rewardDebt = 0;
    }

    /* Withdraw reward to the treasury.
     Because of the referrals its hard to calculate exact reward tokens needed to be reserved for rewards.
     For that reason owner will provide 115% of the value and can withdraw remaining tokens 10 days after farm is closed*/
    function rewardWithdraw() public onlyOwner {
        require(endBlock <= block.number + 288000, "It too early to withdraw reward tokens"); //10 days
        uint256 balance = rewardToken.balanceOf(address(this));
        rewardToken.safeTransfer(divPoolAddress, balance);
        emit RewardWithdraw(msg.sender, balance);
    }

    // Set address of CSSReferral contract
    function setRewardReferral(address _rewardReferral) external onlyOwner {
        rewardReferral = _rewardReferral;
        emit SetRewardReferralAddress(msg.sender, _rewardReferral);
    }


    // Update treasury address by the owner.
    function setDivPoolAddress(address _divPoolAddress) public onlyOwner {
        divPoolAddress = _divPoolAddress;
        emit SetDevPoolAddress(msg.sender, _divPoolAddress);
    }

    // Update burn address by the owner.
    function setBurnAddress(address _burnAddr) public onlyOwner {
        burnAddress = _burnAddr;
        emit SetBurnAddress(msg.sender, _burnAddr);
    }
}

File 2 of 7 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Context.sol";
/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor () {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), msgSender);
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = address(0);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

File 3 of 7 : SafeMath.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

// CAUTION
// This version of SafeMath should only be used with Solidity 0.8 or later,
// because it relies on the compiler's built in overflow checks.

/**
 * @dev Wrappers over Solidity's arithmetic operations.
 *
 * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler
 * now has built in overflow checking.
 */
library SafeMath {
    /**
     * @dev Returns the addition of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            uint256 c = a + b;
            if (c < a) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the substraction of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b > a) return (false, 0);
            return (true, a - b);
        }
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, with an overflow flag.
     *
     * _Available since v3.4._
     */
    function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
            // benefit is lost if 'b' is also tested.
            // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
            if (a == 0) return (true, 0);
            uint256 c = a * b;
            if (c / a != b) return (false, 0);
            return (true, c);
        }
    }

    /**
     * @dev Returns the division of two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a / b);
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag.
     *
     * _Available since v3.4._
     */
    function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) {
        unchecked {
            if (b == 0) return (false, 0);
            return (true, a % b);
        }
    }

    /**
     * @dev Returns the addition of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `+` operator.
     *
     * Requirements:
     *
     * - Addition cannot overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        return a + b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting on
     * overflow (when the result is negative).
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        return a - b;
    }

    /**
     * @dev Returns the multiplication of two unsigned integers, reverting on
     * overflow.
     *
     * Counterpart to Solidity's `*` operator.
     *
     * Requirements:
     *
     * - Multiplication cannot overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        return a * b;
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `/` operator.
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        return a / b;
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting when dividing by zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        return a % b;
    }

    /**
     * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
     * overflow (when the result is negative).
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {trySub}.
     *
     * Counterpart to Solidity's `-` operator.
     *
     * Requirements:
     *
     * - Subtraction cannot overflow.
     */
    function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b <= a, errorMessage);
            return a - b;
        }
    }

    /**
     * @dev Returns the integer division of two unsigned integers, reverting with custom message on
     * division by zero. The result is rounded towards zero.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Counterpart to Solidity's `/` operator. Note: this function uses a
     * `revert` opcode (which leaves remaining gas untouched) while Solidity
     * uses an invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a / b;
        }
    }

    /**
     * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
     * reverting with custom message when dividing by zero.
     *
     * CAUTION: This function is deprecated because it requires allocating memory for the error
     * message unnecessarily. For custom revert reasons use {tryMod}.
     *
     * Counterpart to Solidity's `%` operator. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * Requirements:
     *
     * - The divisor cannot be zero.
     */
    function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
        unchecked {
            require(b > 0, errorMessage);
            return a % b;
        }
    }
}

File 4 of 7 : IBEP20.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.6.4;

interface IBEP20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns the token decimals.
     */
    function decimals() external view returns (uint8);

    /**
     * @dev Returns the token symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the token name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the bep token owner.
     */
    function getOwner() external view returns (address);

    /**
     * @dev Returns the amount of tokens owned by `account`.
     */
    function balanceOf(address account) external view returns (uint256);

    /**
     * @dev Moves `amount` tokens from the caller's account to `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Returns the remaining number of tokens that `spender` will be
     * allowed to spend on behalf of `owner` through {transferFrom}. This is
     * zero by default.
     *
     * This value changes when {approve} or {transferFrom} are called.
     */
    function allowance(address _owner, address spender) external view returns (uint256);

    /**
     * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * IMPORTANT: Beware that changing an allowance with this method brings the risk
     * that someone may use both the old and the new allowance by unfortunate
     * transaction ordering. One possible solution to mitigate this race
     * condition is to first reduce the spender's allowance to 0 and set the
     * desired value afterwards:
     * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
     *
     * Emits an {Approval} event.
     */
    function approve(address spender, uint256 amount) external returns (bool);

    /**
     * @dev Moves `amount` tokens from `sender` to `recipient` using the
     * allowance mechanism. `amount` is then deducted from the caller's
     * allowance.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);

    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

    /**
     * @dev Emitted when the allowance of a `spender` for an `owner` is set by
     * a call to {approve}. `value` is the new allowance.
     */
    event Approval(address indexed owner, address indexed spender, uint256 value);
}

File 5 of 7 : SafeBEP20.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "../interfaces/IBEP20.sol";
import '@openzeppelin/contracts/utils/Address.sol';
import '@openzeppelin/contracts/utils/math/SafeMath.sol';

/**
 * @title SafeBEP20
 * @dev Wrappers around BEP20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeBEP20 for IBEP20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeBEP20 {
    using SafeMath for uint256;
    using Address for address;

    function safeTransfer(IBEP20 token, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(IBEP20 token, address from, address to, uint256 value) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IBEP20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(IBEP20 token, address spender, uint256 value) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        // solhint-disable-next-line max-line-length
        require((value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeBEP20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(IBEP20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).add(value);
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(IBEP20 token, address spender, uint256 value) internal {
        uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeBEP20: decreased allowance below zero");
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IBEP20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeBEP20: low-level call failed");
        if (returndata.length > 0) { // Return data is optional
            // solhint-disable-next-line max-line-length
            require(abi.decode(returndata, (bool)), "SafeBEP20: BEP20 operation did not succeed");
        }
    }
}

File 6 of 7 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/*
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

File 7 of 7 : Address.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        // solhint-disable-next-line no-inline-assembly
        assembly { size := extcodesize(account) }
        return size > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain`call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
      return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: value }(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.staticcall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 200
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract IBEP20","name":"_stakeToken","type":"address"},{"internalType":"contract IBEP20","name":"_rewardToken","type":"address"},{"internalType":"address","name":"_burnAddress","type":"address"},{"internalType":"address","name":"_divPoolAddress","type":"address"},{"internalType":"uint256","name":"_rewardPerBlock","type":"uint256"},{"internalType":"uint256","name":"_startBlock","type":"uint256"},{"internalType":"uint256","name":"_endBlock","type":"uint256"},{"internalType":"uint256","name":"_divPoolFee","type":"uint256"},{"internalType":"uint256","name":"_divBurnFee","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"address","name":"userTo","type":"address"},{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"}],"name":"ReferralPaid","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"}],"name":"RewardPaid","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"RewardWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"burnAddress","type":"address"}],"name":"SetBurnAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"divPoolAddress","type":"address"}],"name":"SetDevPoolAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"address","name":"referralAddress","type":"address"}],"name":"SetRewardReferralAddress","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_endBlock","type":"uint256"}],"name":"StopReward","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[],"name":"DIV_REFERRAL_FEE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"burnAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"address","name":"referrer","type":"address"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"divBurnFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"divPoolAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"divPoolFee","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"endBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_from","type":"uint256"},{"internalType":"uint256","name":"_to","type":"uint256"}],"name":"getMultiplierForBlocks","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"}],"name":"pendingReward","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"poolInfo","outputs":[{"internalType":"contract IBEP20","name":"stakeToken","type":"address"},{"internalType":"uint256","name":"lastRewardBlock","type":"uint256"},{"internalType":"uint256","name":"accRewardTokenPerShare","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardPerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardReferral","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardToken","outputs":[{"internalType":"contract IBEP20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_burnAddr","type":"address"}],"name":"setBurnAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_divPoolAddress","type":"address"}],"name":"setDivPoolAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_rewardReferral","type":"address"}],"name":"setRewardReferral","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stakeToken","outputs":[{"internalType":"contract IBEP20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"startBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"updatePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"userInfo","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101606040523480156200001257600080fd5b5060405162001ab838038062001ab88339810160408190526200003591620001a8565b600080546001600160a01b031916339081178255604051909182917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a3506101f46200009382846200019360201b620010ce1790919060201c565b1115620000f15760405162461bcd60e51b815260206004820152602260248201527f546f74616c206665652063616e6e6f7420626520686967686572207468616e20604482015261352560f01b606482015260840160405180910390fd5b6001600160601b031960608a811b821660805298891b1660a052600580546001600160a01b039889166001600160a01b031991821617909155600680549789169782169790971790965560c09490945260e0839052610100919091526101205261014091909152604080519485018152929094168084526020840185905260009390920183905260018054909116909117905560029190915560035562000280565b6000620001a1828462000242565b9392505050565b60008060008060008060008060006101208a8c031215620001c7578485fd5b8951620001d48162000267565b60208b0151909950620001e78162000267565b60408b0151909850620001fa8162000267565b60608b01519097506200020d8162000267565b8096505060808a0151945060a08a0151935060c08a0151925060e08a015191506101008a015190509295985092959850929598565b600082198211156200026257634e487b7160e01b81526011600452602481fd5b500190565b6001600160a01b03811681146200027d57600080fd5b50565b60805160601c60a05160601c60c05160e05161010051610120516101405161177c6200033c6000396000818161029a01526109b501526000818161021101526109640152600081816101ac015281816104da01528181610512015281816105440152610c02015260006102c10152600081816103a301528181610e42015261105401526000818161042c01528181610628015281816108da01528181610c9601528181610d2c01526111ca015260006102fb015261177c6000f3fe608060405234801561001057600080fd5b506004361061018d5760003560e01c80636e553f65116100de578063db2e21bc11610097578063f2fde38b11610071578063f2fde38b14610401578063f40f0f5214610414578063f7c618c114610427578063fc3964ed1461044e57600080fd5b8063db2e21bc146103e9578063df5d0341146103f1578063e3161ddd146103f957600080fd5b80636e553f651461037057806370d5ae0514610383578063715018a6146103965780638ae39cac1461039e5780638da5cb5b146103c55780638f3eef5f146103d657600080fd5b80632e1a7d4d1161014b5780634b0e7216116101255780634b0e7216146102e357806351ed6a30146102f65780635a2f3d091461031d57806367bed16a1461035d57600080fd5b80632e1a7d4d1461028257806334d3a6871461029557806348cd4cb1146102bc57600080fd5b80622dcfb914610192578063083c6323146101a75780630cdb43c4146101e1578063115ee2131461020c5780631959a002146102335780631b3a99a71461026f575b600080fd5b6101a56101a0366004611522565b610457565b005b6101ce7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020015b60405180910390f35b6007546101f4906001600160a01b031681565b6040516001600160a01b0390911681526020016101d8565b6101ce7f000000000000000000000000000000000000000000000000000000000000000081565b61025a610241366004611522565b6004602052600090815260409020805460019091015482565b604080519283526020830191909152016101d8565b6101ce61027d3660046115d9565b6104d6565b6101a561029036600461157a565b61056f565b6101ce7f000000000000000000000000000000000000000000000000000000000000000081565b6101ce7f000000000000000000000000000000000000000000000000000000000000000081565b6101a56102f1366004611522565b61070b565b6101f47f000000000000000000000000000000000000000000000000000000000000000081565b600154600254600354610338926001600160a01b0316919083565b604080516001600160a01b0390941684526020840192909252908201526060016101d8565b6006546101f4906001600160a01b031681565b6101a561037e3660046115aa565b610781565b6005546101f4906001600160a01b031681565b6101a5610a6e565b6101ce7f000000000000000000000000000000000000000000000000000000000000000081565b6000546001600160a01b03166101f4565b6101a56103e4366004611522565b610ae2565b6101a5610b58565b6101a5610bc9565b6101a5610d8d565b6101a561040f366004611522565b610e9d565b6101ce610422366004611522565b610f87565b6101f47f000000000000000000000000000000000000000000000000000000000000000081565b6101ce6105dc81565b6000546001600160a01b0316331461048a5760405162461bcd60e51b815260040161048190611649565b60405180910390fd5b600780546001600160a01b0319166001600160a01b03831690811790915560405133907fc38d5241a0e3b11cbb7fa74cfaa9cf418dc3f696f245702ae5ac7ed98a745a9e90600090a350565b60007f000000000000000000000000000000000000000000000000000000000000000082116105105761050982846110e1565b9050610569565b7f0000000000000000000000000000000000000000000000000000000000000000831061053f57506000610569565b6105097f0000000000000000000000000000000000000000000000000000000000000000846110e1565b92915050565b3360009081526004602052604090208054600191908311156105c85760405162461bcd60e51b81526020600482015260126024820152711dda5d1a191c985dce881b9bdd0819dbdbd960721b6044820152606401610481565b6105d0610d8d565b600061060a826001015461060464e8d4a510006105fe876002015487600001546110ed90919063ffffffff16565b906110f9565b906110e1565b905080156106855761061b81611105565b61064f6001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163383611237565b60405181815233907fe2403640ba68fed3a2f88b7557551d1993f84b99bb10ff833f0cf8db0c5e04869060200160405180910390a25b83156106af57815461069790856110e1565b825582546106af906001600160a01b03163386611237565b600283015482546106ca9164e8d4a51000916105fe916110ed565b600183015560405184815233907f884edad9ce6fa2440d8a54cc123490eb96d2768479d49ff9c7366125a9424364906020015b60405180910390a250505050565b6000546001600160a01b031633146107355760405162461bcd60e51b815260040161048190611649565b600580546001600160a01b0319166001600160a01b03831690811790915560405133907f4a776f62b8dbd1d1307ad396609f9eaec90260598c090dd09f3375b7770b662890600090a350565b33600090815260046020526040902060025460019190431015806107a3575083155b6107e65760405162461bcd60e51b81526020600482015260146024820152731c1bdbdb08191a591b9d081cdd185c9d081e595d60621b6044820152606401610481565b6107ee610d8d565b60008411801561080857506007546001600160a01b031615155b801561081c57506001600160a01b03831615155b15610887576007546040516315403fe160e21b81523360048201526001600160a01b03858116602483015290911690635500ff8490604401600060405180830381600087803b15801561086e57600080fd5b505af1158015610882573d6000803e3d6000fd5b505050505b8054156109395760006108bc826001015461060464e8d4a510006105fe876002015487600001546110ed90919063ffffffff16565b90508015610937576108cd81611105565b6109016001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000163383611237565b60405181815233907fe2403640ba68fed3a2f88b7557551d1993f84b99bb10ff833f0cf8db0c5e04869060200160405180910390a25b505b8315610a1c578154610956906001600160a01b031633308761129a565b60006109886127106105fe877f00000000000000000000000000000000000000000000000000000000000000006110ed565b60065484549192506109a7916001600160a01b03908116911683611237565b60006109d96127106105fe887f00000000000000000000000000000000000000000000000000000000000000006110ed565b60055485549192506109f8916001600160a01b03908116911683611237565b610a1781610604846106048a88600001546110ce90919063ffffffff16565b835550505b60028201548154610a379164e8d4a51000916105fe916110ed565b600182015560405184815233907fe1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109c906020016106fd565b6000546001600160a01b03163314610a985760405162461bcd60e51b815260040161048190611649565b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b03163314610b0c5760405162461bcd60e51b815260040161048190611649565b600680546001600160a01b0319166001600160a01b03831690811790915560405133907fefe191d36b9f8ee74a6a95afa1bce88e29be33cf3976724b8d77db7d1f2a348890600090a350565b3360008181526004602052604090208054600180549093610b84926001600160a01b0390921691611237565b805460405190815233907f5fafa99d0643513820be26656b45130b01e1c03062e1266bf36f88cbd3bd96959060200160405180910390a2600080825560019091015550565b6000546001600160a01b03163314610bf35760405162461bcd60e51b815260040161048190611649565b610c00436204650061167e565b7f00000000000000000000000000000000000000000000000000000000000000001115610c7e5760405162461bcd60e51b815260206004820152602660248201527f497420746f6f206561726c7920746f2077697468647261772072657761726420604482015265746f6b656e7360d01b6064820152608401610481565b6040516370a0823160e01b81523060048201526000907f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a082319060240160206040518083038186803b158015610ce057600080fd5b505afa158015610cf4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d189190611592565b600654909150610d55906001600160a01b037f00000000000000000000000000000000000000000000000000000000000000008116911683611237565b60405181815233907f6553897c25961cd3a105492c25576d0552123ee868aca283e90f3b4224d7d1779060200160405180910390a250565b6002546001904311610d9c5750565b80546040516370a0823160e01b81523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b158015610ddf57600080fd5b505afa158015610df3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e179190611592565b905080610e28575043600190910155565b6000610e388360010154436104d6565b90506000610e66827f00000000000000000000000000000000000000000000000000000000000000006110ed565b9050610e89610e7e846105fe8464e8d4a510006110ed565b6002860154906110ce565b600285015550504360019092019190915550565b6000546001600160a01b03163314610ec75760405162461bcd60e51b815260040161048190611649565b6001600160a01b038116610f2c5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610481565b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b0381811660009081526004602081905260408083206003546001805493516370a0823160e01b81523095810195909552949591939092869216906370a082319060240160206040518083038186803b158015610fe957600080fd5b505afa158015610ffd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110219190611592565b905083600101544311801561103557508015155b1561109c57600061104a8560010154436104d6565b90506000611078827f00000000000000000000000000000000000000000000000000000000000000006110ed565b9050611097611090846105fe8464e8d4a510006110ed565b85906110ce565b935050505b6110c4836001015461060464e8d4a510006105fe8688600001546110ed90919063ffffffff16565b9695505050505050565b60006110da828461167e565b9392505050565b60006110da82846116d5565b60006110da82846116b6565b60006110da8284611696565b60006111196127106105fe846105dc6110ed565b6007549091506000906001600160a01b0316156111ae57600754604051632087569360e01b81523360048201526001600160a01b039091169063208756939060240160206040518083038186803b15801561117357600080fd5b505afa158015611187573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111ab919061153e565b90505b6001600160a01b03811615611232576111f16001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000168284611237565b6040518281526001600160a01b0382169033907f0a721ab4682ceb61c7e4d264ef879fc419a6d764b136e7d96ef54b2053c756739060200160405180910390a35b505050565b6040516001600160a01b03831660248201526044810182905261123290849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b0319909316929092179091526112d8565b6040516001600160a01b03808516602483015283166044820152606481018290526112d29085906323b872dd60e01b90608401611263565b50505050565b600061132d826040518060400160405280602081526020017f5361666542455032303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b03166113aa9092919063ffffffff16565b805190915015611232578080602001905181019061134b919061155a565b6112325760405162461bcd60e51b815260206004820152602a60248201527f5361666542455032303a204245503230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b6064820152608401610481565b60606113b984846000856113c1565b949350505050565b6060824710156114225760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b6064820152608401610481565b843b6114705760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610481565b600080866001600160a01b0316858760405161148c91906115fa565b60006040518083038185875af1925050503d80600081146114c9576040519150601f19603f3d011682016040523d82523d6000602084013e6114ce565b606091505b50915091506114de8282866114e9565b979650505050505050565b606083156114f85750816110da565b8251156115085782518084602001fd5b8160405162461bcd60e51b81526004016104819190611616565b600060208284031215611533578081fd5b81356110da8161172e565b60006020828403121561154f578081fd5b81516110da8161172e565b60006020828403121561156b578081fd5b815180151581146110da578182fd5b60006020828403121561158b578081fd5b5035919050565b6000602082840312156115a3578081fd5b5051919050565b600080604083850312156115bc578081fd5b8235915060208301356115ce8161172e565b809150509250929050565b600080604083850312156115eb578182fd5b50508035926020909101359150565b6000825161160c8184602087016116ec565b9190910192915050565b60208152600082518060208401526116358160408501602087016116ec565b601f01601f19169190910160400192915050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6000821982111561169157611691611718565b500190565b6000826116b157634e487b7160e01b81526012600452602481fd5b500490565b60008160001904831182151516156116d0576116d0611718565b500290565b6000828210156116e7576116e7611718565b500390565b60005b838110156117075781810151838201526020016116ef565b838111156112d25750506000910152565b634e487b7160e01b600052601160045260246000fd5b6001600160a01b038116811461174357600080fd5b5056fea2646970667358221220090f9ea69c75adf05d67bcc6446d945f93603a51f8eb36b4f8d3d8013fce5c6e64736f6c634300080400330000000000000000000000003bc5798416c1122bcfd7cb0e055d50061f23850d000000000000000000000000f8a0bf9cf54bb92f17374d9e9a321e6a111a51bd000000000000000000000000000000000000000000000000000000000000dead0000000000000000000000005f1b8c1865e01271fd095a0eae19a3d88d1971b60000000000000000000000000000000000000000000000000011c37937e08000000000000000000000000000000000000000000000000000000000000073a3cc00000000000000000000000000000000000000000000000000000000008e01cc000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001f4

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

0000000000000000000000003bc5798416c1122bcfd7cb0e055d50061f23850d000000000000000000000000f8a0bf9cf54bb92f17374d9e9a321e6a111a51bd000000000000000000000000000000000000000000000000000000000000dead0000000000000000000000005f1b8c1865e01271fd095a0eae19a3d88d1971b60000000000000000000000000000000000000000000000000011c37937e08000000000000000000000000000000000000000000000000000000000000073a3cc00000000000000000000000000000000000000000000000000000000008e01cc000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001f4

-----Decoded View---------------
Arg [0] : _stakeToken (address): 0x3bc5798416c1122bcfd7cb0e055d50061f23850d
Arg [1] : _rewardToken (address): 0xf8a0bf9cf54bb92f17374d9e9a321e6a111a51bd
Arg [2] : _burnAddress (address): 0x000000000000000000000000000000000000dead
Arg [3] : _divPoolAddress (address): 0x5f1b8c1865e01271fd095a0eae19a3d88d1971b6
Arg [4] : _rewardPerBlock (uint256): 5000000000000000
Arg [5] : _startBlock (uint256): 7578572
Arg [6] : _endBlock (uint256): 9306572
Arg [7] : _divPoolFee (uint256): 0
Arg [8] : _divBurnFee (uint256): 500

-----Encoded View---------------
9 Constructor Arguments found :
Arg [0] : 0000000000000000000000003bc5798416c1122bcfd7cb0e055d50061f23850d
Arg [1] : 000000000000000000000000f8a0bf9cf54bb92f17374d9e9a321e6a111a51bd
Arg [2] : 000000000000000000000000000000000000000000000000000000000000dead
Arg [3] : 0000000000000000000000005f1b8c1865e01271fd095a0eae19a3d88d1971b6
Arg [4] : 0000000000000000000000000000000000000000000000000011c37937e08000
Arg [5] : 000000000000000000000000000000000000000000000000000000000073a3cc
Arg [6] : 00000000000000000000000000000000000000000000000000000000008e01cc
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [8] : 00000000000000000000000000000000000000000000000000000000000001f4


Block Transaction Gas Used Reward
Age Block Fee Address BC Fee Address Voting Power Jailed Incoming
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.