ETH Price: $2,286.81 (+0.44%)

Token

Evo PC Season 1 (EVOPCS1)
 

Overview

Max Total Supply

56 EVOPCS1

Holders

33

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Filtered by Token Holder
juicyjeff.eth
Balance
1 EVOPCS1
0xd1dd546b28925f3d61461399807135bbfc75a6bb
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
S1CombinationToken

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 1 runs

Other Settings:
default evmVersion
File 1 of 27 : S1CombinationToken.sol
pragma solidity ^0.8.6;

import "./library/Basis.sol";
import "./interfaces/IBaseToken.sol";
import "./interfaces/ICombinationToken.sol";
import "./library/Withdrawable.sol";

contract S1CombinationToken is ICombinationToken, Basis {
    using ECDSA for bytes32;

    // <VARIABLES>
    bool public isInitialized = false;
    mapping(uint256 => bool) public paidOut;
    bool public paidOutIterable;
    uint256 public mintStartTime;

    // Parental base token contract
    IBaseToken internal parent_;
    // Parents for each token by it's ID
    mapping(uint256 => uint256[]) internal tokenParents_;
    // Name for each of every collection
    mapping(uint256 => string) internal combinationName_;
    // A map to store if token is combined
    mapping(uint256 => bool) internal baseIsCombined_;
    // A map to store child to parent mapping
    mapping(uint256 => uint256) internal childByParent_;
    // Max total supply and last token ID
    uint256 public maxTotalSupply = 203;

    /*
    @notion REWARD POOL
            Array which stores a reward for each winner
    */
    uint256[] public rewards;
    // </ VARIABLES>

    // <EVENTS>
    event MintCombinationToken(
        uint256 tokenId,
        address to,
        uint256[] parents
    );

    event RewardPayout(address claimer, uint256 amount, uint256 tokenId);
    event RewardPayoutDone();

    // onlyOwner events
    event Initialize();
    event SetRewards();
    event SetMaxTotalSupply(uint256 newMaxTotalSupply);
    event SetMintStartTime(uint256 mintStartTime);

    // </ EVENTS>

    /**
        @notice A constructor function is executed once when a contract is created and it is used to initialize
                contract state.
        @param _proxyRegistry - wyvern proxy for secondary sales on Opensea (cannot be changed after)
        @param _name - combination token name (cannot be changed after)
        @param _symbol - combination token symbol (cannot be changed after)
        @param _baseURI - combination token address where NFT images are stored
        @param _contractURI - combination token contract metadata URI
        @param _parent - parental BaseToken contract address
        @param _paymentToken - Wrapped ETH (WETH) token contract address for secondary sales (cannot be changed after)
    */
    constructor(
        address _proxyRegistry,
        string memory _name,
        string memory _symbol,
        string memory _baseURI,
        string memory _contractURI,
        address _parent,
        address _paymentToken
    )
    Basis(
        _proxyRegistry,
        _name,
        _symbol,
        _baseURI,
        _contractURI,
        _paymentToken
    )
    {
        parent_ = IBaseToken(_parent);
    }

    // <PUBLIC FUNCTIONS>

    function initialize(
        uint256[] memory _rewards
    ) external virtual onlyOwner {
        require(!isInitialized, "S1CombinationToken: contract is already initialized!");
        isInitialized = true;

        rewards = _rewards;

        emit Initialize();
    }

    /*
        @notion Public function called by user (Base tokens holder) to create a combination token
        @dev Function calls validateCombination in BaseToken.sol smart contract for Combination
             NFT validation
        @param _parents - array of Base token IDs 4 Base NFT from which Combination NFT should be minted
        @param _name - name of Combination NFT
    **/
    function mintCombinationToken(
        uint256[] memory _parents,
        string memory _name
    ) external virtual returns (uint256 _tokenId) {
        address _msgSender = msg.sender;
        _tokenId = lastTokenId_ + 1;

        require(_tokenId <= _maxTotalSupply(), "S1CombinationToken: total supply limit");
        require(mintStartTime != 0 && mintStartTime < block.timestamp, "S1CombinationToken: combination minting is not started yet");

        require(
            _parents.length == 4,
            "S1CombinationToken: invalid parents amount"
        );

        if (_tokenId == 1) {
            require(parent_.soldOut(), "S1CombinationToken: base tokens are not sold out yet");
        }

        // get token ID
        lastTokenId_++;

        _validateCombination(
            _parents,
            _msgSender,
            _tokenId
        );

        // set combination name
        combinationName_[_tokenId] = _name;
        // set token's parents
        tokenParents_[_tokenId] = _parents;
        // mint token
        _mint(_msgSender, _tokenId);

        emit MintCombinationToken(_tokenId, _msgSender, _parents);

        return _tokenId;
    }


    /**
        @dev A simple getter of a parental BaseToken contract
    */
    function parent() external view override returns (IBaseToken) {
        return parent_;
    }

    /**
        @dev Get a base tokens used to combine combination
        @param _tokenId - Combination token Id
        @return uint256[] - an array of Base tokens
    */
    function tokenParents(uint256 _tokenId)
    external
    view
    override
    returns (uint256[] memory)
    {
        return tokenParents_[_tokenId];
    }

    /**
        @dev Returns true if base token is already used
        @param _baseId - Base token Id
        @return bool - true if token is combined and
                false if it's not
    */
    function baseIsCombined(uint256 _baseId)
    external
    view
    override
    returns (bool)
    {
        return baseIsCombined_[_baseId];
    }

    /**
        @dev Returns Combination token name
        @param _tokenId - Combination token Id
        @return string - Token name set by user
    */
    function combinationName(uint256 _tokenId)
    external
    view
    override
    returns (string memory)
    {
        return combinationName_[_tokenId];
    }

    /**
        @dev Get a combination token child by it's parental base token Id
        @param _baseId - Base token Id
        @return uint256 - Combination token Id
    */
    function childByParent(uint256 _baseId)
    external
    view
    override
    returns (uint256)
    {
        return childByParent_[_baseId];
    }

    function payoutReward() external virtual {
        uint256[] memory _rewards = rewards;
        require(!paidOutIterable, "S1CombinationToken: reward is already paid out");
        paidOutIterable = true;
        require(lastTokenId_ >= _rewards.length, "S1CombinationToken: not enough combinations are minted yet");

        uint256 _len = _rewards.length;

        for (
            uint256 index = 0;
            index < _len;
            index++
        ) {
            uint256 _tokenId = index + 1;
            uint256 _payoutAmount = _rewards[index];
            address _tokenOwner = ownerOf(_tokenId);
            if (!_isContract(_tokenOwner)) {
                payable(_tokenOwner).transfer(_payoutAmount);
                paidOut[_tokenId] = true;

                emit RewardPayout(_tokenOwner, _payoutAmount, _tokenId);
            }
        }

        emit RewardPayoutDone();
    }

    function getMyReward(uint256 _tokenId) external virtual {
        require(paidOutIterable, "S1CombinationToken: all rewards are not paid out yet");
        require(!paidOut[_tokenId], "S1CombinationToken: reward by this token is already paid out");
        address _txSender = msg.sender;
        require(ownerOf(_tokenId) == _txSender, "S1CombinationToken: Looks like it's not your token");
        paidOut[_tokenId] = true;

        uint256 _payoutAmount = rewards[_tokenId];

        payable(_txSender).transfer(_payoutAmount);

        emit RewardPayout(_txSender, _payoutAmount, _tokenId);
    }

    function setRewards(
        uint256[] memory _rewards
    ) external virtual onlyOwner {
        rewards = _rewards;

        emit SetRewards();
    }

    function setMaxTotalSupply(uint256 _newMaxTotalSupply) external onlyOwner {
        maxTotalSupply = _newMaxTotalSupply;

        emit SetMaxTotalSupply(_newMaxTotalSupply);
    }

    function setMintStartTime(uint256 _newMintStartTime) external onlyOwner {
        mintStartTime = _newMintStartTime;

        emit SetMintStartTime(_newMintStartTime);
    }

    /**
        @notice A function to serve constant maxTotalSupply
        @dev Function was created for dev purposes, to make proper testing simpler
        @return constant maxTotalSupply variable
    */
    function _maxTotalSupply() internal view virtual returns (uint256) {
        return maxTotalSupply;
    }

    function _validateCombination(
        uint256[] memory _parents,
        address _msgSender,
        uint256 _childId
    ) internal {
        (uint8 _firstMaterial, uint8 _firstEdging, uint8 _firstSuit, uint16 _firstRank) = parent_.baseTokenMainTraits(_parents[0]);
        bytes32 _expectedTraitsHash = keccak256(
            abi.encodePacked(
                _firstMaterial,
                _firstEdging,
                _firstRank
            )
        );

        uint16 _suitChecksum = _firstSuit;
        require(
            parent_.ownerOf(_parents[0]) == _msgSender,
            "S1CombinationToken: you are not a token owner"
        );
        require(
            childByParent_[_parents[0]] == 0,
            "S1CombinationToken: parent already has a child"
        );
        childByParent_[_parents[0]] = _childId;
        baseIsCombined_[_parents[0]] = true;

        for (uint256 i = 1;
            i < _parents.length;
            i++) {
            uint256 _currentlyIterableToken = _parents[i];
            require(
                parent_.ownerOf(_currentlyIterableToken) == _msgSender,
                "S1CombinationToken: you are not a token owner"
            );
            require(
                childByParent_[_currentlyIterableToken] == 0,
                "S1CombinationToken: parent already has a child"
            );

            (uint8 _currentMaterial, uint8 _currentEdging, uint8 _currentSuit, uint16 _currentRank) = parent_.baseTokenMainTraits(_currentlyIterableToken);

            require(_expectedTraitsHash == keccak256(
                abi.encodePacked(
                    _currentMaterial,
                    _currentEdging,
                    _currentRank
                )
            ),
                "S1CombinationToken: wrong material/edging/rank"
            );
            _suitChecksum += _currentSuit;
            childByParent_[_currentlyIterableToken] = _childId;
            baseIsCombined_[_currentlyIterableToken] = true;
        }

        require(_suitChecksum == 15, "S1CombinationToken: wrong suits");
    }

    /**
        @notice Used to receive Ether from Base Token contract
        @dev Function is executed if none of the other functions match the function
             identifier or no data was provided with the function call
    */
    fallback() external payable {}

    /**
        @notice Used to receive Ether from Base Token contract
        @dev Function is executed if none of the other functions match the function
             identifier or no data was provided with the function call
    */
    receive() external payable {}

    /**
        @notice Used to protect Owner from shooting himself in a foot
        @dev This function overrides same-named function from Ownable
             library and makes it an empty one
    */
    function renounceOwnership() public override onlyOwner {}
}

File 2 of 27 : Basis.sol
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/access/Ownable.sol";
import "../library/ERC721Buyable.sol";
import "../interfaces/IBasis.sol";
import "@openzeppelin/contracts/utils/Strings.sol";

contract Basis is IBasis, ERC721Buyable {
    using Strings for uint256;

    string internal baseURI;
    uint256 internal lastTokenId_;
    string public contractURI;

    event SetContractURI(string contractURI);
    event SetBaseURI(string baseUri);

    constructor(
        address _proxyRegistry,
        string memory _name,
        string memory _symbol,
        string memory _baseURI,
        string memory _contractURI,
        address _paymentToken
    ) ERC721(_name, _symbol) ERC721Buyable(_paymentToken, _name, "1.0.0") {
        baseURI = _baseURI;
        contractURI = _contractURI;
        proxyRegistry = _proxyRegistry;
    }

    function setContractURI(string memory _contractURI)
    external
    override
    onlyOwner
    {
        contractURI = _contractURI;

        emit SetContractURI(_contractURI);
    }

    function setBaseURI(string memory _baseUri) external override onlyOwner {
        baseURI = _baseUri;

        emit SetBaseURI(_baseUri);
    }

    /**
     * @dev Get a `tokenURI`
     * @param `_tokenId` an id whose `tokenURI` will be returned
     * @return `tokenURI` string
     */
    function tokenURI(uint256 _tokenId)
    public
    view
    override
    returns (string memory)
    {
        require(_exists(_tokenId), "Basis: URI query for nonexistent token");

        // Concatenate the tokenID to the baseURI, token symbol and token id
        return string(abi.encodePacked(baseURI, _tokenId.toString()));
    }

    function totalSupply()
    external
    view
    override
    returns (uint256)
    {
        return lastTokenId_;
    }

    function _isContract(address _addr) internal returns (bool _isContract){
        uint32 size;
        assembly {
            size := extcodesize(_addr)
        }
        return (size > 0);
    }
}

File 3 of 27 : IBaseToken.sol
pragma solidity ^0.8.6;

import "./ICombinableTokenBasis.sol";

interface IBaseToken is ICombinableTokenBasis {
    function initialize(address _membershipToken, address _childAddress)
        external;

    function publicSaleMint(
        address _to,
        uint256 _amount
    ) external payable;

    function presaleMint(
        address _to,
        uint256 _amount
    ) external payable;

    function setSaleStartTime(uint256 _saleStartTime) external;

    function setPresaleTime(uint256 _presaleStartTime, uint256 _presaleEndTime) external;

    function baseTokenMainTraits(uint256 _tokenId) external view returns (uint8, uint8, uint8, uint16);

    function membershipMintPass(address _minter) external view returns (bool);
}

File 4 of 27 : ICombinationToken.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import "./IBaseToken.sol";

interface ICombinationToken is IERC721 {
    function parent() external view returns (IBaseToken);

    function tokenParents(uint256 _tokenId)
    external
    view
    returns (uint256[] memory);

    function baseIsCombined(uint256 _baseId) external view returns (bool);

    function combinationName(uint256 _tokenId)
    external
    view
    returns (string memory);

    function childByParent(uint256 _baseId)
    external
    view
    returns (uint256);
}

File 5 of 27 : Withdrawable.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/access/Ownable.sol";
import "../interfaces/IWithdrawable.sol";

abstract contract Withdrawable is IWithdrawable, Ownable {
    event Withdraw(uint amount);
    event WithdrawAll();

    function pendingWithdrawal() external view override returns (uint) {
        return address(this).balance;
    }

    function withdraw(uint _amount) external override onlyOwner {
        _withdraw(_amount);

        emit Withdraw(_amount);
    }

    function withdrawAll() external override onlyOwner {
        _withdraw(address(this).balance);

        emit WithdrawAll();
    }

    function _withdraw(uint _amount) internal {
        require(_amount > 0, "Withdrawable: Amount has to be greater than 0");
        require(
            _amount <= address(this).balance,
            "Withdrawable: Not enough funds"
        );
        payable(msg.sender).transfer(_amount);
    }
}

File 6 of 27 : Ownable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../utils/Context.sol";

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

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _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);
    }
}

File 7 of 27 : ERC721Buyable.sol
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";
import "@openzeppelin/contracts/utils/cryptography/draft-EIP712.sol";
import "@openzeppelin/contracts/utils/cryptography/SignatureChecker.sol";
import "../opensea/ERC721Tradable.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";

abstract contract ERC721Buyable is EIP712, ERC721Tradable, ReentrancyGuard {
    using ECDSA for bytes32;
    using SignatureChecker for address;

    uint256 public saleTax = 1_000;
    uint256 public saleTaxDenumerator = 10_000;
    IERC20 public paymentToken;
    address public treasury;
    mapping(address => mapping(uint256 => uint256)) public nonces;

    event SellOfferAcceptedETH(
        address seller,
        address buyer,
        uint256 tokenId,
        uint256 price
    );
    event SellOfferAcceptedWETH(
        address seller,
        address buyer,
        uint256 tokenId,
        uint256 price
    );
    event BuyOfferAcceptedWETH(
        address seller,
        address buyer,
        uint256 tokenId,
        uint256 price
    );

    // onlyOwner events
    event SetSaleTax(uint256 tax);
    event SetTreasury(address treasury);

    // _paymentToken - Wrapped ETH
    // _name - Contract name from EIP712
    // _version - Contract version from EIP712
    constructor(
        address _paymentToken,
        string memory _name,
        string memory _version
    ) EIP712(_name, _version) ReentrancyGuard() {
        treasury = msg.sender;
        paymentToken = IERC20(_paymentToken);
    }

    function setSaleTax(uint256 _tax) external onlyOwner {
        require(_tax <= 1_000, "ERC721Buyable: Looks like this tax is too big");
        saleTax = _tax;
        emit SetSaleTax(_tax);
    }

    function setTreasury(address _treasury) external onlyOwner {
        treasury = _treasury;

        emit SetTreasury(_treasury);
    }

    function buyAcceptingSellOfferETH(
        address _seller,
        address _buyer,
        uint256 _tokenId,
        uint256 nonce,
        uint256 _deadline,
        uint256 _price,
        bytes memory _sellerSignature
    ) external payable nonReentrant {
        bytes32 digest = _hashSellOfferETH(
            _seller,
            _buyer,
            _tokenId,
            _deadline,
            _price
        );
        require(
            _price == msg.value,
            "ERC721Buyable: Not enought ETH to buy token"
        );
        require(
            SignatureChecker.isValidSignatureNow(
                _seller,
                digest,
                _sellerSignature
            ),
            "ERC721Buyable: Invalid signature"
        );
        require(
            block.timestamp < _deadline,
            "ERC721Buyable: Signed transaction expired"
        );
        nonces[_seller][_tokenId]++;
        if (_buyer == address(0)) {
            _buyer = msg.sender;
        }
        uint256 tax = (_price * saleTax) / saleTaxDenumerator;
        if (tax > 0) {
            payable(treasury).transfer(tax);
        }

        payable(_seller).transfer(_price - tax);
        _transfer(_seller, _buyer, _tokenId);

        emit SellOfferAcceptedETH(_seller, _buyer, _tokenId, _price);
    }

    function _hashSellOfferETH(
        address _from,
        address _to,
        uint256 _tokenId,
        uint256 _deadline,
        uint256 _price
    ) internal view returns (bytes32) {
        return
        _hashTypedDataV4(
            keccak256(
                abi.encode(
                    keccak256(
                        "SellOfferETH(address from,address to,uint256 tokenId,uint256 nonce,uint256 deadline,uint256 price)"
                    ),
                    _from,
                    _to,
                    _tokenId,
                    nonces[_from][_tokenId],
                    _deadline,
                    _price
                )
            )
        );
    }

    function buyAcceptingSellOfferWETH(
        address _seller,
        uint256 _tokenId,
        uint256 nonce,
        uint256 _deadline,
        uint256 _price,
        bytes memory _sellerSignature
    ) external {
        bytes32 digest = _hashSellOfferWETH(
            _seller,
            _tokenId,
            _deadline,
            _price
        );
        require(
            SignatureChecker.isValidSignatureNow(
                _seller,
                digest,
                _sellerSignature
            ),
            "ERC721Buyable: Invalid signature"
        );
        require(
            block.timestamp < _deadline,
            "ERC721Buyable: signed transaction expired"
        );
        nonces[_seller][_tokenId]++;
        uint256 tax = (_price * saleTax) / saleTaxDenumerator;
        if (tax > 0) {
            bool _success = paymentToken.transferFrom(_msgSender(), treasury, tax);
            require(_success, "ERC721Buyable: transfer failed");
        }
        bool _success = paymentToken.transferFrom(_msgSender(), _seller, _price - tax);
        require(_success, "ERC721Buyable: transfer failed");
        _transfer(_seller, _msgSender(), _tokenId);

        emit SellOfferAcceptedWETH(_seller, _msgSender(), _tokenId, _price);
    }

    function _hashSellOfferWETH(
        address _from,
        uint256 _tokenId,
        uint256 _deadline,
        uint256 _price
    ) internal view returns (bytes32) {
        return
        _hashTypedDataV4(
            keccak256(
                abi.encode(
                    keccak256(
                        "SellOfferWETH(address from,uint256 tokenId,uint256 nonce,uint256 deadline,uint256 price)"
                    ),
                    _from,
                    _tokenId,
                    nonces[_from][_tokenId],
                    _deadline,
                    _price
                )
            )
        );
    }

    function sellAcceptingBuyOfferWETH(
        address _buyer,
        uint256 _tokenId,
        uint256 nonce,
        uint256 _deadline,
        uint256 _price,
        bytes memory _sellerSignature
    ) external {
        bytes32 digest = _hashBuyOfferWETH(_buyer, _tokenId, _deadline, _price);
        require(
            _buyer.isValidSignatureNow(digest, _sellerSignature),
            "ERC721Buyable: Invalid signature"
        );
        require(
            block.timestamp < _deadline,
            "ERC721Buyable: signed transaction expired"
        );
        nonces[_buyer][_tokenId]++;
        uint256 tax = (_price * saleTax) / saleTaxDenumerator;
        if (tax > 0) {
            bool _success = paymentToken.transferFrom(_buyer, treasury, tax);
            require(_success, "ERC721Buyable: transfer failed");
        }
        bool _success = paymentToken.transferFrom(_buyer, _msgSender(), _price - tax);
        require(_success, "ERC721Buyable: transfer failed");
        _transfer(_msgSender(), _buyer, _tokenId);

        emit BuyOfferAcceptedWETH(_msgSender(), _buyer, _tokenId, _price);
    }

    function _hashBuyOfferWETH(
        address _to,
        uint256 _tokenId,
        uint256 _deadline,
        uint256 _price
    ) internal view returns (bytes32) {
        return
        _hashTypedDataV4(
            keccak256(
                abi.encode(
                    keccak256(
                        "BuyOfferWETH(address to,uint256 tokenId,uint256 nonce,uint256 deadline,uint256 price)"
                    ),
                    _to,
                    _tokenId,
                    nonces[_to][_tokenId],
                    _deadline,
                    _price
                )
            )
        );
    }
}

File 8 of 27 : IBasis.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/token/ERC721/IERC721.sol";

interface IBasis is IERC721 {
    function setBaseURI(string memory _baseUri) external;

    function setContractURI(string memory _contractURI) external;

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

File 9 of 27 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

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

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

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

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

File 10 of 27 : Context.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

File 12 of 27 : ECDSA.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
 *
 * These functions can be used to verify that a message was signed by the holder
 * of the private keys of a given address.
 */
library ECDSA {
    enum RecoverError {
        NoError,
        InvalidSignature,
        InvalidSignatureLength,
        InvalidSignatureS,
        InvalidSignatureV
    }

    function _throwError(RecoverError error) private pure {
        if (error == RecoverError.NoError) {
            return; // no error: do nothing
        } else if (error == RecoverError.InvalidSignature) {
            revert("ECDSA: invalid signature");
        } else if (error == RecoverError.InvalidSignatureLength) {
            revert("ECDSA: invalid signature length");
        } else if (error == RecoverError.InvalidSignatureS) {
            revert("ECDSA: invalid signature 's' value");
        } else if (error == RecoverError.InvalidSignatureV) {
            revert("ECDSA: invalid signature 'v' value");
        }
    }

    /**
     * @dev Returns the address that signed a hashed message (`hash`) with
     * `signature` or error string. This address can then be used for verification purposes.
     *
     * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
     * this function rejects them by requiring the `s` value to be in the lower
     * half order, and the `v` value to be either 27 or 28.
     *
     * IMPORTANT: `hash` _must_ be the result of a hash operation for the
     * verification to be secure: it is possible to craft signatures that
     * recover to arbitrary addresses for non-hashed data. A safe way to ensure
     * this is by receiving a hash of the original message (which may otherwise
     * be too long), and then calling {toEthSignedMessageHash} on it.
     *
     * Documentation for signature generation:
     * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js]
     * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers]
     *
     * _Available since v4.3._
     */
    function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) {
        // Check the signature length
        // - case 65: r,s,v signature (standard)
        // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._
        if (signature.length == 65) {
            bytes32 r;
            bytes32 s;
            uint8 v;
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            assembly {
                r := mload(add(signature, 0x20))
                s := mload(add(signature, 0x40))
                v := byte(0, mload(add(signature, 0x60)))
            }
            return tryRecover(hash, v, r, s);
        } else if (signature.length == 64) {
            bytes32 r;
            bytes32 vs;
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            assembly {
                r := mload(add(signature, 0x20))
                vs := mload(add(signature, 0x40))
            }
            return tryRecover(hash, r, vs);
        } else {
            return (address(0), RecoverError.InvalidSignatureLength);
        }
    }

    /**
     * @dev Returns the address that signed a hashed message (`hash`) with
     * `signature`. This address can then be used for verification purposes.
     *
     * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
     * this function rejects them by requiring the `s` value to be in the lower
     * half order, and the `v` value to be either 27 or 28.
     *
     * IMPORTANT: `hash` _must_ be the result of a hash operation for the
     * verification to be secure: it is possible to craft signatures that
     * recover to arbitrary addresses for non-hashed data. A safe way to ensure
     * this is by receiving a hash of the original message (which may otherwise
     * be too long), and then calling {toEthSignedMessageHash} on it.
     */
    function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
        (address recovered, RecoverError error) = tryRecover(hash, signature);
        _throwError(error);
        return recovered;
    }

    /**
     * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately.
     *
     * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures]
     *
     * _Available since v4.3._
     */
    function tryRecover(
        bytes32 hash,
        bytes32 r,
        bytes32 vs
    ) internal pure returns (address, RecoverError) {
        bytes32 s;
        uint8 v;
        assembly {
            s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff)
            v := add(shr(255, vs), 27)
        }
        return tryRecover(hash, v, r, s);
    }

    /**
     * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately.
     *
     * _Available since v4.2._
     */
    function recover(
        bytes32 hash,
        bytes32 r,
        bytes32 vs
    ) internal pure returns (address) {
        (address recovered, RecoverError error) = tryRecover(hash, r, vs);
        _throwError(error);
        return recovered;
    }

    /**
     * @dev Overload of {ECDSA-tryRecover} that receives the `v`,
     * `r` and `s` signature fields separately.
     *
     * _Available since v4.3._
     */
    function tryRecover(
        bytes32 hash,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal pure returns (address, RecoverError) {
        // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
        // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
        // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most
        // signatures from current libraries generate a unique signature with an s-value in the lower half order.
        //
        // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
        // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
        // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
        // these malleable signatures as well.
        if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) {
            return (address(0), RecoverError.InvalidSignatureS);
        }
        if (v != 27 && v != 28) {
            return (address(0), RecoverError.InvalidSignatureV);
        }

        // If the signature is valid (and not malleable), return the signer address
        address signer = ecrecover(hash, v, r, s);
        if (signer == address(0)) {
            return (address(0), RecoverError.InvalidSignature);
        }

        return (signer, RecoverError.NoError);
    }

    /**
     * @dev Overload of {ECDSA-recover} that receives the `v`,
     * `r` and `s` signature fields separately.
     */
    function recover(
        bytes32 hash,
        uint8 v,
        bytes32 r,
        bytes32 s
    ) internal pure returns (address) {
        (address recovered, RecoverError error) = tryRecover(hash, v, r, s);
        _throwError(error);
        return recovered;
    }

    /**
     * @dev Returns an Ethereum Signed Message, created from a `hash`. This
     * produces hash corresponding to the one signed with the
     * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]
     * JSON-RPC method as part of EIP-191.
     *
     * See {recover}.
     */
    function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {
        // 32 is the length in bytes of hash,
        // enforced by the type signature above
        return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash));
    }

    /**
     * @dev Returns an Ethereum Signed Typed Data, created from a
     * `domainSeparator` and a `structHash`. This produces hash corresponding
     * to the one signed with the
     * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]
     * JSON-RPC method as part of EIP-712.
     *
     * See {recover}.
     */
    function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {
        return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash));
    }
}

File 13 of 27 : draft-EIP712.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ECDSA.sol";

/**
 * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data.
 *
 * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible,
 * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding
 * they need in their contracts using a combination of `abi.encode` and `keccak256`.
 *
 * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding
 * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA
 * ({_hashTypedDataV4}).
 *
 * The implementation of the domain separator was designed to be as efficient as possible while still properly updating
 * the chain id to protect against replay attacks on an eventual fork of the chain.
 *
 * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method
 * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask].
 *
 * _Available since v3.4._
 */
abstract contract EIP712 {
    /* solhint-disable var-name-mixedcase */
    // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to
    // invalidate the cached domain separator if the chain id changes.
    bytes32 private immutable _CACHED_DOMAIN_SEPARATOR;
    uint256 private immutable _CACHED_CHAIN_ID;

    bytes32 private immutable _HASHED_NAME;
    bytes32 private immutable _HASHED_VERSION;
    bytes32 private immutable _TYPE_HASH;

    /* solhint-enable var-name-mixedcase */

    /**
     * @dev Initializes the domain separator and parameter caches.
     *
     * The meaning of `name` and `version` is specified in
     * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]:
     *
     * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol.
     * - `version`: the current major version of the signing domain.
     *
     * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart
     * contract upgrade].
     */
    constructor(string memory name, string memory version) {
        bytes32 hashedName = keccak256(bytes(name));
        bytes32 hashedVersion = keccak256(bytes(version));
        bytes32 typeHash = keccak256(
            "EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"
        );
        _HASHED_NAME = hashedName;
        _HASHED_VERSION = hashedVersion;
        _CACHED_CHAIN_ID = block.chainid;
        _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion);
        _TYPE_HASH = typeHash;
    }

    /**
     * @dev Returns the domain separator for the current chain.
     */
    function _domainSeparatorV4() internal view returns (bytes32) {
        if (block.chainid == _CACHED_CHAIN_ID) {
            return _CACHED_DOMAIN_SEPARATOR;
        } else {
            return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION);
        }
    }

    function _buildDomainSeparator(
        bytes32 typeHash,
        bytes32 nameHash,
        bytes32 versionHash
    ) private view returns (bytes32) {
        return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this)));
    }

    /**
     * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this
     * function returns the hash of the fully encoded EIP712 message for this domain.
     *
     * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example:
     *
     * ```solidity
     * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode(
     *     keccak256("Mail(address to,string contents)"),
     *     mailTo,
     *     keccak256(bytes(mailContents))
     * )));
     * address signer = ECDSA.recover(digest, signature);
     * ```
     */
    function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) {
        return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash);
    }
}

File 14 of 27 : SignatureChecker.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./ECDSA.sol";
import "../Address.sol";
import "../../interfaces/IERC1271.sol";

/**
 * @dev Signature verification helper: Provide a single mechanism to verify both private-key (EOA) ECDSA signature and
 * ERC1271 contract sigantures. Using this instead of ECDSA.recover in your contract will make them compatible with
 * smart contract wallets such as Argent and Gnosis.
 *
 * Note: unlike ECDSA signatures, contract signature's are revocable, and the outcome of this function can thus change
 * through time. It could return true at block N and false at block N+1 (or the opposite).
 *
 * _Available since v4.1._
 */
library SignatureChecker {
    function isValidSignatureNow(
        address signer,
        bytes32 hash,
        bytes memory signature
    ) internal view returns (bool) {
        (address recovered, ECDSA.RecoverError error) = ECDSA.tryRecover(hash, signature);
        if (error == ECDSA.RecoverError.NoError && recovered == signer) {
            return true;
        }

        (bool success, bytes memory result) = signer.staticcall(
            abi.encodeWithSelector(IERC1271.isValidSignature.selector, hash, signature)
        );
        return (success && result.length == 32 && abi.decode(result, (bytes4)) == IERC1271.isValidSignature.selector);
    }
}

File 15 of 27 : ERC721Tradable.sol
// SPDX-License-Identifier: NONLICENSED
pragma solidity ^0.8.6;

import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "../interfaces/IWyvernProxyRegistry.sol";


abstract contract ERC721Tradable is ERC721, Ownable {
    address internal proxyRegistry;

    /**
     * Override isApprovedForAll to whitelist user's OpenSea proxy accounts to enable gas-less listings.
     */
    function isApprovedForAll(address _owner, address _operator)
        override
        public
        view
        returns (bool)
    {
        // Whitelist OpenSea proxy contract for easy trading.
        if (address(IWyvernProxyRegistry(proxyRegistry).proxies(_owner)) == _operator) {
            return true;
        }

        return super.isApprovedForAll(_owner, _operator);
    }
}

File 16 of 27 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT

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;
    }
}

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

pragma solidity ^0.8.0;

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

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

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

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

File 18 of 27 : IERC1271.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC1271 standard signature validation method for
 * contracts as defined in https://eips.ethereum.org/EIPS/eip-1271[ERC-1271].
 *
 * _Available since v4.1._
 */
interface IERC1271 {
    /**
     * @dev Should return whether the signature provided is valid for the provided data
     * @param hash      Hash of the data to be signed
     * @param signature Signature byte array associated with _data
     */
    function isValidSignature(bytes32 hash, bytes memory signature) external view returns (bytes4 magicValue);
}

File 19 of 27 : ERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // 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 Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @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 virtual override returns (uint256) {
        require(owner != address(0), "ERC721: balance query for the zero address");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _owners[tokenId];
        require(owner != address(0), "ERC721: owner query for nonexistent token");
        return owner;
    }

    /**
     * @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())) : "";
    }

    /**
     * @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 virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not owner nor approved for all"
        );

        _approve(to, tokenId);
    }

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

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        require(operator != _msgSender(), "ERC721: 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 virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");

        _transfer(from, to, tokenId);
    }

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

    /**
     * @dev See {IERC721-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) public virtual override {
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
        _safeTransfer(from, to, tokenId, _data);
    }

    /**
     * @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.
     *
     * `_data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: 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`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

    /**
     * @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), "ERC721: operator query for nonexistent token");
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, _data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

        _beforeTokenTransfer(address(0), to, tokenId);

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * 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 {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

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

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);
    }

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

    /**
     * @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.onERC721Received.selector;
            } catch (bytes memory reason) {
                if (reason.length == 0) {
                    revert("ERC721: transfer to non ERC721Receiver implementer");
                } else {
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * 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`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 20 of 27 : IWyvernProxyRegistry.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.6;

interface IOwnableDelegateProxy {}

abstract contract IWyvernProxyRegistry {
    /* Authenticated proxies by user. */
    mapping(address => IOwnableDelegateProxy) public proxies;
    function registerProxy() public virtual returns (IOwnableDelegateProxy proxy);
}

File 21 of 27 : IERC721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @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`, 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 Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

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

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

File 22 of 27 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT

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 `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

File 23 of 27 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

pragma solidity ^0.8.0;

import "./IERC165.sol";

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

File 25 of 27 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 26 of 27 : ICombinableTokenBasis.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.6;

import "./ICombinationToken.sol";
import "./IBasis.sol";

interface ICombinableTokenBasis is IBasis {
    function soldOut() external view returns (bool);

    function child() external view returns (ICombinationToken);

    function setChildAddress(address _child) external;

    function setTransferProhibitedForCombined(bool _prohibited) external;

    function setTransferProhibited(bool _prohibited) external;
}

File 27 of 27 : IWithdrawable.sol
//SPDX-License-Identifier: Unlicense
pragma solidity ^0.8.6;

interface IWithdrawable {
    function pendingWithdrawal() external view returns (uint);
    function withdraw(uint amount) external;
    function withdrawAll() external;
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_proxyRegistry","type":"address"},{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_symbol","type":"string"},{"internalType":"string","name":"_baseURI","type":"string"},{"internalType":"string","name":"_contractURI","type":"string"},{"internalType":"address","name":"_parent","type":"address"},{"internalType":"address","name":"_paymentToken","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"seller","type":"address"},{"indexed":false,"internalType":"address","name":"buyer","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"price","type":"uint256"}],"name":"BuyOfferAcceptedWETH","type":"event"},{"anonymous":false,"inputs":[],"name":"Initialize","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"parents","type":"uint256[]"}],"name":"MintCombinationToken","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"claimer","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"RewardPayout","type":"event"},{"anonymous":false,"inputs":[],"name":"RewardPayoutDone","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"seller","type":"address"},{"indexed":false,"internalType":"address","name":"buyer","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"price","type":"uint256"}],"name":"SellOfferAcceptedETH","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"seller","type":"address"},{"indexed":false,"internalType":"address","name":"buyer","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"price","type":"uint256"}],"name":"SellOfferAcceptedWETH","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"baseUri","type":"string"}],"name":"SetBaseURI","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"contractURI","type":"string"}],"name":"SetContractURI","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"newMaxTotalSupply","type":"uint256"}],"name":"SetMaxTotalSupply","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"mintStartTime","type":"uint256"}],"name":"SetMintStartTime","type":"event"},{"anonymous":false,"inputs":[],"name":"SetRewards","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tax","type":"uint256"}],"name":"SetSaleTax","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"treasury","type":"address"}],"name":"SetTreasury","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"stateMutability":"payable","type":"fallback"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_baseId","type":"uint256"}],"name":"baseIsCombined","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_seller","type":"address"},{"internalType":"address","name":"_buyer","type":"address"},{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"bytes","name":"_sellerSignature","type":"bytes"}],"name":"buyAcceptingSellOfferETH","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"_seller","type":"address"},{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"bytes","name":"_sellerSignature","type":"bytes"}],"name":"buyAcceptingSellOfferWETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_baseId","type":"uint256"}],"name":"childByParent","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"combinationName","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getMyReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_rewards","type":"uint256[]"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"},{"internalType":"address","name":"_operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isInitialized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxTotalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_parents","type":"uint256[]"},{"internalType":"string","name":"_name","type":"string"}],"name":"mintCombinationToken","outputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"nonces","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"paidOut","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paidOutIterable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"parent","outputs":[{"internalType":"contract IBaseToken","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paymentToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"payoutReward","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"rewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"saleTax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"saleTaxDenumerator","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_buyer","type":"address"},{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"nonce","type":"uint256"},{"internalType":"uint256","name":"_deadline","type":"uint256"},{"internalType":"uint256","name":"_price","type":"uint256"},{"internalType":"bytes","name":"_sellerSignature","type":"bytes"}],"name":"sellAcceptingBuyOfferWETH","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_baseUri","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_contractURI","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxTotalSupply","type":"uint256"}],"name":"setMaxTotalSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMintStartTime","type":"uint256"}],"name":"setMintStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_rewards","type":"uint256[]"}],"name":"setRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tax","type":"uint256"}],"name":"setSaleTax","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_treasury","type":"address"}],"name":"setTreasury","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"tokenParents","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"treasury","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]

6101206040526103e8600955612710600a556011805460ff1916905560cb601a553480156200002d57600080fd5b5060405162004811380380620048118339810160408190526200005091620003de565b60408051808201825260058152640312e302e360dc1b602080830191909152885189820190812060c08181527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60e08190524660a081815288517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818901819052818b019690965260608101939093526080808401929092523083820152885180840390910181529190920190965285519590930194909420909152610100929092528751899289928992899289928892839288929183918991620001389160009162000264565b5080516200014e90600190602084019062000264565b5050506200016b620001656200020e60201b60201c565b62000212565b50506001600855600c8054336001600160a01b031991821617909155600b80549091166001600160a01b03929092169190911790558251620001b590600e90602086019062000264565b508151620001cb90601090602085019062000264565b5050600780546001600160a01b039687166001600160a01b0319918216179091556015805498909616971696909617909355506200052398505050505050505050565b3390565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200027290620004d0565b90600052602060002090601f016020900481019282620002965760008555620002e1565b82601f10620002b157805160ff1916838001178555620002e1565b82800160010185558215620002e1579182015b82811115620002e1578251825591602001919060010190620002c4565b50620002ef929150620002f3565b5090565b5b80821115620002ef5760008155600101620002f4565b80516001600160a01b03811681146200032257600080fd5b919050565b600082601f8301126200033957600080fd5b81516001600160401b03808211156200035657620003566200050d565b604051601f8301601f19908116603f011681019082821181831017156200038157620003816200050d565b816040528381526020925086838588010111156200039e57600080fd5b600091505b83821015620003c25785820183015181830184015290820190620003a3565b83821115620003d45760008385830101525b9695505050505050565b600080600080600080600060e0888a031215620003fa57600080fd5b62000405886200030a565b60208901519097506001600160401b03808211156200042357600080fd5b620004318b838c0162000327565b975060408a01519150808211156200044857600080fd5b620004568b838c0162000327565b965060608a01519150808211156200046d57600080fd5b6200047b8b838c0162000327565b955060808a01519150808211156200049257600080fd5b50620004a18a828b0162000327565b935050620004b260a089016200030a565b9150620004c260c089016200030a565b905092959891949750929550565b600181811c90821680620004e557607f821691505b602082108114156200050757634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052604160045260246000fd5b60805160a05160c05160e051610100516142a96200056860003960006133b101526000613400015260006133db0152600061335f0152600061338801526142a96000f3fe6080604052600436106102245760003560e01c806301ffc9a71461022d57806306fdde0314610262578063081812fc14610284578063095ea7b3146102b1578063097bf9c8146102d157806313d88660146102e457806318160ddd146103045780631c2fff7214610323578063220d36d81461034357806323b872dd146103635780632ab4d052146103835780633013ce2914610399578063392e53cd146103b95780633cad99ce146103d35780633f3e4c11146103e957806342842e0e14610409578063502e1a161461042957806355f804b31461046157806360f96a8f146104815780636197a4d21461049f57806361d027b3146104bf57806362f837ef146104df5780636352211e146104f55780636fe0e5591461051557806370a0823114610535578063715018a614610555578063715ffdf11461056a57806374121766146105845780638da5cb5b146105b4578063931e2e49146105c9578063938e3d7b146105df57806395d89b41146105ff57806396317a5f146106145780639a4d5c1614610629578063a22cb46514610649578063a99919c114610669578063b88d4fde14610696578063c07e74d5146106b6578063c54bd9e1146106e3578063c87b56dd14610703578063d1af5df414610723578063d5b3621b14610743578063e8a3d48514610763578063e985e9c514610778578063f02dec3b14610798578063f0f44260146107c8578063f2fde38b146107e8578063f301af421461080857005b3661022b57005b005b34801561023957600080fd5b5061024d610248366004613a66565b610828565b60405190151581526020015b60405180910390f35b34801561026e57600080fd5b5061027761087a565b6040516102599190613dd9565b34801561029057600080fd5b506102a461029f366004613ad4565b61090c565b6040516102599190613cc7565b3480156102bd57600080fd5b5061022b6102cc366004613912565b610999565b61022b6102df36600461385c565b610aaa565b3480156102f057600080fd5b5061022b6102ff3660046139b2565b610d3d565b34801561031057600080fd5b50600f545b604051908152602001610259565b34801561032f57600080fd5b5061027761033e366004613ad4565b610dac565b34801561034f57600080fd5b5061022b61035e36600461393e565b610e4e565b34801561036f57600080fd5b5061022b61037e3660046137b0565b6110ac565b34801561038f57600080fd5b50610315601a5481565b3480156103a557600080fd5b50600b546102a4906001600160a01b031681565b3480156103c557600080fd5b5060115461024d9060ff1681565b3480156103df57600080fd5b50610315600a5481565b3480156103f557600080fd5b5061022b610404366004613ad4565b6110dd565b34801561041557600080fd5b5061022b6104243660046137b0565b611148565b34801561043557600080fd5b50610315610444366004613912565b600d60209081526000928352604080842090915290825290205481565b34801561046d57600080fd5b5061022b61047c366004613aa0565b611163565b34801561048d57600080fd5b506015546001600160a01b03166102a4565b3480156104ab57600080fd5b5061022b6104ba366004613ad4565b6111d5565b3480156104cb57600080fd5b50600c546102a4906001600160a01b031681565b3480156104eb57600080fd5b5061031560095481565b34801561050157600080fd5b506102a4610510366004613ad4565b6112a1565b34801561052157600080fd5b5061022b6105303660046139b2565b611318565b34801561054157600080fd5b5061031561055036600461373d565b611404565b34801561056157600080fd5b5061022b61148b565b34801561057657600080fd5b5060135461024d9060ff1681565b34801561059057600080fd5b5061024d61059f366004613ad4565b60009081526018602052604090205460ff1690565b3480156105c057600080fd5b506102a46114bc565b3480156105d557600080fd5b5061031560145481565b3480156105eb57600080fd5b5061022b6105fa366004613aa0565b6114cb565b34801561060b57600080fd5b5061027761153d565b34801561062057600080fd5b5061022b61154c565b34801561063557600080fd5b506103156106443660046139e6565b6117a4565b34801561065557600080fd5b5061022b6106643660046138e4565b611aa9565b34801561067557600080fd5b50610315610684366004613ad4565b60009081526019602052604090205490565b3480156106a257600080fd5b5061022b6106b13660046137f1565b611b6a565b3480156106c257600080fd5b506106d66106d1366004613ad4565b611ba2565b6040516102599190613d7c565b3480156106ef57600080fd5b5061022b6106fe366004613ad4565b611c03565b34801561070f57600080fd5b5061027761071e366004613ad4565b611e10565b34801561072f57600080fd5b5061022b61073e36600461393e565b611ea8565b34801561074f57600080fd5b5061022b61075e366004613ad4565b6120fc565b34801561076f57600080fd5b50610277612160565b34801561078457600080fd5b5061024d610793366004613777565b6121ee565b3480156107a457600080fd5b5061024d6107b3366004613ad4565b60126020526000908152604090205460ff1681565b3480156107d457600080fd5b5061022b6107e336600461373d565b6122bc565b3480156107f457600080fd5b5061022b61080336600461373d565b612336565b34801561081457600080fd5b50610315610823366004613ad4565b6123d6565b60006001600160e01b031982166380ac58cd60e01b148061085957506001600160e01b03198216635b5e139f60e01b145b8061087457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461088990614122565b80601f01602080910402602001604051908101604052809291908181526020018280546108b590614122565b80156109025780601f106108d757610100808354040283529160200191610902565b820191906000526020600020905b8154815290600101906020018083116108e557829003601f168201915b5050505050905090565b6000610917826123f7565b61097d5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b60006109a4826112a1565b9050806001600160a01b0316836001600160a01b03161415610a125760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610974565b336001600160a01b0382161480610a2e5750610a2e81336121ee565b610a9b5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f776044820152771b995c881b9bdc88185c1c1c9bdd995908199bdc88185b1b60421b6064820152608401610974565b610aa58383612414565b505050565b60026008541415610afd5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610974565b60026008556000610b118888888787612482565b9050348314610b765760405162461bcd60e51b815260206004820152602b60248201527f45524337323142757961626c653a204e6f7420656e6f7567687420455448207460448201526a3790313abc903a37b5b2b760a91b6064820152608401610974565b610b8188828461252c565b610b9d5760405162461bcd60e51b815260040161097490613fdf565b834210610bfe5760405162461bcd60e51b815260206004820152602960248201527f45524337323142757961626c653a205369676e6564207472616e73616374696f6044820152681b88195e1c1a5c995960ba1b6064820152608401610974565b6001600160a01b0388166000908152600d602090815260408083208984529091528120805491610c2d8361415d565b90915550506001600160a01b038716610c44573396505b6000600a5460095485610c5791906140c0565b610c6191906140ac565b90508015610ca557600c546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015610ca3573d6000803e3d6000fd5b505b6001600160a01b0389166108fc610cbc83876140df565b6040518115909202916000818181858888f19350505050158015610ce4573d6000803e3d6000fd5b50610cf0898989612678565b7f0919dd2bf769d97497dac32ec38d1620dba154dc7d4374848a2293a0c1ce867d89898987604051610d259493929190613d32565b60405180910390a15050600160085550505050505050565b33610d466114bc565b6001600160a01b031614610d6c5760405162461bcd60e51b815260040161097490613f0b565b8051610d7f90601b906020840190613560565b506040517fcead6bea62662740c692a735d17cd8e3d7f1c412a411b636775f7fa10d7f371b90600090a150565b6000818152601760205260409020805460609190610dc990614122565b80601f0160208091040260200160405190810160405280929190818152602001828054610df590614122565b8015610e425780601f10610e1757610100808354040283529160200191610e42565b820191906000526020600020905b815481529060010190602001808311610e2557829003601f168201915b50505050509050919050565b6000610e5c87878686612806565b9050610e6987828461252c565b610e855760405162461bcd60e51b815260040161097490613fdf565b834210610ea45760405162461bcd60e51b815260040161097490613e75565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491610ed38361415d565b91905055506000600a5460095485610eeb91906140c0565b610ef591906140ac565b90508015610faa57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd92610f3792339216908790600401613cdb565b602060405180830381600087803b158015610f5157600080fd5b505af1158015610f65573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f899190613a49565b905080610fa85760405162461bcd60e51b815260040161097490613dec565b505b600b546000906001600160a01b03166323b872dd338b610fca868a6140df565b6040518463ffffffff1660e01b8152600401610fe893929190613cdb565b602060405180830381600087803b15801561100257600080fd5b505af1158015611016573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061103a9190613a49565b9050806110595760405162461bcd60e51b815260040161097490613dec565b61106489338a612678565b7f8b4cb679525333b871a22887d818d55be20d198dd58ca071a0901e5033ba0b2789338a886040516110999493929190613d32565b60405180910390a1505050505050505050565b6110b63382612870565b6110d25760405162461bcd60e51b815260040161097490613f40565b610aa5838383612678565b336110e66114bc565b6001600160a01b03161461110c5760405162461bcd60e51b815260040161097490613f0b565b601a8190556040518181527f5d18a6b3e7e847824d58b9b569ab040f1707a3e20e54857610a00028e4822975906020015b60405180910390a150565b610aa583838360405180602001604052806000815250611b6a565b3361116c6114bc565b6001600160a01b0316146111925760405162461bcd60e51b815260040161097490613f0b565b80516111a590600e9060208401906135ab565b507f23c8c9488efebfd474e85a7956de6f39b17c7ab88502d42a623db2d8e382bbaa8160405161113d9190613dd9565b336111de6114bc565b6001600160a01b0316146112045760405162461bcd60e51b815260040161097490613f0b565b6103e881111561126c5760405162461bcd60e51b815260206004820152602d60248201527f45524337323142757961626c653a204c6f6f6b73206c696b652074686973207460448201526c617820697320746f6f2062696760981b6064820152608401610974565b60098190556040518181527f3fe94ea41084ff6af75f0f3e32844008c7de9a1e7f2b5f1a4173eacad584221b9060200161113d565b6000818152600260205260408120546001600160a01b0316806108745760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610974565b336113216114bc565b6001600160a01b0316146113475760405162461bcd60e51b815260040161097490613f0b565b60115460ff16156113b75760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a20636f6e747261637420697320604482015273616c726561647920696e697469616c697a65642160601b6064820152608401610974565b6011805460ff1916600117905580516113d790601b906020840190613560565b506040517f80f860092ed8101278311dd6b10dda4920a40ea5dfcbacfe724e2accfaf63efc90600090a150565b60006001600160a01b03821661146f5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610974565b506001600160a01b031660009081526003602052604090205490565b336114946114bc565b6001600160a01b0316146114ba5760405162461bcd60e51b815260040161097490613f0b565b565b6006546001600160a01b031690565b336114d46114bc565b6001600160a01b0316146114fa5760405162461bcd60e51b815260040161097490613f0b565b805161150d9060109060208401906135ab565b507f5ca9f750836b0b7efdace104f07b5c9f0df0650c0fd24f5163e99044ae36ea528160405161113d9190613dd9565b60606001805461088990614122565b6000601b80548060200260200160405190810160405280929190818152602001828054801561159a57602002820191906000526020600020905b815481526020019060010190808311611586575b5050601354939450505060ff90911615905061160f5760405162461bcd60e51b815260206004820152602e60248201527f5331436f6d62696e6174696f6e546f6b656e3a2072657761726420697320616c60448201526d1c9958591e481c185a59081bdd5d60921b6064820152608401610974565b6013805460ff191660011790558051600f5410156116925760405162461bcd60e51b815260206004820152603a60248201527f5331436f6d62696e6174696f6e546f6b656e3a206e6f7420656e6f75676820636044820152791bdb589a5b985d1a5bdb9cc8185c99481b5a5b9d1959081e595d60321b6064820152608401610974565b805160005b818110156117765760006116ac826001614094565b905060008483815181106116c2576116c26141ce565b6020026020010151905060006116d7836112a1565b9050803b63ffffffff16611760576040516001600160a01b0382169083156108fc029084906000818181858888f1935050505015801561171b573d6000803e3d6000fd5b5060008381526012602052604090819020805460ff19166001179055516000805160206142348339815191529061175790839085908790613d5b565b60405180910390a15b505050808061176e9061415d565b915050611697565b506040517fec5893a567ee572184e707c5f98a7255288dfeb96cd9a6ce1e1c1f48205ef4bf90600090a15050565b600f5460009033906117b7906001614094565b91506117c2601a5490565b8211156118205760405162461bcd60e51b815260206004820152602660248201527f5331436f6d62696e6174696f6e546f6b656e3a20746f74616c20737570706c79604482015265081b1a5b5a5d60d21b6064820152608401610974565b60145415801590611832575042601454105b6118a15760405162461bcd60e51b815260206004820152603a60248201527f5331436f6d62696e6174696f6e546f6b656e3a20636f6d62696e6174696f6e206044820152791b5a5b9d1a5b99c81a5cc81b9bdd081cdd185c9d1959081e595d60321b6064820152608401610974565b83516004146119055760405162461bcd60e51b815260206004820152602a60248201527f5331436f6d62696e6174696f6e546f6b656e3a20696e76616c696420706172656044820152691b9d1cc8185b5bdd5b9d60b21b6064820152608401610974565b81600114156119fd57601560009054906101000a90046001600160a01b03166001600160a01b031663893da6c96040518163ffffffff1660e01b815260040160206040518083038186803b15801561195c57600080fd5b505afa158015611970573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119949190613a49565b6119fd5760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a206261736520746f6b656e7320604482015273185c99481b9bdd081cdbdb19081bdd5d081e595d60621b6064820152608401610974565b600f8054906000611a0d8361415d565b9190505550611a1d848284612932565b60008281526017602090815260409091208451611a3c928601906135ab565b5060008281526016602090815260409091208551611a5c92870190613560565b50611a678183612e92565b7fcd33e1c846e5acc6224c69a15f1c2bd58be05821a3a9633c97bd85ca5b8e481a828286604051611a9a93929190614014565b60405180910390a15092915050565b6001600160a01b038216331415611afe5760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610974565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b611b743383612870565b611b905760405162461bcd60e51b815260040161097490613f40565b611b9c84848484612fb2565b50505050565b600081815260166020908152604091829020805483518184028101840190945280845260609392830182828015610e4257602002820191906000526020600020905b815481526020019060010190808311611be45750505050509050919050565b60135460ff16611c725760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a20616c6c207265776172647320604482015273185c99481b9bdd081c185a59081bdd5d081e595d60621b6064820152608401610974565b60008181526012602052604090205460ff1615611cf65760405162461bcd60e51b815260206004820152603c60248201527f5331436f6d62696e6174696f6e546f6b656e3a2072657761726420627920746860448201527b1a5cc81d1bdad95b881a5cc8185b1c9958591e481c185a59081bdd5d60221b6064820152608401610974565b3380611d01836112a1565b6001600160a01b031614611d725760405162461bcd60e51b815260206004820152603260248201527f5331436f6d62696e6174696f6e546f6b656e3a204c6f6f6b73206c696b6520696044820152713a13b9903737ba103cb7bab9103a37b5b2b760711b6064820152608401610974565b6000828152601260205260408120805460ff19166001179055601b805484908110611d9f57611d9f6141ce565b60009182526020822001546040519092506001600160a01b0384169183156108fc02918491818181858888f19350505050158015611de1573d6000803e3d6000fd5b50600080516020614234833981519152828285604051611e0393929190613d5b565b60405180910390a1505050565b6060611e1b826123f7565b611e765760405162461bcd60e51b815260206004820152602660248201527f42617369733a2055524920717565727920666f72206e6f6e6578697374656e74604482015265103a37b5b2b760d11b6064820152608401610974565b600e611e8183612fe5565b604051602001611e92929190613be9565b6040516020818303038152906040529050919050565b6000611eb6878786866130e2565b9050611ecc6001600160a01b038816828461252c565b611ee85760405162461bcd60e51b815260040161097490613fdf565b834210611f075760405162461bcd60e51b815260040161097490613e75565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491611f368361415d565b91905055506000600a5460095485611f4e91906140c0565b611f5891906140ac565b9050801561200d57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd92611f9a928e9216908790600401613cdb565b602060405180830381600087803b158015611fb457600080fd5b505af1158015611fc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611fec9190613a49565b90508061200b5760405162461bcd60e51b815260040161097490613dec565b505b600b546000906001600160a01b03166323b872dd8a3361202d868a6140df565b6040518463ffffffff1660e01b815260040161204b93929190613cdb565b602060405180830381600087803b15801561206557600080fd5b505af1158015612079573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061209d9190613a49565b9050806120bc5760405162461bcd60e51b815260040161097490613dec565b6120c7338a8a612678565b7fc449542e187835de02e1b181e93b2267fd8592c5728e4b347834a6711b51ccb3338a8a886040516110999493929190613d32565b336121056114bc565b6001600160a01b03161461212b5760405162461bcd60e51b815260040161097490613f0b565b60148190556040518181527fbde518b8db0e4db49cacb618e2c4f716581a2d84e5f32eb877ea67604bd5e0be9060200161113d565b6010805461216d90614122565b80601f016020809104026020016040519081016040528092919081815260200182805461219990614122565b80156121e65780601f106121bb576101008083540402835291602001916121e6565b820191906000526020600020905b8154815290600101906020018083116121c957829003601f168201915b505050505081565b60075460405163c455279160e01b81526000916001600160a01b038085169291169063c455279190612224908790600401613cc7565b60206040518083038186803b15801561223c57600080fd5b505afa158015612250573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612274919061375a565b6001600160a01b0316141561228b57506001610874565b6001600160a01b0380841660009081526005602090815260408083209386168352929052205460ff165b9392505050565b336122c56114bc565b6001600160a01b0316146122eb5760405162461bcd60e51b815260040161097490613f0b565b600c80546001600160a01b0319166001600160a01b0383161790556040517fcb7ef3e545f5cdb893f5c568ba710fe08f336375a2d9fd66e161033f8fc09ef39061113d908390613cc7565b3361233f6114bc565b6001600160a01b0316146123655760405162461bcd60e51b815260040161097490613f0b565b6001600160a01b0381166123ca5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610974565b6123d381613141565b50565b601b81815481106123e657600080fd5b600091825260209091200154905081565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190612449826112a1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6001600160a01b038581166000818152600d6020908152604080832088845282528083205481517f5a3ac364254bf8141cade7fc83e6b4ac37b75f1d4df26a245ef4a174edfe2593938101939093529082019390935292871660608401526080830186905260a083019190915260c0820184905260e082018390529061252290610100015b60405160208183030381529060405280519060200120613193565b9695505050505050565b600080600061253b85856131e1565b90925090506000816004811115612554576125546141b8565b1480156125725750856001600160a01b0316826001600160a01b0316145b15612582576001925050506122b5565b600080876001600160a01b0316631626ba7e60e01b88886040516024016125aa929190613dc0565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b03199094169390931790925290516125e89190613bcd565b600060405180830381855afa9150503d8060008114612623576040519150601f19603f3d011682016040523d82523d6000602084013e612628565b606091505b509150915081801561263b575080516020145b801561266c57508051630b135d3f60e11b906126609083016020908101908401613a83565b6001600160e01b031916145b98975050505050505050565b826001600160a01b031661268b826112a1565b6001600160a01b0316146126f35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610974565b6001600160a01b0382166127555760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610974565b612760600082612414565b6001600160a01b03831660009081526003602052604081208054600192906127899084906140df565b90915550506001600160a01b03821660009081526003602052604081208054600192906127b7908490614094565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03868116918217909255915184939187169160008051602061425483398151915291a4505050565b6001600160a01b0384166000908152600d60209081526040808320868452825280832054905161286592612507927f8cbb7530fdede89f5d16a7ee48153cff90c0b84c0b3fa0c3f178a5ddfda170b2928a928a92918a918a9101613d8f565b90505b949350505050565b600061287b826123f7565b6128dc5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610974565b60006128e7836112a1565b9050806001600160a01b0316846001600160a01b031614806129225750836001600160a01b03166129178461090c565b6001600160a01b0316145b80612868575061286881856121ee565b600080600080601560009054906101000a90046001600160a01b03166001600160a01b0316638afe79898860008151811061296f5761296f6141ce565b60200260200101516040518263ffffffff1660e01b815260040161299591815260200190565b60806040518083038186803b1580156129ad57600080fd5b505afa1580156129c1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129e59190613aed565b93509350935093506000848483604051602001612a0493929190613c90565b60408051601f198184030181529190528051602090910120601554895191925060ff8516916001600160a01b03808b16921690636352211e908c90600090612a4e57612a4e6141ce565b60200260200101516040518263ffffffff1660e01b8152600401612a7491815260200190565b60206040518083038186803b158015612a8c57600080fd5b505afa158015612aa0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ac4919061375a565b6001600160a01b031614612aea5760405162461bcd60e51b815260040161097490613ebe565b601960008a600081518110612b0157612b016141ce565b6020026020010151815260200190815260200160002054600014612b375760405162461bcd60e51b815260040161097490613f91565b86601960008b600081518110612b4f57612b4f6141ce565b60200260200101518152602001908152602001600020819055506001601860008b600081518110612b8257612b826141ce565b6020908102919091018101518252810191909152604001600020805460ff191691151591909117905560015b8951811015612e325760008a8281518110612bcb57612bcb6141ce565b60209081029190910101516015546040516331a9108f60e11b8152600481018390529192506001600160a01b038c811692911690636352211e9060240160206040518083038186803b158015612c2057600080fd5b505afa158015612c34573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c58919061375a565b6001600160a01b031614612c7e5760405162461bcd60e51b815260040161097490613ebe565b60008181526019602052604090205415612caa5760405162461bcd60e51b815260040161097490613f91565b601554604051638afe798960e01b8152600481018390526000918291829182916001600160a01b0390911690638afe79899060240160806040518083038186803b158015612cf757600080fd5b505afa158015612d0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d2f9190613aed565b9350935093509350838382604051602001612d4c93929190613c90565b604051602081830303815290604052805190602001208814612dc75760405162461bcd60e51b815260206004820152602e60248201527f5331436f6d62696e6174696f6e546f6b656e3a2077726f6e67206d617465726960448201526d616c2f656467696e672f72616e6b60901b6064820152608401610974565b612dd460ff83168861406e565b96508c601960008781526020019081526020016000208190555060016018600087815260200190815260200160002060006101000a81548160ff02191690831515021790555050505050508080612e2a9061415d565b915050612bae565b508061ffff16600f14612e875760405162461bcd60e51b815260206004820152601f60248201527f5331436f6d62696e6174696f6e546f6b656e3a2077726f6e67207375697473006044820152606401610974565b505050505050505050565b6001600160a01b038216612ee85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610974565b612ef1816123f7565b15612f3d5760405162461bcd60e51b815260206004820152601c60248201527b115490cdcc8c4e881d1bdad95b88185b1c9958591e481b5a5b9d195960221b6044820152606401610974565b6001600160a01b0382166000908152600360205260408120805460019290612f66908490614094565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386169081179091559051839290600080516020614254833981519152908290a45050565b612fbd848484612678565b612fc984848484613251565b611b9c5760405162461bcd60e51b815260040161097490613e23565b6060816130095750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613033578061301d8161415d565b915061302c9050600a836140ac565b915061300d565b6000816001600160401b0381111561304d5761304d6141e4565b6040519080825280601f01601f191660200182016040528015613077576020820181803683370190505b5090505b84156128685761308c6001836140df565b9150613099600a86614178565b6130a4906030614094565b60f81b8183815181106130b9576130b96141ce565b60200101906001600160f81b031916908160001a9053506130db600a866140ac565b945061307b565b6001600160a01b0384166000908152600d60209081526040808320868452825280832054905161286592612507927f2feec0009bd50e41c6079eeb85f264c8fb21147d30736dbaae14aa7936f4559f928a928a92918a918a9101613d8f565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006108746131a061335b565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b6000808251604114156132185760208301516040840151606085015160001a61320c8782858561344e565b9450945050505061324a565b8251604014156132425760208301516040840151613237868383613531565b93509350505061324a565b506000905060025b9250929050565b60006001600160a01b0384163b1561335357604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613295903390899088908890600401613cff565b602060405180830381600087803b1580156132af57600080fd5b505af19250505080156132df575060408051601f3d908101601f191682019092526132dc91810190613a83565b60015b613339573d80801561330d576040519150601f19603f3d011682016040523d82523d6000602084013e613312565b606091505b5080516133315760405162461bcd60e51b815260040161097490613e23565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612868565b506001612868565b60007f00000000000000000000000000000000000000000000000000000000000000004614156133aa57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6000806fa2a8918ca85bafe22016d0b997e4df60600160ff1b0383111561347b5750600090506003613528565b8460ff16601b1415801561349357508460ff16601c14155b156134a45750600090506004613528565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156134f8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661352157600060019250925050613528565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b016135528782888561344e565b935093505050935093915050565b82805482825590600052602060002090810192821561359b579160200282015b8281111561359b578251825591602001919060010190613580565b506135a792915061361e565b5090565b8280546135b790614122565b90600052602060002090601f0160209004810192826135d9576000855561359b565b82601f106135f257805160ff191683800117855561359b565b8280016001018555821561359b579182018281111561359b578251825591602001919060010190613580565b5b808211156135a7576000815560010161361f565b600082601f83011261364457600080fd5b813560206001600160401b0382111561365f5761365f6141e4565b8160051b61366e82820161403e565b83815282810190868401838801850189101561368957600080fd5b600093505b858410156136ac57803583526001939093019291840191840161368e565b50979650505050505050565b600082601f8301126136c957600080fd5b81356001600160401b038111156136e2576136e26141e4565b6136f5601f8201601f191660200161403e565b81815284602083860101111561370a57600080fd5b816020850160208301376000918101602001919091529392505050565b805160ff8116811461373857600080fd5b919050565b60006020828403121561374f57600080fd5b81356122b5816141fa565b60006020828403121561376c57600080fd5b81516122b5816141fa565b6000806040838503121561378a57600080fd5b8235613795816141fa565b915060208301356137a5816141fa565b809150509250929050565b6000806000606084860312156137c557600080fd5b83356137d0816141fa565b925060208401356137e0816141fa565b929592945050506040919091013590565b6000806000806080858703121561380757600080fd5b8435613812816141fa565b93506020850135613822816141fa565b92506040850135915060608501356001600160401b0381111561384457600080fd5b613850878288016136b8565b91505092959194509250565b600080600080600080600060e0888a03121561387757600080fd5b8735613882816141fa565b96506020880135613892816141fa565b955060408801359450606088013593506080880135925060a0880135915060c08801356001600160401b038111156138c957600080fd5b6138d58a828b016136b8565b91505092959891949750929550565b600080604083850312156138f757600080fd5b8235613902816141fa565b915060208301356137a58161420f565b6000806040838503121561392557600080fd5b8235613930816141fa565b946020939093013593505050565b60008060008060008060c0878903121561395757600080fd5b8635613962816141fa565b95506020870135945060408701359350606087013592506080870135915060a08701356001600160401b0381111561399957600080fd5b6139a589828a016136b8565b9150509295509295509295565b6000602082840312156139c457600080fd5b81356001600160401b038111156139da57600080fd5b61286884828501613633565b600080604083850312156139f957600080fd5b82356001600160401b0380821115613a1057600080fd5b613a1c86838701613633565b93506020850135915080821115613a3257600080fd5b50613a3f858286016136b8565b9150509250929050565b600060208284031215613a5b57600080fd5b81516122b58161420f565b600060208284031215613a7857600080fd5b81356122b58161421d565b600060208284031215613a9557600080fd5b81516122b58161421d565b600060208284031215613ab257600080fd5b81356001600160401b03811115613ac857600080fd5b612868848285016136b8565b600060208284031215613ae657600080fd5b5035919050565b60008060008060808587031215613b0357600080fd5b613b0c85613727565b9350613b1a60208601613727565b9250613b2860408601613727565b9150606085015161ffff81168114613b3f57600080fd5b939692955090935050565b600081518084526020808501945080840160005b83811015613b7a57815187529582019590820190600101613b5e565b509495945050505050565b60008151808452613b9d8160208601602086016140f6565b601f01601f19169290920160200192915050565b60008151613bc38185602086016140f6565b9290920192915050565b60008251613bdf8184602087016140f6565b9190910192915050565b600080845481600182811c915080831680613c0557607f831692505b6020808410821415613c2557634e487b7160e01b86526022600452602486fd5b818015613c395760018114613c4a57613c77565b60ff19861689528489019650613c77565b60008b81526020902060005b86811015613c6f5781548b820152908501908301613c56565b505084890196505b505050505050613c878185613bb1565b95945050505050565b60f893841b6001600160f81b031990811682529290931b909116600183015260f01b6001600160f01b031916600282015260040190565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061252290830184613b85565b6001600160a01b0394851681529290931660208301526040820152606081019190915260800190565b6001600160a01b039390931683526020830191909152604082015260600190565b6020815260006122b56020830184613b4a565b9586526001600160a01b0394909416602086015260408501929092526060840152608083015260a082015260c00190565b8281526040602082015260006128686040830184613b85565b6020815260006122b56020830184613b85565b6020808252601e908201527f45524337323142757961626c653a207472616e73666572206661696c65640000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526029908201527f45524337323142757961626c653a207369676e6564207472616e73616374696f6040820152681b88195e1c1a5c995960ba1b606082015260800190565b6020808252602d908201527f5331436f6d62696e6174696f6e546f6b656e3a20796f7520617265206e6f742060408201526c30903a37b5b2b71037bbb732b960991b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252602e908201527f5331436f6d62696e6174696f6e546f6b656e3a20706172656e7420616c72656160408201526d191e481a185cc8184818da1a5b1960921b606082015260800190565b6020808252818101527f45524337323142757961626c653a20496e76616c6964207369676e6174757265604082015260600190565b8381526001600160a01b038316602082015260606040820181905260009061286590830184613b4a565b604051601f8201601f191681016001600160401b0381118282101715614066576140666141e4565b604052919050565b600061ffff80831681851680830382111561408b5761408b61418c565b01949350505050565b600082198211156140a7576140a761418c565b500190565b6000826140bb576140bb6141a2565b500490565b60008160001904831182151516156140da576140da61418c565b500290565b6000828210156140f1576140f161418c565b500390565b60005b838110156141115781810151838201526020016140f9565b83811115611b9c5750506000910152565b600181811c9082168061413657607f821691505b6020821081141561415757634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156141715761417161418c565b5060010190565b600082614187576141876141a2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146123d357600080fd5b80151581146123d357600080fd5b6001600160e01b0319811681146123d357600080fdfecf0aa54119192462151ebf099a8743ac47b6485ce4965abf5b329683220eb548ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa26469706673582212202bb4ce836aa89b9dcc218847a3ab48660942ae0c37dee3f7e500ccfdfb78566264736f6c63430008060033000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c100000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000f794f9e028d168a59341aaf77fc8f57f33ddc6cf000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2000000000000000000000000000000000000000000000000000000000000000f45766f20504320536561736f6e20310000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000745564f5043533100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002868747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f636f6d62696e66742f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045697066733a2f2f45564f504353313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131312f000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x6080604052600436106102245760003560e01c806301ffc9a71461022d57806306fdde0314610262578063081812fc14610284578063095ea7b3146102b1578063097bf9c8146102d157806313d88660146102e457806318160ddd146103045780631c2fff7214610323578063220d36d81461034357806323b872dd146103635780632ab4d052146103835780633013ce2914610399578063392e53cd146103b95780633cad99ce146103d35780633f3e4c11146103e957806342842e0e14610409578063502e1a161461042957806355f804b31461046157806360f96a8f146104815780636197a4d21461049f57806361d027b3146104bf57806362f837ef146104df5780636352211e146104f55780636fe0e5591461051557806370a0823114610535578063715018a614610555578063715ffdf11461056a57806374121766146105845780638da5cb5b146105b4578063931e2e49146105c9578063938e3d7b146105df57806395d89b41146105ff57806396317a5f146106145780639a4d5c1614610629578063a22cb46514610649578063a99919c114610669578063b88d4fde14610696578063c07e74d5146106b6578063c54bd9e1146106e3578063c87b56dd14610703578063d1af5df414610723578063d5b3621b14610743578063e8a3d48514610763578063e985e9c514610778578063f02dec3b14610798578063f0f44260146107c8578063f2fde38b146107e8578063f301af421461080857005b3661022b57005b005b34801561023957600080fd5b5061024d610248366004613a66565b610828565b60405190151581526020015b60405180910390f35b34801561026e57600080fd5b5061027761087a565b6040516102599190613dd9565b34801561029057600080fd5b506102a461029f366004613ad4565b61090c565b6040516102599190613cc7565b3480156102bd57600080fd5b5061022b6102cc366004613912565b610999565b61022b6102df36600461385c565b610aaa565b3480156102f057600080fd5b5061022b6102ff3660046139b2565b610d3d565b34801561031057600080fd5b50600f545b604051908152602001610259565b34801561032f57600080fd5b5061027761033e366004613ad4565b610dac565b34801561034f57600080fd5b5061022b61035e36600461393e565b610e4e565b34801561036f57600080fd5b5061022b61037e3660046137b0565b6110ac565b34801561038f57600080fd5b50610315601a5481565b3480156103a557600080fd5b50600b546102a4906001600160a01b031681565b3480156103c557600080fd5b5060115461024d9060ff1681565b3480156103df57600080fd5b50610315600a5481565b3480156103f557600080fd5b5061022b610404366004613ad4565b6110dd565b34801561041557600080fd5b5061022b6104243660046137b0565b611148565b34801561043557600080fd5b50610315610444366004613912565b600d60209081526000928352604080842090915290825290205481565b34801561046d57600080fd5b5061022b61047c366004613aa0565b611163565b34801561048d57600080fd5b506015546001600160a01b03166102a4565b3480156104ab57600080fd5b5061022b6104ba366004613ad4565b6111d5565b3480156104cb57600080fd5b50600c546102a4906001600160a01b031681565b3480156104eb57600080fd5b5061031560095481565b34801561050157600080fd5b506102a4610510366004613ad4565b6112a1565b34801561052157600080fd5b5061022b6105303660046139b2565b611318565b34801561054157600080fd5b5061031561055036600461373d565b611404565b34801561056157600080fd5b5061022b61148b565b34801561057657600080fd5b5060135461024d9060ff1681565b34801561059057600080fd5b5061024d61059f366004613ad4565b60009081526018602052604090205460ff1690565b3480156105c057600080fd5b506102a46114bc565b3480156105d557600080fd5b5061031560145481565b3480156105eb57600080fd5b5061022b6105fa366004613aa0565b6114cb565b34801561060b57600080fd5b5061027761153d565b34801561062057600080fd5b5061022b61154c565b34801561063557600080fd5b506103156106443660046139e6565b6117a4565b34801561065557600080fd5b5061022b6106643660046138e4565b611aa9565b34801561067557600080fd5b50610315610684366004613ad4565b60009081526019602052604090205490565b3480156106a257600080fd5b5061022b6106b13660046137f1565b611b6a565b3480156106c257600080fd5b506106d66106d1366004613ad4565b611ba2565b6040516102599190613d7c565b3480156106ef57600080fd5b5061022b6106fe366004613ad4565b611c03565b34801561070f57600080fd5b5061027761071e366004613ad4565b611e10565b34801561072f57600080fd5b5061022b61073e36600461393e565b611ea8565b34801561074f57600080fd5b5061022b61075e366004613ad4565b6120fc565b34801561076f57600080fd5b50610277612160565b34801561078457600080fd5b5061024d610793366004613777565b6121ee565b3480156107a457600080fd5b5061024d6107b3366004613ad4565b60126020526000908152604090205460ff1681565b3480156107d457600080fd5b5061022b6107e336600461373d565b6122bc565b3480156107f457600080fd5b5061022b61080336600461373d565b612336565b34801561081457600080fd5b50610315610823366004613ad4565b6123d6565b60006001600160e01b031982166380ac58cd60e01b148061085957506001600160e01b03198216635b5e139f60e01b145b8061087457506301ffc9a760e01b6001600160e01b03198316145b92915050565b60606000805461088990614122565b80601f01602080910402602001604051908101604052809291908181526020018280546108b590614122565b80156109025780601f106108d757610100808354040283529160200191610902565b820191906000526020600020905b8154815290600101906020018083116108e557829003601f168201915b5050505050905090565b6000610917826123f7565b61097d5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b60006109a4826112a1565b9050806001600160a01b0316836001600160a01b03161415610a125760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610974565b336001600160a01b0382161480610a2e5750610a2e81336121ee565b610a9b5760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f776044820152771b995c881b9bdc88185c1c1c9bdd995908199bdc88185b1b60421b6064820152608401610974565b610aa58383612414565b505050565b60026008541415610afd5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610974565b60026008556000610b118888888787612482565b9050348314610b765760405162461bcd60e51b815260206004820152602b60248201527f45524337323142757961626c653a204e6f7420656e6f7567687420455448207460448201526a3790313abc903a37b5b2b760a91b6064820152608401610974565b610b8188828461252c565b610b9d5760405162461bcd60e51b815260040161097490613fdf565b834210610bfe5760405162461bcd60e51b815260206004820152602960248201527f45524337323142757961626c653a205369676e6564207472616e73616374696f6044820152681b88195e1c1a5c995960ba1b6064820152608401610974565b6001600160a01b0388166000908152600d602090815260408083208984529091528120805491610c2d8361415d565b90915550506001600160a01b038716610c44573396505b6000600a5460095485610c5791906140c0565b610c6191906140ac565b90508015610ca557600c546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015610ca3573d6000803e3d6000fd5b505b6001600160a01b0389166108fc610cbc83876140df565b6040518115909202916000818181858888f19350505050158015610ce4573d6000803e3d6000fd5b50610cf0898989612678565b7f0919dd2bf769d97497dac32ec38d1620dba154dc7d4374848a2293a0c1ce867d89898987604051610d259493929190613d32565b60405180910390a15050600160085550505050505050565b33610d466114bc565b6001600160a01b031614610d6c5760405162461bcd60e51b815260040161097490613f0b565b8051610d7f90601b906020840190613560565b506040517fcead6bea62662740c692a735d17cd8e3d7f1c412a411b636775f7fa10d7f371b90600090a150565b6000818152601760205260409020805460609190610dc990614122565b80601f0160208091040260200160405190810160405280929190818152602001828054610df590614122565b8015610e425780601f10610e1757610100808354040283529160200191610e42565b820191906000526020600020905b815481529060010190602001808311610e2557829003601f168201915b50505050509050919050565b6000610e5c87878686612806565b9050610e6987828461252c565b610e855760405162461bcd60e51b815260040161097490613fdf565b834210610ea45760405162461bcd60e51b815260040161097490613e75565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491610ed38361415d565b91905055506000600a5460095485610eeb91906140c0565b610ef591906140ac565b90508015610faa57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd92610f3792339216908790600401613cdb565b602060405180830381600087803b158015610f5157600080fd5b505af1158015610f65573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f899190613a49565b905080610fa85760405162461bcd60e51b815260040161097490613dec565b505b600b546000906001600160a01b03166323b872dd338b610fca868a6140df565b6040518463ffffffff1660e01b8152600401610fe893929190613cdb565b602060405180830381600087803b15801561100257600080fd5b505af1158015611016573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061103a9190613a49565b9050806110595760405162461bcd60e51b815260040161097490613dec565b61106489338a612678565b7f8b4cb679525333b871a22887d818d55be20d198dd58ca071a0901e5033ba0b2789338a886040516110999493929190613d32565b60405180910390a1505050505050505050565b6110b63382612870565b6110d25760405162461bcd60e51b815260040161097490613f40565b610aa5838383612678565b336110e66114bc565b6001600160a01b03161461110c5760405162461bcd60e51b815260040161097490613f0b565b601a8190556040518181527f5d18a6b3e7e847824d58b9b569ab040f1707a3e20e54857610a00028e4822975906020015b60405180910390a150565b610aa583838360405180602001604052806000815250611b6a565b3361116c6114bc565b6001600160a01b0316146111925760405162461bcd60e51b815260040161097490613f0b565b80516111a590600e9060208401906135ab565b507f23c8c9488efebfd474e85a7956de6f39b17c7ab88502d42a623db2d8e382bbaa8160405161113d9190613dd9565b336111de6114bc565b6001600160a01b0316146112045760405162461bcd60e51b815260040161097490613f0b565b6103e881111561126c5760405162461bcd60e51b815260206004820152602d60248201527f45524337323142757961626c653a204c6f6f6b73206c696b652074686973207460448201526c617820697320746f6f2062696760981b6064820152608401610974565b60098190556040518181527f3fe94ea41084ff6af75f0f3e32844008c7de9a1e7f2b5f1a4173eacad584221b9060200161113d565b6000818152600260205260408120546001600160a01b0316806108745760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610974565b336113216114bc565b6001600160a01b0316146113475760405162461bcd60e51b815260040161097490613f0b565b60115460ff16156113b75760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a20636f6e747261637420697320604482015273616c726561647920696e697469616c697a65642160601b6064820152608401610974565b6011805460ff1916600117905580516113d790601b906020840190613560565b506040517f80f860092ed8101278311dd6b10dda4920a40ea5dfcbacfe724e2accfaf63efc90600090a150565b60006001600160a01b03821661146f5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610974565b506001600160a01b031660009081526003602052604090205490565b336114946114bc565b6001600160a01b0316146114ba5760405162461bcd60e51b815260040161097490613f0b565b565b6006546001600160a01b031690565b336114d46114bc565b6001600160a01b0316146114fa5760405162461bcd60e51b815260040161097490613f0b565b805161150d9060109060208401906135ab565b507f5ca9f750836b0b7efdace104f07b5c9f0df0650c0fd24f5163e99044ae36ea528160405161113d9190613dd9565b60606001805461088990614122565b6000601b80548060200260200160405190810160405280929190818152602001828054801561159a57602002820191906000526020600020905b815481526020019060010190808311611586575b5050601354939450505060ff90911615905061160f5760405162461bcd60e51b815260206004820152602e60248201527f5331436f6d62696e6174696f6e546f6b656e3a2072657761726420697320616c60448201526d1c9958591e481c185a59081bdd5d60921b6064820152608401610974565b6013805460ff191660011790558051600f5410156116925760405162461bcd60e51b815260206004820152603a60248201527f5331436f6d62696e6174696f6e546f6b656e3a206e6f7420656e6f75676820636044820152791bdb589a5b985d1a5bdb9cc8185c99481b5a5b9d1959081e595d60321b6064820152608401610974565b805160005b818110156117765760006116ac826001614094565b905060008483815181106116c2576116c26141ce565b6020026020010151905060006116d7836112a1565b9050803b63ffffffff16611760576040516001600160a01b0382169083156108fc029084906000818181858888f1935050505015801561171b573d6000803e3d6000fd5b5060008381526012602052604090819020805460ff19166001179055516000805160206142348339815191529061175790839085908790613d5b565b60405180910390a15b505050808061176e9061415d565b915050611697565b506040517fec5893a567ee572184e707c5f98a7255288dfeb96cd9a6ce1e1c1f48205ef4bf90600090a15050565b600f5460009033906117b7906001614094565b91506117c2601a5490565b8211156118205760405162461bcd60e51b815260206004820152602660248201527f5331436f6d62696e6174696f6e546f6b656e3a20746f74616c20737570706c79604482015265081b1a5b5a5d60d21b6064820152608401610974565b60145415801590611832575042601454105b6118a15760405162461bcd60e51b815260206004820152603a60248201527f5331436f6d62696e6174696f6e546f6b656e3a20636f6d62696e6174696f6e206044820152791b5a5b9d1a5b99c81a5cc81b9bdd081cdd185c9d1959081e595d60321b6064820152608401610974565b83516004146119055760405162461bcd60e51b815260206004820152602a60248201527f5331436f6d62696e6174696f6e546f6b656e3a20696e76616c696420706172656044820152691b9d1cc8185b5bdd5b9d60b21b6064820152608401610974565b81600114156119fd57601560009054906101000a90046001600160a01b03166001600160a01b031663893da6c96040518163ffffffff1660e01b815260040160206040518083038186803b15801561195c57600080fd5b505afa158015611970573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119949190613a49565b6119fd5760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a206261736520746f6b656e7320604482015273185c99481b9bdd081cdbdb19081bdd5d081e595d60621b6064820152608401610974565b600f8054906000611a0d8361415d565b9190505550611a1d848284612932565b60008281526017602090815260409091208451611a3c928601906135ab565b5060008281526016602090815260409091208551611a5c92870190613560565b50611a678183612e92565b7fcd33e1c846e5acc6224c69a15f1c2bd58be05821a3a9633c97bd85ca5b8e481a828286604051611a9a93929190614014565b60405180910390a15092915050565b6001600160a01b038216331415611afe5760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610974565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b611b743383612870565b611b905760405162461bcd60e51b815260040161097490613f40565b611b9c84848484612fb2565b50505050565b600081815260166020908152604091829020805483518184028101840190945280845260609392830182828015610e4257602002820191906000526020600020905b815481526020019060010190808311611be45750505050509050919050565b60135460ff16611c725760405162461bcd60e51b815260206004820152603460248201527f5331436f6d62696e6174696f6e546f6b656e3a20616c6c207265776172647320604482015273185c99481b9bdd081c185a59081bdd5d081e595d60621b6064820152608401610974565b60008181526012602052604090205460ff1615611cf65760405162461bcd60e51b815260206004820152603c60248201527f5331436f6d62696e6174696f6e546f6b656e3a2072657761726420627920746860448201527b1a5cc81d1bdad95b881a5cc8185b1c9958591e481c185a59081bdd5d60221b6064820152608401610974565b3380611d01836112a1565b6001600160a01b031614611d725760405162461bcd60e51b815260206004820152603260248201527f5331436f6d62696e6174696f6e546f6b656e3a204c6f6f6b73206c696b6520696044820152713a13b9903737ba103cb7bab9103a37b5b2b760711b6064820152608401610974565b6000828152601260205260408120805460ff19166001179055601b805484908110611d9f57611d9f6141ce565b60009182526020822001546040519092506001600160a01b0384169183156108fc02918491818181858888f19350505050158015611de1573d6000803e3d6000fd5b50600080516020614234833981519152828285604051611e0393929190613d5b565b60405180910390a1505050565b6060611e1b826123f7565b611e765760405162461bcd60e51b815260206004820152602660248201527f42617369733a2055524920717565727920666f72206e6f6e6578697374656e74604482015265103a37b5b2b760d11b6064820152608401610974565b600e611e8183612fe5565b604051602001611e92929190613be9565b6040516020818303038152906040529050919050565b6000611eb6878786866130e2565b9050611ecc6001600160a01b038816828461252c565b611ee85760405162461bcd60e51b815260040161097490613fdf565b834210611f075760405162461bcd60e51b815260040161097490613e75565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491611f368361415d565b91905055506000600a5460095485611f4e91906140c0565b611f5891906140ac565b9050801561200d57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd92611f9a928e9216908790600401613cdb565b602060405180830381600087803b158015611fb457600080fd5b505af1158015611fc8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611fec9190613a49565b90508061200b5760405162461bcd60e51b815260040161097490613dec565b505b600b546000906001600160a01b03166323b872dd8a3361202d868a6140df565b6040518463ffffffff1660e01b815260040161204b93929190613cdb565b602060405180830381600087803b15801561206557600080fd5b505af1158015612079573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061209d9190613a49565b9050806120bc5760405162461bcd60e51b815260040161097490613dec565b6120c7338a8a612678565b7fc449542e187835de02e1b181e93b2267fd8592c5728e4b347834a6711b51ccb3338a8a886040516110999493929190613d32565b336121056114bc565b6001600160a01b03161461212b5760405162461bcd60e51b815260040161097490613f0b565b60148190556040518181527fbde518b8db0e4db49cacb618e2c4f716581a2d84e5f32eb877ea67604bd5e0be9060200161113d565b6010805461216d90614122565b80601f016020809104026020016040519081016040528092919081815260200182805461219990614122565b80156121e65780601f106121bb576101008083540402835291602001916121e6565b820191906000526020600020905b8154815290600101906020018083116121c957829003601f168201915b505050505081565b60075460405163c455279160e01b81526000916001600160a01b038085169291169063c455279190612224908790600401613cc7565b60206040518083038186803b15801561223c57600080fd5b505afa158015612250573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612274919061375a565b6001600160a01b0316141561228b57506001610874565b6001600160a01b0380841660009081526005602090815260408083209386168352929052205460ff165b9392505050565b336122c56114bc565b6001600160a01b0316146122eb5760405162461bcd60e51b815260040161097490613f0b565b600c80546001600160a01b0319166001600160a01b0383161790556040517fcb7ef3e545f5cdb893f5c568ba710fe08f336375a2d9fd66e161033f8fc09ef39061113d908390613cc7565b3361233f6114bc565b6001600160a01b0316146123655760405162461bcd60e51b815260040161097490613f0b565b6001600160a01b0381166123ca5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610974565b6123d381613141565b50565b601b81815481106123e657600080fd5b600091825260209091200154905081565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b0384169081179091558190612449826112a1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6001600160a01b038581166000818152600d6020908152604080832088845282528083205481517f5a3ac364254bf8141cade7fc83e6b4ac37b75f1d4df26a245ef4a174edfe2593938101939093529082019390935292871660608401526080830186905260a083019190915260c0820184905260e082018390529061252290610100015b60405160208183030381529060405280519060200120613193565b9695505050505050565b600080600061253b85856131e1565b90925090506000816004811115612554576125546141b8565b1480156125725750856001600160a01b0316826001600160a01b0316145b15612582576001925050506122b5565b600080876001600160a01b0316631626ba7e60e01b88886040516024016125aa929190613dc0565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b03199094169390931790925290516125e89190613bcd565b600060405180830381855afa9150503d8060008114612623576040519150601f19603f3d011682016040523d82523d6000602084013e612628565b606091505b509150915081801561263b575080516020145b801561266c57508051630b135d3f60e11b906126609083016020908101908401613a83565b6001600160e01b031916145b98975050505050505050565b826001600160a01b031661268b826112a1565b6001600160a01b0316146126f35760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610974565b6001600160a01b0382166127555760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610974565b612760600082612414565b6001600160a01b03831660009081526003602052604081208054600192906127899084906140df565b90915550506001600160a01b03821660009081526003602052604081208054600192906127b7908490614094565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03868116918217909255915184939187169160008051602061425483398151915291a4505050565b6001600160a01b0384166000908152600d60209081526040808320868452825280832054905161286592612507927f8cbb7530fdede89f5d16a7ee48153cff90c0b84c0b3fa0c3f178a5ddfda170b2928a928a92918a918a9101613d8f565b90505b949350505050565b600061287b826123f7565b6128dc5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610974565b60006128e7836112a1565b9050806001600160a01b0316846001600160a01b031614806129225750836001600160a01b03166129178461090c565b6001600160a01b0316145b80612868575061286881856121ee565b600080600080601560009054906101000a90046001600160a01b03166001600160a01b0316638afe79898860008151811061296f5761296f6141ce565b60200260200101516040518263ffffffff1660e01b815260040161299591815260200190565b60806040518083038186803b1580156129ad57600080fd5b505afa1580156129c1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129e59190613aed565b93509350935093506000848483604051602001612a0493929190613c90565b60408051601f198184030181529190528051602090910120601554895191925060ff8516916001600160a01b03808b16921690636352211e908c90600090612a4e57612a4e6141ce565b60200260200101516040518263ffffffff1660e01b8152600401612a7491815260200190565b60206040518083038186803b158015612a8c57600080fd5b505afa158015612aa0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ac4919061375a565b6001600160a01b031614612aea5760405162461bcd60e51b815260040161097490613ebe565b601960008a600081518110612b0157612b016141ce565b6020026020010151815260200190815260200160002054600014612b375760405162461bcd60e51b815260040161097490613f91565b86601960008b600081518110612b4f57612b4f6141ce565b60200260200101518152602001908152602001600020819055506001601860008b600081518110612b8257612b826141ce565b6020908102919091018101518252810191909152604001600020805460ff191691151591909117905560015b8951811015612e325760008a8281518110612bcb57612bcb6141ce565b60209081029190910101516015546040516331a9108f60e11b8152600481018390529192506001600160a01b038c811692911690636352211e9060240160206040518083038186803b158015612c2057600080fd5b505afa158015612c34573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c58919061375a565b6001600160a01b031614612c7e5760405162461bcd60e51b815260040161097490613ebe565b60008181526019602052604090205415612caa5760405162461bcd60e51b815260040161097490613f91565b601554604051638afe798960e01b8152600481018390526000918291829182916001600160a01b0390911690638afe79899060240160806040518083038186803b158015612cf757600080fd5b505afa158015612d0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d2f9190613aed565b9350935093509350838382604051602001612d4c93929190613c90565b604051602081830303815290604052805190602001208814612dc75760405162461bcd60e51b815260206004820152602e60248201527f5331436f6d62696e6174696f6e546f6b656e3a2077726f6e67206d617465726960448201526d616c2f656467696e672f72616e6b60901b6064820152608401610974565b612dd460ff83168861406e565b96508c601960008781526020019081526020016000208190555060016018600087815260200190815260200160002060006101000a81548160ff02191690831515021790555050505050508080612e2a9061415d565b915050612bae565b508061ffff16600f14612e875760405162461bcd60e51b815260206004820152601f60248201527f5331436f6d62696e6174696f6e546f6b656e3a2077726f6e67207375697473006044820152606401610974565b505050505050505050565b6001600160a01b038216612ee85760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610974565b612ef1816123f7565b15612f3d5760405162461bcd60e51b815260206004820152601c60248201527b115490cdcc8c4e881d1bdad95b88185b1c9958591e481b5a5b9d195960221b6044820152606401610974565b6001600160a01b0382166000908152600360205260408120805460019290612f66908490614094565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386169081179091559051839290600080516020614254833981519152908290a45050565b612fbd848484612678565b612fc984848484613251565b611b9c5760405162461bcd60e51b815260040161097490613e23565b6060816130095750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613033578061301d8161415d565b915061302c9050600a836140ac565b915061300d565b6000816001600160401b0381111561304d5761304d6141e4565b6040519080825280601f01601f191660200182016040528015613077576020820181803683370190505b5090505b84156128685761308c6001836140df565b9150613099600a86614178565b6130a4906030614094565b60f81b8183815181106130b9576130b96141ce565b60200101906001600160f81b031916908160001a9053506130db600a866140ac565b945061307b565b6001600160a01b0384166000908152600d60209081526040808320868452825280832054905161286592612507927f2feec0009bd50e41c6079eeb85f264c8fb21147d30736dbaae14aa7936f4559f928a928a92918a918a9101613d8f565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006108746131a061335b565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b6000808251604114156132185760208301516040840151606085015160001a61320c8782858561344e565b9450945050505061324a565b8251604014156132425760208301516040840151613237868383613531565b93509350505061324a565b506000905060025b9250929050565b60006001600160a01b0384163b1561335357604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290613295903390899088908890600401613cff565b602060405180830381600087803b1580156132af57600080fd5b505af19250505080156132df575060408051601f3d908101601f191682019092526132dc91810190613a83565b60015b613339573d80801561330d576040519150601f19603f3d011682016040523d82523d6000602084013e613312565b606091505b5080516133315760405162461bcd60e51b815260040161097490613e23565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612868565b506001612868565b60007f00000000000000000000000000000000000000000000000000000000000000014614156133aa57507fb05c581c81172177643ce0f59d478f695488e4c261a45651914e613940fddd5690565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527f3218f9b8902347cd3e0118596b907935959910f5ec6a5c4ea87f26092f992cfe828401527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6000806fa2a8918ca85bafe22016d0b997e4df60600160ff1b0383111561347b5750600090506003613528565b8460ff16601b1415801561349357508460ff16601c14155b156134a45750600090506004613528565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156134f8573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b03811661352157600060019250925050613528565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b016135528782888561344e565b935093505050935093915050565b82805482825590600052602060002090810192821561359b579160200282015b8281111561359b578251825591602001919060010190613580565b506135a792915061361e565b5090565b8280546135b790614122565b90600052602060002090601f0160209004810192826135d9576000855561359b565b82601f106135f257805160ff191683800117855561359b565b8280016001018555821561359b579182018281111561359b578251825591602001919060010190613580565b5b808211156135a7576000815560010161361f565b600082601f83011261364457600080fd5b813560206001600160401b0382111561365f5761365f6141e4565b8160051b61366e82820161403e565b83815282810190868401838801850189101561368957600080fd5b600093505b858410156136ac57803583526001939093019291840191840161368e565b50979650505050505050565b600082601f8301126136c957600080fd5b81356001600160401b038111156136e2576136e26141e4565b6136f5601f8201601f191660200161403e565b81815284602083860101111561370a57600080fd5b816020850160208301376000918101602001919091529392505050565b805160ff8116811461373857600080fd5b919050565b60006020828403121561374f57600080fd5b81356122b5816141fa565b60006020828403121561376c57600080fd5b81516122b5816141fa565b6000806040838503121561378a57600080fd5b8235613795816141fa565b915060208301356137a5816141fa565b809150509250929050565b6000806000606084860312156137c557600080fd5b83356137d0816141fa565b925060208401356137e0816141fa565b929592945050506040919091013590565b6000806000806080858703121561380757600080fd5b8435613812816141fa565b93506020850135613822816141fa565b92506040850135915060608501356001600160401b0381111561384457600080fd5b613850878288016136b8565b91505092959194509250565b600080600080600080600060e0888a03121561387757600080fd5b8735613882816141fa565b96506020880135613892816141fa565b955060408801359450606088013593506080880135925060a0880135915060c08801356001600160401b038111156138c957600080fd5b6138d58a828b016136b8565b91505092959891949750929550565b600080604083850312156138f757600080fd5b8235613902816141fa565b915060208301356137a58161420f565b6000806040838503121561392557600080fd5b8235613930816141fa565b946020939093013593505050565b60008060008060008060c0878903121561395757600080fd5b8635613962816141fa565b95506020870135945060408701359350606087013592506080870135915060a08701356001600160401b0381111561399957600080fd5b6139a589828a016136b8565b9150509295509295509295565b6000602082840312156139c457600080fd5b81356001600160401b038111156139da57600080fd5b61286884828501613633565b600080604083850312156139f957600080fd5b82356001600160401b0380821115613a1057600080fd5b613a1c86838701613633565b93506020850135915080821115613a3257600080fd5b50613a3f858286016136b8565b9150509250929050565b600060208284031215613a5b57600080fd5b81516122b58161420f565b600060208284031215613a7857600080fd5b81356122b58161421d565b600060208284031215613a9557600080fd5b81516122b58161421d565b600060208284031215613ab257600080fd5b81356001600160401b03811115613ac857600080fd5b612868848285016136b8565b600060208284031215613ae657600080fd5b5035919050565b60008060008060808587031215613b0357600080fd5b613b0c85613727565b9350613b1a60208601613727565b9250613b2860408601613727565b9150606085015161ffff81168114613b3f57600080fd5b939692955090935050565b600081518084526020808501945080840160005b83811015613b7a57815187529582019590820190600101613b5e565b509495945050505050565b60008151808452613b9d8160208601602086016140f6565b601f01601f19169290920160200192915050565b60008151613bc38185602086016140f6565b9290920192915050565b60008251613bdf8184602087016140f6565b9190910192915050565b600080845481600182811c915080831680613c0557607f831692505b6020808410821415613c2557634e487b7160e01b86526022600452602486fd5b818015613c395760018114613c4a57613c77565b60ff19861689528489019650613c77565b60008b81526020902060005b86811015613c6f5781548b820152908501908301613c56565b505084890196505b505050505050613c878185613bb1565b95945050505050565b60f893841b6001600160f81b031990811682529290931b909116600183015260f01b6001600160f01b031916600282015260040190565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061252290830184613b85565b6001600160a01b0394851681529290931660208301526040820152606081019190915260800190565b6001600160a01b039390931683526020830191909152604082015260600190565b6020815260006122b56020830184613b4a565b9586526001600160a01b0394909416602086015260408501929092526060840152608083015260a082015260c00190565b8281526040602082015260006128686040830184613b85565b6020815260006122b56020830184613b85565b6020808252601e908201527f45524337323142757961626c653a207472616e73666572206661696c65640000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526029908201527f45524337323142757961626c653a207369676e6564207472616e73616374696f6040820152681b88195e1c1a5c995960ba1b606082015260800190565b6020808252602d908201527f5331436f6d62696e6174696f6e546f6b656e3a20796f7520617265206e6f742060408201526c30903a37b5b2b71037bbb732b960991b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252602e908201527f5331436f6d62696e6174696f6e546f6b656e3a20706172656e7420616c72656160408201526d191e481a185cc8184818da1a5b1960921b606082015260800190565b6020808252818101527f45524337323142757961626c653a20496e76616c6964207369676e6174757265604082015260600190565b8381526001600160a01b038316602082015260606040820181905260009061286590830184613b4a565b604051601f8201601f191681016001600160401b0381118282101715614066576140666141e4565b604052919050565b600061ffff80831681851680830382111561408b5761408b61418c565b01949350505050565b600082198211156140a7576140a761418c565b500190565b6000826140bb576140bb6141a2565b500490565b60008160001904831182151516156140da576140da61418c565b500290565b6000828210156140f1576140f161418c565b500390565b60005b838110156141115781810151838201526020016140f9565b83811115611b9c5750506000910152565b600181811c9082168061413657607f821691505b6020821081141561415757634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156141715761417161418c565b5060010190565b600082614187576141876141a2565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146123d357600080fd5b80151581146123d357600080fd5b6001600160e01b0319811681146123d357600080fdfecf0aa54119192462151ebf099a8743ac47b6485ce4965abf5b329683220eb548ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa26469706673582212202bb4ce836aa89b9dcc218847a3ab48660942ae0c37dee3f7e500ccfdfb78566264736f6c63430008060033

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

000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c100000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000f794f9e028d168a59341aaf77fc8f57f33ddc6cf000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2000000000000000000000000000000000000000000000000000000000000000f45766f20504320536561736f6e20310000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000745564f5043533100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002868747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f636f6d62696e66742f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000045697066733a2f2f45564f504353313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131312f000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _proxyRegistry (address): 0xa5409ec958C83C3f309868babACA7c86DCB077c1
Arg [1] : _name (string): Evo PC Season 1
Arg [2] : _symbol (string): EVOPCS1
Arg [3] : _baseURI (string): https://evopc.trophyhunters.io/combinft/
Arg [4] : _contractURI (string): ipfs://EVOPCS1111111111111111111111111111111111111111111111111111111/
Arg [5] : _parent (address): 0xF794f9E028D168A59341AAF77FC8F57f33DdC6CF
Arg [6] : _paymentToken (address): 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2

-----Encoded View---------------
18 Constructor Arguments found :
Arg [0] : 000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000e0
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000160
Arg [4] : 00000000000000000000000000000000000000000000000000000000000001c0
Arg [5] : 000000000000000000000000f794f9e028d168a59341aaf77fc8f57f33ddc6cf
Arg [6] : 000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Arg [7] : 000000000000000000000000000000000000000000000000000000000000000f
Arg [8] : 45766f20504320536561736f6e20310000000000000000000000000000000000
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000007
Arg [10] : 45564f5043533100000000000000000000000000000000000000000000000000
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000028
Arg [12] : 68747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f63
Arg [13] : 6f6d62696e66742f000000000000000000000000000000000000000000000000
Arg [14] : 0000000000000000000000000000000000000000000000000000000000000045
Arg [15] : 697066733a2f2f45564f50435331313131313131313131313131313131313131
Arg [16] : 3131313131313131313131313131313131313131313131313131313131313131
Arg [17] : 313131312f000000000000000000000000000000000000000000000000000000


Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.