ETH Price: $3,460.69 (+1.55%)
Gas: 9 Gwei

Contract

0xE25C43B59c04030bd9BB393f77D9F7DA1bdb73b9
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Value
Exit194486542024-03-16 16:31:47107 days ago1710606707IN
0xE25C43B5...A1bdb73b9
0 ETH0.0025541732.0782981
Exit191429442024-02-02 19:58:35149 days ago1706903915IN
0xE25C43B5...A1bdb73b9
0 ETH0.0018883419.52320426
Exit189863292024-01-11 21:22:59171 days ago1705008179IN
0xE25C43B5...A1bdb73b9
0 ETH0.0018196122.85289182
Exit179422822023-08-18 14:30:59318 days ago1692369059IN
0xE25C43B5...A1bdb73b9
0 ETH0.0025810541.28173937
Exit178316762023-08-03 3:05:47333 days ago1691031947IN
0xE25C43B5...A1bdb73b9
0 ETH0.001255915.77320619
Exit177950152023-07-29 0:06:47338 days ago1690589207IN
0xE25C43B5...A1bdb73b9
0 ETH0.001303720.85165259
Exit177247952023-07-19 4:13:59348 days ago1689740039IN
0xE25C43B5...A1bdb73b9
0 ETH0.0020992921.70416072
Exit175977702023-07-01 7:37:11366 days ago1688197031IN
0xE25C43B5...A1bdb73b9
0 ETH0.0012122715.2251758
Exit174649172023-06-12 15:40:11385 days ago1686584411IN
0xE25C43B5...A1bdb73b9
0 ETH0.0017334621.77096898
Exit173014482023-05-20 15:12:23408 days ago1684595543IN
0xE25C43B5...A1bdb73b9
0 ETH0.0044388245.89213722
Exit172777492023-05-17 7:01:59411 days ago1684306919IN
0xE25C43B5...A1bdb73b9
0 ETH0.0037227138.48838057
Exit170663892023-04-17 12:06:47441 days ago1681733207IN
0xE25C43B5...A1bdb73b9
0 ETH0.0023008228.89643246
Exit170624002023-04-16 22:31:47441 days ago1681684307IN
0xE25C43B5...A1bdb73b9
0 ETH0.0023067828.97136673
Exit170388992023-04-13 13:47:47445 days ago1681393667IN
0xE25C43B5...A1bdb73b9
0 ETH0.003192840.09901604
Exit170039032023-04-08 13:14:11450 days ago1680959651IN
0xE25C43B5...A1bdb73b9
0 ETH0.0018726319.36081191
Exit169988542023-04-07 20:05:59450 days ago1680897959IN
0xE25C43B5...A1bdb73b9
0 ETH0.001600220.09732719
Exit169792162023-04-05 1:01:23453 days ago1680656483IN
0xE25C43B5...A1bdb73b9
0 ETH0.0049320761.94284545
Exit169788402023-04-04 23:45:11453 days ago1680651911IN
0xE25C43B5...A1bdb73b9
0 ETH0.0015376724.59369739
Exit169612312023-04-02 11:52:35456 days ago1680436355IN
0xE25C43B5...A1bdb73b9
0 ETH0.0017173717.75561738
Exit169572562023-04-01 22:26:59456 days ago1680388019IN
0xE25C43B5...A1bdb73b9
0 ETH0.0013182816.55653594
Exit169563632023-04-01 19:25:59456 days ago1680377159IN
0xE25C43B5...A1bdb73b9
0 ETH0.0018491923.22443293
Exit169552272023-04-01 15:36:35457 days ago1680363395IN
0xE25C43B5...A1bdb73b9
0 ETH0.0022062127.70826442
Exit169433182023-03-30 23:27:23458 days ago1680218843IN
0xE25C43B5...A1bdb73b9
0 ETH0.0031925533.00722961
Exit169384612023-03-30 7:04:35459 days ago1680159875IN
0xE25C43B5...A1bdb73b9
0 ETH0.0020081425.22062763
Exit169378432023-03-30 5:00:11459 days ago1680152411IN
0xE25C43B5...A1bdb73b9
0 ETH0.002143826.92448561
View all transactions

View more zero value Internal Transactions in Advanced View mode

Advanced mode:
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
CookieJar

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 11 : CookieJar.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

/*
          .::::::::::::::::::::::::::::::::::::::::::::::.      
        ~JYJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJY555555555YY!     
        .PG5YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY5PPPPPPPPPPGP:    
        ^J555555PPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPPP5555J~     
            .:^^:7YYYYYYYYYYYYYYYYYYYYYYYYY5555555J~~~^.        
          .::.. .:^^^^^^^^^^^^^^^^^^^^^^^^^^~~~~~^:^^~~^.      
        .::.                                .:::::::::^^~^     
      .::.                 ................  :^:::::::::^~~.   
      .:..                ................... .::::::::::::^~.  
      ::                ...................... :^:::::::::::^~  
    .:.               ....................... .^:::::::::::^~. 
    .:.               ....................... .^::::::::::::~. 
    .:.              ........................ .^::::::::::::~. 
    .:.              ........................ .^::::::::::::~. 
    .:.              ........................ .:::::::::::::~. 
    .:.              ........................ .:::::::::::::~. 
    .:.              ........................ .:::::::::::::~. 
    .:.              .....               .... .:::::::::::::~. 
    .:.              ..    .::^^^~~^^::.    . .:::::::::::::~. 
    .:.                .:~!7777??777???77~:.  .^::::::::::::~. 
    .:.              .~777777JYY5Y7777777?J7^..^::::::::::::~. 
    .:. .......... .^777!77775555Y77777777??J?^:::::::::::::~. 
    .:. ......... .!7?Y5J77777?77777777?Y?7??JY~::::::::::::~. 
    .^  ........  !77JYY?777777777?JJJJ?7?JJ?J5J::::::::::::~. 
    .^. ........ :?777!7777?777777Y55P5J?JJ??JYY^:::::::::::~. 
    .~:  ....... ^?!!77777JJ777777??JJ???J???J5J::::::::::::~. 
    .~^.  ...... :J7!!777777777777777777JYYJJY5!::::::::::::~. 
    .~^:.   ..... ~J77777?JJ?7777777777?Y55YY57::::::::::::^~. 
      ~^:::.        ^??77?55P5?7777?J??JJJYY5Y!:::::::::::::^~. 
      :~^::::......  .~7??Y5YJ??7??YYJYYY55Y7^:::::::::::::^~^  
      ^~~^^^^^^::::::::~!7JJYYYYYYYYYYYJ7~^::^^^^^^^^^^^^~~^   
        .^^~~~~~~~~~~~~~~^^~~~!!!77!!!~~~^^~~~~~~~~~~~~~~^^.    
          ...................FLIP SHIBA..................
*/

import "./StakingWrapper.sol";
import "./IERC1155.sol";

import "@openzeppelin/contracts/access/AccessControl.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";

contract CookieJar is StakingWrapper, AccessControl {
    using SafeMath for uint256;

    uint256 private constant DECIMALS = 1e18;

    IERC1155 public cookieToken;

    struct Cookie {
        uint256 crumbs;
        uint256 releaseTime;
    }

    bool public allowBoosts = true;
    uint256 public start;
    uint256 public maxStake;
    uint256 public cookieRaid;
    uint256 public rewardRate;
    uint256 private burned;
    uint256[4] public boosts = [
        50, // 5%
        100, // 10%
        150, // 15%
        330 // 33%
    ];

    mapping(address => uint256) public lastUpdateTime;
    mapping(address => uint256) public crumbs;
    mapping(uint256 => Cookie) public cookies;

    event Redeemed(address indexed user, uint256 crumbs);
    event CookieAdded(
        uint256 cookie,
        uint256 maxIssuance,
        uint256 crumbs,
        uint256 releaseTime,
        string tokenUri
    );

    modifier updateReward(address account) {
        if (account != address(0)) {
            crumbs[account] = earned(account);
            lastUpdateTime[account] = _blockTime();
        }
        _;
    }

    constructor(
        address _tokenAddress,
        address _cookiesAddress,
        uint256 _burned,
        uint56 _maxStake,
        uint256 _rewardRate,
        uint256 _cookieRaid
    ) StakingWrapper(_tokenAddress) {
        cookieToken = IERC1155(_cookiesAddress);
        burned = _burned;
        maxStake = _maxStake * DECIMALS;
        cookieRaid = _cookieRaid * DECIMALS;
        rewardRate = _rewardRate;

        _setupRole(DEFAULT_ADMIN_ROLE, _msgSender());
    }

    function percentStaked() public view returns (uint256 percent) {
        return (totalStaked().mul(1000)).div(totalSupply().sub(burned));
    }

    function boostAmount() public view returns (uint256 boost) {
        if (!allowBoosts) return 0;
        if (percentStaked() >= boosts[3]) return 330;
        if (percentStaked() >= boosts[2]) return 150;
        if (percentStaked() >= boosts[1]) return 100;
        if (percentStaked() >= boosts[0]) return 50;
        return 0;
    }

    function earned(address account) public view returns (uint256) {
        uint256 blockTime = _blockTime();
        uint256 base = balanceOf(account)
            .mul(blockTime.sub(lastUpdateTime[account]).mul(rewardRate))
            .div(DECIMALS)
            .add(crumbs[account]);

        return base.add(base.mul(boostAmount()).div(1000));
    }

    function cookieReleaseTime(uint256 cookie) public view returns (uint256) {
        return cookies[cookie].releaseTime;
    }

    function cookieCrumbs(uint256 cookie) public view returns (uint256) {
        return cookies[cookie].crumbs;
    }

    function cookieTotalIssuance(uint256 cookie) public view returns (uint256) {
        return cookieToken.totalSupply(cookie);
    }

    function cookieMaxIssuance(uint256 cookie) public view returns (uint256) {
        return cookieToken.maxIssuance(cookie);
    }

    function mintingOpen() public view returns (bool) {
        return totalStaked() >= cookieRaid;
    }

    function stake(uint256 amount) public override updateReward(msg.sender) {
        require(_blockTime() >= start, "cookie jar not ready");
        require(
            amount.add(balanceOf(msg.sender)) <= maxStake,
            "deposit > max allowed"
        );

        super.stake(amount);
    }

    function withdraw(uint256 amount) public override updateReward(msg.sender) {
        require(amount > 0, "why withdraw 0?");
        super.withdraw(amount);
    }

    function exit() external {
        withdraw(balanceOf(msg.sender));
    }

    function redeem(uint256 id, uint256 quantity)
        public
        updateReward(msg.sender)
    {
        require(totalStaked() >= cookieRaid, "raid not started");
        require(quantity > 0, "mint 1 or more");
        require(cookies[id].crumbs != 0, "cookie not found");
        require(_blockTime() >= cookies[id].releaseTime, "cookie not released");

        Cookie memory c = cookies[id];

        uint256 requiredCrumbs = quantity.mul(c.crumbs);
        require(crumbs[msg.sender] >= requiredCrumbs, "need more crumbs");

        crumbs[msg.sender] = crumbs[msg.sender].sub(requiredCrumbs);
        cookieToken.mint(msg.sender, id, quantity);

        emit Redeemed(msg.sender, requiredCrumbs);
    }

    function _blockTime() internal view returns (uint256) {
        return block.timestamp;
    }

    // ADMIN FUNCTIONS //

    function setStart(uint256 _start) public onlyRole(DEFAULT_ADMIN_ROLE) {
        start = _start;
    }

    function setAllowBoosts(bool _allowBoosts)
        public
        onlyRole(DEFAULT_ADMIN_ROLE)
    {
        allowBoosts = _allowBoosts;
    }

    function setCookieRaid(uint256 _cookieRaid)
        public
        onlyRole(DEFAULT_ADMIN_ROLE)
    {
        cookieRaid = _cookieRaid;
    }

    function setMaxStake(uint256 _maxStake)
        public
        onlyRole(DEFAULT_ADMIN_ROLE)
    {
        maxStake = _maxStake;
    }

    function setRewardRate(uint256 _toStakePerPoint)
        public
        onlyRole(DEFAULT_ADMIN_ROLE)
    {
        uint256 _rewardRate = (
            uint256(1e18).div(86400).mul(DECIMALS).div(_toStakePerPoint)
        );

        rewardRate = _rewardRate;
    }

    function setRewardRateNoCalc(uint256 _rewardRate)
        public
        onlyRole(DEFAULT_ADMIN_ROLE)
    {
        rewardRate = _rewardRate;
    }

    function createCookie(
        uint256 _maxIssuance,
        string memory _tokenURI,
        uint256 _crumbs,
        uint256 _releaseTime
    ) public onlyRole(DEFAULT_ADMIN_ROLE) returns (uint256 tokenId) {
        tokenId = cookieToken.initializeToken(_maxIssuance, _tokenURI);
        require(tokenId > 0, "ERC1155 create did not succeed");

        Cookie storage c = cookies[tokenId];
        c.crumbs = _crumbs;
        c.releaseTime = _releaseTime;

        emit CookieAdded(
            tokenId,
            _maxIssuance,
            _crumbs,
            _releaseTime,
            _tokenURI
        );
    }
}

File 2 of 11 : StakingWrapper.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/utils/math/SafeMath.sol";

contract StakingWrapper {
    using SafeMath for uint256;
    IERC20 public token;

    uint256 private _totalStaked;
    mapping(address => uint256) private _balances;

    event Staked(address indexed user, uint256 amount);
    event Withdrawn(address indexed user, uint256 amount);

    constructor(address _tokenAddress) {
        token = IERC20(_tokenAddress);
    }

    function totalStaked() public view returns (uint256) {
        return _totalStaked;
    }

    function totalSupply() public view returns (uint256) {
        return token.totalSupply();
    }

    function balanceOf(address account) public view returns (uint256) {
        return _balances[account];
    }

    function stake(uint256 amount) public virtual {
        _totalStaked = _totalStaked.add(amount);
        _balances[msg.sender] = _balances[msg.sender].add(amount);
        token.transferFrom(msg.sender, address(this), amount);
        emit Staked(msg.sender, amount);
    }

    function withdraw(uint256 amount) public virtual {
        _totalStaked = _totalStaked.sub(amount);
        _balances[msg.sender] = _balances[msg.sender].sub(amount);
        token.transfer(msg.sender, amount);
        emit Withdrawn(msg.sender, amount);
    }
}

File 3 of 11 : IERC1155.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "@openzeppelin/contracts/utils/introspection/IERC165.sol";

interface IERC1155 is IERC165 {
    function initializeToken(uint256 _maxIssuance, string memory _tokenURI)
        external
        returns (uint256);

    function mint(
        address to,
        uint256 id,
        uint256 amount
    ) external returns (bool);

    function maxIssuance(uint256 tokenId) external view returns (uint256);

    function totalSupply(uint256 id) external view returns (uint256);
}

File 4 of 11 : AccessControl.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";

/**
 * @dev Contract module that allows children to implement role-based access
 * control mechanisms. This is a lightweight version that doesn't allow enumerating role
 * members except through off-chain means by accessing the contract event logs. Some
 * applications may benefit from on-chain enumerability, for those cases see
 * {AccessControlEnumerable}.
 *
 * Roles are referred to by their `bytes32` identifier. These should be exposed
 * in the external API and be unique. The best way to achieve this is by
 * using `public constant` hash digests:
 *
 * ```
 * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
 * ```
 *
 * Roles can be used to represent a set of permissions. To restrict access to a
 * function call, use {hasRole}:
 *
 * ```
 * function foo() public {
 *     require(hasRole(MY_ROLE, msg.sender));
 *     ...
 * }
 * ```
 *
 * Roles can be granted and revoked dynamically via the {grantRole} and
 * {revokeRole} functions. Each role has an associated admin role, and only
 * accounts that have a role's admin role can call {grantRole} and {revokeRole}.
 *
 * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
 * that only accounts with this role will be able to grant or revoke other
 * roles. More complex role relationships can be created by using
 * {_setRoleAdmin}.
 *
 * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
 * grant and revoke this role. Extra precautions should be taken to secure
 * accounts that have been granted it.
 */
abstract contract AccessControl is Context, IAccessControl, ERC165 {
    struct RoleData {
        mapping(address => bool) members;
        bytes32 adminRole;
    }

    mapping(bytes32 => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @dev Modifier that checks that an account has a specific role. Reverts
     * with a standardized message including the required role.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     *
     * _Available since v4.1._
     */
    modifier onlyRole(bytes32 role) {
        _checkRole(role, _msgSender());
        _;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) public view override returns (bool) {
        return _roles[role].members[account];
    }

    /**
     * @dev Revert with a standard message if `account` is missing `role`.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     */
    function _checkRole(bytes32 role, address account) internal view {
        if (!hasRole(role, account)) {
            revert(
                string(
                    abi.encodePacked(
                        "AccessControl: account ",
                        Strings.toHexString(uint160(account), 20),
                        " is missing role ",
                        Strings.toHexString(uint256(role), 32)
                    )
                )
            );
        }
    }

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) public view override returns (bytes32) {
        return _roles[role].adminRole;
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _grantRole(role, account);
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _revokeRole(role, account);
    }

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) public virtual override {
        require(account == _msgSender(), "AccessControl: can only renounce roles for self");

        _revokeRole(role, account);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event. Note that unlike {grantRole}, this function doesn't perform any
     * checks on the calling account.
     *
     * [WARNING]
     * ====
     * This function should only be called from the constructor when setting
     * up the initial roles for the system.
     *
     * Using this function in any other way is effectively circumventing the admin
     * system imposed by {AccessControl}.
     * ====
     */
    function _setupRole(bytes32 role, address account) internal virtual {
        _grantRole(role, account);
    }

    /**
     * @dev Sets `adminRole` as ``role``'s admin role.
     *
     * Emits a {RoleAdminChanged} event.
     */
    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
        bytes32 previousAdminRole = getRoleAdmin(role);
        _roles[role].adminRole = adminRole;
        emit RoleAdminChanged(role, previousAdminRole, adminRole);
    }

    function _grantRole(bytes32 role, address account) private {
        if (!hasRole(role, account)) {
            _roles[role].members[account] = true;
            emit RoleGranted(role, account, _msgSender());
        }
    }

    function _revokeRole(bytes32 role, address account) private {
        if (hasRole(role, account)) {
            _roles[role].members[account] = false;
            emit RoleRevoked(role, account, _msgSender());
        }
    }
}

File 5 of 11 : 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. 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 6 of 11 : IERC20.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @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 7 of 11 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

File 8 of 11 : IAccessControl.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev External interface of AccessControl declared to support ERC165 detection.
 */
interface IAccessControl {
    /**
     * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
     *
     * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
     * {RoleAdminChanged} not being emitted signaling this.
     *
     * _Available since v3.1._
     */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);

    /**
     * @dev Emitted when `account` is granted `role`.
     *
     * `sender` is the account that originated the contract call, an admin role
     * bearer except when using {AccessControl-_setupRole}.
     */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Emitted when `account` is revoked `role`.
     *
     * `sender` is the account that originated the contract call:
     *   - if using `revokeRole`, it is the admin role bearer
     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)
     */
    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) external view returns (bool);

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {AccessControl-_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) external view returns (bytes32);

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) external;
}

File 9 of 11 : 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) {
        return msg.data;
    }
}

File 10 of 11 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}

File 11 of 11 : ERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_tokenAddress","type":"address"},{"internalType":"address","name":"_cookiesAddress","type":"address"},{"internalType":"uint256","name":"_burned","type":"uint256"},{"internalType":"uint56","name":"_maxStake","type":"uint56"},{"internalType":"uint256","name":"_rewardRate","type":"uint256"},{"internalType":"uint256","name":"_cookieRaid","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"cookie","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"maxIssuance","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"crumbs","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"releaseTime","type":"uint256"},{"indexed":false,"internalType":"string","name":"tokenUri","type":"string"}],"name":"CookieAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"crumbs","type":"uint256"}],"name":"Redeemed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Staked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdrawn","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"allowBoosts","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"boostAmount","outputs":[{"internalType":"uint256","name":"boost","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"boosts","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"cookie","type":"uint256"}],"name":"cookieCrumbs","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"cookie","type":"uint256"}],"name":"cookieMaxIssuance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cookieRaid","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"cookie","type":"uint256"}],"name":"cookieReleaseTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"cookieToken","outputs":[{"internalType":"contract IERC1155","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"cookie","type":"uint256"}],"name":"cookieTotalIssuance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"cookies","outputs":[{"internalType":"uint256","name":"crumbs","type":"uint256"},{"internalType":"uint256","name":"releaseTime","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxIssuance","type":"uint256"},{"internalType":"string","name":"_tokenURI","type":"string"},{"internalType":"uint256","name":"_crumbs","type":"uint256"},{"internalType":"uint256","name":"_releaseTime","type":"uint256"}],"name":"createCookie","outputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"crumbs","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"earned","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"exit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"lastUpdateTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxStake","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mintingOpen","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"percentStaked","outputs":[{"internalType":"uint256","name":"percent","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"redeem","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardRate","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"_allowBoosts","type":"bool"}],"name":"setAllowBoosts","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_cookieRaid","type":"uint256"}],"name":"setCookieRaid","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxStake","type":"uint256"}],"name":"setMaxStake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_toStakePerPoint","type":"uint256"}],"name":"setRewardRate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_rewardRate","type":"uint256"}],"name":"setRewardRateNoCalc","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_start","type":"uint256"}],"name":"setStart","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"stake","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"start","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6004805460ff60a01b1916600160a01b17815561010060405260326080908152606460a052609660c05261014a60e0526200003e91600a9190620001ad565b503480156200004c57600080fd5b5060405162001c0638038062001c068339810160408190526200006f916200022a565b600080546001600160a01b038089166001600160a01b03199283161790925560048054928816929091169190911790556009849055620000c1670de0b6b3a764000066ffffffffffffff85166200029f565b600655620000d8670de0b6b3a7640000826200029f565b6007556008829055620000ed600033620000f9565b505050505050620002cd565b62000105828262000109565b5050565b60008281526003602090815260408083206001600160a01b038516845290915290205460ff16620001055760008281526003602090815260408083206001600160a01b03851684529091529020805460ff19166001179055620001693390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b8260048101928215620001e4579160200282015b82811115620001e4578251829061ffff16905591602001919060010190620001c1565b50620001f2929150620001f6565b5090565b5b80821115620001f25760008155600101620001f7565b80516001600160a01b03811681146200022557600080fd5b919050565b60008060008060008060c087890312156200024457600080fd5b6200024f876200020d565b95506200025f602088016200020d565b945060408701519350606087015166ffffffffffffff811681146200028357600080fd5b809350506080870151915060a087015190509295509295509295565b6000816000190483118215151615620002c857634e487b7160e01b600052601160045260246000fd5b500290565b61192980620002dd6000396000f3fe608060405234801561001057600080fd5b50600436106102475760003560e01c80637cbc23731161013b578063a694fc3a116100b8578063ea1b28e01161007c578063ea1b28e014610515578063eae4e25c1461051e578063f6a03ebf14610531578063f7f4e33214610544578063fc0c546a1461058057600080fd5b8063a694fc3a146104be578063be9a6555146104d1578063ca7ed1e3146104da578063d547741f146104fa578063e9fad8ee1461050d57600080fd5b806391d14854116100ff57806391d14854146104525780639e447fc614610465578063a1638f5714610478578063a217fddf146104a3578063a5acede4146104ab57600080fd5b80637cbc237314610413578063817b1cd21461042657806381f3f6691461042e57806386b0d34a146104415780638f4bb4971461044a57600080fd5b806348f2194f116101c95780636d2c55d11161018d5780636d2c55d1146103a35780636fc14837146103ab57806370a08231146103be5780637b0a47ee146103e75780637b6e3cfe146103f057600080fd5b806348f2194f1461034e5780634afd82e71461036257806351a055d114610375578063535846f614610388578063653497421461039057600080fd5b80632e1a7d4d116102105780632e1a7d4d146102e05780632f2ff15d146102f557806330c26f851461030857806336568abe146103285780633826e1701461033b57600080fd5b80628cc2621461024c57806301ffc9a71461027257806318160ddd14610295578063248a9ca31461029d5780632ce9aead146102c0575b600080fd5b61025f61025a36600461151c565b610593565b6040519081526020015b60405180910390f35b6102856102803660046115b6565b610643565b6040519015158152602001610269565b61025f61067a565b61025f6102ab366004611571565b60009081526003602052604090206001015490565b61025f6102ce36600461151c565b600e6020526000908152604090205481565b6102f36102ee366004611571565b610706565b005b6102f361030336600461158a565b610792565b61025f61031636600461151c565b600f6020526000908152604090205481565b6102f361033636600461158a565b6107bd565b6102f3610349366004611537565b610837565b60045461028590600160a01b900460ff1681565b61025f610370366004611571565b610862565b6102f3610383366004611571565b610879565b61025f61088b565b6102f361039e366004611571565b610904565b61025f610916565b6102f36103b9366004611571565b61093e565b61025f6103cc36600461151c565b6001600160a01b031660009081526002602052604090205490565b61025f60085481565b61025f6103fe366004611571565b60009081526010602052604090206001015490565b6102f36104213660046116c4565b610950565b60015461025f565b61025f61043c366004611571565b610c3a565b61025f60075481565b610285610cba565b61028561046036600461158a565b610ccf565b6102f3610473366004611571565b610cfa565b60045461048b906001600160a01b031681565b6040516001600160a01b039091168152602001610269565b61025f600081565b61025f6104b93660046115f9565b610d2d565b6102f36104cc366004611571565b610e72565b61025f60055481565b61025f6104e8366004611571565b60009081526010602052604090205490565b6102f361050836600461158a565b610f60565b6102f3610f86565b61025f60065481565b61025f61052c366004611571565b610fa1565b6102f361053f366004611571565b610fd5565b61056b610552366004611571565b6010602052600090815260409020805460019091015482565b60408051928352602083019190915201610269565b60005461048b906001600160a01b031681565b6001600160a01b0381166000908152600f6020908152604080832054600854600e909352908320544292849261061792909161061191670de0b6b3a76400009161060b916105ed91906105e7908a90610fe7565b90610ffa565b6001600160a01b038a166000908152600260205260409020546105e7565b90611006565b90611012565b905061063b6106346103e861060b61062d61088b565b8590610ffa565b8290611012565b949350505050565b60006001600160e01b03198216637965db0b60e01b148061067457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60008060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156106c957600080fd5b505afa1580156106dd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061070191906115e0565b905090565b33801561073e5761071681610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b600082116107855760405162461bcd60e51b815260206004820152600f60248201526e77687920776974686472617720303f60881b60448201526064015b60405180910390fd5b61078e8261101e565b5050565b6000828152600360205260409020600101546107ae8133611119565b6107b8838361117d565b505050565b6001600160a01b038116331461082d5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b606482015260840161077c565b61078e8282611203565b60006108438133611119565b5060048054911515600160a01b0260ff60a01b19909216919091179055565b600a816004811061087257600080fd5b0154905081565b60006108858133611119565b50600755565b600454600090600160a01b900460ff166108a55750600090565b600d546108b0610916565b106108bc575061014a90565b600c546108c7610916565b106108d25750609690565b600b546108dd610916565b106108e85750606490565b600a546108f3610916565b106108fe5750603290565b50600090565b60006109108133611119565b50600855565b600061070161092f60095461092961067a565b90610fe7565b61060b6103e86105e760015490565b600061094a8133611119565b50600655565b3380156109885761096081610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b60075460015410156109cf5760405162461bcd60e51b815260206004820152601060248201526f1c985a59081b9bdd081cdd185c9d195960821b604482015260640161077c565b60008211610a105760405162461bcd60e51b815260206004820152600e60248201526d6d696e742031206f72206d6f726560901b604482015260640161077c565b600083815260106020526040902054610a5e5760405162461bcd60e51b815260206004820152601060248201526f18dbdbdada59481b9bdd08199bdd5b9960821b604482015260640161077c565b600083815260106020526040902060010154421015610ab55760405162461bcd60e51b815260206004820152601360248201527218dbdbdada59481b9bdd081c995b19585cd959606a1b604482015260640161077c565b600083815260106020908152604080832081518083019092528054808352600190910154928201929092529190610aed908590610ffa565b336000908152600f6020526040902054909150811115610b425760405162461bcd60e51b815260206004820152601060248201526f6e656564206d6f7265206372756d627360801b604482015260640161077c565b336000908152600f6020526040902054610b5c9082610fe7565b336000818152600f60205260409081902092909255600480549251630ab714fb60e11b81529081019190915260248101879052604481018690526001600160a01b039091169063156e29f690606401602060405180830381600087803b158015610bc557600080fd5b505af1158015610bd9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bfd9190611554565b5060405181815233907f4896181ff8f4543cc00db9fe9b6fb7e6f032b7eb772c72ab1ec1b4d2e03b93699060200160405180910390a25050505050565b6004805460405163f5ae843360e01b81529182018390526000916001600160a01b039091169063f5ae8433906024015b60206040518083038186803b158015610c8257600080fd5b505afa158015610c96573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067491906115e0565b6000600754610cc860015490565b1015905090565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b6000610d068133611119565b6000610d258361060b670de0b6b3a76400006105e78162015180611006565b600855505050565b600080610d3a8133611119565b6004805460405163333a09cd60e21b81526001600160a01b039091169163cce8273491610d6b918a918a910161179a565b602060405180830381600087803b158015610d8557600080fd5b505af1158015610d99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dbd91906115e0565b915060008211610e0f5760405162461bcd60e51b815260206004820152601e60248201527f455243313135352063726561746520646964206e6f7420737563636565640000604482015260640161077c565b600082815260106020526040908190208581556001810185905590517ff75b9f8d3475a4d918ef28bab4d6f729e8611271010c0703ed5e0d9e0d2ba0f490610e609085908a90899089908c906117b3565b60405180910390a15050949350505050565b338015610eaa57610e8281610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b600554421015610ef35760405162461bcd60e51b8152602060048201526014602482015273636f6f6b6965206a6172206e6f7420726561647960601b604482015260640161077c565b60065433600090815260026020526040902054610f11908490611012565b1115610f575760405162461bcd60e51b815260206004820152601560248201527419195c1bdcda5d080f881b585e08185b1b1bddd959605a1b604482015260640161077c565b61078e8261126a565b600082815260036020526040902060010154610f7c8133611119565b6107b88383611203565b33600090815260026020526040902054610f9f90610706565b565b6004805460405163bd85b03960e01b81529182018390526000916001600160a01b039091169063bd85b03990602401610c6a565b6000610fe18133611119565b50600555565b6000610ff38284611842565b9392505050565b6000610ff38284611823565b6000610ff38284611801565b6000610ff382846117e9565b60015461102b9082610fe7565b600155336000908152600260205260409020546110489082610fe7565b336000818152600260205260408082209390935554915163a9059cbb60e01b81526004810191909152602481018390526001600160a01b039091169063a9059cbb90604401602060405180830381600087803b1580156110a757600080fd5b505af11580156110bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110df9190611554565b5060405181815233907f7084f5476618d8e60b11ef0d7d3f06914655adb8793e28ff7f018d4c76d505d5906020015b60405180910390a250565b6111238282610ccf565b61078e5761113b816001600160a01b03166014611364565b611146836020611364565b604051602001611157929190611712565b60408051601f198184030181529082905262461bcd60e51b825261077c91600401611787565b6111878282610ccf565b61078e5760008281526003602090815260408083206001600160a01b03851684529091529020805460ff191660011790556111bf3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b61120d8282610ccf565b1561078e5760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6001546112779082611012565b600155336000908152600260205260409020546112949082611012565b33600081815260026020526040808220939093555491516323b872dd60e01b81526004810191909152306024820152604481018390526001600160a01b03909116906323b872dd90606401602060405180830381600087803b1580156112f957600080fd5b505af115801561130d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113319190611554565b5060405181815233907f9e71bc8eea02a63969f509818f2dafb9254532904319f9dbda79b67bd34a5f3d9060200161110e565b60606000611373836002611823565b61137e9060026117e9565b67ffffffffffffffff811115611396576113966118cc565b6040519080825280601f01601f1916602001820160405280156113c0576020820181803683370190505b509050600360fc1b816000815181106113db576113db6118b6565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061140a5761140a6118b6565b60200101906001600160f81b031916908160001a905350600061142e846002611823565b6114399060016117e9565b90505b60018111156114b1576f181899199a1a9b1b9c1cb0b131b232b360811b85600f166010811061146d5761146d6118b6565b1a60f81b828281518110611483576114836118b6565b60200101906001600160f81b031916908160001a90535060049490941c936114aa81611889565b905061143c565b508315610ff35760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e74604482015260640161077c565b80356001600160a01b038116811461151757600080fd5b919050565b60006020828403121561152e57600080fd5b610ff382611500565b60006020828403121561154957600080fd5b8135610ff3816118e2565b60006020828403121561156657600080fd5b8151610ff3816118e2565b60006020828403121561158357600080fd5b5035919050565b6000806040838503121561159d57600080fd5b823591506115ad60208401611500565b90509250929050565b6000602082840312156115c857600080fd5b81356001600160e01b031981168114610ff357600080fd5b6000602082840312156115f257600080fd5b5051919050565b6000806000806080858703121561160f57600080fd5b84359350602085013567ffffffffffffffff8082111561162e57600080fd5b818701915087601f83011261164257600080fd5b813581811115611654576116546118cc565b604051601f8201601f19908116603f0116810190838211818310171561167c5761167c6118cc565b816040528281528a602084870101111561169557600080fd5b826020860160208301376000928101602001929092525095989597505050506040840135936060013592915050565b600080604083850312156116d757600080fd5b50508035926020909101359150565b600081518084526116fe816020860160208601611859565b601f01601f19169290920160200192915050565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161174a816017850160208801611859565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161177b816028840160208801611859565b01602801949350505050565b602081526000610ff360208301846116e6565b82815260406020820152600061063b60408301846116e6565b85815284602082015283604082015282606082015260a0608082015260006117de60a08301846116e6565b979650505050505050565b600082198211156117fc576117fc6118a0565b500190565b60008261181e57634e487b7160e01b600052601260045260246000fd5b500490565b600081600019048311821515161561183d5761183d6118a0565b500290565b600082821015611854576118546118a0565b500390565b60005b8381101561187457818101518382015260200161185c565b83811115611883576000848401525b50505050565b600081611898576118986118a0565b506000190190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b80151581146118f057600080fd5b5056fea26469706673582212204c58d92d7111fbf368260d6d83316e75df009d823f64d9069aaa4ff9198ed6a664736f6c63430008060033000000000000000000000000a71d0588eaf47f12b13cf8ec750430d21df0497400000000000000000000000045461d30ae48b76362d6e77df46a2d5005bca69d00000000000000000000000000000000000013b8b5b5056e16b3be040000000000000000000000000000000000000000000000000000000000000002540be400000000000000000000000000000000000000000000000000000000000001c41c0000000000000000000000000000000000000000000000000000015d3ef79800

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106102475760003560e01c80637cbc23731161013b578063a694fc3a116100b8578063ea1b28e01161007c578063ea1b28e014610515578063eae4e25c1461051e578063f6a03ebf14610531578063f7f4e33214610544578063fc0c546a1461058057600080fd5b8063a694fc3a146104be578063be9a6555146104d1578063ca7ed1e3146104da578063d547741f146104fa578063e9fad8ee1461050d57600080fd5b806391d14854116100ff57806391d14854146104525780639e447fc614610465578063a1638f5714610478578063a217fddf146104a3578063a5acede4146104ab57600080fd5b80637cbc237314610413578063817b1cd21461042657806381f3f6691461042e57806386b0d34a146104415780638f4bb4971461044a57600080fd5b806348f2194f116101c95780636d2c55d11161018d5780636d2c55d1146103a35780636fc14837146103ab57806370a08231146103be5780637b0a47ee146103e75780637b6e3cfe146103f057600080fd5b806348f2194f1461034e5780634afd82e71461036257806351a055d114610375578063535846f614610388578063653497421461039057600080fd5b80632e1a7d4d116102105780632e1a7d4d146102e05780632f2ff15d146102f557806330c26f851461030857806336568abe146103285780633826e1701461033b57600080fd5b80628cc2621461024c57806301ffc9a71461027257806318160ddd14610295578063248a9ca31461029d5780632ce9aead146102c0575b600080fd5b61025f61025a36600461151c565b610593565b6040519081526020015b60405180910390f35b6102856102803660046115b6565b610643565b6040519015158152602001610269565b61025f61067a565b61025f6102ab366004611571565b60009081526003602052604090206001015490565b61025f6102ce36600461151c565b600e6020526000908152604090205481565b6102f36102ee366004611571565b610706565b005b6102f361030336600461158a565b610792565b61025f61031636600461151c565b600f6020526000908152604090205481565b6102f361033636600461158a565b6107bd565b6102f3610349366004611537565b610837565b60045461028590600160a01b900460ff1681565b61025f610370366004611571565b610862565b6102f3610383366004611571565b610879565b61025f61088b565b6102f361039e366004611571565b610904565b61025f610916565b6102f36103b9366004611571565b61093e565b61025f6103cc36600461151c565b6001600160a01b031660009081526002602052604090205490565b61025f60085481565b61025f6103fe366004611571565b60009081526010602052604090206001015490565b6102f36104213660046116c4565b610950565b60015461025f565b61025f61043c366004611571565b610c3a565b61025f60075481565b610285610cba565b61028561046036600461158a565b610ccf565b6102f3610473366004611571565b610cfa565b60045461048b906001600160a01b031681565b6040516001600160a01b039091168152602001610269565b61025f600081565b61025f6104b93660046115f9565b610d2d565b6102f36104cc366004611571565b610e72565b61025f60055481565b61025f6104e8366004611571565b60009081526010602052604090205490565b6102f361050836600461158a565b610f60565b6102f3610f86565b61025f60065481565b61025f61052c366004611571565b610fa1565b6102f361053f366004611571565b610fd5565b61056b610552366004611571565b6010602052600090815260409020805460019091015482565b60408051928352602083019190915201610269565b60005461048b906001600160a01b031681565b6001600160a01b0381166000908152600f6020908152604080832054600854600e909352908320544292849261061792909161061191670de0b6b3a76400009161060b916105ed91906105e7908a90610fe7565b90610ffa565b6001600160a01b038a166000908152600260205260409020546105e7565b90611006565b90611012565b905061063b6106346103e861060b61062d61088b565b8590610ffa565b8290611012565b949350505050565b60006001600160e01b03198216637965db0b60e01b148061067457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60008060009054906101000a90046001600160a01b03166001600160a01b03166318160ddd6040518163ffffffff1660e01b815260040160206040518083038186803b1580156106c957600080fd5b505afa1580156106dd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061070191906115e0565b905090565b33801561073e5761071681610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b600082116107855760405162461bcd60e51b815260206004820152600f60248201526e77687920776974686472617720303f60881b60448201526064015b60405180910390fd5b61078e8261101e565b5050565b6000828152600360205260409020600101546107ae8133611119565b6107b8838361117d565b505050565b6001600160a01b038116331461082d5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b606482015260840161077c565b61078e8282611203565b60006108438133611119565b5060048054911515600160a01b0260ff60a01b19909216919091179055565b600a816004811061087257600080fd5b0154905081565b60006108858133611119565b50600755565b600454600090600160a01b900460ff166108a55750600090565b600d546108b0610916565b106108bc575061014a90565b600c546108c7610916565b106108d25750609690565b600b546108dd610916565b106108e85750606490565b600a546108f3610916565b106108fe5750603290565b50600090565b60006109108133611119565b50600855565b600061070161092f60095461092961067a565b90610fe7565b61060b6103e86105e760015490565b600061094a8133611119565b50600655565b3380156109885761096081610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b60075460015410156109cf5760405162461bcd60e51b815260206004820152601060248201526f1c985a59081b9bdd081cdd185c9d195960821b604482015260640161077c565b60008211610a105760405162461bcd60e51b815260206004820152600e60248201526d6d696e742031206f72206d6f726560901b604482015260640161077c565b600083815260106020526040902054610a5e5760405162461bcd60e51b815260206004820152601060248201526f18dbdbdada59481b9bdd08199bdd5b9960821b604482015260640161077c565b600083815260106020526040902060010154421015610ab55760405162461bcd60e51b815260206004820152601360248201527218dbdbdada59481b9bdd081c995b19585cd959606a1b604482015260640161077c565b600083815260106020908152604080832081518083019092528054808352600190910154928201929092529190610aed908590610ffa565b336000908152600f6020526040902054909150811115610b425760405162461bcd60e51b815260206004820152601060248201526f6e656564206d6f7265206372756d627360801b604482015260640161077c565b336000908152600f6020526040902054610b5c9082610fe7565b336000818152600f60205260409081902092909255600480549251630ab714fb60e11b81529081019190915260248101879052604481018690526001600160a01b039091169063156e29f690606401602060405180830381600087803b158015610bc557600080fd5b505af1158015610bd9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bfd9190611554565b5060405181815233907f4896181ff8f4543cc00db9fe9b6fb7e6f032b7eb772c72ab1ec1b4d2e03b93699060200160405180910390a25050505050565b6004805460405163f5ae843360e01b81529182018390526000916001600160a01b039091169063f5ae8433906024015b60206040518083038186803b158015610c8257600080fd5b505afa158015610c96573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067491906115e0565b6000600754610cc860015490565b1015905090565b60009182526003602090815260408084206001600160a01b0393909316845291905290205460ff1690565b6000610d068133611119565b6000610d258361060b670de0b6b3a76400006105e78162015180611006565b600855505050565b600080610d3a8133611119565b6004805460405163333a09cd60e21b81526001600160a01b039091169163cce8273491610d6b918a918a910161179a565b602060405180830381600087803b158015610d8557600080fd5b505af1158015610d99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dbd91906115e0565b915060008211610e0f5760405162461bcd60e51b815260206004820152601e60248201527f455243313135352063726561746520646964206e6f7420737563636565640000604482015260640161077c565b600082815260106020526040908190208581556001810185905590517ff75b9f8d3475a4d918ef28bab4d6f729e8611271010c0703ed5e0d9e0d2ba0f490610e609085908a90899089908c906117b3565b60405180910390a15050949350505050565b338015610eaa57610e8281610593565b6001600160a01b0382166000908152600f6020908152604080832093909355600e9052204290555b600554421015610ef35760405162461bcd60e51b8152602060048201526014602482015273636f6f6b6965206a6172206e6f7420726561647960601b604482015260640161077c565b60065433600090815260026020526040902054610f11908490611012565b1115610f575760405162461bcd60e51b815260206004820152601560248201527419195c1bdcda5d080f881b585e08185b1b1bddd959605a1b604482015260640161077c565b61078e8261126a565b600082815260036020526040902060010154610f7c8133611119565b6107b88383611203565b33600090815260026020526040902054610f9f90610706565b565b6004805460405163bd85b03960e01b81529182018390526000916001600160a01b039091169063bd85b03990602401610c6a565b6000610fe18133611119565b50600555565b6000610ff38284611842565b9392505050565b6000610ff38284611823565b6000610ff38284611801565b6000610ff382846117e9565b60015461102b9082610fe7565b600155336000908152600260205260409020546110489082610fe7565b336000818152600260205260408082209390935554915163a9059cbb60e01b81526004810191909152602481018390526001600160a01b039091169063a9059cbb90604401602060405180830381600087803b1580156110a757600080fd5b505af11580156110bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110df9190611554565b5060405181815233907f7084f5476618d8e60b11ef0d7d3f06914655adb8793e28ff7f018d4c76d505d5906020015b60405180910390a250565b6111238282610ccf565b61078e5761113b816001600160a01b03166014611364565b611146836020611364565b604051602001611157929190611712565b60408051601f198184030181529082905262461bcd60e51b825261077c91600401611787565b6111878282610ccf565b61078e5760008281526003602090815260408083206001600160a01b03851684529091529020805460ff191660011790556111bf3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b61120d8282610ccf565b1561078e5760008281526003602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b6001546112779082611012565b600155336000908152600260205260409020546112949082611012565b33600081815260026020526040808220939093555491516323b872dd60e01b81526004810191909152306024820152604481018390526001600160a01b03909116906323b872dd90606401602060405180830381600087803b1580156112f957600080fd5b505af115801561130d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113319190611554565b5060405181815233907f9e71bc8eea02a63969f509818f2dafb9254532904319f9dbda79b67bd34a5f3d9060200161110e565b60606000611373836002611823565b61137e9060026117e9565b67ffffffffffffffff811115611396576113966118cc565b6040519080825280601f01601f1916602001820160405280156113c0576020820181803683370190505b509050600360fc1b816000815181106113db576113db6118b6565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061140a5761140a6118b6565b60200101906001600160f81b031916908160001a905350600061142e846002611823565b6114399060016117e9565b90505b60018111156114b1576f181899199a1a9b1b9c1cb0b131b232b360811b85600f166010811061146d5761146d6118b6565b1a60f81b828281518110611483576114836118b6565b60200101906001600160f81b031916908160001a90535060049490941c936114aa81611889565b905061143c565b508315610ff35760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e74604482015260640161077c565b80356001600160a01b038116811461151757600080fd5b919050565b60006020828403121561152e57600080fd5b610ff382611500565b60006020828403121561154957600080fd5b8135610ff3816118e2565b60006020828403121561156657600080fd5b8151610ff3816118e2565b60006020828403121561158357600080fd5b5035919050565b6000806040838503121561159d57600080fd5b823591506115ad60208401611500565b90509250929050565b6000602082840312156115c857600080fd5b81356001600160e01b031981168114610ff357600080fd5b6000602082840312156115f257600080fd5b5051919050565b6000806000806080858703121561160f57600080fd5b84359350602085013567ffffffffffffffff8082111561162e57600080fd5b818701915087601f83011261164257600080fd5b813581811115611654576116546118cc565b604051601f8201601f19908116603f0116810190838211818310171561167c5761167c6118cc565b816040528281528a602084870101111561169557600080fd5b826020860160208301376000928101602001929092525095989597505050506040840135936060013592915050565b600080604083850312156116d757600080fd5b50508035926020909101359150565b600081518084526116fe816020860160208601611859565b601f01601f19169290920160200192915050565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161174a816017850160208801611859565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161177b816028840160208801611859565b01602801949350505050565b602081526000610ff360208301846116e6565b82815260406020820152600061063b60408301846116e6565b85815284602082015283604082015282606082015260a0608082015260006117de60a08301846116e6565b979650505050505050565b600082198211156117fc576117fc6118a0565b500190565b60008261181e57634e487b7160e01b600052601260045260246000fd5b500490565b600081600019048311821515161561183d5761183d6118a0565b500290565b600082821015611854576118546118a0565b500390565b60005b8381101561187457818101518382015260200161185c565b83811115611883576000848401525b50505050565b600081611898576118986118a0565b506000190190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b80151581146118f057600080fd5b5056fea26469706673582212204c58d92d7111fbf368260d6d83316e75df009d823f64d9069aaa4ff9198ed6a664736f6c63430008060033

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

000000000000000000000000a71d0588eaf47f12b13cf8ec750430d21df0497400000000000000000000000045461d30ae48b76362d6e77df46a2d5005bca69d00000000000000000000000000000000000013b8b5b5056e16b3be040000000000000000000000000000000000000000000000000000000000000002540be400000000000000000000000000000000000000000000000000000000000001c41c0000000000000000000000000000000000000000000000000000015d3ef79800

-----Decoded View---------------
Arg [0] : _tokenAddress (address): 0xa71d0588EAf47f12B13cF8eC750430d21DF04974
Arg [1] : _cookiesAddress (address): 0x45461D30AE48b76362D6E77df46a2D5005bca69D
Arg [2] : _burned (uint256): 400000000000000000000000000000000
Arg [3] : _maxStake (uint56): 10000000000
Arg [4] : _rewardRate (uint256): 115740
Arg [5] : _cookieRaid (uint256): 1500000000000

-----Encoded View---------------
6 Constructor Arguments found :
Arg [0] : 000000000000000000000000a71d0588eaf47f12b13cf8ec750430d21df04974
Arg [1] : 00000000000000000000000045461d30ae48b76362d6e77df46a2d5005bca69d
Arg [2] : 00000000000000000000000000000000000013b8b5b5056e16b3be0400000000
Arg [3] : 00000000000000000000000000000000000000000000000000000002540be400
Arg [4] : 000000000000000000000000000000000000000000000000000000000001c41c
Arg [5] : 0000000000000000000000000000000000000000000000000000015d3ef79800


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.