ETH Price: $2,683.61 (+0.56%)

Token

Evolution Playing Cards (EVOPC)
 

Overview

Max Total Supply

2,222 EVOPC

Holders

655

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
4 EVOPC
0x4e1ef4b6be0fc254db204ebddb2114da0ce24505
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:
BaseToken

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 1 runs

Other Settings:
default evmVersion
File 1 of 29 : BaseToken.sol
pragma solidity ^0.8.6;

import "./interfaces/IMembershipToken.sol";
import "./interfaces/IBaseToken.sol";
import "./interfaces/ICombinationToken.sol";
import "./library/CombinableTokenBasis.sol";

contract BaseToken is IBaseToken, CombinableTokenBasis {
    //    using EC
    // <DATA STRUCTS>

    /** @notice A structure to store main token properties used to mint Combination NFT */
    struct BaseTokenMainTraits {
        /** Material values
            | 1 = Classic | 8 = Titan        |
            | 2 = Gold    | 16 = Unicellular  |
            | 4 = Renim   | 32 = Veganleather |
        */
        uint8 Material;

        /** Edging values
            | 1 = Classic | 8 = Ornament  |
            | 2 = DNA     | 16 = Shabby    |
            | 4 = French  | 32 = Textline  |
        */
        uint8 Edging;

        /** Suit values
            | 1 = Clubs    | 4 = Hearts |
            | 2 = Diamonds | 8 = Spades |
        */
        uint8 Suit;

        /** Rank values
            | 1 = A  | 32 = 6   | 1024 = J |
            | 2 = 2  | 64 = 7   | 2048 = Q |
            | 4 = 3  | 128 = 8  | 4096 = K |
            | 8 = 4  | 256 = 9  |          |
            | 16 = 5 | 512 = 10 |          |
        */
        uint16 Rank;
    }
    // < /DATA STRUCTS>

    // <VARIABLES>
    // Base NFT price in Ether during main sale
    uint256 public constant price = 0.09 ether;
    // Base NFT price in Ether during presale
    uint256 public constant presalePrice = 0.055 ether;
    // Contract address where Reward Fund is accumulated during main sale
    address public rewardPool;
    // Part of Base token price to send to Reward Fund during main sale
    uint256 public rewardShare = 0.035 ether;
    // Part of Base token price to send to Reward Fund during presale
    uint256 public rewardSharePresale = 0.035 ether;
    // Max total supply and last token ID
    uint256 public maxTotalSupply = 5_715;
    // Max presale total supply and last token ID
    uint256 public maxPresaleTotalSupply = 3_000;

    bool public isInitialized;

    // Membership token contract
    IMembershipToken public membershipToken;

    // An array where are stored main traits for each Base token
    BaseTokenMainTraits[] internal baseTokenMainTraits_;

    uint256 internal randomNonce_;

    /** Timing variables */
    // A variable to store a timestamp when public sale will become available
    uint256 public saleStartTime;
    // Time when presale starts
    uint256 public presaleStartTime;
    // Time when presale ends
    uint256 public presaleEndTime;

    uint256 public constant presaleTokensAmountPerAddress = 4;
    mapping(address => uint256) public presaleTokensAmountByAddress;

    mapping(address => bool) internal _membershipMintPass;
    // </ VARIABLES >

    // <EVENTS>
    event PublicSaleMint(address to, uint256 tokenId, uint8 material, uint8 edging, uint8 suit, uint16 rank);
    event PresaleMint(address to, uint256 tokenId, uint8 material, uint8 edging, uint8 suit, uint16 rank);

    // restricted events
    event Initialize(address membershipToken, address childAddress);

    event SetSaleStartTime(uint256 timestamp);
    event SetPresaleStartTime(uint256 timestamp);
    event SetPresaleEndTime(uint256 timestamp);

    event SetMaxTotalSupply(uint256 newMaxTotalSupply);
    event SetMaxPresaleTotalSupply(uint256 newMaxPresaleTotalSupply);
    event SoldOut();
    // </ 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 - base token name (cannot be changed after)
        @param _symbol - base token symbol (cannot be changed after)
        @param _baseURI - base token address where NFT images are stored
        @param _contractURI - base token contract metadata URI
        @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 _paymentToken
    )
    CombinableTokenBasis(
        _proxyRegistry,
        _name,
        _symbol,
        _baseURI,
        _contractURI,
        _paymentToken
    )
    {
    }

    // <INTERNAL FUNCTIONS TO GET CONSTANTS INTERNALLY>

    /**
        @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 _maxPresaleTotalSupply() internal view virtual returns (uint256) {
        return maxPresaleTotalSupply;
    }

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

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

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

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

    function _presaleTokensAmountPerAddress() internal view virtual returns (uint256) {
        return presaleTokensAmountPerAddress;
    }

    /**
        @notice A function to initialize contract and set Membership and Combination token addresses
        @dev Called only once, an attempt to call it repeatedly will be rejected
        @param _membershipToken - Membership token address
        @param _childAddress - Combination token address
    */
    function initialize(address _membershipToken, address _childAddress)
    external
    override
    onlyOwner
    {
        require(!isInitialized, "BaseToken: contract is already initialized!");
        membershipToken = IMembershipToken(_membershipToken);
        child_ = ICombinationToken(_childAddress);
        rewardPool = _childAddress;
        isInitialized = true;

        emit Initialize(_membershipToken, _childAddress);
    }

    // <PUBLIC FUNCTIONS>
    /**
        @notice A function to buy (mint) base tokens
        @param _to - recipient address (usually the same as the address of transaction sender)
        @param _amount - amount of tokens to mint
    */
    function publicSaleMint(
        address _to,
        uint256 _amount
    ) external payable override {
        require(
            msg.value == _price() * _amount,
            "BaseToken: tx value is too small"
        );
        address _txSender = msg.sender;
        uint256 _blockTimestamp = block.timestamp;

        require(
            !_isContract(_txSender),
            "BaseToken: you have to be a person to call this function"
        );
        if (lastTokenId_ < _maxPresaleTotalSupply()) {
            require(
                _blockTimestamp > saleStartTime && saleStartTime != 0,
                "BaseToken: Main sale hasn't started yet"
            );
        }
        require(
            lastTokenId_ + _amount <= _maxTotalSupply(),
            "BaseToken: Cannot mint more tokens than the maxTotalSupply"
        );

        _membershipMintPass[_txSender] = true;
        require(_amount <= 13, "BaseToken: Cannot buy more tokens than 13");

        payable(rewardPool).transfer(_amount * _rewardShare());
        _mintTokens(_to, _amount, false);
    }

    /**
        @notice A function to buy (mint) base tokens during presale period
        @param _to - recipient address (usually the same as the address of transaction sender)
        @param _amount - amount of tokens to mint
    */
    function presaleMint(
        address _to,
        uint256 _amount
    ) external payable override {
        address _txSender = msg.sender;
        uint256 _blockTimestamp = block.timestamp;

        require(
            msg.value == _presalePrice() * _amount,
            "BaseToken: tx value is too small"
        );

        require(
            !_isContract(_txSender),
            "BaseToken: you have to be a person to call this function"
        );
        require(
            (presaleStartTime < _blockTimestamp &&
        _blockTimestamp < presaleEndTime),
            "BaseToken: Presale is not active"
        );
        require(
            presaleTokensAmountByAddress[_txSender] + _amount <=
            _presaleTokensAmountPerAddress(),
            "BaseToken: Amount of tokens exceeds presale limits"
        );
        presaleTokensAmountByAddress[_txSender] =
        presaleTokensAmountByAddress[_txSender] +
        _amount;
        require(
            lastTokenId_ + _amount <= _maxPresaleTotalSupply(),
            "BaseToken: Cannot mint more tokens than the maxPresaleTotalSupply"
        );

        _membershipMintPass[_txSender] = true;

        payable(rewardPool).transfer(_amount * _rewardSharePresale());
        _mintTokens(_to, _amount, true);
    }

    /**
        @dev A simple getter for Base token main traits
    */
    function baseTokenMainTraits(uint256 _tokenId) external view override returns (uint8, uint8, uint8, uint16){
        uint256 _index = _tokenId - 1;
        return (baseTokenMainTraits_[_index].Material,
        baseTokenMainTraits_[_index].Edging,
        baseTokenMainTraits_[_index].Suit,
        baseTokenMainTraits_[_index].Rank);
    }

    function membershipMintPass(address _minter) external view override returns (bool) {
        return _membershipMintPass[_minter];
    }
    // </ PUBLIC FUNCTIONS>

    // <PRIVATE FUNCTIONS>
    /**
        @notice Internal function called by _mintTokens to generate token main properties
        @dev For random generation of main properties, function uses data from two sources:
             - from the blockchain (block.timestamp, block.difficulty, block.number)
             - from the smart contract (randomNonce_)
        @dev Function randomly generates Material, Edging, Suit, Rank and writes them to
             baseTokenMainTraits_ array to store on-chain (these properties can never be changed)
        @param _tokenId - Id of newly minted token
    */
    function _generateBaseTokenMainTraits(
        uint256 _tokenId
    ) internal returns (uint8, uint8, uint8, uint16){
        uint256 _blockTimestamp = block.timestamp;
        uint256 _blockDifficulty = block.difficulty;
        uint256 _blockNumber = block.number;
        BaseTokenMainTraits memory _baseTokenMainTraits = BaseTokenMainTraits(0, 0, 0, 0);

        // random nonce increased
        randomNonce_ += (_tokenId > 1)
        ? baseTokenMainTraits_[_tokenId - 2].Rank
        : _blockTimestamp;

        _baseTokenMainTraits.Material = uint8(
            2 **
            (uint256(
                keccak256(
                    abi.encodePacked(
                        _blockNumber,
                        _blockTimestamp,
                        _blockDifficulty,
                        msg.sender,
                        randomNonce_
                    )
                )
            ) % 6)
        );

        // random nonce increased
        randomNonce_ += (_tokenId > 1)
        ? baseTokenMainTraits_[_tokenId - 2].Suit
        : _blockTimestamp;

        _baseTokenMainTraits.Edging = uint8(
            2 **
            (uint256(
                keccak256(
                    abi.encodePacked(
                        _blockNumber,
                        _blockTimestamp,
                        _blockDifficulty,
                        msg.sender,
                        randomNonce_
                    )
                )
            ) % 6)
        );

        // random nonce increased
        randomNonce_ += (_tokenId > 1)
        ? baseTokenMainTraits_[_tokenId - 2].Material
        : _blockTimestamp;

        _baseTokenMainTraits.Suit = uint8(
            2 **
            (uint256(
                keccak256(
                    abi.encodePacked(
                        _blockNumber,
                        _blockTimestamp,
                        _blockDifficulty,
                        msg.sender,
                        randomNonce_
                    )
                )
            ) % 4)
        );

        // random nonce increased
        randomNonce_ += (_tokenId > 1)
        ? baseTokenMainTraits_[_tokenId - 2].Edging
        : _blockTimestamp;

        _baseTokenMainTraits.Rank = uint16(
            2 **
            (uint256(
                keccak256(
                    abi.encodePacked(
                        _blockNumber,
                        _blockTimestamp,
                        _blockDifficulty,
                        msg.sender,
                        randomNonce_
                    )
                )
            ) % 13)
        );

        baseTokenMainTraits_.push(_baseTokenMainTraits);

        return (_baseTokenMainTraits.Material, _baseTokenMainTraits.Edging, _baseTokenMainTraits.Suit, _baseTokenMainTraits.Rank);
    }

    /**
        @notice Internal function called by publicSaleMint/presaleMint to mint tokens
        @dev Function calls _generateBaseTokenMainTraits to generate Base token main traits
        @param _to - recipient address (usually the same as the address of transaction sender)
        @param _amount - amount of tokens to mint
    */
    function _mintTokens(
        address _to,
        uint256 _amount,
        bool _isPresale
    ) private {
        uint256 _newLastTokenId = lastTokenId_ + _amount;
        uint256 _blockTimestamp = block.timestamp;

        for (
            uint256 _tokenId = lastTokenId_ + 1;
            _tokenId <= _newLastTokenId;
            _tokenId++
        ) {
            _mint(_to, _tokenId);
            (uint8 _material, uint8 _edging, uint8 _suit, uint16 _rank) = _generateBaseTokenMainTraits(_tokenId);
            if (_isPresale) {
                emit PresaleMint(_to, _tokenId, _material, _edging, _suit, _rank);
            } else {
                emit PublicSaleMint(_to, _tokenId, _material, _edging, _suit, _rank);
            }
        }
        lastTokenId_ += _amount;
        if (lastTokenId_ == _maxTotalSupply()) {
            soldOut_ = true;

            emit SoldOut();
        }
    }
    // </ PRIVATE FUNCTIONS />

    // <RESTRICTED ACCESS METHODS>
    /**
        @notice Sale start time setter function
        @dev Available for owner only
        @dev Impossible to set new time if current sale start time is up
        @param _saleStartTime - new sale start time
    */
    function setSaleStartTime(uint256 _saleStartTime)
    external
    override
    virtual
    onlyOwner
    {
        require(_saleStartTime > block.timestamp, "BaseToken: new sale start time should be in future");
        require(saleStartTime == 0 || saleStartTime > block.timestamp, "BaseToken: sale shouldn't be started");

        saleStartTime = _saleStartTime;

        emit SetSaleStartTime(_saleStartTime);
    }


    function setPresaleTime(uint256 _presaleStartTime, uint256 _presaleEndTime)
    external
    override
    virtual
    onlyOwner
    {
        require(_presaleStartTime > 0 &&
            _presaleStartTime > block.timestamp,
            "BaseToken: Invalid presale start time");
        require(_presaleStartTime < _presaleEndTime,
            "BaseToken: presale_start_time > presale_end_time");
        require(_presaleEndTime < saleStartTime,
            "BaseToken: presale_end_time > sale_start_time");

        presaleStartTime = _presaleStartTime;
        presaleEndTime = _presaleEndTime;

        emit SetPresaleStartTime(_presaleStartTime);
        emit SetPresaleEndTime(_presaleEndTime);
    }

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

        emit SetMaxTotalSupply(_newMaxTotalSupply);
    }

    function setMaxPresaleTotalSupply(uint256 _newMaxPresaleTotalSupply) external virtual onlyOwner {
        maxPresaleTotalSupply = _newMaxPresaleTotalSupply;

        emit SetMaxPresaleTotalSupply(_newMaxPresaleTotalSupply);
    }

    /**
        @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 {}
    // </ RESTRICTED ACCESS FUNCTIONS>
}

File 2 of 29 : IMembershipToken.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.6;

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

interface IMembershipToken is IERC721{
    function initialize(address _baseTokenAddress)
        external;

    function mint() external;

    function setContractURI(string memory _contractURI) external;

    function setBaseURI(string memory _baseUri) external;
}

File 3 of 29 : 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 29 : 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 29 : CombinableTokenBasis.sol
pragma solidity ^0.8.6;

import "../interfaces/ICombinableTokenBasis.sol";
import "../interfaces/ICombinationToken.sol";
import "./Basis.sol";
import "./Withdrawable.sol";

contract CombinableTokenBasis is ICombinableTokenBasis, Basis, Withdrawable {
    ICombinationToken internal child_;
    bool public transferProhibitedForCombined;
    bool public transferProhibited;
    bool internal soldOut_;

    event SetChildAddress(address child);
    event SetTransferProhibitedForCombined(bool prohibited);
    event SetTransferProhibited(bool prohibited);

    constructor(
        address _proxyRegistry,
        string memory _name,
        string memory _symbol,
        string memory _baseURI,
        string memory _contractURI,
        address _paymentToken
    )
    Basis(
        _proxyRegistry,
        _name,
        _symbol,
        _baseURI,
        _contractURI,
        _paymentToken
    )
    {
    }

    function soldOut() external view override returns (bool){
        return soldOut_;
    }

    function child() external view override returns (ICombinationToken) {
        return child_;
    }

    function setChildAddress(address _child) external override onlyOwner {
        child_ = ICombinationToken(_child);

        emit SetChildAddress(_child);
    }

    function setTransferProhibitedForCombined(bool _prohibited) external override onlyOwner {
        transferProhibitedForCombined = _prohibited;

        emit SetTransferProhibitedForCombined(_prohibited);
    }

    function setTransferProhibited(bool _prohibited) external override onlyOwner {
        transferProhibited = _prohibited;

        emit SetTransferProhibited(_prohibited);
    }

    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        if (transferProhibited || (transferProhibitedForCombined && child_.baseIsCombined(tokenId))) {
            require(
                from == address(0),
                "CombinableTokenBasis: Sorry, it is prohibited to transfer Base tokens"
            );
        }
    }
}

File 6 of 29 : 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 7 of 29 : IERC165.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

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

File 8 of 29 : 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 9 of 29 : 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 10 of 29 : 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 11 of 29 : 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 12 of 29 : 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 13 of 29 : 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 14 of 29 : 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 15 of 29 : 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 16 of 29 : 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 17 of 29 : 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 18 of 29 : 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 19 of 29 : 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 20 of 29 : 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 21 of 29 : 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 22 of 29 : 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 23 of 29 : 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 24 of 29 : 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 25 of 29 : 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 26 of 29 : 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 27 of 29 : 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 28 of 29 : 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 29 of 29 : 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":"_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":[{"indexed":false,"internalType":"address","name":"membershipToken","type":"address"},{"indexed":false,"internalType":"address","name":"childAddress","type":"address"}],"name":"Initialize","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":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint8","name":"material","type":"uint8"},{"indexed":false,"internalType":"uint8","name":"edging","type":"uint8"},{"indexed":false,"internalType":"uint8","name":"suit","type":"uint8"},{"indexed":false,"internalType":"uint16","name":"rank","type":"uint16"}],"name":"PresaleMint","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"uint8","name":"material","type":"uint8"},{"indexed":false,"internalType":"uint8","name":"edging","type":"uint8"},{"indexed":false,"internalType":"uint8","name":"suit","type":"uint8"},{"indexed":false,"internalType":"uint16","name":"rank","type":"uint16"}],"name":"PublicSaleMint","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":"address","name":"child","type":"address"}],"name":"SetChildAddress","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":"newMaxPresaleTotalSupply","type":"uint256"}],"name":"SetMaxPresaleTotalSupply","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":"timestamp","type":"uint256"}],"name":"SetPresaleEndTime","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"SetPresaleStartTime","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"SetSaleStartTime","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"tax","type":"uint256"}],"name":"SetSaleTax","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"prohibited","type":"bool"}],"name":"SetTransferProhibited","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"prohibited","type":"bool"}],"name":"SetTransferProhibitedForCombined","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"treasury","type":"address"}],"name":"SetTreasury","type":"event"},{"anonymous":false,"inputs":[],"name":"SoldOut","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"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"anonymous":false,"inputs":[],"name":"WithdrawAll","type":"event"},{"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":"_tokenId","type":"uint256"}],"name":"baseTokenMainTraits","outputs":[{"internalType":"uint8","name":"","type":"uint8"},{"internalType":"uint8","name":"","type":"uint8"},{"internalType":"uint8","name":"","type":"uint8"},{"internalType":"uint16","name":"","type":"uint16"}],"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":[],"name":"child","outputs":[{"internalType":"contract ICombinationToken","name":"","type":"address"}],"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":"address","name":"_membershipToken","type":"address"},{"internalType":"address","name":"_childAddress","type":"address"}],"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":"maxPresaleTotalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxTotalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_minter","type":"address"}],"name":"membershipMintPass","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"membershipToken","outputs":[{"internalType":"contract IMembershipToken","name":"","type":"address"}],"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":[],"name":"paymentToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pendingWithdrawal","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleEndTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"presaleMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"presalePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"presaleTokensAmountByAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleTokensAmountPerAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"price","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"publicSaleMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"rewardPool","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardShare","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"rewardSharePresale","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":"saleStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":"address","name":"_child","type":"address"}],"name":"setChildAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_contractURI","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxPresaleTotalSupply","type":"uint256"}],"name":"setMaxPresaleTotalSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxTotalSupply","type":"uint256"}],"name":"setMaxTotalSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_presaleStartTime","type":"uint256"},{"internalType":"uint256","name":"_presaleEndTime","type":"uint256"}],"name":"setPresaleTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_saleStartTime","type":"uint256"}],"name":"setSaleStartTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tax","type":"uint256"}],"name":"setSaleTax","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_prohibited","type":"bool"}],"name":"setTransferProhibited","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_prohibited","type":"bool"}],"name":"setTransferProhibitedForCombined","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_treasury","type":"address"}],"name":"setTreasury","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"soldOut","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"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":"transferProhibited","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"transferProhibitedForCombined","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"treasury","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawAll","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101206040526103e8600955612710600a55667c585087238000601355667c585087238000601455611653601555610bb86016553480156200004057600080fd5b5060405162004ca938038062004ca98339810160408190526200006391620003f4565b60408051808201825260058152640312e302e360dc1b602080830191909152875188820190812060c08181527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60e08190524660a081815288517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818901819052818b01969096526060810193909352608080840192909252308382015288518084039091018152919092019096528551959093019490942090915261010092909252865188928892889288928892889288928892889288928892889283928892918391899162000157916000916200027a565b5080516200016d9060019060208401906200027a565b5050506200018a620001846200022460201b60201c565b62000228565b50506001600855600c8054336001600160a01b031991821617909155600b80549091166001600160a01b03929092169190911790558251620001d490600e9060208601906200027a565b508151620001ea9060109060208501906200027a565b5050600780546001600160a01b0319166001600160a01b03969096169590951790945550620005259e505050505050505050505050505050565b3390565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200028890620004d2565b90600052602060002090601f016020900481019282620002ac5760008555620002f7565b82601f10620002c757805160ff1916838001178555620002f7565b82800160010185558215620002f7579182015b82811115620002f7578251825591602001919060010190620002da565b506200030592915062000309565b5090565b5b808211156200030557600081556001016200030a565b80516001600160a01b03811681146200033857600080fd5b919050565b600082601f8301126200034f57600080fd5b81516001600160401b03808211156200036c576200036c6200050f565b604051601f8301601f19908116603f011681019082821181831017156200039757620003976200050f565b81604052838152602092508683858801011115620003b457600080fd5b600091505b83821015620003d85785820183015181830184015290820190620003b9565b83821115620003ea5760008385830101525b9695505050505050565b60008060008060008060c087890312156200040e57600080fd5b620004198762000320565b60208801519096506001600160401b03808211156200043757600080fd5b620004458a838b016200033d565b965060408901519150808211156200045c57600080fd5b6200046a8a838b016200033d565b955060608901519150808211156200048157600080fd5b6200048f8a838b016200033d565b94506080890151915080821115620004a657600080fd5b50620004b589828a016200033d565b925050620004c660a0880162000320565b90509295509295509295565b600181811c90821680620004e757607f821691505b602082108114156200050957634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052604160045260246000fd5b60805160a05160c05160e0516101005161473f6200056a6000396000613972015260006139c10152600061399c0152600061392001526000613949015261473f6000f3fe6080604052600436106102c75760003560e01c80620e7fa8146102cc57806301ffc9a7146102fa57806306fdde031461032a578063081812fc1461034c578063095ea7b314610379578063097bf9c81461039b5780630c166a61146103ae57806310ac1ee2146103ce57806318160ddd146103e45780631cbaee2d146103f95780631db09ddc1461040f578063220d36d81461043c578063237b5e961461045c57806323b872dd1461047a578063249b7c191461049a5780632ab4d052146104b05780632e1a7d4d146104c65780633013ce29146104e6578063392e53cd146105065780633aefab86146105205780633c322798146105405780633cad99ce146105565780633f3e4c111461056c57806342842e0e1461058c578063485cc955146105ac578063502e1a16146105cc578063525f8a5c1461060457806355f804b3146106245780635c40329e146106445780635e3f0e6c146106645780636197a4d21461067957806361d027b31461069957806362ad351b146106b957806362f837ef146106de5780636352211e146106f457806366666aa91461071457806370a0823114610734578063715018a6146107545780637c90d65b146107695780637e2888221461078a578063819d19551461079d578063853828b6146107d65780638639b4bb146107eb578063893da6c9146108015780638afe7989146108205780638da5cb5b1461086e57806392ebd23614610883578063938e3d7b146108a357806395d89b41146108c35780639b6a6709146108d8578063a035b1fe146108eb578063a22cb46514610907578063a82524b214610927578063ac5ae11b1461093d578063b88d4fde14610950578063bed1d46d14610970578063c87b56dd14610991578063d1af5df4146109b1578063d85beb85146109d1578063e8a3d485146109f1578063e985e9c514610a06578063f0f4426014610a26578063f2fde38b14610a46575b600080fd5b3480156102d857600080fd5b506102e766c3663566a5800081565b6040519081526020015b60405180910390f35b34801561030657600080fd5b5061031a610315366004613ee1565b610a66565b60405190151581526020016102f1565b34801561033657600080fd5b5061033f610ab8565b6040516102f19190614212565b34801561035857600080fd5b5061036c610367366004613f80565b610b4a565b6040516102f191906140f7565b34801561038557600080fd5b50610399610394366004613e07565b610bd7565b005b6103996103a9366004613d51565b610ce8565b3480156103ba57600080fd5b506103996103c9366004613c4f565b610f7b565b3480156103da57600080fd5b506102e760145481565b3480156103f057600080fd5b50600f546102e7565b34801561040557600080fd5b506102e7601a5481565b34801561041b57600080fd5b506102e761042a366004613c4f565b601d6020526000908152604090205481565b34801561044857600080fd5b50610399610457366004613e33565b611000565b34801561046857600080fd5b506011546001600160a01b031661036c565b34801561048657600080fd5b50610399610495366004613ca5565b61125e565b3480156104a657600080fd5b506102e7601c5481565b3480156104bc57600080fd5b506102e760155481565b3480156104d257600080fd5b506103996104e1366004613f80565b61128f565b3480156104f257600080fd5b50600b5461036c906001600160a01b031681565b34801561051257600080fd5b5060175461031a9060ff1681565b34801561052c57600080fd5b5061039961053b366004613ea7565b6112f7565b34801561054c57600080fd5b506102e760135481565b34801561056257600080fd5b506102e7600a5481565b34801561057857600080fd5b50610399610587366004613f80565b611373565b34801561059857600080fd5b506103996105a7366004613ca5565b6113d7565b3480156105b857600080fd5b506103996105c7366004613c6c565b6113f2565b3480156105d857600080fd5b506102e76105e7366004613e07565b600d60209081526000928352604080842090915290825290205481565b34801561061057600080fd5b5061039961061f366004613f80565b611518565b34801561063057600080fd5b5061039961063f366004613f38565b61164e565b34801561065057600080fd5b5061039961065f366004613f99565b6116c0565b34801561067057600080fd5b506102e7600481565b34801561068557600080fd5b50610399610694366004613f80565b611894565b3480156106a557600080fd5b50600c5461036c906001600160a01b031681565b3480156106c557600080fd5b5060175461036c9061010090046001600160a01b031681565b3480156106ea57600080fd5b506102e760095481565b34801561070057600080fd5b5061036c61070f366004613f80565b611960565b34801561072057600080fd5b5060125461036c906001600160a01b031681565b34801561074057600080fd5b506102e761074f366004613c4f565b6119d7565b34801561076057600080fd5b50610399611a5e565b34801561077557600080fd5b5060115461031a90600160a81b900460ff1681565b34801561079657600080fd5b50476102e7565b3480156107a957600080fd5b5061031a6107b8366004613c4f565b6001600160a01b03166000908152601e602052604090205460ff1690565b3480156107e257600080fd5b50610399611a8f565b3480156107f757600080fd5b506102e760165481565b34801561080d57600080fd5b50601154600160b01b900460ff1661031a565b34801561082c57600080fd5b5061084061083b366004613f80565b611af2565b6040805160ff95861681529385166020850152919093169082015261ffff90911660608201526080016102f1565b34801561087a57600080fd5b5061036c611bc1565b34801561088f57600080fd5b5061039961089e366004613ea7565b611bd0565b3480156108af57600080fd5b506103996108be366004613f38565b611c4c565b3480156108cf57600080fd5b5061033f611cbe565b6103996108e6366004613e07565b611ccd565b3480156108f757600080fd5b506102e767013fbe85edc9000081565b34801561091357600080fd5b50610399610922366004613dd9565b611f43565b34801561093357600080fd5b506102e7601b5481565b61039961094b366004613e07565b612004565b34801561095c57600080fd5b5061039961096b366004613ce6565b612222565b34801561097c57600080fd5b5060115461031a90600160a01b900460ff1681565b34801561099d57600080fd5b5061033f6109ac366004613f80565b612254565b3480156109bd57600080fd5b506103996109cc366004613e33565b6122ec565b3480156109dd57600080fd5b506103996109ec366004613f80565b612540565b3480156109fd57600080fd5b5061033f6125a4565b348015610a1257600080fd5b5061031a610a21366004613c6c565b612632565b348015610a3257600080fd5b50610399610a41366004613c4f565b612700565b348015610a5257600080fd5b50610399610a61366004613c4f565b61277a565b60006001600160e01b031982166380ac58cd60e01b1480610a9757506001600160e01b03198216635b5e139f60e01b145b80610ab257506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060008054610ac7906145b8565b80601f0160208091040260200160405190810160405280929190818152602001828054610af3906145b8565b8015610b405780601f10610b1557610100808354040283529160200191610b40565b820191906000526020600020905b815481529060010190602001808311610b2357829003601f168201915b5050505050905090565b6000610b558261281a565b610bbb5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6000610be282611960565b9050806001600160a01b0316836001600160a01b03161415610c505760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610bb2565b336001600160a01b0382161480610c6c5750610c6c8133612632565b610cd95760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f776044820152771b995c881b9bdc88185c1c1c9bdd995908199bdc88185b1b60421b6064820152608401610bb2565b610ce38383612837565b505050565b60026008541415610d3b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610bb2565b60026008556000610d4f88888887876128a5565b9050348314610db45760405162461bcd60e51b815260206004820152602b60248201527f45524337323142757961626c653a204e6f7420656e6f7567687420455448207460448201526a3790313abc903a37b5b2b760a91b6064820152608401610bb2565b610dbf88828461294f565b610ddb5760405162461bcd60e51b8152600401610bb2906143d5565b834210610e3c5760405162461bcd60e51b815260206004820152602960248201527f45524337323142757961626c653a205369676e6564207472616e73616374696f6044820152681b88195e1c1a5c995960ba1b6064820152608401610bb2565b6001600160a01b0388166000908152600d602090815260408083208984529091528120805491610e6b836145f3565b90915550506001600160a01b038716610e82573396505b6000600a5460095485610e959190614556565b610e9f9190614457565b90508015610ee357600c546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015610ee1573d6000803e3d6000fd5b505b6001600160a01b0389166108fc610efa8387614575565b6040518115909202916000818181858888f19350505050158015610f22573d6000803e3d6000fd5b50610f2e898989612a9b565b7f0919dd2bf769d97497dac32ec38d1620dba154dc7d4374848a2293a0c1ce867d89898987604051610f639493929190614162565b60405180910390a15050600160085550505050505050565b33610f84611bc1565b6001600160a01b031614610faa5760405162461bcd60e51b8152600401610bb29061434f565b601180546001600160a01b0319166001600160a01b0383161790556040517fd5b496569a6ad0a6c044608a3d8b08eee668e7a35c963a164b8ef376b004916690610ff59083906140f7565b60405180910390a150565b600061100e87878686612c34565b905061101b87828461294f565b6110375760405162461bcd60e51b8152600401610bb2906143d5565b8342106110565760405162461bcd60e51b8152600401610bb290614306565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491611085836145f3565b91905055506000600a546009548561109d9190614556565b6110a79190614457565b9050801561115c57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd926110e99233921690879060040161410b565b602060405180830381600087803b15801561110357600080fd5b505af1158015611117573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061113b9190613ec4565b90508061115a5760405162461bcd60e51b8152600401610bb290614225565b505b600b546000906001600160a01b03166323b872dd338b61117c868a614575565b6040518463ffffffff1660e01b815260040161119a9392919061410b565b602060405180830381600087803b1580156111b457600080fd5b505af11580156111c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111ec9190613ec4565b90508061120b5760405162461bcd60e51b8152600401610bb290614225565b61121689338a612a9b565b7f8b4cb679525333b871a22887d818d55be20d198dd58ca071a0901e5033ba0b2789338a8860405161124b9493929190614162565b60405180910390a1505050505050505050565b6112683382612c9e565b6112845760405162461bcd60e51b8152600401610bb290614384565b610ce3838383612a9b565b33611298611bc1565b6001600160a01b0316146112be5760405162461bcd60e51b8152600401610bb29061434f565b6112c781612d60565b6040518181527f5b6b431d4476a211bb7d41c20d1aab9ae2321deee0d20be3d9fc9b1093fa6e3d90602001610ff5565b33611300611bc1565b6001600160a01b0316146113265760405162461bcd60e51b8152600401610bb29061434f565b60118054821515600160a01b0260ff60a01b199091161790556040517f27f1bd8a3f7152926d391c31ade39f3452205d10a6db1d2eeaf4f2d4a5adcf0190610ff590831515815260200190565b3361137c611bc1565b6001600160a01b0316146113a25760405162461bcd60e51b8152600401610bb29061434f565b60158190556040518181527f5d18a6b3e7e847824d58b9b569ab040f1707a3e20e54857610a00028e482297590602001610ff5565b610ce383838360405180602001604052806000815250612222565b336113fb611bc1565b6001600160a01b0316146114215760405162461bcd60e51b8152600401610bb29061434f565b60175460ff16156114885760405162461bcd60e51b815260206004820152602b60248201527f42617365546f6b656e3a20636f6e747261637420697320616c7265616479206960448201526a6e697469616c697a65642160a81b6064820152608401610bb2565b60178054601180546001600160a01b03199081166001600160a01b038681169182179093556012805490921681179091556001600160a81b031990921661010091861691820260ff1916176001179092556040805192835260208301919091527fdc90fed0326ba91706deeac7eb34ac9f8b680734f9d782864dc29704d23bed6a91015b60405180910390a15050565b33611521611bc1565b6001600160a01b0316146115475760405162461bcd60e51b8152600401610bb29061434f565b4281116115b15760405162461bcd60e51b815260206004820152603260248201527f42617365546f6b656e3a206e65772073616c652073746172742074696d652073604482015271686f756c6420626520696e2066757475726560701b6064820152608401610bb2565b601a5415806115c1575042601a54115b6116195760405162461bcd60e51b8152602060048201526024808201527f42617365546f6b656e3a2073616c652073686f756c646e2774206265207374616044820152631c9d195960e21b6064820152608401610bb2565b601a8190556040518181527f857dbbe37dc351454ca7ef7c21564f13c072765b994bdf58c52bdee0876934da90602001610ff5565b33611657611bc1565b6001600160a01b03161461167d5760405162461bcd60e51b8152600401610bb29061434f565b805161169090600e906020840190613b21565b507f23c8c9488efebfd474e85a7956de6f39b17c7ab88502d42a623db2d8e382bbaa81604051610ff59190614212565b336116c9611bc1565b6001600160a01b0316146116ef5760405162461bcd60e51b8152600401610bb29061434f565b6000821180156116fe57504282115b6117585760405162461bcd60e51b815260206004820152602560248201527f42617365546f6b656e3a20496e76616c69642070726573616c652073746172746044820152642074696d6560d81b6064820152608401610bb2565b8082106117c05760405162461bcd60e51b815260206004820152603060248201527f42617365546f6b656e3a2070726573616c655f73746172745f74696d65203e2060448201526f70726573616c655f656e645f74696d6560801b6064820152608401610bb2565b601a5481106118275760405162461bcd60e51b815260206004820152602d60248201527f42617365546f6b656e3a2070726573616c655f656e645f74696d65203e20736160448201526c6c655f73746172745f74696d6560981b6064820152608401610bb2565b601b829055601c8190556040518281527f2cb0d53ec107d1f3efc36c6e39a4de0e1723a3d637aa9178b3356254906fd0139060200160405180910390a16040518181527f62400d834946b484fe5d73edd368d4efc77d2c705e471a10ac0524a162230e7e9060200161150c565b3361189d611bc1565b6001600160a01b0316146118c35760405162461bcd60e51b8152600401610bb29061434f565b6103e881111561192b5760405162461bcd60e51b815260206004820152602d60248201527f45524337323142757961626c653a204c6f6f6b73206c696b652074686973207460448201526c617820697320746f6f2062696760981b6064820152608401610bb2565b60098190556040518181527f3fe94ea41084ff6af75f0f3e32844008c7de9a1e7f2b5f1a4173eacad584221b90602001610ff5565b6000818152600260205260408120546001600160a01b031680610ab25760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610bb2565b60006001600160a01b038216611a425760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610bb2565b506001600160a01b031660009081526003602052604090205490565b33611a67611bc1565b6001600160a01b031614611a8d5760405162461bcd60e51b8152600401610bb29061434f565b565b33611a98611bc1565b6001600160a01b031614611abe5760405162461bcd60e51b8152600401610bb29061434f565b611ac747612d60565b6040517f5a648bc540f9bf9a33d1fe64d284e4a69a88aa95d4c7f8054d4bc85f877dcf4e90600090a1565b600080808080611b03600187614575565b905060188181548110611b1857611b18614664565b6000918252602090912001546018805460ff9092169183908110611b3e57611b3e614664565b9060005260206000200160000160019054906101000a900460ff1660188381548110611b6c57611b6c614664565b9060005260206000200160000160029054906101000a900460ff1660188481548110611b9a57611b9a614664565b60009182526020909120015492999198509650630100000090910461ffff16945092505050565b6006546001600160a01b031690565b33611bd9611bc1565b6001600160a01b031614611bff5760405162461bcd60e51b8152600401610bb29061434f565b60118054821515600160a81b0260ff60a81b199091161790556040517f6be482a1cd377fd2826c8595999d17e99efc268068d18fbd2ebab94c060f2b7890610ff590831515815260200190565b33611c55611bc1565b6001600160a01b031614611c7b5760405162461bcd60e51b8152600401610bb29061434f565b8051611c8e906010906020840190613b21565b507f5ca9f750836b0b7efdace104f07b5c9f0df0650c0fd24f5163e99044ae36ea5281604051610ff59190614212565b606060018054610ac7906145b8565b3342611ce08366c3663566a58000614556565b3414611cfe5760405162461bcd60e51b8152600401610bb29061440a565b813b63ffffffff1615611d235760405162461bcd60e51b8152600401610bb2906142ae565b80601b54108015611d355750601c5481105b611d815760405162461bcd60e51b815260206004820181905260248201527f42617365546f6b656e3a2050726573616c65206973206e6f74206163746976656044820152606401610bb2565b60046001600160a01b0383166000908152601d6020526040902054611da790859061443f565b1115611e105760405162461bcd60e51b815260206004820152603260248201527f42617365546f6b656e3a20416d6f756e74206f6620746f6b656e7320657863656044820152716564732070726573616c65206c696d69747360701b6064820152608401610bb2565b6001600160a01b0382166000908152601d6020526040902054611e3490849061443f565b6001600160a01b0383166000908152601d602052604090205560165483600f54611e5e919061443f565b1115611eca5760405162461bcd60e51b815260206004820152604160248201526000805160206146ca83398151915260448201527f6e73207468616e20746865206d617850726573616c65546f74616c537570706c6064820152607960f81b608482015260a401610bb2565b6001600160a01b038083166000908152601e60205260409020805460ff19166001179055601254166108fc611efe60145490565b611f089086614556565b6040518115909202916000818181858888f19350505050158015611f30573d6000803e3d6000fd5b50611f3d84846001612e47565b50505050565b6001600160a01b038216331415611f985760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610bb2565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6120168167013fbe85edc90000614556565b34146120345760405162461bcd60e51b8152600401610bb29061440a565b3342813b63ffffffff161561205b5760405162461bcd60e51b8152600401610bb2906142ae565b601654600f5410156120d557601a54811180156120795750601a5415155b6120d55760405162461bcd60e51b815260206004820152602760248201527f42617365546f6b656e3a204d61696e2073616c65206861736e277420737461726044820152661d1959081e595d60ca1b6064820152608401610bb2565b60155483600f546120e6919061443f565b11156121455760405162461bcd60e51b815260206004820152603a60248201526000805160206146ca8339815191526044820152796e73207468616e20746865206d6178546f74616c537570706c7960301b6064820152608401610bb2565b6001600160a01b0382166000908152601e60205260409020805460ff19166001179055600d8311156121cb5760405162461bcd60e51b815260206004820152602960248201527f42617365546f6b656e3a2043616e6e6f7420627579206d6f726520746f6b656e60448201526873207468616e20313360b81b6064820152608401610bb2565b6012546001600160a01b03166108fc6121e360135490565b6121ed9086614556565b6040518115909202916000818181858888f19350505050158015612215573d6000803e3d6000fd5b50611f3d84846000612e47565b61222c3383612c9e565b6122485760405162461bcd60e51b8152600401610bb290614384565b611f3d84848484612fa5565b606061225f8261281a565b6122ba5760405162461bcd60e51b815260206004820152602660248201527f42617369733a2055524920717565727920666f72206e6f6e6578697374656e74604482015265103a37b5b2b760d11b6064820152608401610bb2565b600e6122c583612fd8565b6040516020016122d692919061401f565b6040516020818303038152906040529050919050565b60006122fa878786866130d5565b90506123106001600160a01b038816828461294f565b61232c5760405162461bcd60e51b8152600401610bb2906143d5565b83421061234b5760405162461bcd60e51b8152600401610bb290614306565b6001600160a01b0387166000908152600d60209081526040808320898452909152812080549161237a836145f3565b91905055506000600a54600954856123929190614556565b61239c9190614457565b9050801561245157600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd926123de928e921690879060040161410b565b602060405180830381600087803b1580156123f857600080fd5b505af115801561240c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124309190613ec4565b90508061244f5760405162461bcd60e51b8152600401610bb290614225565b505b600b546000906001600160a01b03166323b872dd8a33612471868a614575565b6040518463ffffffff1660e01b815260040161248f9392919061410b565b602060405180830381600087803b1580156124a957600080fd5b505af11580156124bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124e19190613ec4565b9050806125005760405162461bcd60e51b8152600401610bb290614225565b61250b338a8a612a9b565b7fc449542e187835de02e1b181e93b2267fd8592c5728e4b347834a6711b51ccb3338a8a8860405161124b9493929190614162565b33612549611bc1565b6001600160a01b03161461256f5760405162461bcd60e51b8152600401610bb29061434f565b60168190556040518181527f5e09940833ef8cddfdf303c21eaf750609d4b8f504e093c69c4591594e8e6e9b90602001610ff5565b601080546125b1906145b8565b80601f01602080910402602001604051908101604052809291908181526020018280546125dd906145b8565b801561262a5780601f106125ff5761010080835404028352916020019161262a565b820191906000526020600020905b81548152906001019060200180831161260d57829003601f168201915b505050505081565b60075460405163c455279160e01b81526000916001600160a01b038085169291169063c4552791906126689087906004016140f7565b60206040518083038186803b15801561268057600080fd5b505afa158015612694573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126b89190613f1b565b6001600160a01b031614156126cf57506001610ab2565b6001600160a01b0380841660009081526005602090815260408083209386168352929052205460ff165b9392505050565b33612709611bc1565b6001600160a01b03161461272f5760405162461bcd60e51b8152600401610bb29061434f565b600c80546001600160a01b0319166001600160a01b0383161790556040517fcb7ef3e545f5cdb893f5c568ba710fe08f336375a2d9fd66e161033f8fc09ef390610ff59083906140f7565b33612783611bc1565b6001600160a01b0316146127a95760405162461bcd60e51b8152600401610bb29061434f565b6001600160a01b03811661280e5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610bb2565b61281781613134565b50565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b038416908117909155819061286c82611960565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6001600160a01b038581166000818152600d6020908152604080832088845282528083205481517f5a3ac364254bf8141cade7fc83e6b4ac37b75f1d4df26a245ef4a174edfe2593938101939093529082019390935292871660608401526080830186905260a083019190915260c0820184905260e082018390529061294590610100015b60405160208183030381529060405280519060200120613186565b9695505050505050565b600080600061295e85856131d4565b909250905060008160048111156129775761297761464e565b1480156129955750856001600160a01b0316826001600160a01b0316145b156129a5576001925050506126f9565b600080876001600160a01b0316631626ba7e60e01b88886040516024016129cd9291906141f9565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909416939093179092529051612a0b9190614003565b600060405180830381855afa9150503d8060008114612a46576040519150601f19603f3d011682016040523d82523d6000602084013e612a4b565b606091505b5091509150818015612a5e575080516020145b8015612a8f57508051630b135d3f60e11b90612a839083016020908101908401613efe565b6001600160e01b031916145b98975050505050505050565b826001600160a01b0316612aae82611960565b6001600160a01b031614612b165760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610bb2565b6001600160a01b038216612b785760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610bb2565b612b83838383613244565b612b8e600082612837565b6001600160a01b0383166000908152600360205260408120805460019290612bb7908490614575565b90915550506001600160a01b0382166000908152600360205260408120805460019290612be590849061443f565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716916000805160206146ea83398151915291a4505050565b6001600160a01b0384166000908152600d602090815260408083208684528252808320549051612c939261292a927f8cbb7530fdede89f5d16a7ee48153cff90c0b84c0b3fa0c3f178a5ddfda170b2928a928a92918a918a91016141c8565b90505b949350505050565b6000612ca98261281a565b612d0a5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610bb2565b6000612d1583611960565b9050806001600160a01b0316846001600160a01b03161480612d505750836001600160a01b0316612d4584610b4a565b6001600160a01b0316145b80612c965750612c968185612632565b60008111612dc65760405162461bcd60e51b815260206004820152602d60248201527f576974686472617761626c653a20416d6f756e742068617320746f206265206760448201526c0726561746572207468616e203609c1b6064820152608401610bb2565b47811115612e165760405162461bcd60e51b815260206004820152601e60248201527f576974686472617761626c653a204e6f7420656e6f7567682066756e647300006044820152606401610bb2565b604051339082156108fc029083906000818181858888f19350505050158015612e43573d6000803e3d6000fd5b5050565b600082600f54612e57919061443f565b600f549091504290600090612e6d90600161443f565b90505b828111612f3d57612e818682613377565b600080600080612e90856134a3565b93509350935093508715612ee4577fbfa75414001e9f18f76ea01e8b52acc9ae8ff8e884c128ecfda326b56017ebb28a8686868686604051612ed79695949392919061418b565b60405180910390a1612f26565b7f9691906fc1ed21f220add64ba737c8c97d22656f6dc9f0dbfcb2a6cfabae4e708a8686868686604051612f1d9695949392919061418b565b60405180910390a15b505050508080612f35906145f3565b915050612e70565b5083600f6000828254612f50919061443f565b9091555050601554600f541415612f9e576011805460ff60b01b1916600160b01b1790556040517f52df9fe5b9c9a7b0b4fdc2c9f89387959e35e4209c2a8d133a2b8165edad2a0490600090a15b5050505050565b612fb0848484612a9b565b612fbc84848484613812565b611f3d5760405162461bcd60e51b8152600401610bb29061425c565b606081612ffc5750506040805180820190915260018152600360fc1b602082015290565b8160005b81156130265780613010816145f3565b915061301f9050600a83614457565b9150613000565b6000816001600160401b038111156130405761304061467a565b6040519080825280601f01601f19166020018201604052801561306a576020820181803683370190505b5090505b8415612c965761307f600183614575565b915061308c600a8661460e565b61309790603061443f565b60f81b8183815181106130ac576130ac614664565b60200101906001600160f81b031916908160001a9053506130ce600a86614457565b945061306e565b6001600160a01b0384166000908152600d602090815260408083208684528252808320549051612c939261292a927f2feec0009bd50e41c6079eeb85f264c8fb21147d30736dbaae14aa7936f4559f928a928a92918a918a91016141c8565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000610ab261319361391c565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b60008082516041141561320b5760208301516040840151606085015160001a6131ff87828585613a0f565b9450945050505061323d565b825160401415613235576020830151604084015161322a868383613af2565b93509350505061323d565b506000905060025b9250929050565b601154600160a81b900460ff16806132e75750601154600160a01b900460ff1680156132e75750601154604051633a090bb360e11b8152600481018390526001600160a01b039091169063741217669060240160206040518083038186803b1580156132af57600080fd5b505afa1580156132c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132e79190613ec4565b15610ce3576001600160a01b03831615610ce35760405162461bcd60e51b815260206004820152604560248201527f436f6d62696e61626c65546f6b656e42617369733a20536f7272792c2069742060448201527f69732070726f6869626974656420746f207472616e73666572204261736520746064820152646f6b656e7360d81b608482015260a401610bb2565b6001600160a01b0382166133cd5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610bb2565b6133d68161281a565b156134225760405162461bcd60e51b815260206004820152601c60248201527b115490cdcc8c4e881d1bdad95b88185b1c9958591e481b5a5b9d195960221b6044820152606401610bb2565b61342e60008383613244565b6001600160a01b038216600090815260036020526040812080546001929061345790849061443f565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392906000805160206146ea833981519152908290a45050565b6040805160808101825260008082526020820181905291810182905260608101829052819081908190429044904390600189116134e05783613515565b60186134ed60028b614575565b815481106134fd576134fd614664565b6000918252602090912001546301000000900461ffff165b60196000828254613526919061443f565b90915550506019546040516006916135489185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c61356b919061460e565b6135769060026144ae565b60ff1681526001891161358957836135bc565b601861359660028b614575565b815481106135a6576135a6614664565b60009182526020909120015462010000900460ff165b601960008282546135cd919061443f565b90915550506019546040516006916135ef9185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c613612919061460e565b61361d9060026144ae565b60ff166020820152600189116136335783613660565b601861364060028b614575565b8154811061365057613650614664565b60009182526020909120015460ff165b60196000828254613671919061443f565b90915550506019546040516004916136939185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c6136b6919061460e565b6136c19060026144ae565b60ff166040820152600189116136d75783613709565b60186136e460028b614575565b815481106136f4576136f4614664565b600091825260209091200154610100900460ff165b6019600082825461371a919061443f565b9091555050601954604051600d9161373c9185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c61375f919061460e565b61376a9060026144ae565b61ffff908116606083019081526018805460018101825560009190915283517fb13d2d76d1f4b7be834882e410b3e3a8afaf69f83600ae24db354391d2378d2e90910180546020860151604090960151935194851663010000000264ffff0000001960ff80871662010000029190911664ffffff000019828a166101000261ffff19909516928716929092179390931716919091171790559b929a5098509650945050505050565b60006001600160a01b0384163b1561391457604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061385690339089908890889060040161412f565b602060405180830381600087803b15801561387057600080fd5b505af19250505080156138a0575060408051601f3d908101601f1916820190925261389d91810190613efe565b60015b6138fa573d8080156138ce576040519150601f19603f3d011682016040523d82523d6000602084013e6138d3565b606091505b5080516138f25760405162461bcd60e51b8152600401610bb29061425c565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612c96565b506001612c96565b60007f000000000000000000000000000000000000000000000000000000000000000046141561396b57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6000806fa2a8918ca85bafe22016d0b997e4df60600160ff1b03831115613a3c5750600090506003613ae9565b8460ff16601b14158015613a5457508460ff16601c14155b15613a655750600090506004613ae9565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015613ab9573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613ae257600060019250925050613ae9565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b01613b1387828885613a0f565b935093505050935093915050565b828054613b2d906145b8565b90600052602060002090601f016020900481019282613b4f5760008555613b95565b82601f10613b6857805160ff1916838001178555613b95565b82800160010185558215613b95579182015b82811115613b95578251825591602001919060010190613b7a565b50613ba1929150613ba5565b5090565b5b80821115613ba15760008155600101613ba6565b60006001600160401b0380841115613bd457613bd461467a565b604051601f8501601f19908116603f01168101908282118183101715613bfc57613bfc61467a565b81604052809350858152868686011115613c1557600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613c4057600080fd5b6126f983833560208501613bba565b600060208284031215613c6157600080fd5b81356126f981614690565b60008060408385031215613c7f57600080fd5b8235613c8a81614690565b91506020830135613c9a81614690565b809150509250929050565b600080600060608486031215613cba57600080fd5b8335613cc581614690565b92506020840135613cd581614690565b929592945050506040919091013590565b60008060008060808587031215613cfc57600080fd5b8435613d0781614690565b93506020850135613d1781614690565b92506040850135915060608501356001600160401b03811115613d3957600080fd5b613d4587828801613c2f565b91505092959194509250565b600080600080600080600060e0888a031215613d6c57600080fd5b8735613d7781614690565b96506020880135613d8781614690565b955060408801359450606088013593506080880135925060a0880135915060c08801356001600160401b03811115613dbe57600080fd5b613dca8a828b01613c2f565b91505092959891949750929550565b60008060408385031215613dec57600080fd5b8235613df781614690565b91506020830135613c9a816146a5565b60008060408385031215613e1a57600080fd5b8235613e2581614690565b946020939093013593505050565b60008060008060008060c08789031215613e4c57600080fd5b8635613e5781614690565b95506020870135945060408701359350606087013592506080870135915060a08701356001600160401b03811115613e8e57600080fd5b613e9a89828a01613c2f565b9150509295509295509295565b600060208284031215613eb957600080fd5b81356126f9816146a5565b600060208284031215613ed657600080fd5b81516126f9816146a5565b600060208284031215613ef357600080fd5b81356126f9816146b3565b600060208284031215613f1057600080fd5b81516126f9816146b3565b600060208284031215613f2d57600080fd5b81516126f981614690565b600060208284031215613f4a57600080fd5b81356001600160401b03811115613f6057600080fd5b8201601f81018413613f7157600080fd5b612c9684823560208401613bba565b600060208284031215613f9257600080fd5b5035919050565b60008060408385031215613fac57600080fd5b50508035926020909101359150565b60008151808452613fd381602086016020860161458c565b601f01601f19169290920160200192915050565b60008151613ff981856020860161458c565b9290920192915050565b6000825161401581846020870161458c565b9190910192915050565b600080845481600182811c91508083168061403b57607f831692505b602080841082141561405b57634e487b7160e01b86526022600452602486fd5b81801561406f5760018114614080576140ad565b60ff198616895284890196506140ad565b60008b81526020902060005b868110156140a55781548b82015290850190830161408c565b505084890196505b5050505050506140bd8185613fe7565b95945050505050565b94855260208501939093526040840191909152606090811b6001600160601b03191690830152607482015260940190565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061294590830184613fbb565b6001600160a01b0394851681529290931660208301526040820152606081019190915260800190565b6001600160a01b03969096168652602086019490945260ff9283166040860152908216606085015216608083015261ffff1660a082015260c00190565b9586526001600160a01b0394909416602086015260408501929092526060840152608083015260a082015260c00190565b828152604060208201526000612c966040830184613fbb565b6020815260006126f96020830184613fbb565b6020808252601e908201527f45524337323142757961626c653a207472616e73666572206661696c65640000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526038908201527f42617365546f6b656e3a20796f75206861766520746f2062652061207065727360408201527737b7103a379031b0b636103a3434b990333ab731ba34b7b760411b606082015260800190565b60208082526029908201527f45524337323142757961626c653a207369676e6564207472616e73616374696f6040820152681b88195e1c1a5c995960ba1b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252818101527f45524337323142757961626c653a20496e76616c6964207369676e6174757265604082015260600190565b6020808252818101527f42617365546f6b656e3a2074782076616c756520697320746f6f20736d616c6c604082015260600190565b6000821982111561445257614452614622565b500190565b60008261446657614466614638565b500490565b600181815b808511156144a657816000190482111561448c5761448c614622565b8085161561449957918102915b93841c9390800290614470565b509250929050565b60006126f983836000826144c457506001610ab2565b816144d157506000610ab2565b81600181146144e757600281146144f15761450d565b6001915050610ab2565b60ff84111561450257614502614622565b50506001821b610ab2565b5060208310610133831016604e8410600b8410161715614530575081810a610ab2565b61453a838361446b565b806000190482111561454e5761454e614622565b029392505050565b600081600019048311821515161561457057614570614622565b500290565b60008282101561458757614587614622565b500390565b60005b838110156145a757818101518382015260200161458f565b83811115611f3d5750506000910152565b600181811c908216806145cc57607f821691505b602082108114156145ed57634e487b7160e01b600052602260045260246000fd5b50919050565b600060001982141561460757614607614622565b5060010190565b60008261461d5761461d614638565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461281757600080fd5b801515811461281757600080fd5b6001600160e01b03198116811461281757600080fdfe42617365546f6b656e3a2043616e6e6f74206d696e74206d6f726520746f6b65ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122021d4bfb10022e90a0e77661b63b917ee2367671d92e8bcc50741cc1c9d3fd04f64736f6c63430008060033000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c100000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2000000000000000000000000000000000000000000000000000000000000001745766f6c7574696f6e20506c6179696e67204361726473000000000000000000000000000000000000000000000000000000000000000000000000000000000545564f5043000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002768747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f626173656e66742f000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000043697066733a2f2f45564f50433131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131312f0000000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x6080604052600436106102c75760003560e01c80620e7fa8146102cc57806301ffc9a7146102fa57806306fdde031461032a578063081812fc1461034c578063095ea7b314610379578063097bf9c81461039b5780630c166a61146103ae57806310ac1ee2146103ce57806318160ddd146103e45780631cbaee2d146103f95780631db09ddc1461040f578063220d36d81461043c578063237b5e961461045c57806323b872dd1461047a578063249b7c191461049a5780632ab4d052146104b05780632e1a7d4d146104c65780633013ce29146104e6578063392e53cd146105065780633aefab86146105205780633c322798146105405780633cad99ce146105565780633f3e4c111461056c57806342842e0e1461058c578063485cc955146105ac578063502e1a16146105cc578063525f8a5c1461060457806355f804b3146106245780635c40329e146106445780635e3f0e6c146106645780636197a4d21461067957806361d027b31461069957806362ad351b146106b957806362f837ef146106de5780636352211e146106f457806366666aa91461071457806370a0823114610734578063715018a6146107545780637c90d65b146107695780637e2888221461078a578063819d19551461079d578063853828b6146107d65780638639b4bb146107eb578063893da6c9146108015780638afe7989146108205780638da5cb5b1461086e57806392ebd23614610883578063938e3d7b146108a357806395d89b41146108c35780639b6a6709146108d8578063a035b1fe146108eb578063a22cb46514610907578063a82524b214610927578063ac5ae11b1461093d578063b88d4fde14610950578063bed1d46d14610970578063c87b56dd14610991578063d1af5df4146109b1578063d85beb85146109d1578063e8a3d485146109f1578063e985e9c514610a06578063f0f4426014610a26578063f2fde38b14610a46575b600080fd5b3480156102d857600080fd5b506102e766c3663566a5800081565b6040519081526020015b60405180910390f35b34801561030657600080fd5b5061031a610315366004613ee1565b610a66565b60405190151581526020016102f1565b34801561033657600080fd5b5061033f610ab8565b6040516102f19190614212565b34801561035857600080fd5b5061036c610367366004613f80565b610b4a565b6040516102f191906140f7565b34801561038557600080fd5b50610399610394366004613e07565b610bd7565b005b6103996103a9366004613d51565b610ce8565b3480156103ba57600080fd5b506103996103c9366004613c4f565b610f7b565b3480156103da57600080fd5b506102e760145481565b3480156103f057600080fd5b50600f546102e7565b34801561040557600080fd5b506102e7601a5481565b34801561041b57600080fd5b506102e761042a366004613c4f565b601d6020526000908152604090205481565b34801561044857600080fd5b50610399610457366004613e33565b611000565b34801561046857600080fd5b506011546001600160a01b031661036c565b34801561048657600080fd5b50610399610495366004613ca5565b61125e565b3480156104a657600080fd5b506102e7601c5481565b3480156104bc57600080fd5b506102e760155481565b3480156104d257600080fd5b506103996104e1366004613f80565b61128f565b3480156104f257600080fd5b50600b5461036c906001600160a01b031681565b34801561051257600080fd5b5060175461031a9060ff1681565b34801561052c57600080fd5b5061039961053b366004613ea7565b6112f7565b34801561054c57600080fd5b506102e760135481565b34801561056257600080fd5b506102e7600a5481565b34801561057857600080fd5b50610399610587366004613f80565b611373565b34801561059857600080fd5b506103996105a7366004613ca5565b6113d7565b3480156105b857600080fd5b506103996105c7366004613c6c565b6113f2565b3480156105d857600080fd5b506102e76105e7366004613e07565b600d60209081526000928352604080842090915290825290205481565b34801561061057600080fd5b5061039961061f366004613f80565b611518565b34801561063057600080fd5b5061039961063f366004613f38565b61164e565b34801561065057600080fd5b5061039961065f366004613f99565b6116c0565b34801561067057600080fd5b506102e7600481565b34801561068557600080fd5b50610399610694366004613f80565b611894565b3480156106a557600080fd5b50600c5461036c906001600160a01b031681565b3480156106c557600080fd5b5060175461036c9061010090046001600160a01b031681565b3480156106ea57600080fd5b506102e760095481565b34801561070057600080fd5b5061036c61070f366004613f80565b611960565b34801561072057600080fd5b5060125461036c906001600160a01b031681565b34801561074057600080fd5b506102e761074f366004613c4f565b6119d7565b34801561076057600080fd5b50610399611a5e565b34801561077557600080fd5b5060115461031a90600160a81b900460ff1681565b34801561079657600080fd5b50476102e7565b3480156107a957600080fd5b5061031a6107b8366004613c4f565b6001600160a01b03166000908152601e602052604090205460ff1690565b3480156107e257600080fd5b50610399611a8f565b3480156107f757600080fd5b506102e760165481565b34801561080d57600080fd5b50601154600160b01b900460ff1661031a565b34801561082c57600080fd5b5061084061083b366004613f80565b611af2565b6040805160ff95861681529385166020850152919093169082015261ffff90911660608201526080016102f1565b34801561087a57600080fd5b5061036c611bc1565b34801561088f57600080fd5b5061039961089e366004613ea7565b611bd0565b3480156108af57600080fd5b506103996108be366004613f38565b611c4c565b3480156108cf57600080fd5b5061033f611cbe565b6103996108e6366004613e07565b611ccd565b3480156108f757600080fd5b506102e767013fbe85edc9000081565b34801561091357600080fd5b50610399610922366004613dd9565b611f43565b34801561093357600080fd5b506102e7601b5481565b61039961094b366004613e07565b612004565b34801561095c57600080fd5b5061039961096b366004613ce6565b612222565b34801561097c57600080fd5b5060115461031a90600160a01b900460ff1681565b34801561099d57600080fd5b5061033f6109ac366004613f80565b612254565b3480156109bd57600080fd5b506103996109cc366004613e33565b6122ec565b3480156109dd57600080fd5b506103996109ec366004613f80565b612540565b3480156109fd57600080fd5b5061033f6125a4565b348015610a1257600080fd5b5061031a610a21366004613c6c565b612632565b348015610a3257600080fd5b50610399610a41366004613c4f565b612700565b348015610a5257600080fd5b50610399610a61366004613c4f565b61277a565b60006001600160e01b031982166380ac58cd60e01b1480610a9757506001600160e01b03198216635b5e139f60e01b145b80610ab257506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060008054610ac7906145b8565b80601f0160208091040260200160405190810160405280929190818152602001828054610af3906145b8565b8015610b405780601f10610b1557610100808354040283529160200191610b40565b820191906000526020600020905b815481529060010190602001808311610b2357829003601f168201915b5050505050905090565b6000610b558261281a565b610bbb5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600460205260409020546001600160a01b031690565b6000610be282611960565b9050806001600160a01b0316836001600160a01b03161415610c505760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610bb2565b336001600160a01b0382161480610c6c5750610c6c8133612632565b610cd95760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f776044820152771b995c881b9bdc88185c1c1c9bdd995908199bdc88185b1b60421b6064820152608401610bb2565b610ce38383612837565b505050565b60026008541415610d3b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c006044820152606401610bb2565b60026008556000610d4f88888887876128a5565b9050348314610db45760405162461bcd60e51b815260206004820152602b60248201527f45524337323142757961626c653a204e6f7420656e6f7567687420455448207460448201526a3790313abc903a37b5b2b760a91b6064820152608401610bb2565b610dbf88828461294f565b610ddb5760405162461bcd60e51b8152600401610bb2906143d5565b834210610e3c5760405162461bcd60e51b815260206004820152602960248201527f45524337323142757961626c653a205369676e6564207472616e73616374696f6044820152681b88195e1c1a5c995960ba1b6064820152608401610bb2565b6001600160a01b0388166000908152600d602090815260408083208984529091528120805491610e6b836145f3565b90915550506001600160a01b038716610e82573396505b6000600a5460095485610e959190614556565b610e9f9190614457565b90508015610ee357600c546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015610ee1573d6000803e3d6000fd5b505b6001600160a01b0389166108fc610efa8387614575565b6040518115909202916000818181858888f19350505050158015610f22573d6000803e3d6000fd5b50610f2e898989612a9b565b7f0919dd2bf769d97497dac32ec38d1620dba154dc7d4374848a2293a0c1ce867d89898987604051610f639493929190614162565b60405180910390a15050600160085550505050505050565b33610f84611bc1565b6001600160a01b031614610faa5760405162461bcd60e51b8152600401610bb29061434f565b601180546001600160a01b0319166001600160a01b0383161790556040517fd5b496569a6ad0a6c044608a3d8b08eee668e7a35c963a164b8ef376b004916690610ff59083906140f7565b60405180910390a150565b600061100e87878686612c34565b905061101b87828461294f565b6110375760405162461bcd60e51b8152600401610bb2906143d5565b8342106110565760405162461bcd60e51b8152600401610bb290614306565b6001600160a01b0387166000908152600d602090815260408083208984529091528120805491611085836145f3565b91905055506000600a546009548561109d9190614556565b6110a79190614457565b9050801561115c57600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd926110e99233921690879060040161410b565b602060405180830381600087803b15801561110357600080fd5b505af1158015611117573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061113b9190613ec4565b90508061115a5760405162461bcd60e51b8152600401610bb290614225565b505b600b546000906001600160a01b03166323b872dd338b61117c868a614575565b6040518463ffffffff1660e01b815260040161119a9392919061410b565b602060405180830381600087803b1580156111b457600080fd5b505af11580156111c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111ec9190613ec4565b90508061120b5760405162461bcd60e51b8152600401610bb290614225565b61121689338a612a9b565b7f8b4cb679525333b871a22887d818d55be20d198dd58ca071a0901e5033ba0b2789338a8860405161124b9493929190614162565b60405180910390a1505050505050505050565b6112683382612c9e565b6112845760405162461bcd60e51b8152600401610bb290614384565b610ce3838383612a9b565b33611298611bc1565b6001600160a01b0316146112be5760405162461bcd60e51b8152600401610bb29061434f565b6112c781612d60565b6040518181527f5b6b431d4476a211bb7d41c20d1aab9ae2321deee0d20be3d9fc9b1093fa6e3d90602001610ff5565b33611300611bc1565b6001600160a01b0316146113265760405162461bcd60e51b8152600401610bb29061434f565b60118054821515600160a01b0260ff60a01b199091161790556040517f27f1bd8a3f7152926d391c31ade39f3452205d10a6db1d2eeaf4f2d4a5adcf0190610ff590831515815260200190565b3361137c611bc1565b6001600160a01b0316146113a25760405162461bcd60e51b8152600401610bb29061434f565b60158190556040518181527f5d18a6b3e7e847824d58b9b569ab040f1707a3e20e54857610a00028e482297590602001610ff5565b610ce383838360405180602001604052806000815250612222565b336113fb611bc1565b6001600160a01b0316146114215760405162461bcd60e51b8152600401610bb29061434f565b60175460ff16156114885760405162461bcd60e51b815260206004820152602b60248201527f42617365546f6b656e3a20636f6e747261637420697320616c7265616479206960448201526a6e697469616c697a65642160a81b6064820152608401610bb2565b60178054601180546001600160a01b03199081166001600160a01b038681169182179093556012805490921681179091556001600160a81b031990921661010091861691820260ff1916176001179092556040805192835260208301919091527fdc90fed0326ba91706deeac7eb34ac9f8b680734f9d782864dc29704d23bed6a91015b60405180910390a15050565b33611521611bc1565b6001600160a01b0316146115475760405162461bcd60e51b8152600401610bb29061434f565b4281116115b15760405162461bcd60e51b815260206004820152603260248201527f42617365546f6b656e3a206e65772073616c652073746172742074696d652073604482015271686f756c6420626520696e2066757475726560701b6064820152608401610bb2565b601a5415806115c1575042601a54115b6116195760405162461bcd60e51b8152602060048201526024808201527f42617365546f6b656e3a2073616c652073686f756c646e2774206265207374616044820152631c9d195960e21b6064820152608401610bb2565b601a8190556040518181527f857dbbe37dc351454ca7ef7c21564f13c072765b994bdf58c52bdee0876934da90602001610ff5565b33611657611bc1565b6001600160a01b03161461167d5760405162461bcd60e51b8152600401610bb29061434f565b805161169090600e906020840190613b21565b507f23c8c9488efebfd474e85a7956de6f39b17c7ab88502d42a623db2d8e382bbaa81604051610ff59190614212565b336116c9611bc1565b6001600160a01b0316146116ef5760405162461bcd60e51b8152600401610bb29061434f565b6000821180156116fe57504282115b6117585760405162461bcd60e51b815260206004820152602560248201527f42617365546f6b656e3a20496e76616c69642070726573616c652073746172746044820152642074696d6560d81b6064820152608401610bb2565b8082106117c05760405162461bcd60e51b815260206004820152603060248201527f42617365546f6b656e3a2070726573616c655f73746172745f74696d65203e2060448201526f70726573616c655f656e645f74696d6560801b6064820152608401610bb2565b601a5481106118275760405162461bcd60e51b815260206004820152602d60248201527f42617365546f6b656e3a2070726573616c655f656e645f74696d65203e20736160448201526c6c655f73746172745f74696d6560981b6064820152608401610bb2565b601b829055601c8190556040518281527f2cb0d53ec107d1f3efc36c6e39a4de0e1723a3d637aa9178b3356254906fd0139060200160405180910390a16040518181527f62400d834946b484fe5d73edd368d4efc77d2c705e471a10ac0524a162230e7e9060200161150c565b3361189d611bc1565b6001600160a01b0316146118c35760405162461bcd60e51b8152600401610bb29061434f565b6103e881111561192b5760405162461bcd60e51b815260206004820152602d60248201527f45524337323142757961626c653a204c6f6f6b73206c696b652074686973207460448201526c617820697320746f6f2062696760981b6064820152608401610bb2565b60098190556040518181527f3fe94ea41084ff6af75f0f3e32844008c7de9a1e7f2b5f1a4173eacad584221b90602001610ff5565b6000818152600260205260408120546001600160a01b031680610ab25760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610bb2565b60006001600160a01b038216611a425760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610bb2565b506001600160a01b031660009081526003602052604090205490565b33611a67611bc1565b6001600160a01b031614611a8d5760405162461bcd60e51b8152600401610bb29061434f565b565b33611a98611bc1565b6001600160a01b031614611abe5760405162461bcd60e51b8152600401610bb29061434f565b611ac747612d60565b6040517f5a648bc540f9bf9a33d1fe64d284e4a69a88aa95d4c7f8054d4bc85f877dcf4e90600090a1565b600080808080611b03600187614575565b905060188181548110611b1857611b18614664565b6000918252602090912001546018805460ff9092169183908110611b3e57611b3e614664565b9060005260206000200160000160019054906101000a900460ff1660188381548110611b6c57611b6c614664565b9060005260206000200160000160029054906101000a900460ff1660188481548110611b9a57611b9a614664565b60009182526020909120015492999198509650630100000090910461ffff16945092505050565b6006546001600160a01b031690565b33611bd9611bc1565b6001600160a01b031614611bff5760405162461bcd60e51b8152600401610bb29061434f565b60118054821515600160a81b0260ff60a81b199091161790556040517f6be482a1cd377fd2826c8595999d17e99efc268068d18fbd2ebab94c060f2b7890610ff590831515815260200190565b33611c55611bc1565b6001600160a01b031614611c7b5760405162461bcd60e51b8152600401610bb29061434f565b8051611c8e906010906020840190613b21565b507f5ca9f750836b0b7efdace104f07b5c9f0df0650c0fd24f5163e99044ae36ea5281604051610ff59190614212565b606060018054610ac7906145b8565b3342611ce08366c3663566a58000614556565b3414611cfe5760405162461bcd60e51b8152600401610bb29061440a565b813b63ffffffff1615611d235760405162461bcd60e51b8152600401610bb2906142ae565b80601b54108015611d355750601c5481105b611d815760405162461bcd60e51b815260206004820181905260248201527f42617365546f6b656e3a2050726573616c65206973206e6f74206163746976656044820152606401610bb2565b60046001600160a01b0383166000908152601d6020526040902054611da790859061443f565b1115611e105760405162461bcd60e51b815260206004820152603260248201527f42617365546f6b656e3a20416d6f756e74206f6620746f6b656e7320657863656044820152716564732070726573616c65206c696d69747360701b6064820152608401610bb2565b6001600160a01b0382166000908152601d6020526040902054611e3490849061443f565b6001600160a01b0383166000908152601d602052604090205560165483600f54611e5e919061443f565b1115611eca5760405162461bcd60e51b815260206004820152604160248201526000805160206146ca83398151915260448201527f6e73207468616e20746865206d617850726573616c65546f74616c537570706c6064820152607960f81b608482015260a401610bb2565b6001600160a01b038083166000908152601e60205260409020805460ff19166001179055601254166108fc611efe60145490565b611f089086614556565b6040518115909202916000818181858888f19350505050158015611f30573d6000803e3d6000fd5b50611f3d84846001612e47565b50505050565b6001600160a01b038216331415611f985760405162461bcd60e51b815260206004820152601960248201527822a9219b99189d1030b8383937bb32903a379031b0b63632b960391b6044820152606401610bb2565b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6120168167013fbe85edc90000614556565b34146120345760405162461bcd60e51b8152600401610bb29061440a565b3342813b63ffffffff161561205b5760405162461bcd60e51b8152600401610bb2906142ae565b601654600f5410156120d557601a54811180156120795750601a5415155b6120d55760405162461bcd60e51b815260206004820152602760248201527f42617365546f6b656e3a204d61696e2073616c65206861736e277420737461726044820152661d1959081e595d60ca1b6064820152608401610bb2565b60155483600f546120e6919061443f565b11156121455760405162461bcd60e51b815260206004820152603a60248201526000805160206146ca8339815191526044820152796e73207468616e20746865206d6178546f74616c537570706c7960301b6064820152608401610bb2565b6001600160a01b0382166000908152601e60205260409020805460ff19166001179055600d8311156121cb5760405162461bcd60e51b815260206004820152602960248201527f42617365546f6b656e3a2043616e6e6f7420627579206d6f726520746f6b656e60448201526873207468616e20313360b81b6064820152608401610bb2565b6012546001600160a01b03166108fc6121e360135490565b6121ed9086614556565b6040518115909202916000818181858888f19350505050158015612215573d6000803e3d6000fd5b50611f3d84846000612e47565b61222c3383612c9e565b6122485760405162461bcd60e51b8152600401610bb290614384565b611f3d84848484612fa5565b606061225f8261281a565b6122ba5760405162461bcd60e51b815260206004820152602660248201527f42617369733a2055524920717565727920666f72206e6f6e6578697374656e74604482015265103a37b5b2b760d11b6064820152608401610bb2565b600e6122c583612fd8565b6040516020016122d692919061401f565b6040516020818303038152906040529050919050565b60006122fa878786866130d5565b90506123106001600160a01b038816828461294f565b61232c5760405162461bcd60e51b8152600401610bb2906143d5565b83421061234b5760405162461bcd60e51b8152600401610bb290614306565b6001600160a01b0387166000908152600d60209081526040808320898452909152812080549161237a836145f3565b91905055506000600a54600954856123929190614556565b61239c9190614457565b9050801561245157600b54600c546040516323b872dd60e01b81526000926001600160a01b03908116926323b872dd926123de928e921690879060040161410b565b602060405180830381600087803b1580156123f857600080fd5b505af115801561240c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124309190613ec4565b90508061244f5760405162461bcd60e51b8152600401610bb290614225565b505b600b546000906001600160a01b03166323b872dd8a33612471868a614575565b6040518463ffffffff1660e01b815260040161248f9392919061410b565b602060405180830381600087803b1580156124a957600080fd5b505af11580156124bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124e19190613ec4565b9050806125005760405162461bcd60e51b8152600401610bb290614225565b61250b338a8a612a9b565b7fc449542e187835de02e1b181e93b2267fd8592c5728e4b347834a6711b51ccb3338a8a8860405161124b9493929190614162565b33612549611bc1565b6001600160a01b03161461256f5760405162461bcd60e51b8152600401610bb29061434f565b60168190556040518181527f5e09940833ef8cddfdf303c21eaf750609d4b8f504e093c69c4591594e8e6e9b90602001610ff5565b601080546125b1906145b8565b80601f01602080910402602001604051908101604052809291908181526020018280546125dd906145b8565b801561262a5780601f106125ff5761010080835404028352916020019161262a565b820191906000526020600020905b81548152906001019060200180831161260d57829003601f168201915b505050505081565b60075460405163c455279160e01b81526000916001600160a01b038085169291169063c4552791906126689087906004016140f7565b60206040518083038186803b15801561268057600080fd5b505afa158015612694573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126b89190613f1b565b6001600160a01b031614156126cf57506001610ab2565b6001600160a01b0380841660009081526005602090815260408083209386168352929052205460ff165b9392505050565b33612709611bc1565b6001600160a01b03161461272f5760405162461bcd60e51b8152600401610bb29061434f565b600c80546001600160a01b0319166001600160a01b0383161790556040517fcb7ef3e545f5cdb893f5c568ba710fe08f336375a2d9fd66e161033f8fc09ef390610ff59083906140f7565b33612783611bc1565b6001600160a01b0316146127a95760405162461bcd60e51b8152600401610bb29061434f565b6001600160a01b03811661280e5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610bb2565b61281781613134565b50565b6000908152600260205260409020546001600160a01b0316151590565b600081815260046020526040902080546001600160a01b0319166001600160a01b038416908117909155819061286c82611960565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6001600160a01b038581166000818152600d6020908152604080832088845282528083205481517f5a3ac364254bf8141cade7fc83e6b4ac37b75f1d4df26a245ef4a174edfe2593938101939093529082019390935292871660608401526080830186905260a083019190915260c0820184905260e082018390529061294590610100015b60405160208183030381529060405280519060200120613186565b9695505050505050565b600080600061295e85856131d4565b909250905060008160048111156129775761297761464e565b1480156129955750856001600160a01b0316826001600160a01b0316145b156129a5576001925050506126f9565b600080876001600160a01b0316631626ba7e60e01b88886040516024016129cd9291906141f9565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b0319909416939093179092529051612a0b9190614003565b600060405180830381855afa9150503d8060008114612a46576040519150601f19603f3d011682016040523d82523d6000602084013e612a4b565b606091505b5091509150818015612a5e575080516020145b8015612a8f57508051630b135d3f60e11b90612a839083016020908101908401613efe565b6001600160e01b031916145b98975050505050505050565b826001600160a01b0316612aae82611960565b6001600160a01b031614612b165760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610bb2565b6001600160a01b038216612b785760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610bb2565b612b83838383613244565b612b8e600082612837565b6001600160a01b0383166000908152600360205260408120805460019290612bb7908490614575565b90915550506001600160a01b0382166000908152600360205260408120805460019290612be590849061443f565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716916000805160206146ea83398151915291a4505050565b6001600160a01b0384166000908152600d602090815260408083208684528252808320549051612c939261292a927f8cbb7530fdede89f5d16a7ee48153cff90c0b84c0b3fa0c3f178a5ddfda170b2928a928a92918a918a91016141c8565b90505b949350505050565b6000612ca98261281a565b612d0a5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610bb2565b6000612d1583611960565b9050806001600160a01b0316846001600160a01b03161480612d505750836001600160a01b0316612d4584610b4a565b6001600160a01b0316145b80612c965750612c968185612632565b60008111612dc65760405162461bcd60e51b815260206004820152602d60248201527f576974686472617761626c653a20416d6f756e742068617320746f206265206760448201526c0726561746572207468616e203609c1b6064820152608401610bb2565b47811115612e165760405162461bcd60e51b815260206004820152601e60248201527f576974686472617761626c653a204e6f7420656e6f7567682066756e647300006044820152606401610bb2565b604051339082156108fc029083906000818181858888f19350505050158015612e43573d6000803e3d6000fd5b5050565b600082600f54612e57919061443f565b600f549091504290600090612e6d90600161443f565b90505b828111612f3d57612e818682613377565b600080600080612e90856134a3565b93509350935093508715612ee4577fbfa75414001e9f18f76ea01e8b52acc9ae8ff8e884c128ecfda326b56017ebb28a8686868686604051612ed79695949392919061418b565b60405180910390a1612f26565b7f9691906fc1ed21f220add64ba737c8c97d22656f6dc9f0dbfcb2a6cfabae4e708a8686868686604051612f1d9695949392919061418b565b60405180910390a15b505050508080612f35906145f3565b915050612e70565b5083600f6000828254612f50919061443f565b9091555050601554600f541415612f9e576011805460ff60b01b1916600160b01b1790556040517f52df9fe5b9c9a7b0b4fdc2c9f89387959e35e4209c2a8d133a2b8165edad2a0490600090a15b5050505050565b612fb0848484612a9b565b612fbc84848484613812565b611f3d5760405162461bcd60e51b8152600401610bb29061425c565b606081612ffc5750506040805180820190915260018152600360fc1b602082015290565b8160005b81156130265780613010816145f3565b915061301f9050600a83614457565b9150613000565b6000816001600160401b038111156130405761304061467a565b6040519080825280601f01601f19166020018201604052801561306a576020820181803683370190505b5090505b8415612c965761307f600183614575565b915061308c600a8661460e565b61309790603061443f565b60f81b8183815181106130ac576130ac614664565b60200101906001600160f81b031916908160001a9053506130ce600a86614457565b945061306e565b6001600160a01b0384166000908152600d602090815260408083208684528252808320549051612c939261292a927f2feec0009bd50e41c6079eeb85f264c8fb21147d30736dbaae14aa7936f4559f928a928a92918a918a91016141c8565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000610ab261319361391c565b8360405161190160f01b6020820152602281018390526042810182905260009060620160405160208183030381529060405280519060200120905092915050565b60008082516041141561320b5760208301516040840151606085015160001a6131ff87828585613a0f565b9450945050505061323d565b825160401415613235576020830151604084015161322a868383613af2565b93509350505061323d565b506000905060025b9250929050565b601154600160a81b900460ff16806132e75750601154600160a01b900460ff1680156132e75750601154604051633a090bb360e11b8152600481018390526001600160a01b039091169063741217669060240160206040518083038186803b1580156132af57600080fd5b505afa1580156132c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132e79190613ec4565b15610ce3576001600160a01b03831615610ce35760405162461bcd60e51b815260206004820152604560248201527f436f6d62696e61626c65546f6b656e42617369733a20536f7272792c2069742060448201527f69732070726f6869626974656420746f207472616e73666572204261736520746064820152646f6b656e7360d81b608482015260a401610bb2565b6001600160a01b0382166133cd5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610bb2565b6133d68161281a565b156134225760405162461bcd60e51b815260206004820152601c60248201527b115490cdcc8c4e881d1bdad95b88185b1c9958591e481b5a5b9d195960221b6044820152606401610bb2565b61342e60008383613244565b6001600160a01b038216600090815260036020526040812080546001929061345790849061443f565b909155505060008181526002602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392906000805160206146ea833981519152908290a45050565b6040805160808101825260008082526020820181905291810182905260608101829052819081908190429044904390600189116134e05783613515565b60186134ed60028b614575565b815481106134fd576134fd614664565b6000918252602090912001546301000000900461ffff165b60196000828254613526919061443f565b90915550506019546040516006916135489185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c61356b919061460e565b6135769060026144ae565b60ff1681526001891161358957836135bc565b601861359660028b614575565b815481106135a6576135a6614664565b60009182526020909120015462010000900460ff165b601960008282546135cd919061443f565b90915550506019546040516006916135ef9185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c613612919061460e565b61361d9060026144ae565b60ff166020820152600189116136335783613660565b601861364060028b614575565b8154811061365057613650614664565b60009182526020909120015460ff165b60196000828254613671919061443f565b90915550506019546040516004916136939185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c6136b6919061460e565b6136c19060026144ae565b60ff166040820152600189116136d75783613709565b60186136e460028b614575565b815481106136f4576136f4614664565b600091825260209091200154610100900460ff165b6019600082825461371a919061443f565b9091555050601954604051600d9161373c9185918891889133916020016140c6565b6040516020818303038152906040528051906020012060001c61375f919061460e565b61376a9060026144ae565b61ffff908116606083019081526018805460018101825560009190915283517fb13d2d76d1f4b7be834882e410b3e3a8afaf69f83600ae24db354391d2378d2e90910180546020860151604090960151935194851663010000000264ffff0000001960ff80871662010000029190911664ffffff000019828a166101000261ffff19909516928716929092179390931716919091171790559b929a5098509650945050505050565b60006001600160a01b0384163b1561391457604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061385690339089908890889060040161412f565b602060405180830381600087803b15801561387057600080fd5b505af19250505080156138a0575060408051601f3d908101601f1916820190925261389d91810190613efe565b60015b6138fa573d8080156138ce576040519150601f19603f3d011682016040523d82523d6000602084013e6138d3565b606091505b5080516138f25760405162461bcd60e51b8152600401610bb29061425c565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612c96565b506001612c96565b60007f000000000000000000000000000000000000000000000000000000000000000146141561396b57507f8890a638ca12fcd6c7d1c60cf7dcceac7bab089bb17bd96add5adfc2ad623e7a90565b50604080517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f6020808301919091527f361673da4fd572f7a9a4d7862b40e269f3bb0620952faba0f5d083cc715e0cb1828401527f06c015bd22b4c69690933c1058878ebdfef31f9aaae40bbe86d8a09fe1b2972c60608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b6000806fa2a8918ca85bafe22016d0b997e4df60600160ff1b03831115613a3c5750600090506003613ae9565b8460ff16601b14158015613a5457508460ff16601c14155b15613a655750600090506004613ae9565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa158015613ab9573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613ae257600060019250925050613ae9565b9150600090505b94509492505050565b6000806001600160ff1b03831660ff84901c601b01613b1387828885613a0f565b935093505050935093915050565b828054613b2d906145b8565b90600052602060002090601f016020900481019282613b4f5760008555613b95565b82601f10613b6857805160ff1916838001178555613b95565b82800160010185558215613b95579182015b82811115613b95578251825591602001919060010190613b7a565b50613ba1929150613ba5565b5090565b5b80821115613ba15760008155600101613ba6565b60006001600160401b0380841115613bd457613bd461467a565b604051601f8501601f19908116603f01168101908282118183101715613bfc57613bfc61467a565b81604052809350858152868686011115613c1557600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613c4057600080fd5b6126f983833560208501613bba565b600060208284031215613c6157600080fd5b81356126f981614690565b60008060408385031215613c7f57600080fd5b8235613c8a81614690565b91506020830135613c9a81614690565b809150509250929050565b600080600060608486031215613cba57600080fd5b8335613cc581614690565b92506020840135613cd581614690565b929592945050506040919091013590565b60008060008060808587031215613cfc57600080fd5b8435613d0781614690565b93506020850135613d1781614690565b92506040850135915060608501356001600160401b03811115613d3957600080fd5b613d4587828801613c2f565b91505092959194509250565b600080600080600080600060e0888a031215613d6c57600080fd5b8735613d7781614690565b96506020880135613d8781614690565b955060408801359450606088013593506080880135925060a0880135915060c08801356001600160401b03811115613dbe57600080fd5b613dca8a828b01613c2f565b91505092959891949750929550565b60008060408385031215613dec57600080fd5b8235613df781614690565b91506020830135613c9a816146a5565b60008060408385031215613e1a57600080fd5b8235613e2581614690565b946020939093013593505050565b60008060008060008060c08789031215613e4c57600080fd5b8635613e5781614690565b95506020870135945060408701359350606087013592506080870135915060a08701356001600160401b03811115613e8e57600080fd5b613e9a89828a01613c2f565b9150509295509295509295565b600060208284031215613eb957600080fd5b81356126f9816146a5565b600060208284031215613ed657600080fd5b81516126f9816146a5565b600060208284031215613ef357600080fd5b81356126f9816146b3565b600060208284031215613f1057600080fd5b81516126f9816146b3565b600060208284031215613f2d57600080fd5b81516126f981614690565b600060208284031215613f4a57600080fd5b81356001600160401b03811115613f6057600080fd5b8201601f81018413613f7157600080fd5b612c9684823560208401613bba565b600060208284031215613f9257600080fd5b5035919050565b60008060408385031215613fac57600080fd5b50508035926020909101359150565b60008151808452613fd381602086016020860161458c565b601f01601f19169290920160200192915050565b60008151613ff981856020860161458c565b9290920192915050565b6000825161401581846020870161458c565b9190910192915050565b600080845481600182811c91508083168061403b57607f831692505b602080841082141561405b57634e487b7160e01b86526022600452602486fd5b81801561406f5760018114614080576140ad565b60ff198616895284890196506140ad565b60008b81526020902060005b868110156140a55781548b82015290850190830161408c565b505084890196505b5050505050506140bd8185613fe7565b95945050505050565b94855260208501939093526040840191909152606090811b6001600160601b03191690830152607482015260940190565b6001600160a01b0391909116815260200190565b6001600160a01b039384168152919092166020820152604081019190915260600190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061294590830184613fbb565b6001600160a01b0394851681529290931660208301526040820152606081019190915260800190565b6001600160a01b03969096168652602086019490945260ff9283166040860152908216606085015216608083015261ffff1660a082015260c00190565b9586526001600160a01b0394909416602086015260408501929092526060840152608083015260a082015260c00190565b828152604060208201526000612c966040830184613fbb565b6020815260006126f96020830184613fbb565b6020808252601e908201527f45524337323142757961626c653a207472616e73666572206661696c65640000604082015260600190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526038908201527f42617365546f6b656e3a20796f75206861766520746f2062652061207065727360408201527737b7103a379031b0b636103a3434b990333ab731ba34b7b760411b606082015260800190565b60208082526029908201527f45524337323142757961626c653a207369676e6564207472616e73616374696f6040820152681b88195e1c1a5c995960ba1b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252818101527f45524337323142757961626c653a20496e76616c6964207369676e6174757265604082015260600190565b6020808252818101527f42617365546f6b656e3a2074782076616c756520697320746f6f20736d616c6c604082015260600190565b6000821982111561445257614452614622565b500190565b60008261446657614466614638565b500490565b600181815b808511156144a657816000190482111561448c5761448c614622565b8085161561449957918102915b93841c9390800290614470565b509250929050565b60006126f983836000826144c457506001610ab2565b816144d157506000610ab2565b81600181146144e757600281146144f15761450d565b6001915050610ab2565b60ff84111561450257614502614622565b50506001821b610ab2565b5060208310610133831016604e8410600b8410161715614530575081810a610ab2565b61453a838361446b565b806000190482111561454e5761454e614622565b029392505050565b600081600019048311821515161561457057614570614622565b500290565b60008282101561458757614587614622565b500390565b60005b838110156145a757818101518382015260200161458f565b83811115611f3d5750506000910152565b600181811c908216806145cc57607f821691505b602082108114156145ed57634e487b7160e01b600052602260045260246000fd5b50919050565b600060001982141561460757614607614622565b5060010190565b60008261461d5761461d614638565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461281757600080fd5b801515811461281757600080fd5b6001600160e01b03198116811461281757600080fdfe42617365546f6b656e3a2043616e6e6f74206d696e74206d6f726520746f6b65ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa264697066735822122021d4bfb10022e90a0e77661b63b917ee2367671d92e8bcc50741cc1c9d3fd04f64736f6c63430008060033

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

000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c100000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2000000000000000000000000000000000000000000000000000000000000001745766f6c7574696f6e20506c6179696e67204361726473000000000000000000000000000000000000000000000000000000000000000000000000000000000545564f5043000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002768747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f626173656e66742f000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000043697066733a2f2f45564f50433131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131312f0000000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _proxyRegistry (address): 0xa5409ec958C83C3f309868babACA7c86DCB077c1
Arg [1] : _name (string): Evolution Playing Cards
Arg [2] : _symbol (string): EVOPC
Arg [3] : _baseURI (string): https://evopc.trophyhunters.io/basenft/
Arg [4] : _contractURI (string): ipfs://EVOPC111111111111111111111111111111111111111111111111111111/
Arg [5] : _paymentToken (address): 0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2

-----Encoded View---------------
17 Constructor Arguments found :
Arg [0] : 000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000c0
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000100
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [4] : 00000000000000000000000000000000000000000000000000000000000001a0
Arg [5] : 000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc2
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000017
Arg [7] : 45766f6c7574696f6e20506c6179696e67204361726473000000000000000000
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [9] : 45564f5043000000000000000000000000000000000000000000000000000000
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000027
Arg [11] : 68747470733a2f2f65766f70632e74726f70687968756e746572732e696f2f62
Arg [12] : 6173656e66742f00000000000000000000000000000000000000000000000000
Arg [13] : 0000000000000000000000000000000000000000000000000000000000000043
Arg [14] : 697066733a2f2f45564f50433131313131313131313131313131313131313131
Arg [15] : 3131313131313131313131313131313131313131313131313131313131313131
Arg [16] : 31312f0000000000000000000000000000000000000000000000000000000000


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.