ETH Price: $3,333.76 (-1.94%)
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Unstake NFT212257342024-11-20 1:42:1166 days ago1732066931IN
0x954ac35f...9e6cbF83c
0 ETH0.000455749.81590511
Stake NFT212152662024-11-18 14:41:3568 days ago1731940895IN
0x954ac35f...9e6cbF83c
0 ETH0.0012333316.21077131
Unstake NFT212008402024-11-16 14:25:1170 days ago1731767111IN
0x954ac35f...9e6cbF83c
0 ETH0.0007233115.57889575
Unstake NFT210008972024-10-19 16:45:5998 days ago1729356359IN
0x954ac35f...9e6cbF83c
0 ETH0.0012133617.90652055
Unstake NFT207724562024-09-17 19:36:59129 days ago1726601819IN
0x954ac35f...9e6cbF83c
0 ETH0.0008058917.35755208
Unstake NFT207391902024-09-13 4:05:11134 days ago1726200311IN
0x954ac35f...9e6cbF83c
0 ETH0.000070691.52254194
Stake NFT204209022024-07-30 17:36:59179 days ago1722361019IN
0x954ac35f...9e6cbF83c
0 ETH0.003936449.76791016
Unstake NFT203621262024-07-22 12:39:35187 days ago1721651975IN
0x954ac35f...9e6cbF83c
0 ETH0.000403868.69861968
Unstake NFT203553292024-07-21 13:51:47188 days ago1721569907IN
0x954ac35f...9e6cbF83c
0 ETH0.000125772.7090493
Unstake NFT203551762024-07-21 13:21:11188 days ago1721568071IN
0x954ac35f...9e6cbF83c
0 ETH0.000114442.4649623
Unstake NFT203550172024-07-21 12:48:59188 days ago1721566139IN
0x954ac35f...9e6cbF83c
0 ETH0.000112492.4228841
Stake NFT202850822024-07-11 18:33:11197 days ago1720722791IN
0x954ac35f...9e6cbF83c
0 ETH0.000586227.70530721
Unstake NFT202705072024-07-09 17:44:23200 days ago1720547063IN
0x954ac35f...9e6cbF83c
0 ETH0.000321845.63003116
Unstake NFT200677702024-06-11 9:44:23228 days ago1718099063IN
0x954ac35f...9e6cbF83c
0 ETH0.000375058.07799928
Unstake NFT200402082024-06-07 13:19:35232 days ago1717766375IN
0x954ac35f...9e6cbF83c
0 ETH0.0006676714.38053523
Unstake NFT200054762024-06-02 16:57:59237 days ago1717347479IN
0x954ac35f...9e6cbF83c
0 ETH0.0007125915.34808608
Unstake NFT199641462024-05-27 22:19:23242 days ago1716848363IN
0x954ac35f...9e6cbF83c
0 ETH0.0007372215.8785309
Stake NFT198134622024-05-06 20:35:47263 days ago1715027747IN
0x954ac35f...9e6cbF83c
0 ETH0.012997556.05074056
Unstake NFT198118352024-05-06 15:08:11264 days ago1715008091IN
0x954ac35f...9e6cbF83c
0 ETH0.0010387115.29161777
Stake NFT198109772024-05-06 12:14:59264 days ago1714997699IN
0x954ac35f...9e6cbF83c
0 ETH0.000436255.73403461
Unstake NFT198109472024-05-06 12:08:59264 days ago1714997339IN
0x954ac35f...9e6cbF83c
0 ETH0.000259875.59735146
Stake NFT198042242024-05-05 13:34:47265 days ago1714916087IN
0x954ac35f...9e6cbF83c
0 ETH0.000439695.77929741
Unstake NFT198038842024-05-05 12:26:35265 days ago1714911995IN
0x954ac35f...9e6cbF83c
0 ETH0.000266455.73898213
Unstake NFT198033272024-05-05 10:34:47265 days ago1714905287IN
0x954ac35f...9e6cbF83c
0 ETH0.00028176.06733683
Stake NFT197698982024-04-30 18:24:47269 days ago1714501487IN
0x954ac35f...9e6cbF83c
0 ETH0.0016965911.40220306
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:
xborgStaker

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion, MIT license

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2023-01-13
*/

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)
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 direct9                                
 * 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;
    }
}

// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)
pragma solidity ^0.8.1;

/**
 * @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
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 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");

        (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");

        (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");

        (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");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal 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

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

// OpenZeppelin Contracts (last updated v4.6.0) (utils/math/SafeMath.sol)
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 generally not needed starting with Solidity 0.8, since 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 subtraction 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;
        }
    }
}

// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)
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);
    }
}


pragma solidity ^0.8.0;

/**
 * @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() {
        _setOwner(_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 {
        _setOwner(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");
        _setOwner(newOwner);
    }

    function _setOwner(address newOwner) private {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}


pragma solidity ^0.8.0;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
abstract contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant _NOT_ENTERED = 1;
    uint256 private constant _ENTERED = 2;

    uint256 private _status;

    constructor() {
        _status = _NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and make it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        // On the first call to nonReentrant, _notEntered will be true
        require(_status != _ENTERED, "ReentrancyGuard: reentrant call");

        // Any calls to nonReentrant after this point will fail
        _status = _ENTERED;

        _;

        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = _NOT_ENTERED;
    }
}

// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)
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);
}

// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)
pragma solidity ^0.8.0;

/**
 * @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;
    }
}

// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721.sol)
pragma solidity ^0.8.0;

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);
}

// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721Receiver.sol)
pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721Receiver.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)
pragma solidity ^0.8.0;

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

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

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

pragma solidity ^0.8.0;

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata and Enumerable extension. Built to optimize for lower gas during batch mints.
 *
 * Assumes serials are sequentially minted starting at 0 (e.g. 0, 1, 2, 3..).
 *
 * Assumes the number of issuable tokens (collection size) is capped and fits in a uint128.
 *
 * Does not support burning tokens to address(0).
 */
contract ERC721X is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    struct TokenOwnership {
        address addr;
        uint64 startTimestamp;
    }

    struct AddressData {
        uint64 balance;
        uint64 numberMinted;
    }

    uint256 private currentIndex = 0;
    uint256 private burnedIndex = 0;

    uint256 internal immutable collectionSize;
    uint256 internal immutable maxBatchSize;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to ownership details
    // An empty struct value does not necessarily mean the token is unowned. See ownershipOf implementation for details.
    mapping(uint256 => TokenOwnership) private _ownerships;

    // Mapping owner address to address data
    mapping(address => AddressData) private _addressData;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
    * @dev
    * `maxBatchSize` refers to how much a minter can mint at a time.
    * `collectionSize_` refers to how many tokens are in the collection.
    */
    constructor(
        string memory name_,
        string memory symbol_,
        uint256 maxBatchSize_,
        uint256 collectionSize_
    ) {
        require(collectionSize_ > 0, "ERC721X: collection must have a nonzero supply");
        require(maxBatchSize_ > 0, "ERC721X: max batch size must be nonzero");
        _name = name_;
        _symbol = symbol_;
        maxBatchSize = maxBatchSize_;
        collectionSize = collectionSize_;
    }

    /**
    * @dev See Remove store data in IERC721Enumerable {IERC721Enumerable-totalSupply}.
    */
    function totalSupply() public view returns (uint256) {
        return currentIndex - burnedIndex;
    }

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

    /**
    * @dev See {IERC721-balanceOf}.
    */
    function balanceOf(address owner) public view override returns (uint256) {
        require(owner != address(0), "ERC721X: balance query for the zero address");
        return uint256(_addressData[owner].balance);
    }

    function _numberMinted(address owner) internal view returns (uint256) {
        require(owner != address(0), "ERC721X: number minted query for the zero address");
        return uint256(_addressData[owner].numberMinted);
    }

    function ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) {
        require(_exists(tokenId), "ERC721X: owner query for nonexistent token");
        uint256 lowestTokenToCheck;
        if (tokenId >= maxBatchSize) {
            lowestTokenToCheck = tokenId - maxBatchSize + 1;
        }

        for (uint256 curr = tokenId; curr >= lowestTokenToCheck; curr--) {
            TokenOwnership memory ownership = _ownerships[curr];
            if (ownership.addr != address(0)) {
                return ownership;
            }
        }
        revert("ERC721X: unable to determine the owner of token");
    }

    /**
    * @dev See {IERC721-ownerOf}.
    */
    function ownerOf(uint256 tokenId) public view override returns (address) {
        return ownershipOf(tokenId).addr;
    }

    /**
    * @dev See {IERC721Metadata-name}.
    */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
    * @dev See {IERC721Metadata-symbol}.
    */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
    * @dev See {IERC721Metadata-tokenURI}.
    */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");
        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString(), ".json")): "";
    }

    /**
    * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
    * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
    * by default, can be overriden in child contracts.
    */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
    * @dev See {IERC721-approve}.
    */
    function approve(address to, uint256 tokenId) public override {
        address owner = ERC721X.ownerOf(tokenId);
        require(to != owner, "ERC721X: approval to current owner");
        require(_msgSender() == owner || isApprovedForAll(owner, _msgSender()),"ERC721X: approve caller is not owner nor approved for all");
        _approve(to, tokenId, owner);
    }

    /**
    * @dev See {IERC721-getApproved}.
    */
    function getApproved(uint256 tokenId) public view override returns (address) {
        require(_exists(tokenId), "ERC721X: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
    * @dev See {IERC721-setApprovalForAll}.
    */
    function setApprovalForAll(address operator, bool approved) public override {
        require(operator != _msgSender(), "ERC721X: approve to caller");

        _operatorApprovals[_msgSender()][operator] = approved;
        emit ApprovalForAll(_msgSender(), operator, approved);
    }

    /**
    * @dev See {IERC721-isApprovedForAll}.
    */
    function isApprovedForAll(address owner, address operator) public view virtual override returns (bool){
        return _operatorApprovals[owner][operator];
    }

    /**
    * @dev See {IERC721-transferFrom}.
    */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override {
        _transfer(from, to, tokenId);
    }

    /**
    * @dev See {IERC721-safeTransferFrom}.
    */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public override {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
    * @dev See {IERC721-safeTransferFrom}.
    */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public override {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721X: transfer to non ERC721Receiver implementer");
    }

    /**
    * @dev Returns whether `tokenId` exists.
    *
    * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
    *
    * Tokens start existing when they are minted (`_mint`),
    */
    function _exists(uint256 tokenId) internal view returns (bool) {
        return tokenId < currentIndex;
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        require(_exists(tokenId), "ERC721X: operator query for nonexistent token");
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);
        return(spender == prevOwnership.addr || getApproved(tokenId) == spender || isApprovedForAll(prevOwnership.addr, spender));
        //return (spender == owner || isApprovedForAll(owner, spender) || getApproved(tokenId) == spender);
    }

    function _safeMint(address to, uint256 quantity) internal {
        _safeMint(to, quantity, "");
    }

    /**
    * @dev Mints `quantity` tokens and transfers them to `to`.
    *
    * Requirements:
    *
    * - there must be `quantity` tokens remaining unminted in the total collection.
    * - `to` cannot be the zero address.
    * - `quantity` cannot be larger than the max batch size.
    *
    * Emits a {Transfer} event.
    */
    function _safeMint(
        address to,
        uint256 quantity,
        bytes memory _data
    ) internal {
        uint256 startTokenId = currentIndex;
        require(to != address(0), "ERC721X: mint to the zero address");
        require(!_exists(startTokenId), "ERC721X: token already minted");
        require(quantity <= maxBatchSize, "ERC721X: quantity to mint over than max batch size");

        _beforeTokenTransfers(address(0), to, startTokenId, quantity);

        unchecked {
            _addressData[to].balance += uint64(quantity);
            _addressData[to].numberMinted += uint64(quantity);

            _ownerships[startTokenId] = TokenOwnership(to, uint64(block.timestamp));

            uint256 updatedIndex = startTokenId;

            for (uint256 i = 0; i < quantity; i++) {
                emit Transfer(address(0), to, updatedIndex);
                require(_checkOnERC721Received(address(0), to, updatedIndex, _data), "ERC721X: transfer to non ERC721Receiver implementer");
                updatedIndex++;
            }
            currentIndex = updatedIndex;
            _afterTokenTransfers(address(0), to, startTokenId, quantity);
        }
    }

    /**
    * @dev burn function Transfers `tokenId` from `from` to `unused address`.
    *
    * Requirements:
    *
    * - `to` cannot be the zero address and fix to unused address.
    * - `tokenId` token must be owned by `from`.
    *
    * Emits a {Transfer} event.
    */

    function _burn(
        address from,
        uint256 tokenId
        ) internal virtual {
        address to = 0x000000000000000000000000000000000000dEaD;
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);

        //bool isApprovedOrOwner = (_msgSender() == prevOwnership.addr ||
        //getApproved(tokenId) == _msgSender() ||
        //isApprovedForAll(prevOwnership.addr, _msgSender()));

        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721X: burn caller is not owner nor approved");
        require(prevOwnership.addr == from, "ERC721X: burn from incorrect owner");

        _beforeTokenTransfers(from, to, tokenId, 1);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId, prevOwnership.addr);

        _addressData[from].balance -= 1;
        _addressData[to].balance += 1;
        _ownerships[tokenId] = TokenOwnership(to, uint64(block.timestamp));

        // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
        // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
        uint256 nextTokenId = tokenId + 1;
        if (_ownerships[nextTokenId].addr == address(0)) {
            if (_exists(nextTokenId)) {
                _ownerships[nextTokenId] = TokenOwnership(
                prevOwnership.addr,
                prevOwnership.startTimestamp
                );
            }
        }
        emit Transfer(from, to, tokenId);
        burnedIndex++;
        _afterTokenTransfers(from, to, tokenId, 1);
    }

    /**
    * @dev Transfers `tokenId` from `from` to `to`.
    *
    * Requirements:
    *
    * - `to` cannot be the zero address.
    * - `tokenId` token must be owned by `from`.
    *
    * Emits a {Transfer} event.
    */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);

        //bool isApprovedOrOwner = (_msgSender() == prevOwnership.addr ||
        //getApproved(tokenId) == _msgSender() ||
        //isApprovedForAll(prevOwnership.addr, _msgSender()));

        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721X: transfer caller is not owner nor approved");
        require(prevOwnership.addr == from, "ERC721X: transfer from incorrect owner");
        require(to != address(0), "ERC721X: transfer to the zero address");

        _beforeTokenTransfers(from, to, tokenId, 1);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId, prevOwnership.addr);

        _addressData[from].balance -= 1;
        _addressData[to].balance += 1;
        _ownerships[tokenId] = TokenOwnership(to, uint64(block.timestamp));

        // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
        // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
        uint256 nextTokenId = tokenId + 1;
        if (_ownerships[nextTokenId].addr == address(0)) {
            if (_exists(nextTokenId)) {
                _ownerships[nextTokenId] = TokenOwnership(
                prevOwnership.addr,
                prevOwnership.startTimestamp
                );
            }
        }

        emit Transfer(from, to, tokenId);
        _afterTokenTransfers(from, to, tokenId, 1);
    }

    /**
    * @dev Approve `to` to operate on `tokenId`
    *
    * Emits a {Approval} event.
    */
    function _approve(
        address to,
        uint256 tokenId,
        address owner
    ) private {
        _tokenApprovals[tokenId] = to;
        emit Approval(owner, to, tokenId);
    }

    uint256 public nextOwnerToExplicitlySet = 0;

    /**
    * @dev Explicitly set `owners` to eliminate loops in future calls of ownerOf().
    */
    function _setOwnersExplicit(uint256 quantity) internal {
        uint256 oldNextOwnerToSet = nextOwnerToExplicitlySet;
        require(quantity > 0, "quantity must be nonzero");
        uint256 endIndex = oldNextOwnerToSet + quantity - 1;
        if (endIndex > collectionSize - 1) {
            endIndex = collectionSize - 1;
        }
        // We know if the last one in the group exists, all in the group exist, due to serial ordering.
        require(_exists(endIndex), "not enough minted yet for this cleanup");
        for (uint256 i = oldNextOwnerToSet; i <= endIndex; i++) {
            if (_ownerships[i].addr == address(0)) {
                TokenOwnership memory ownership = ownershipOf(i);
                _ownerships[i] = TokenOwnership(
                ownership.addr,
                ownership.startTimestamp
                );
            }
        }
        nextOwnerToExplicitlySet = endIndex + 1;
    }

    /**
    * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
    * The call is not executed if the target address is not a contract.
    *
    * @param from address representing the previous owner of the given token ID
    * @param to target address that will receive the tokens
    * @param tokenId uint256 ID of the token to be transferred
    * @param _data bytes optional data to send along with the call
    * @return bool whether the call correctly returned the expected magic value
    */
    function _checkOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        if (to.isContract()) {
            try
                IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data)
            returns (bytes4 retval) {
                return retval == IERC721Receiver(to).onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721X: transfer to non ERC721Receiver implementer");
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
    * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting.
    *
    * startTokenId - the first token id to be transferred
    * quantity - the amount to be transferred
    *
    * Calling conditions:
    *
    * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
    * transferred to `to`.
    * - When `from` is zero, `tokenId` will be minted for `to`.
    */
    function _beforeTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}

    /**
    * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes
    * minting.
    *
    * startTokenId - the first token id to be transferred
    * quantity - the amount to be transferred
    *
    * Calling conditions:
    *
    * - when `from` and `to` are both non-zero.
    * - `from` and `to` are never both zero.
    */
    function _afterTokenTransfers(
        address from,
        address to,
        uint256 startTokenId,
        uint256 quantity
    ) internal virtual {}
}

// OpenZeppelin Contracts v4.4.1 (utils/structs/EnumerableSet.sol)
pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;
        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) {
            // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastValue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastValue;
                // Update the index for the moved value
                set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        return set._values[index];
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function _values(Set storage set) private view returns (bytes32[] memory) {
        return set._values;
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
        return _values(set._inner);
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(AddressSet storage set) internal view returns (address[] memory) {
        bytes32[] memory store = _values(set._inner);
        address[] memory result;

        assembly {
            result := store
        }

        return result;
    }

    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(UintSet storage set) internal view returns (uint256[] memory) {
        bytes32[] memory store = _values(set._inner);
        uint256[] memory result;

        assembly {
            result := store
        }

        return result;
    }
}

pragma solidity ^0.8.0;
pragma abicoder v2;

abstract contract TokenStake is Ownable, ERC721X {
    using EnumerableSet for EnumerableSet.AddressSet;

    EnumerableSet.AddressSet private _tokenStakers;
    mapping(uint256 => address) private _stakedTokens;

    event TokenStaked(address indexed tokenStaker, uint256 tokenId);
    event TokenUnstaked(address indexed tokenStaker, uint256 tokenId);
    event TokenRecoverUnstaked(uint256 tokenId);
    event BatchUpdateTokenStaked(address indexed newTokenStaker, uint256[] tokenIds);

    event TokenStakerAdded(address indexed tokenStaker);
    event TokenStakerRemoved(address indexed tokenStaker);

    modifier tokenStakersOnly() {
        require(_tokenStakers.contains(_msgSender()), "TokenStake: Not staker");
        _;
    }

    modifier whenTokenNotStaked(uint256 tokenId) {
        require(_stakedTokens[tokenId] == address(0), "TokenStake: Token is staked");
        _;
    }

    modifier whenTokenStaked(uint256 tokenId) {
        require(_stakedTokens[tokenId] != address(0), "TokenStake: Token is not staked");
        _;
    }

    /**
     * @notice Returns `true` if token is staked and can't be transfered
     */
    function isTokenStaked(uint256 tokenId) public view returns (bool) {
        return _stakedTokens[tokenId] != address(0);
    }

    /**
     * @notice Returns the address of the staker for a specific `tokenId``
     * Returns 0x0 if token is not staked
     */
    function stakerForToken(uint256 tokenId) public view returns (address) {
        return _stakedTokens[tokenId];
    }

    /**
     * @notice Lock a token for staking
     * only callable by members of the `tokenStakers` list
     * The owner of the token must approve the staking contract prior to call this method
     */
    function stakeToken(uint256 tokenId) external tokenStakersOnly whenTokenNotStaked(tokenId) {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "TokenStake: Staker not approved");
        _stakedTokens[tokenId] = _msgSender();
        emit TokenStaked(_msgSender(), tokenId);
    }

    /**
     * @notice Lock a token for staking
     * only callable by the staker
     */
    function unstakeToken(uint256 tokenId) external whenTokenStaked(tokenId) {
        require(_msgSender() == _stakedTokens[tokenId], "TokenStake: Token not stake by account");
        require(_msgSender() != address(0), "TokenStake: can't unstake from zero address");
        _stakedTokens[tokenId] = address(0);
        emit TokenUnstaked(_msgSender(), tokenId);
    }

    /**
     * @notice Recover a staked token
     * only callable by the owner
     */
    function recoverStakeToken(uint256 tokenId) external onlyOwner whenTokenStaked(tokenId) {
        _stakedTokens[tokenId] = address(0);
        emit TokenRecoverUnstaked(tokenId);
    }

    /**
     * @dev Change the token staker for a list of tokenIds
     * only callable by the owner
     * this is usefull if the staker contract must be updated
     * if `newStaker` is set to 0x0, tokens will be unstaked
     */
    function batchUpdateTokenStake(address newStaker, uint256[] calldata tokenIds) external onlyOwner {
        for (uint256 i = 0; i < tokenIds.length; i++) {
            require(_stakedTokens[tokenIds[i]] != address(0), "TokenStake: not restakeable");
            if (newStaker != address(0)) {
                require(_isApprovedOrOwner(newStaker, tokenIds[i]), "TokenStake: Staker not approved");
            }
            _stakedTokens[tokenIds[i]] = newStaker;
        }
        emit BatchUpdateTokenStaked(newStaker, tokenIds);
    }

    /**
     * @dev returns true if `account` is a member of the staker group
     */
    function isTokenStaker(address account) public view returns (bool) {
        return _tokenStakers.contains(account);
    }

    /**
     * @dev Add `tokenStaker` to the list of allowed stakers
     * only callable by the owner
     */
    function addTokenStaker(address tokenStaker) external onlyOwner {
        require(!_tokenStakers.contains(tokenStaker), "TokenStake: Already TokenStaker");
        _tokenStakers.add(tokenStaker);
        emit TokenStakerAdded(tokenStaker);
    }

    /**
     * @dev Remove `tokenStaker` from the list of allowed stakers
     * only callable by the owner
     */
    function removeTokenStaker(address tokenStaker) external onlyOwner {
        require(_tokenStakers.contains(tokenStaker), "TokenStake: Not TokenStaker");
        _tokenStakers.remove(tokenStaker);
        emit TokenStakerRemoved(tokenStaker);
    }
}

pragma solidity ^0.8.0;

contract xborgStaker is Ownable {
    TokenStake public xborgContract;
    using SafeMath for uint256;

    struct StakerInfo {
        uint256 point;
    }

    struct XborgInfo {
        uint256 NFTtype;
    }

    mapping(address => StakerInfo) private _stakerInfo;
    mapping(uint256 => XborgInfo) private _xborgInfo;

    uint256 private controllerKey;
    uint256 private commonTypepoint;
    uint256 private rareTypepoint;
    uint256 private eliteTypepoint;
    uint256 private ooTypepoint;
    uint256 public totalStaked;

    event NFTstake(string stakingStatus, uint256 tokenID, address stakerOf);
    event NFTunstake(string stakingStatus, uint256 tokenID, address stakerOf);

    constructor(TokenStake _xborgContract, uint256 _key){
        xborgContract = _xborgContract;
        controllerKey = _key;
        totalStaked = 0;
    }

    function stakeNFT(uint256[] calldata tokenIds, uint256 _key) external {
        require(controllerKey == _key, "Called with incorrect controller key");
        for (uint256 i = 0; i < tokenIds.length; i++) {
            require(msg.sender == xborgContract.ownerOf(tokenIds[i]) , "stake caller is not owner");
            xborgContract.stakeToken(tokenIds[i]);
            totalStaked++;     
            emit NFTstake("stake", tokenIds[i], msg.sender);      
        }
    }

    function unstakeNFT(uint256[] calldata tokenIds, uint256 _key) external {
        require(controllerKey == _key, "Called with incorrect controller key");
        for (uint256 i = 0; i < tokenIds.length; i++) {
            require(msg.sender == xborgContract.ownerOf(tokenIds[i]) , "stake caller is not owner");
            xborgContract.unstakeToken(tokenIds[i]);
            totalStaked--;
            emit NFTunstake("unstake", tokenIds[i], msg.sender);
        }     
    }

    function isNFTStaked(uint256 tokenId) public view returns (bool) {
        return xborgContract.isTokenStaked(tokenId);
    }
    

    function checkStakerPoint(address stakerAddr) public view returns (uint256) {
        uint256 summaryPoint = 0;
        for (uint256 i = 0; i < 0; i++) {
            if (stakerAddr == stakerOfToken(i)){
                uint256 TokenType = _xborgInfo[i].NFTtype;            
                if (TokenType == 0){
                    summaryPoint += 0;
                }
                else if (TokenType == 1){
                    summaryPoint += commonTypepoint;
                }
                else if (TokenType == 2){
                    summaryPoint += rareTypepoint;
                }
                else if (TokenType == 3){
                    summaryPoint += eliteTypepoint;
                }
                else if (TokenType == 4){
                    summaryPoint += ooTypepoint;
                }
            }
        }
        return summaryPoint;
    }

    function setNFTPoint(uint256[] calldata tokenPoints) external onlyOwner{
        commonTypepoint = tokenPoints[0];
        rareTypepoint = tokenPoints[1];
        eliteTypepoint = tokenPoints[2];
        ooTypepoint = tokenPoints[3];
    }

    function setNFTType(uint256[] calldata tokenIds, uint256[] calldata tokenType) external onlyOwner{
        for (uint256 i = 0; i < tokenIds.length; i++) {
            require(tokenIds.length == tokenType.length, "the length i not match");
            _xborgInfo[tokenIds[i]].NFTtype = tokenType[i];
        }
    }

    function checkNFTType(uint256 tokenId) public view returns (uint256) {
        return _xborgInfo[tokenId].NFTtype; 
    }

    function stakerOfToken(uint256 tokenId) public view returns (address) {
        return xborgContract.stakerForToken(tokenId); 
    }

    function setControllerKey(uint256 _key) external onlyOwner {
        controllerKey = _key;
    }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"contract TokenStake","name":"_xborgContract","type":"address"},{"internalType":"uint256","name":"_key","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"stakingStatus","type":"string"},{"indexed":false,"internalType":"uint256","name":"tokenID","type":"uint256"},{"indexed":false,"internalType":"address","name":"stakerOf","type":"address"}],"name":"NFTstake","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"stakingStatus","type":"string"},{"indexed":false,"internalType":"uint256","name":"tokenID","type":"uint256"},{"indexed":false,"internalType":"address","name":"stakerOf","type":"address"}],"name":"NFTunstake","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"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"checkNFTType","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"stakerAddr","type":"address"}],"name":"checkStakerPoint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"isNFTStaked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_key","type":"uint256"}],"name":"setControllerKey","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenPoints","type":"uint256[]"}],"name":"setNFTPoint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256[]","name":"tokenType","type":"uint256[]"}],"name":"setNFTType","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256","name":"_key","type":"uint256"}],"name":"stakeNFT","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"stakerOfToken","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalStaked","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":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"},{"internalType":"uint256","name":"_key","type":"uint256"}],"name":"unstakeNFT","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"xborgContract","outputs":[{"internalType":"contract TokenStake","name":"","type":"address"}],"stateMutability":"view","type":"function"}]

60806040523480156200001157600080fd5b5060405162001b9e38038062001b9e8339818101604052810190620000379190620001a9565b620000576200004b620000af60201b60201c565b620000b760201b60201c565b81600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080600481905550600060098190555050506200027b565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6000815190506200018c8162000247565b92915050565b600081519050620001a38162000261565b92915050565b60008060408385031215620001c357620001c262000242565b5b6000620001d3858286016200017b565b9250506020620001e68582860162000192565b9150509250929050565b6000620001fd8262000218565b9050919050565b60006200021182620001f0565b9050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600080fd5b620002528162000204565b81146200025e57600080fd5b50565b6200026c8162000238565b81146200027857600080fd5b50565b611913806200028b6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c80638da5cb5b1161008c5780639e5c5f7b116100665780639e5c5f7b14610223578063ac8bb71d14610253578063b3c722e514610283578063f2fde38b1461029f576100ea565b80638da5cb5b146101cd5780639a9648ea146101eb5780639d11987e14610207576100ea565b8063433b30a1116100c8578063433b30a114610159578063715018a614610175578063758202f41461017f578063817b1cd2146101af576100ea565b80630adad7bd146100ef5780632b62e8141461011f5780633f678a291461013b575b600080fd5b6101096004803603810190610104919061127c565b6102bb565b60405161011691906113da565b60405180910390f35b6101396004803603810190610134919061116e565b61036f565b005b6101436104a8565b6040516101509190611410565b60405180910390f35b610173600480360381019061016e91906111ef565b6104ce565b005b61017d61077a565b005b6101996004803603810190610194919061127c565b610802565b6040516101a69190611543565b60405180910390f35b6101b7610822565b6040516101c49190611543565b60405180910390f35b6101d5610828565b6040516101e291906113da565b60405180910390f35b61020560048036038101906102009190611121565b610851565b005b610221600480360381019061021c91906111ef565b610955565b005b61023d600480360381019061023891906110c7565b610c01565b60405161024a9190611543565b60405180910390f35b61026d6004803603810190610268919061127c565b610d1f565b60405161027a91906113f5565b60405180910390f35b61029d6004803603810190610298919061127c565b610dd3565b005b6102b960048036038101906102b491906110c7565b610e59565b005b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634125062c836040518263ffffffff1660e01b81526004016103189190611543565b60206040518083038186803b15801561033057600080fd5b505afa158015610344573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061036891906110f4565b9050919050565b610377610f51565b73ffffffffffffffffffffffffffffffffffffffff16610395610828565b73ffffffffffffffffffffffffffffffffffffffff16146103eb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103e2906114e7565b60405180910390fd5b60005b848490508110156104a157828290508585905014610441576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104389061146b565b60405180910390fd5b828282818110610454576104536116e5565b5b9050602002013560036000878785818110610472576104716116e5565b5b9050602002013581526020019081526020016000206000018190555080806104999061166d565b9150506103ee565b5050505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b8060045414610512576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105099061148b565b60405180910390fd5b60005b8383905081101561077457600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e858584818110610571576105706116e5565b5b905060200201356040518263ffffffff1660e01b81526004016105949190611543565b60206040518083038186803b1580156105ac57600080fd5b505afa1580156105c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e491906110f4565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610651576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106489061144b565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632cfb66888585848181106106a2576106a16116e5565b5b905060200201356040518263ffffffff1660e01b81526004016106c59190611543565b600060405180830381600087803b1580156106df57600080fd5b505af11580156106f3573d6000803e3d6000fd5b505050506009600081548092919061070a90611643565b91905055507f029d5b5d1bb52f7dd88e0b473cccd9271586c2ac57235f5f200a161a50417d07848483818110610743576107426116e5565b5b90506020020135336040516107599291906114ab565b60405180910390a1808061076c9061166d565b915050610515565b50505050565b610782610f51565b73ffffffffffffffffffffffffffffffffffffffff166107a0610828565b73ffffffffffffffffffffffffffffffffffffffff16146107f6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107ed906114e7565b60405180910390fd5b6108006000610f59565b565b600060036000838152602001908152602001600020600001549050919050565b60095481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610859610f51565b73ffffffffffffffffffffffffffffffffffffffff16610877610828565b73ffffffffffffffffffffffffffffffffffffffff16146108cd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108c4906114e7565b60405180910390fd5b818160008181106108e1576108e06116e5565b5b9050602002013560058190555081816001818110610902576109016116e5565b5b9050602002013560068190555081816002818110610923576109226116e5565b5b9050602002013560078190555081816003818110610944576109436116e5565b5b905060200201356008819055505050565b8060045414610999576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109909061148b565b60405180910390fd5b60005b83839050811015610bfb57600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e8585848181106109f8576109f76116e5565b5b905060200201356040518263ffffffff1660e01b8152600401610a1b9190611543565b60206040518083038186803b158015610a3357600080fd5b505afa158015610a47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6b91906110f4565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610ad8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610acf9061144b565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cda6b847858584818110610b2957610b286116e5565b5b905060200201356040518263ffffffff1660e01b8152600401610b4c9190611543565b600060405180830381600087803b158015610b6657600080fd5b505af1158015610b7a573d6000803e3d6000fd5b5050505060096000815480929190610b919061166d565b91905055507fc358df2c57d882759eeb0f6c0ad4fc43809541226464f11a89506d9c1c2db94a848483818110610bca57610bc96116e5565b5b9050602002013533604051610be0929190611507565b60405180910390a18080610bf39061166d565b91505061099c565b50505050565b6000806000905060005b6000811015610d1557610c1d816102bb565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161415610d02576000600360008381526020019081526020016000206000015490506000811415610c8857600083610c81919061156f565b9250610d00565b6001811415610ca65760055483610c9f919061156f565b9250610cff565b6002811415610cc45760065483610cbd919061156f565b9250610cfe565b6003811415610ce25760075483610cdb919061156f565b9250610cfd565b6004811415610cfc5760085483610cf9919061156f565b92505b5b5b5b5b505b8080610d0d9061166d565b915050610c0b565b5080915050919050565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f0a52424836040518263ffffffff1660e01b8152600401610d7c9190611543565b60206040518083038186803b158015610d9457600080fd5b505afa158015610da8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dcc919061124f565b9050919050565b610ddb610f51565b73ffffffffffffffffffffffffffffffffffffffff16610df9610828565b73ffffffffffffffffffffffffffffffffffffffff1614610e4f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e46906114e7565b60405180910390fd5b8060048190555050565b610e61610f51565b73ffffffffffffffffffffffffffffffffffffffff16610e7f610828565b73ffffffffffffffffffffffffffffffffffffffff1614610ed5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ecc906114e7565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610f45576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f3c9061142b565b60405180910390fd5b610f4e81610f59565b50565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b60008135905061102c81611898565b92915050565b60008151905061104181611898565b92915050565b60008083601f84011261105d5761105c611719565b5b8235905067ffffffffffffffff81111561107a57611079611714565b5b6020830191508360208202830111156110965761109561171e565b5b9250929050565b6000815190506110ac816118af565b92915050565b6000813590506110c1816118c6565b92915050565b6000602082840312156110dd576110dc611728565b5b60006110eb8482850161101d565b91505092915050565b60006020828403121561110a57611109611728565b5b600061111884828501611032565b91505092915050565b6000806020838503121561113857611137611728565b5b600083013567ffffffffffffffff81111561115657611155611723565b5b61116285828601611047565b92509250509250929050565b6000806000806040858703121561118857611187611728565b5b600085013567ffffffffffffffff8111156111a6576111a5611723565b5b6111b287828801611047565b9450945050602085013567ffffffffffffffff8111156111d5576111d4611723565b5b6111e187828801611047565b925092505092959194509250565b60008060006040848603121561120857611207611728565b5b600084013567ffffffffffffffff81111561122657611225611723565b5b61123286828701611047565b93509350506020611245868287016110b2565b9150509250925092565b60006020828403121561126557611264611728565b5b60006112738482850161109d565b91505092915050565b60006020828403121561129257611291611728565b5b60006112a0848285016110b2565b91505092915050565b6112b2816115c5565b82525050565b6112c1816115d7565b82525050565b6112d08161160d565b82525050565b60006112e360268361155e565b91506112ee8261172d565b604082019050919050565b600061130660198361155e565b91506113118261177c565b602082019050919050565b600061132960168361155e565b9150611334826117a5565b602082019050919050565b600061134c60248361155e565b9150611357826117ce565b604082019050919050565b600061136f60078361155e565b915061137a8261181d565b602082019050919050565b600061139260208361155e565b915061139d82611846565b602082019050919050565b60006113b560058361155e565b91506113c08261186f565b602082019050919050565b6113d481611603565b82525050565b60006020820190506113ef60008301846112a9565b92915050565b600060208201905061140a60008301846112b8565b92915050565b600060208201905061142560008301846112c7565b92915050565b60006020820190508181036000830152611444816112d6565b9050919050565b60006020820190508181036000830152611464816112f9565b9050919050565b600060208201905081810360008301526114848161131c565b9050919050565b600060208201905081810360008301526114a48161133f565b9050919050565b600060608201905081810360008301526114c481611362565b90506114d360208301856113cb565b6114e060408301846112a9565b9392505050565b6000602082019050818103600083015261150081611385565b9050919050565b60006060820190508181036000830152611520816113a8565b905061152f60208301856113cb565b61153c60408301846112a9565b9392505050565b600060208201905061155860008301846113cb565b92915050565b600082825260208201905092915050565b600061157a82611603565b915061158583611603565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156115ba576115b96116b6565b5b828201905092915050565b60006115d0826115e3565b9050919050565b60008115159050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60006116188261161f565b9050919050565b600061162a82611631565b9050919050565b600061163c826115e3565b9050919050565b600061164e82611603565b91506000821415611662576116616116b6565b5b600182039050919050565b600061167882611603565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156116ab576116aa6116b6565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b7f7374616b652063616c6c6572206973206e6f74206f776e657200000000000000600082015250565b7f746865206c656e6774682069206e6f74206d6174636800000000000000000000600082015250565b7f43616c6c6564207769746820696e636f727265637420636f6e74726f6c6c657260008201527f206b657900000000000000000000000000000000000000000000000000000000602082015250565b7f756e7374616b6500000000000000000000000000000000000000000000000000600082015250565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b7f7374616b65000000000000000000000000000000000000000000000000000000600082015250565b6118a1816115c5565b81146118ac57600080fd5b50565b6118b8816115d7565b81146118c357600080fd5b50565b6118cf81611603565b81146118da57600080fd5b5056fea264697066735822122080fa44b73b64c002f58d95fa417925185e04ba7b15e02e0d8341ab6d159a37b664736f6c63430008070033000000000000000000000000b452ff31b35dee74f2fdfd5194b91af1bad07b9100000000000000000000000000000000000000000000000000000004b62860ca

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100ea5760003560e01c80638da5cb5b1161008c5780639e5c5f7b116100665780639e5c5f7b14610223578063ac8bb71d14610253578063b3c722e514610283578063f2fde38b1461029f576100ea565b80638da5cb5b146101cd5780639a9648ea146101eb5780639d11987e14610207576100ea565b8063433b30a1116100c8578063433b30a114610159578063715018a614610175578063758202f41461017f578063817b1cd2146101af576100ea565b80630adad7bd146100ef5780632b62e8141461011f5780633f678a291461013b575b600080fd5b6101096004803603810190610104919061127c565b6102bb565b60405161011691906113da565b60405180910390f35b6101396004803603810190610134919061116e565b61036f565b005b6101436104a8565b6040516101509190611410565b60405180910390f35b610173600480360381019061016e91906111ef565b6104ce565b005b61017d61077a565b005b6101996004803603810190610194919061127c565b610802565b6040516101a69190611543565b60405180910390f35b6101b7610822565b6040516101c49190611543565b60405180910390f35b6101d5610828565b6040516101e291906113da565b60405180910390f35b61020560048036038101906102009190611121565b610851565b005b610221600480360381019061021c91906111ef565b610955565b005b61023d600480360381019061023891906110c7565b610c01565b60405161024a9190611543565b60405180910390f35b61026d6004803603810190610268919061127c565b610d1f565b60405161027a91906113f5565b60405180910390f35b61029d6004803603810190610298919061127c565b610dd3565b005b6102b960048036038101906102b491906110c7565b610e59565b005b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634125062c836040518263ffffffff1660e01b81526004016103189190611543565b60206040518083038186803b15801561033057600080fd5b505afa158015610344573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061036891906110f4565b9050919050565b610377610f51565b73ffffffffffffffffffffffffffffffffffffffff16610395610828565b73ffffffffffffffffffffffffffffffffffffffff16146103eb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103e2906114e7565b60405180910390fd5b60005b848490508110156104a157828290508585905014610441576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016104389061146b565b60405180910390fd5b828282818110610454576104536116e5565b5b9050602002013560036000878785818110610472576104716116e5565b5b9050602002013581526020019081526020016000206000018190555080806104999061166d565b9150506103ee565b5050505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b8060045414610512576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105099061148b565b60405180910390fd5b60005b8383905081101561077457600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e858584818110610571576105706116e5565b5b905060200201356040518263ffffffff1660e01b81526004016105949190611543565b60206040518083038186803b1580156105ac57600080fd5b505afa1580156105c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e491906110f4565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610651576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106489061144b565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632cfb66888585848181106106a2576106a16116e5565b5b905060200201356040518263ffffffff1660e01b81526004016106c59190611543565b600060405180830381600087803b1580156106df57600080fd5b505af11580156106f3573d6000803e3d6000fd5b505050506009600081548092919061070a90611643565b91905055507f029d5b5d1bb52f7dd88e0b473cccd9271586c2ac57235f5f200a161a50417d07848483818110610743576107426116e5565b5b90506020020135336040516107599291906114ab565b60405180910390a1808061076c9061166d565b915050610515565b50505050565b610782610f51565b73ffffffffffffffffffffffffffffffffffffffff166107a0610828565b73ffffffffffffffffffffffffffffffffffffffff16146107f6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107ed906114e7565b60405180910390fd5b6108006000610f59565b565b600060036000838152602001908152602001600020600001549050919050565b60095481565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b610859610f51565b73ffffffffffffffffffffffffffffffffffffffff16610877610828565b73ffffffffffffffffffffffffffffffffffffffff16146108cd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108c4906114e7565b60405180910390fd5b818160008181106108e1576108e06116e5565b5b9050602002013560058190555081816001818110610902576109016116e5565b5b9050602002013560068190555081816002818110610923576109226116e5565b5b9050602002013560078190555081816003818110610944576109436116e5565b5b905060200201356008819055505050565b8060045414610999576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109909061148b565b60405180910390fd5b60005b83839050811015610bfb57600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e8585848181106109f8576109f76116e5565b5b905060200201356040518263ffffffff1660e01b8152600401610a1b9190611543565b60206040518083038186803b158015610a3357600080fd5b505afa158015610a47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6b91906110f4565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610ad8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610acf9061144b565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cda6b847858584818110610b2957610b286116e5565b5b905060200201356040518263ffffffff1660e01b8152600401610b4c9190611543565b600060405180830381600087803b158015610b6657600080fd5b505af1158015610b7a573d6000803e3d6000fd5b5050505060096000815480929190610b919061166d565b91905055507fc358df2c57d882759eeb0f6c0ad4fc43809541226464f11a89506d9c1c2db94a848483818110610bca57610bc96116e5565b5b9050602002013533604051610be0929190611507565b60405180910390a18080610bf39061166d565b91505061099c565b50505050565b6000806000905060005b6000811015610d1557610c1d816102bb565b73ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161415610d02576000600360008381526020019081526020016000206000015490506000811415610c8857600083610c81919061156f565b9250610d00565b6001811415610ca65760055483610c9f919061156f565b9250610cff565b6002811415610cc45760065483610cbd919061156f565b9250610cfe565b6003811415610ce25760075483610cdb919061156f565b9250610cfd565b6004811415610cfc5760085483610cf9919061156f565b92505b5b5b5b5b505b8080610d0d9061166d565b915050610c0b565b5080915050919050565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f0a52424836040518263ffffffff1660e01b8152600401610d7c9190611543565b60206040518083038186803b158015610d9457600080fd5b505afa158015610da8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610dcc919061124f565b9050919050565b610ddb610f51565b73ffffffffffffffffffffffffffffffffffffffff16610df9610828565b73ffffffffffffffffffffffffffffffffffffffff1614610e4f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e46906114e7565b60405180910390fd5b8060048190555050565b610e61610f51565b73ffffffffffffffffffffffffffffffffffffffff16610e7f610828565b73ffffffffffffffffffffffffffffffffffffffff1614610ed5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ecc906114e7565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610f45576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f3c9061142b565b60405180910390fd5b610f4e81610f59565b50565b600033905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050816000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b60008135905061102c81611898565b92915050565b60008151905061104181611898565b92915050565b60008083601f84011261105d5761105c611719565b5b8235905067ffffffffffffffff81111561107a57611079611714565b5b6020830191508360208202830111156110965761109561171e565b5b9250929050565b6000815190506110ac816118af565b92915050565b6000813590506110c1816118c6565b92915050565b6000602082840312156110dd576110dc611728565b5b60006110eb8482850161101d565b91505092915050565b60006020828403121561110a57611109611728565b5b600061111884828501611032565b91505092915050565b6000806020838503121561113857611137611728565b5b600083013567ffffffffffffffff81111561115657611155611723565b5b61116285828601611047565b92509250509250929050565b6000806000806040858703121561118857611187611728565b5b600085013567ffffffffffffffff8111156111a6576111a5611723565b5b6111b287828801611047565b9450945050602085013567ffffffffffffffff8111156111d5576111d4611723565b5b6111e187828801611047565b925092505092959194509250565b60008060006040848603121561120857611207611728565b5b600084013567ffffffffffffffff81111561122657611225611723565b5b61123286828701611047565b93509350506020611245868287016110b2565b9150509250925092565b60006020828403121561126557611264611728565b5b60006112738482850161109d565b91505092915050565b60006020828403121561129257611291611728565b5b60006112a0848285016110b2565b91505092915050565b6112b2816115c5565b82525050565b6112c1816115d7565b82525050565b6112d08161160d565b82525050565b60006112e360268361155e565b91506112ee8261172d565b604082019050919050565b600061130660198361155e565b91506113118261177c565b602082019050919050565b600061132960168361155e565b9150611334826117a5565b602082019050919050565b600061134c60248361155e565b9150611357826117ce565b604082019050919050565b600061136f60078361155e565b915061137a8261181d565b602082019050919050565b600061139260208361155e565b915061139d82611846565b602082019050919050565b60006113b560058361155e565b91506113c08261186f565b602082019050919050565b6113d481611603565b82525050565b60006020820190506113ef60008301846112a9565b92915050565b600060208201905061140a60008301846112b8565b92915050565b600060208201905061142560008301846112c7565b92915050565b60006020820190508181036000830152611444816112d6565b9050919050565b60006020820190508181036000830152611464816112f9565b9050919050565b600060208201905081810360008301526114848161131c565b9050919050565b600060208201905081810360008301526114a48161133f565b9050919050565b600060608201905081810360008301526114c481611362565b90506114d360208301856113cb565b6114e060408301846112a9565b9392505050565b6000602082019050818103600083015261150081611385565b9050919050565b60006060820190508181036000830152611520816113a8565b905061152f60208301856113cb565b61153c60408301846112a9565b9392505050565b600060208201905061155860008301846113cb565b92915050565b600082825260208201905092915050565b600061157a82611603565b915061158583611603565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156115ba576115b96116b6565b5b828201905092915050565b60006115d0826115e3565b9050919050565b60008115159050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b60006116188261161f565b9050919050565b600061162a82611631565b9050919050565b600061163c826115e3565b9050919050565b600061164e82611603565b91506000821415611662576116616116b6565b5b600182039050919050565b600061167882611603565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156116ab576116aa6116b6565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600080fd5b600080fd5b600080fd5b600080fd5b600080fd5b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b7f7374616b652063616c6c6572206973206e6f74206f776e657200000000000000600082015250565b7f746865206c656e6774682069206e6f74206d6174636800000000000000000000600082015250565b7f43616c6c6564207769746820696e636f727265637420636f6e74726f6c6c657260008201527f206b657900000000000000000000000000000000000000000000000000000000602082015250565b7f756e7374616b6500000000000000000000000000000000000000000000000000600082015250565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b7f7374616b65000000000000000000000000000000000000000000000000000000600082015250565b6118a1816115c5565b81146118ac57600080fd5b50565b6118b8816115d7565b81146118c357600080fd5b50565b6118cf81611603565b81146118da57600080fd5b5056fea264697066735822122080fa44b73b64c002f58d95fa417925185e04ba7b15e02e0d8341ab6d159a37b664736f6c63430008070033

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

000000000000000000000000b452ff31b35dee74f2fdfd5194b91af1bad07b9100000000000000000000000000000000000000000000000000000004b62860ca

-----Decoded View---------------
Arg [0] : _xborgContract (address): 0xb452Ff31B35Dee74f2FdfD5194B91Af1BaD07b91
Arg [1] : _key (uint256): 20235968714

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000b452ff31b35dee74f2fdfd5194b91af1bad07b91
Arg [1] : 00000000000000000000000000000000000000000000000000000004b62860ca


Deployed Bytecode Sourcemap

66740:3863:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;70360:134;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;69902:319;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;66779:31;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;68115:484;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;19979:94;;;:::i;:::-;;70229:123;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;67264:26;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;19328:87;;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;69650:244;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;67625:482;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;68748:894;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;68607:127;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;:::-;;;;;;;;70502:98;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;20228:192;;;;;;;;;;;;;:::i;:::-;;:::i;:::-;;70360:134;70421:7;70448:13;;;;;;;;;;;:28;;;70477:7;70448:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;70441:44;;70360:134;;;:::o;69902:319::-;19559:12;:10;:12::i;:::-;19548:23;;:7;:5;:7::i;:::-;:23;;;19540:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;70015:9:::1;70010:204;70034:8;;:15;;70030:1;:19;70010:204;;;70098:9;;:16;;70079:8;;:15;;:35;70071:70;;;;;;;;;;;;:::i;:::-;;;;;;;;;70190:9;;70200:1;70190:12;;;;;;;:::i;:::-;;;;;;;;70156:10;:23;70167:8;;70176:1;70167:11;;;;;;;:::i;:::-;;;;;;;;70156:23;;;;;;;;;;;:31;;:46;;;;70051:3;;;;;:::i;:::-;;;;70010:204;;;;69902:319:::0;;;;:::o;66779:31::-;;;;;;;;;;;;;:::o;68115:484::-;68223:4;68206:13;;:21;68198:70;;;;;;;;;;;;:::i;:::-;;;;;;;;;68284:9;68279:308;68303:8;;:15;;68299:1;:19;68279:308;;;68362:13;;;;;;;;;;;:21;;;68384:8;;68393:1;68384:11;;;;;;;:::i;:::-;;;;;;;;68362:34;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;68348:48;;:10;:48;;;68340:87;;;;;;;;;;;;:::i;:::-;;;;;;;;;68442:13;;;;;;;;;;;:26;;;68469:8;;68478:1;68469:11;;;;;;;:::i;:::-;;;;;;;;68442:39;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;68496:11;;:13;;;;;;;;;:::i;:::-;;;;;;68529:46;68551:8;;68560:1;68551:11;;;;;;;:::i;:::-;;;;;;;;68564:10;68529:46;;;;;;;:::i;:::-;;;;;;;;68320:3;;;;;:::i;:::-;;;;68279:308;;;;68115:484;;;:::o;19979:94::-;19559:12;:10;:12::i;:::-;19548:23;;:7;:5;:7::i;:::-;:23;;;19540:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;20044:21:::1;20062:1;20044:9;:21::i;:::-;19979:94::o:0;70229:123::-;70289:7;70316:10;:19;70327:7;70316:19;;;;;;;;;;;:27;;;70309:34;;70229:123;;;:::o;67264:26::-;;;;:::o;19328:87::-;19374:7;19401:6;;;;;;;;;;;19394:13;;19328:87;:::o;69650:244::-;19559:12;:10;:12::i;:::-;19548:23;;:7;:5;:7::i;:::-;:23;;;19540:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;69750:11:::1;;69762:1;69750:14;;;;;;;:::i;:::-;;;;;;;;69732:15;:32;;;;69791:11;;69803:1;69791:14;;;;;;;:::i;:::-;;;;;;;;69775:13;:30;;;;69833:11;;69845:1;69833:14;;;;;;;:::i;:::-;;;;;;;;69816;:31;;;;69872:11;;69884:1;69872:14;;;;;;;:::i;:::-;;;;;;;;69858:11;:28;;;;69650:244:::0;;:::o;67625:482::-;67731:4;67714:13;;:21;67706:70;;;;;;;;;;;;:::i;:::-;;;;;;;;;67792:9;67787:313;67811:8;;:15;;67807:1;:19;67787:313;;;67870:13;;;;;;;;;;;:21;;;67892:8;;67901:1;67892:11;;;;;;;:::i;:::-;;;;;;;;67870:34;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;67856:48;;:10;:48;;;67848:87;;;;;;;;;;;;:::i;:::-;;;;;;;;;67950:13;;;;;;;;;;;:24;;;67975:8;;67984:1;67975:11;;;;;;;:::i;:::-;;;;;;;;67950:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;68002:11;;:13;;;;;;;;;:::i;:::-;;;;;;68040:42;68058:8;;68067:1;68058:11;;;;;;;:::i;:::-;;;;;;;;68071:10;68040:42;;;;;;;:::i;:::-;;;;;;;;67828:3;;;;;:::i;:::-;;;;67787:313;;;;67625:482;;;:::o;68748:894::-;68815:7;68835:20;68858:1;68835:24;;68875:9;68870:735;68894:1;68890;:5;68870:735;;;68935:16;68949:1;68935:13;:16::i;:::-;68921:30;;:10;:30;;;68917:677;;;68971:17;68991:10;:13;69002:1;68991:13;;;;;;;;;;;:21;;;68971:41;;69060:1;69047:9;:14;69043:536;;;69101:1;69085:17;;;;;:::i;:::-;;;69043:536;;;69162:1;69149:9;:14;69145:434;;;69203:15;;69187:31;;;;;:::i;:::-;;;69145:434;;;69278:1;69265:9;:14;69261:318;;;69319:13;;69303:29;;;;;:::i;:::-;;;69261:318;;;69392:1;69379:9;:14;69375:204;;;69433:14;;69417:30;;;;;:::i;:::-;;;69375:204;;;69507:1;69494:9;:14;69490:89;;;69548:11;;69532:27;;;;;:::i;:::-;;;69490:89;69375:204;69261:318;69145:434;69043:536;68952:642;68917:677;68897:3;;;;;:::i;:::-;;;;68870:735;;;;69622:12;69615:19;;;68748:894;;;:::o;68607:127::-;68666:4;68690:13;;;;;;;;;;;:27;;;68718:7;68690:36;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;68683:43;;68607:127;;;:::o;70502:98::-;19559:12;:10;:12::i;:::-;19548:23;;:7;:5;:7::i;:::-;:23;;;19540:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;70588:4:::1;70572:13;:20;;;;70502:98:::0;:::o;20228:192::-;19559:12;:10;:12::i;:::-;19548:23;;:7;:5;:7::i;:::-;:23;;;19540:68;;;;;;;;;;;;:::i;:::-;;;;;;;;;20337:1:::1;20317:22;;:8;:22;;;;20309:73;;;;;;;;;;;;:::i;:::-;;;;;;;;;20393:19;20403:8;20393:9;:19::i;:::-;20228:192:::0;:::o;687:98::-;740:7;767:10;760:17;;687:98;:::o;20428:173::-;20484:16;20503:6;;;;;;;;;;;20484:25;;20529:8;20520:6;;:17;;;;;;;;;;;;;;;;;;20584:8;20553:40;;20574:8;20553:40;;;;;;;;;;;;20473:128;20428:173;:::o;7:139:1:-;53:5;91:6;78:20;69:29;;107:33;134:5;107:33;:::i;:::-;7:139;;;;:::o;152:143::-;209:5;240:6;234:13;225:22;;256:33;283:5;256:33;:::i;:::-;152:143;;;;:::o;318:568::-;391:8;401:6;451:3;444:4;436:6;432:17;428:27;418:122;;459:79;;:::i;:::-;418:122;572:6;559:20;549:30;;602:18;594:6;591:30;588:117;;;624:79;;:::i;:::-;588:117;738:4;730:6;726:17;714:29;;792:3;784:4;776:6;772:17;762:8;758:32;755:41;752:128;;;799:79;;:::i;:::-;752:128;318:568;;;;;:::o;892:137::-;946:5;977:6;971:13;962:22;;993:30;1017:5;993:30;:::i;:::-;892:137;;;;:::o;1035:139::-;1081:5;1119:6;1106:20;1097:29;;1135:33;1162:5;1135:33;:::i;:::-;1035:139;;;;:::o;1180:329::-;1239:6;1288:2;1276:9;1267:7;1263:23;1259:32;1256:119;;;1294:79;;:::i;:::-;1256:119;1414:1;1439:53;1484:7;1475:6;1464:9;1460:22;1439:53;:::i;:::-;1429:63;;1385:117;1180:329;;;;:::o;1515:351::-;1585:6;1634:2;1622:9;1613:7;1609:23;1605:32;1602:119;;;1640:79;;:::i;:::-;1602:119;1760:1;1785:64;1841:7;1832:6;1821:9;1817:22;1785:64;:::i;:::-;1775:74;;1731:128;1515:351;;;;:::o;1872:559::-;1958:6;1966;2015:2;2003:9;1994:7;1990:23;1986:32;1983:119;;;2021:79;;:::i;:::-;1983:119;2169:1;2158:9;2154:17;2141:31;2199:18;2191:6;2188:30;2185:117;;;2221:79;;:::i;:::-;2185:117;2334:80;2406:7;2397:6;2386:9;2382:22;2334:80;:::i;:::-;2316:98;;;;2112:312;1872:559;;;;;:::o;2437:934::-;2559:6;2567;2575;2583;2632:2;2620:9;2611:7;2607:23;2603:32;2600:119;;;2638:79;;:::i;:::-;2600:119;2786:1;2775:9;2771:17;2758:31;2816:18;2808:6;2805:30;2802:117;;;2838:79;;:::i;:::-;2802:117;2951:80;3023:7;3014:6;3003:9;2999:22;2951:80;:::i;:::-;2933:98;;;;2729:312;3108:2;3097:9;3093:18;3080:32;3139:18;3131:6;3128:30;3125:117;;;3161:79;;:::i;:::-;3125:117;3274:80;3346:7;3337:6;3326:9;3322:22;3274:80;:::i;:::-;3256:98;;;;3051:313;2437:934;;;;;;;:::o;3377:704::-;3472:6;3480;3488;3537:2;3525:9;3516:7;3512:23;3508:32;3505:119;;;3543:79;;:::i;:::-;3505:119;3691:1;3680:9;3676:17;3663:31;3721:18;3713:6;3710:30;3707:117;;;3743:79;;:::i;:::-;3707:117;3856:80;3928:7;3919:6;3908:9;3904:22;3856:80;:::i;:::-;3838:98;;;;3634:312;3985:2;4011:53;4056:7;4047:6;4036:9;4032:22;4011:53;:::i;:::-;4001:63;;3956:118;3377:704;;;;;:::o;4087:345::-;4154:6;4203:2;4191:9;4182:7;4178:23;4174:32;4171:119;;;4209:79;;:::i;:::-;4171:119;4329:1;4354:61;4407:7;4398:6;4387:9;4383:22;4354:61;:::i;:::-;4344:71;;4300:125;4087:345;;;;:::o;4438:329::-;4497:6;4546:2;4534:9;4525:7;4521:23;4517:32;4514:119;;;4552:79;;:::i;:::-;4514:119;4672:1;4697:53;4742:7;4733:6;4722:9;4718:22;4697:53;:::i;:::-;4687:63;;4643:117;4438:329;;;;:::o;4773:118::-;4860:24;4878:5;4860:24;:::i;:::-;4855:3;4848:37;4773:118;;:::o;4897:109::-;4978:21;4993:5;4978:21;:::i;:::-;4973:3;4966:34;4897:109;;:::o;5012:169::-;5118:56;5168:5;5118:56;:::i;:::-;5113:3;5106:69;5012:169;;:::o;5187:366::-;5329:3;5350:67;5414:2;5409:3;5350:67;:::i;:::-;5343:74;;5426:93;5515:3;5426:93;:::i;:::-;5544:2;5539:3;5535:12;5528:19;;5187:366;;;:::o;5559:::-;5701:3;5722:67;5786:2;5781:3;5722:67;:::i;:::-;5715:74;;5798:93;5887:3;5798:93;:::i;:::-;5916:2;5911:3;5907:12;5900:19;;5559:366;;;:::o;5931:::-;6073:3;6094:67;6158:2;6153:3;6094:67;:::i;:::-;6087:74;;6170:93;6259:3;6170:93;:::i;:::-;6288:2;6283:3;6279:12;6272:19;;5931:366;;;:::o;6303:::-;6445:3;6466:67;6530:2;6525:3;6466:67;:::i;:::-;6459:74;;6542:93;6631:3;6542:93;:::i;:::-;6660:2;6655:3;6651:12;6644:19;;6303:366;;;:::o;6675:365::-;6817:3;6838:66;6902:1;6897:3;6838:66;:::i;:::-;6831:73;;6913:93;7002:3;6913:93;:::i;:::-;7031:2;7026:3;7022:12;7015:19;;6675:365;;;:::o;7046:366::-;7188:3;7209:67;7273:2;7268:3;7209:67;:::i;:::-;7202:74;;7285:93;7374:3;7285:93;:::i;:::-;7403:2;7398:3;7394:12;7387:19;;7046:366;;;:::o;7418:365::-;7560:3;7581:66;7645:1;7640:3;7581:66;:::i;:::-;7574:73;;7656:93;7745:3;7656:93;:::i;:::-;7774:2;7769:3;7765:12;7758:19;;7418:365;;;:::o;7789:118::-;7876:24;7894:5;7876:24;:::i;:::-;7871:3;7864:37;7789:118;;:::o;7913:222::-;8006:4;8044:2;8033:9;8029:18;8021:26;;8057:71;8125:1;8114:9;8110:17;8101:6;8057:71;:::i;:::-;7913:222;;;;:::o;8141:210::-;8228:4;8266:2;8255:9;8251:18;8243:26;;8279:65;8341:1;8330:9;8326:17;8317:6;8279:65;:::i;:::-;8141:210;;;;:::o;8357:260::-;8469:4;8507:2;8496:9;8492:18;8484:26;;8520:90;8607:1;8596:9;8592:17;8583:6;8520:90;:::i;:::-;8357:260;;;;:::o;8623:419::-;8789:4;8827:2;8816:9;8812:18;8804:26;;8876:9;8870:4;8866:20;8862:1;8851:9;8847:17;8840:47;8904:131;9030:4;8904:131;:::i;:::-;8896:139;;8623:419;;;:::o;9048:::-;9214:4;9252:2;9241:9;9237:18;9229:26;;9301:9;9295:4;9291:20;9287:1;9276:9;9272:17;9265:47;9329:131;9455:4;9329:131;:::i;:::-;9321:139;;9048:419;;;:::o;9473:::-;9639:4;9677:2;9666:9;9662:18;9654:26;;9726:9;9720:4;9716:20;9712:1;9701:9;9697:17;9690:47;9754:131;9880:4;9754:131;:::i;:::-;9746:139;;9473:419;;;:::o;9898:::-;10064:4;10102:2;10091:9;10087:18;10079:26;;10151:9;10145:4;10141:20;10137:1;10126:9;10122:17;10115:47;10179:131;10305:4;10179:131;:::i;:::-;10171:139;;9898:419;;;:::o;10323:639::-;10545:4;10583:2;10572:9;10568:18;10560:26;;10632:9;10626:4;10622:20;10618:1;10607:9;10603:17;10596:47;10660:131;10786:4;10660:131;:::i;:::-;10652:139;;10801:72;10869:2;10858:9;10854:18;10845:6;10801:72;:::i;:::-;10883;10951:2;10940:9;10936:18;10927:6;10883:72;:::i;:::-;10323:639;;;;;:::o;10968:419::-;11134:4;11172:2;11161:9;11157:18;11149:26;;11221:9;11215:4;11211:20;11207:1;11196:9;11192:17;11185:47;11249:131;11375:4;11249:131;:::i;:::-;11241:139;;10968:419;;;:::o;11393:639::-;11615:4;11653:2;11642:9;11638:18;11630:26;;11702:9;11696:4;11692:20;11688:1;11677:9;11673:17;11666:47;11730:131;11856:4;11730:131;:::i;:::-;11722:139;;11871:72;11939:2;11928:9;11924:18;11915:6;11871:72;:::i;:::-;11953;12021:2;12010:9;12006:18;11997:6;11953:72;:::i;:::-;11393:639;;;;;:::o;12038:222::-;12131:4;12169:2;12158:9;12154:18;12146:26;;12182:71;12250:1;12239:9;12235:17;12226:6;12182:71;:::i;:::-;12038:222;;;;:::o;12347:169::-;12431:11;12465:6;12460:3;12453:19;12505:4;12500:3;12496:14;12481:29;;12347:169;;;;:::o;12522:305::-;12562:3;12581:20;12599:1;12581:20;:::i;:::-;12576:25;;12615:20;12633:1;12615:20;:::i;:::-;12610:25;;12769:1;12701:66;12697:74;12694:1;12691:81;12688:107;;;12775:18;;:::i;:::-;12688:107;12819:1;12816;12812:9;12805:16;;12522:305;;;;:::o;12833:96::-;12870:7;12899:24;12917:5;12899:24;:::i;:::-;12888:35;;12833:96;;;:::o;12935:90::-;12969:7;13012:5;13005:13;12998:21;12987:32;;12935:90;;;:::o;13031:126::-;13068:7;13108:42;13101:5;13097:54;13086:65;;13031:126;;;:::o;13163:77::-;13200:7;13229:5;13218:16;;13163:77;;;:::o;13246:145::-;13315:9;13348:37;13379:5;13348:37;:::i;:::-;13335:50;;13246:145;;;:::o;13397:126::-;13447:9;13480:37;13511:5;13480:37;:::i;:::-;13467:50;;13397:126;;;:::o;13529:113::-;13579:9;13612:24;13630:5;13612:24;:::i;:::-;13599:37;;13529:113;;;:::o;13648:171::-;13687:3;13710:24;13728:5;13710:24;:::i;:::-;13701:33;;13756:4;13749:5;13746:15;13743:41;;;13764:18;;:::i;:::-;13743:41;13811:1;13804:5;13800:13;13793:20;;13648:171;;;:::o;13825:233::-;13864:3;13887:24;13905:5;13887:24;:::i;:::-;13878:33;;13933:66;13926:5;13923:77;13920:103;;;14003:18;;:::i;:::-;13920:103;14050:1;14043:5;14039:13;14032:20;;13825:233;;;:::o;14064:180::-;14112:77;14109:1;14102:88;14209:4;14206:1;14199:15;14233:4;14230:1;14223:15;14250:180;14298:77;14295:1;14288:88;14395:4;14392:1;14385:15;14419:4;14416:1;14409:15;14436:117;14545:1;14542;14535:12;14559:117;14668:1;14665;14658:12;14682:117;14791:1;14788;14781:12;14805:117;14914:1;14911;14904:12;14928:117;15037:1;15034;15027:12;15051:225;15191:34;15187:1;15179:6;15175:14;15168:58;15260:8;15255:2;15247:6;15243:15;15236:33;15051:225;:::o;15282:175::-;15422:27;15418:1;15410:6;15406:14;15399:51;15282:175;:::o;15463:172::-;15603:24;15599:1;15591:6;15587:14;15580:48;15463:172;:::o;15641:223::-;15781:34;15777:1;15769:6;15765:14;15758:58;15850:6;15845:2;15837:6;15833:15;15826:31;15641:223;:::o;15870:157::-;16010:9;16006:1;15998:6;15994:14;15987:33;15870:157;:::o;16033:182::-;16173:34;16169:1;16161:6;16157:14;16150:58;16033:182;:::o;16221:155::-;16361:7;16357:1;16349:6;16345:14;16338:31;16221:155;:::o;16382:122::-;16455:24;16473:5;16455:24;:::i;:::-;16448:5;16445:35;16435:63;;16494:1;16491;16484:12;16435:63;16382:122;:::o;16510:116::-;16580:21;16595:5;16580:21;:::i;:::-;16573:5;16570:32;16560:60;;16616:1;16613;16606:12;16560:60;16510:116;:::o;16632:122::-;16705:24;16723:5;16705:24;:::i;:::-;16698:5;16695:35;16685:63;;16744:1;16741;16734:12;16685:63;16632:122;:::o

Swarm Source

ipfs://80fa44b73b64c002f58d95fa417925185e04ba7b15e02e0d8341ab6d159a37b6

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.