ETH Price: $3,386.74 (+1.42%)

Token

Farmverse (FARM)
 

Overview

Max Total Supply

4,445 FARM

Holders

615

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
5 FARM
0x67348faa08c2aa475bf61c0717739654879636cd
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:
Farmverse

Compiler Version
v0.8.9+commit.e5eed63a

Optimization Enabled:
Yes with 800 runs

Other Settings:
default evmVersion
File 1 of 18 : Farmverse.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.4;

/// @title The Farmverse
/// @author MilkyTaste @ Ao Collaboration Ltd.
/// https://thefarmverse.app

import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";
import "./ERC721Ao.sol";
import "./Payable.sol";

contract Farmverse is ERC721Ao, Payable {
    using Strings for uint256;

    uint256 public tokenPrice = 0.0088 ether;

    // Token values incremented for gas efficiency
    uint16 private maxSalePlusOne = 4445;
    uint16 private constant MAX_PER_TRANS = 5;

    // Presale
    bytes32 public merkleRoot = "";

    // State
    bool public saleActive = false;

    string public baseURI;
    string public placeholderURI;

    constructor() ERC721Ao("Farmverse", "FARM") Payable() {}

    //
    // Modifiers
    //

    /**
     * Ensure sale is active.
     */
    modifier isSaleActive() {
        require(saleActive, "Farmverse: Invalid state");
        _;
    }

    /**
     * Ensure amount of tokens to mint is within the transaction limit.
     */
    modifier correctPrice(uint16 numTokens) {
        require(msg.value == tokenPrice * numTokens, "Farmverse: Invalid Ether value");
        _;
    }

    /**
     * Ensure amount of tokens to mint is within the limit.
     */
    modifier withinMintLimit(uint16 numTokens) {
        require((_totalMinted() + numTokens) < maxSalePlusOne, "Farmverse: Exceeds available tokens");
        _;
    }

    //
    // Minting
    //

    /**
     * Mint tokens during the public sale.
     * @param numTokens Number of tokens to mint.
     */
    function mintPublic(uint16 numTokens)
        external
        payable
        isSaleActive
        withinMintLimit(numTokens)
        correctPrice(numTokens)
    {
        require(numTokens <= MAX_PER_TRANS, "Farmverse: Exceeds transaction limit");
        _safeMint(msg.sender, numTokens);
    }

    /**
     * Mint tokens when farmlisted.
     * @param numTokens Number of tokens to mint.
     * @param proof The Merkle proof used to validate the leaf is in the root.
     */
    function mintFarmlist(uint16 numTokens, bytes32[] calldata proof)
        external
        payable
        isSaleActive
        withinMintLimit(numTokens)
        correctPrice(numTokens)
    {
        require(numTokens <= MAX_PER_TRANS * 2, "Farmverse: Exceeds transaction limit");
        bytes32 leaf = keccak256(abi.encode(msg.sender));
        require(verify(merkleRoot, leaf, proof), "Farmverse: Not a valid proof");
        _safeMint(msg.sender, numTokens);
    }

    /**
     * Mints reserved tokens.
     * @param numTokens Number of tokens to mint.
     * @param mintTo Address to mint tokens to.
     */
    function mintReserved(uint16 numTokens, address mintTo) external onlyOwner withinMintLimit(numTokens) {
        _safeMint(mintTo, numTokens);
    }

    //
    // Admin
    //

    /**
     * Toggle the sale active state.
     */
    function toggleSaleActive() external onlyOwner {
        saleActive = !saleActive;
    }

    /**
     * Update token price.
     * @param tokenPrice_ The new price per token.
     */
    function setTokenPrice(uint256 tokenPrice_) external onlyOwner {
        tokenPrice = tokenPrice_;
    }

    /**
     * Update maximum number of tokens for sale.
     * @param maxSale The new maximum number of tokens for sale.
     */
    function setMaxSale(uint16 maxSale) external onlyOwner {
        maxSalePlusOne = maxSale + 1;
    }

    /**
     * Set the presale Merkle root.
     * @param merkleRoot_ The new merkle root.
     */
    function setMerkleRoot(bytes32 merkleRoot_) external onlyOwner {
        merkleRoot = merkleRoot_;
    }

    /**
     * Sets base URI.
     * @param baseURI_ The new base URI.
     * @dev Only use this method after sell out as it will leak unminted token data.
     */
    function setBaseURI(string memory baseURI_) external onlyOwner {
        baseURI = baseURI_;
    }

    function _baseURI() internal view virtual override returns (string memory) {
        return baseURI;
    }

    /**
     * Sets placeholder URI.
     * @param placeholderURI_ The new placeholder URI.
     */
    function setPlaceholderURI(string memory placeholderURI_) external onlyOwner {
        placeholderURI = placeholderURI_;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(uint16(tokenId)), "ERC721Metadata: URI query for nonexistent token");

        string memory uri = _baseURI();
        return bytes(uri).length > 0 ? string(abi.encodePacked(uri, tokenId.toString(), ".json")) : placeholderURI;
    }

    /**
     * @dev Return sale claim info.
     * saleClaims[0]: maxSale (total available tokens)
     * saleClaims[1]: totalSupply
     * saleClaims[2]: tokenPrice
     */
    function saleClaims() public view virtual returns (uint256[3] memory) {
        return [maxSalePlusOne - 1, totalSupply(), tokenPrice];
    }

    /// @inheritdoc	ERC165
    function supportsInterface(bytes4 interfaceId) public view override(ERC721Ao, ERC2981) returns (bool) {
        return ERC721Ao.supportsInterface(interfaceId) || ERC2981.supportsInterface(interfaceId);
    }

    /**
     * Verify the Merkle proof is valid.
     * @param root The Merkle root. Use the value stored in the contract
     * @param leaf The leaf.
     * @param proof The Merkle proof used to validate the leaf is in the root
     */
    function verify(
        bytes32 root,
        bytes32 leaf,
        bytes32[] memory proof
    ) public pure returns (bool) {
        return MerkleProof.verify(proof, root, leaf);
    }
}

File 2 of 18 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.0;

/**
 * @dev These functions deal with verification of Merkle Trees proofs.
 *
 * The proofs can be generated using the JavaScript library
 * https://github.com/miguelmota/merkletreejs[merkletreejs].
 * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled.
 *
 * See `test/utils/cryptography/MerkleProof.test.js` for some examples.
 */
library MerkleProof {
    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    function verify(
        bytes32[] memory proof,
        bytes32 root,
        bytes32 leaf
    ) internal pure returns (bool) {
        return processProof(proof, leaf) == root;
    }

    /**
     * @dev Returns the rebuilt hash obtained by traversing a Merklee tree up
     * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt
     * hash matches the root of the tree. When processing the proof, the pairs
     * of leafs & pre-images are assumed to be sorted.
     *
     * _Available since v4.4._
     */
    function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            bytes32 proofElement = proof[i];
            if (computedHash <= proofElement) {
                // Hash(current computed hash + current element of the proof)
                computedHash = keccak256(abi.encodePacked(computedHash, proofElement));
            } else {
                // Hash(current element of the proof + current computed hash)
                computedHash = keccak256(abi.encodePacked(proofElement, computedHash));
            }
        }
        return computedHash;
    }
}

File 3 of 18 : ERC721Ao.sol
// SPDX-License-Identifier: MIT
/// @author Chiru Labs
/// @author Optimisations by MilkyTaste#8662 @MilkyTasteEth https://milkytaste.xyz

pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import "@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol";
import "@openzeppelin/contracts/utils/Address.sol";
import "@openzeppelin/contracts/utils/Context.sol";
import "@openzeppelin/contracts/utils/Strings.sol";
import "@openzeppelin/contracts/utils/introspection/ERC165.sol";

error ApprovalCallerNotOwnerNorApproved();
error ApprovalQueryForNonexistentToken();
error ApproveToCaller();
error ApprovalToCurrentOwner();
error BalanceQueryForZeroAddress();
error MintToZeroAddress();
error MintZeroQuantity();
error OwnerQueryForNonexistentToken();
error OwnerQueryForNotExplicitlySet();
error TokenIndexOutOfBounds();
error TransferCallerNotOwnerNorApproved();
error TransferFromIncorrectOwner();
error TransferToNonERC721ReceiverImplementer();
error TransferToZeroAddress();
error URIQueryForNonexistentToken();

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension. Built to optimize for lower gas during batch mints.
 *
 * Assumes serials are sequentially minted starting at _startTokenId() (defaults to 0, e.g. 0, 1, 2, 3..).
 *
 * Assumes that the maximum token id cannot exceed 2**16 - 1 (max value of uint16).
 *
 * This contract has been further optimised for gas efficiency during minting and transfers.
 * This impacts read functions like `balanceOf`.
 * Instead use `explicitOwnerOf` passing in a `tokenId` that the user explicitly owns.
 */
contract ERC721Ao is Context, ERC165, IERC721, IERC721Metadata, IERC721Enumerable {
    using Address for address;
    using Strings for uint256;

    // Compiler will pack this into a single 256bit word.
    struct TokenOwnership {
        // The address of the owner.
        address addr;
        // Keeps track of the start time of ownership with minimal overhead for tokenomics.
        uint64 startTimestamp;
        // Whether the token has been burned.
        bool burned;
    }

    // The tokenId of the next token to be minted.
    uint16 internal _currentIndex;

    // The number of tokens burned.
    uint16 internal _burnCounter;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

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

    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
        _currentIndex = _startTokenId();
    }

    /**
     * To change the starting tokenId, please override this function.
     */
    function _startTokenId() internal view virtual returns (uint16) {
        return 0;
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     * @dev Burned tokens are calculated here, use _totalMinted() if you want to count just minted tokens.
     */
    function totalSupply() public view returns (uint256) {
        // Counter underflow is impossible as _burnCounter cannot be incremented
        // more than _currentIndex - _startTokenId() times
        unchecked {
            return _currentIndex - _burnCounter - _startTokenId();
        }
    }

    /**
     * @dev An extension of enumerable.
     * @notice Use this method to get a list of all tokens owned by a given address.
     */
    function tokensOfOwner(address addr) external view returns (uint256[] memory) {
        uint256 balance = balanceOf(addr);
        if (balance == 0) {
            return new uint256[](0);
        }
        uint256[] memory tokenIds = new uint256[](balance);
        uint256 counter = 0;
        for (uint16 tokenId = _startTokenId(); tokenId < _currentIndex; tokenId++) {
            if (!_ownerships[tokenId].burned && ownerOf(tokenId) == addr) {
                tokenIds[counter] = tokenId;
                counter++;
                if (counter == balance) {
                    return tokenIds;
                }
            }
        }
        revert TokenIndexOutOfBounds();
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address addr, uint256 index) external view returns (uint256) {
        uint256 counter = 0;
        for (uint16 tokenId = _startTokenId(); tokenId < _currentIndex; tokenId++) {
            if (!_ownerships[tokenId].burned && ownerOf(tokenId) == addr) {
                if (counter == index) {
                    return tokenId;
                }
                counter++;
            }
        }
        revert TokenIndexOutOfBounds();
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) external view returns (uint256) {
        // We have to iterate to exclude burned tokens
        uint256 counter = 0;
        for (uint16 tokenId = _startTokenId(); tokenId < _currentIndex; tokenId++) {
            if (_ownerships[tokenId].burned == false) {
                if (counter == index) {
                    return tokenId;
                }
                counter++;
            }
        }
        revert TokenIndexOutOfBounds();
    }

    /**
     * Returns the total amount of tokens minted in the contract.
     */
    function _totalMinted() internal view returns (uint16) {
        // Counter underflow is impossible as _currentIndex does not decrement,
        // and it is initialized to _startTokenId()
        unchecked {
            return _currentIndex - _startTokenId();
        }
    }

    /**
     * @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}.
     * @dev This is NOT gas efficient.
     * @dev Highly recommend NOT integrating to this function into other contract's write functions.
     * @dev Use `explicitOwnerOf(id) == owner` instead.
     */
    function balanceOf(address owner) public view override returns (uint256) {
        if (owner == address(0)) revert BalanceQueryForZeroAddress();
        uint16 owned = 0;
        // Loop through tokens to find the owner
        for (uint16 i = _startTokenId(); i < _currentIndex; i++) {
            if (ownerOf(i) == owner) {
                owned++;
            }
        }
        return owned;
    }

    /**
     * Gas spent here starts off proportional to the maximum mint batch size.
     * It gradually moves to O(1) as tokens get transferred around in the collection over time.
     */
    function ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) {
        uint16 curr = uint16(tokenId);

        unchecked {
            if (_startTokenId() <= curr && curr < _currentIndex) {
                TokenOwnership memory ownership = _ownerships[curr];
                if (!ownership.burned) {
                    if (ownership.addr != address(0)) {
                        return ownership;
                    }
                    // Invariant:
                    // There will always be an ownership that has an address and is not burned
                    // before an ownership that does not have an address and is not burned.
                    // Hence, curr will not underflow.
                    while (true) {
                        curr--;
                        ownership = _ownerships[curr];
                        if (ownership.addr != address(0)) {
                            return ownership;
                        }
                    }
                }
            }
        }
        revert OwnerQueryForNonexistentToken();
    }

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

    /**
     * Check the explicitly set ownership of a token.
     * @notice This reverts of the token owner is 0x0.
     * @notice This does not indicate the token is unowned, only that the ownership is not explicitly recorded.
     * @dev Use this method as a gas optimised version of `ownerOf`.
     * @dev Be sure the `tokenId` used has the ownership explicitly set.
     * @param tokenId The tokenId to be checked.
     */
    function explicitOwnerOf(uint256 tokenId) public view returns (address) {
        TokenOwnership memory ownership = _ownerships[uint16(tokenId)];
        if (ownership.burned) revert OwnerQueryForNonexistentToken();
        if (ownership.addr == address(0)) revert OwnerQueryForNotExplicitlySet();
        return ownership.addr;
    }

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

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

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        if (!_exists(uint16(tokenId))) revert URIQueryForNonexistentToken();

        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 override {
        address owner = ownerOf(tokenId);
        if (to == owner) revert ApprovalToCurrentOwner();

        if (_msgSender() != owner && !isApprovedForAll(owner, _msgSender())) {
            revert ApprovalCallerNotOwnerNorApproved();
        }

        _approve(to, uint16(tokenId), owner);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view override returns (address) {
        uint16 tokenId16 = uint16(tokenId);
        if (!_exists(tokenId16)) revert ApprovalQueryForNonexistentToken();

        return _tokenApprovals[tokenId16];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public override {
        if (operator == _msgSender()) revert ApproveToCaller();

        _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 {
        _transfer(from, to, uint16(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 {
        _transfer(from, to, uint16(tokenId));
        if (to.isContract() && !_checkContractOnERC721Received(from, to, tokenId, _data)) {
            revert TransferToNonERC721ReceiverImplementer();
        }
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     */
    function _exists(uint16 tokenId) internal view returns (bool) {
        return _startTokenId() <= tokenId && tokenId < _currentIndex && !_ownerships[tokenId].burned;
    }

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

    /**
     * @dev Safely mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received},
     *   which is called for each safe transfer.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(
        address to,
        uint16 quantity,
        bytes memory _data
    ) internal {
        _mint(to, quantity, _data, true);
    }

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event.
     */
    function _mint(
        address to,
        uint16 quantity,
        bytes memory _data,
        bool safe
    ) internal {
        uint16 startTokenId = _currentIndex;
        if (to == address(0)) revert MintToZeroAddress();
        if (quantity == 0) revert MintZeroQuantity();

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

        // Overflows are incredibly unrealistic.
        // updatedIndex overflows if _currentIndex + quantity > 65,535 (2**16) - 1
        unchecked {
            _ownerships[startTokenId].addr = to;
            _ownerships[startTokenId].startTimestamp = uint64(block.timestamp);

            uint16 updatedIndex = startTokenId;
            uint16 end = updatedIndex + quantity;

            if (safe && to.isContract()) {
                do {
                    emit Transfer(address(0), to, updatedIndex);
                    if (!_checkContractOnERC721Received(address(0), to, updatedIndex++, _data)) {
                        revert TransferToNonERC721ReceiverImplementer();
                    }
                } while (updatedIndex != end);
                // Reentrancy protection
                if (_currentIndex != startTokenId) revert();
            } else {
                do {
                    emit Transfer(address(0), to, updatedIndex++);
                } while (updatedIndex != end);
            }
            _currentIndex = updatedIndex;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

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

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

        if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved();
        if (prevOwnership.addr != from) revert TransferFromIncorrectOwner();
        if (to == address(0)) revert TransferToZeroAddress();

        _beforeTokenTransfers(from, to, tokenId, 1);

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

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**16.
        unchecked {
            _ownerships[tokenId].addr = to;
            _ownerships[tokenId].startTimestamp = uint64(block.timestamp);

            // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint16 nextTokenId = tokenId + 1;
            if (_ownerships[nextTokenId].addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId < _currentIndex) {
                    _ownerships[nextTokenId].addr = prevOwnership.addr;
                    _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

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

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint16 tokenId) internal virtual {
        TokenOwnership memory prevOwnership = ownershipOf(tokenId);

        _beforeTokenTransfers(prevOwnership.addr, address(0), tokenId, 1);

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

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as tokenId would have to be 2**16.
        unchecked {
            // Keep track of who burned the token, and the timestamp of burning.
            _ownerships[tokenId].addr = prevOwnership.addr;
            _ownerships[tokenId].startTimestamp = uint64(block.timestamp);
            _ownerships[tokenId].burned = true;

            // If the ownership slot of tokenId+1 is not explicitly set, that means the burn initiator owns it.
            // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls.
            uint16 nextTokenId = tokenId + 1;
            if (_ownerships[nextTokenId].addr == address(0)) {
                // This will suffice for checking _exists(nextTokenId),
                // as a burned slot cannot contain the zero address.
                if (nextTokenId < _currentIndex) {
                    _ownerships[nextTokenId].addr = prevOwnership.addr;
                    _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp;
                }
            }
        }

        emit Transfer(prevOwnership.addr, address(0), tokenId);
        _afterTokenTransfers(prevOwnership.addr, address(0), tokenId, 1);

        // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times.
        unchecked {
            _burnCounter++;
        }
    }

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

    /**
     * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target 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 _checkContractOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
            return retval == IERC721Receiver(to).onERC721Received.selector;
        } catch (bytes memory reason) {
            if (reason.length == 0) {
                revert TransferToNonERC721ReceiverImplementer();
            } else {
                assembly {
                    revert(add(32, reason), mload(reason))
                }
            }
        }
    }

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

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

File 4 of 18 : Payable.sol
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.4;

/// @title Payable
/// @author MilkyTaste @ Ao Collaboration Ltd.
/// Manage payables

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
import "@openzeppelin/contracts/utils/Address.sol";
import "./ERC2981.sol";

contract Payable is Ownable, ERC2981, ReentrancyGuard {
    address private constant ADDR1 = 0xa9f14b1542C9B5ace7596aC25Ade6fae82d9dDa2;
    address private constant ADDR2 = 0x4c54b734471EF8080C5c252e5588F625D2e5E93E;
    address private constant ADDR3 = 0x8bffc7415B1F8ceA3BF9e1f36EBb2FF15d175CF5;
    address private constant ADDR4 = 0x5A74eC34857BEC78E79F22a4F4F66E6A53126750;

    constructor() {
        _setRoyalties(ADDR1, 690); // 6.9% royalties
    }

    /**
     * Set the royalties information
     * @param recipient recipient of the royalties
     * @param value percentage (using 2 decimals - 10000 = 100, 0 = 0)
     */
    function setRoyalties(address recipient, uint256 value) external onlyOwner {
        require(recipient != address(0), "zero address");
        _setRoyalties(recipient, value);
    }

    /**
     * Withdraw funds
     */
    function withdraw() external nonReentrant {
        require(msg.sender == owner(), "Payable: Locked withdraw");
        uint256 bal = address(this).balance;
        Address.sendValue(payable(ADDR4), bal / 20); // 5
        Address.sendValue(payable(ADDR3), bal / 8); // 12.5
        Address.sendValue(payable(ADDR2), bal / 10); // 10
        Address.sendValue(payable(ADDR1), address(this).balance); // The rest
    }
}

File 5 of 18 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721.sol)

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 6 of 18 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

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

File 7 of 18 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)

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 8 of 18 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

File 9 of 18 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Address.sol)

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 10 of 18 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

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

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

File 11 of 18 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

File 12 of 18 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

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 13 of 18 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)

pragma solidity ^0.8.0;

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

File 14 of 18 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

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() {
        _transferOwnership(_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 {
        _transferOwnership(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");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 15 of 18 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (security/ReentrancyGuard.sol)

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 making 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 16 of 18 : ERC2981.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.8;

import "@openzeppelin/contracts/interfaces/IERC2981.sol";

/// @dev This is a contract used to add ERC2981 support to ERC721 and 1155
contract ERC2981 is IERC2981 {
    struct RoyaltyInfo {
        address recipient;
        uint24 amount;
    }

    RoyaltyInfo private _royalties;

    /// @dev Sets token royalties
    /// @param recipient recipient of the royalties
    /// @param value percentage (using 2 decimals - 10000 = 100, 0 = 0)
    function _setRoyalties(address recipient, uint256 value) internal {
        require(value <= 10000, "ERC2981Royalties: Too high");
        _royalties = RoyaltyInfo(recipient, uint24(value));
    }

    /// @inheritdoc IERC2981
    function royaltyInfo(uint256, uint256 value)
        external
        view
        override
        returns (address receiver, uint256 royaltyAmount)
    {
        RoyaltyInfo memory royalties = _royalties;
        receiver = royalties.recipient;
        royaltyAmount = (value * royalties.amount) / 10000;
    }

    /// @inheritdoc IERC165
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC2981).interfaceId || interfaceId == type(IERC165).interfaceId;
    }
}

File 17 of 18 : IERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC2981.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Interface for the NFT Royalty Standard
 */
interface IERC2981 is IERC165 {
    /**
     * @dev Called with the sale price to determine how much royalty is owed and to whom.
     * @param tokenId - the NFT asset queried for royalty information
     * @param salePrice - the sale price of the NFT asset specified by `tokenId`
     * @return receiver - address of who should be sent the royalty payment
     * @return royaltyAmount - the royalty payment amount for `salePrice`
     */
    function royaltyInfo(uint256 tokenId, uint256 salePrice)
        external
        view
        returns (address receiver, uint256 royaltyAmount);
}

File 18 of 18 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC165.sol)

pragma solidity ^0.8.0;

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

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

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApprovalToCurrentOwner","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"OwnerQueryForNotExplicitlySet","type":"error"},{"inputs":[],"name":"TokenIndexOutOfBounds","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"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":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","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":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"explicitOwnerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"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":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"numTokens","type":"uint16"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"mintFarmlist","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"numTokens","type":"uint16"}],"name":"mintPublic","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint16","name":"numTokens","type":"uint16"},{"internalType":"address","name":"mintTo","type":"address"}],"name":"mintReserved","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"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":"placeholderURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"royaltyAmount","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":"saleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"saleClaims","outputs":[{"internalType":"uint256[3]","name":"","type":"uint256[3]"}],"stateMutability":"view","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":"uint16","name":"maxSale","type":"uint16"}],"name":"setMaxSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"merkleRoot_","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"placeholderURI_","type":"string"}],"name":"setPlaceholderURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"setRoyalties","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenPrice_","type":"uint256"}],"name":"setTokenPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tokenPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"tokensOfOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"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":[{"internalType":"bytes32","name":"root","type":"bytes32"},{"internalType":"bytes32","name":"leaf","type":"bytes32"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"verify","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6080604052661f438daa0600006008556009805461ffff191661115d1790556000600a55600b805460ff191690553480156200003a57600080fd5b50604051806040016040528060098152602001684661726d766572736560b81b815250604051806040016040528060048152602001634641524d60e01b815250620000946200008e620000fd60201b60201c565b62000101565b8151620000a9906001906020850190620001f2565b508051620000bf906002906020840190620001f2565b50506000805461ffff60a01b19169055506001600755620000f773a9f14b1542c9b5ace7596ac25ade6fae82d9dda26102b262000151565b620002d5565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b612710811115620001a85760405162461bcd60e51b815260206004820152601a60248201527f45524332393831526f79616c746965733a20546f6f2068696768000000000000604482015260640160405180910390fd5b604080518082019091526001600160a01b0390921680835262ffffff909116602090920182905260068054600160a01b9093026001600160b81b0319909316909117919091179055565b828054620002009062000298565b90600052602060002090601f0160209004810192826200022457600085556200026f565b82601f106200023f57805160ff19168380011785556200026f565b828001600101855582156200026f579182015b828111156200026f57825182559160200191906001019062000252565b506200027d92915062000281565b5090565b5b808211156200027d576000815560010162000282565b600181811c90821680620002ad57607f821691505b60208210811415620002cf57634e487b7160e01b600052602260045260246000fd5b50919050565b612ef380620002e56000396000f3fe6080604052600436106102bb5760003560e01c80636c0360eb1161016e578063a22cb465116100cb578063e985e9c51161007f578063f1545cf311610064578063f1545cf31461078a578063f2fde38b146107aa578063f8d0762e146107ca57600080fd5b8063e985e9c51461072e578063ea2aa8221461077757600080fd5b8063bf153822116100b0578063bf153822146106cc578063c87b56dd146106ec578063d25539fb1461070c57600080fd5b8063a22cb4651461068c578063b88d4fde146106ac57600080fd5b80637ff9b596116101225780638c7ea24b116101075780638c7ea24b146106395780638da5cb5b1461065957806395d89b411461067757600080fd5b80637ff9b596146105f65780638462151c1461060c57600080fd5b8063715018a611610153578063715018a6146105ac5780637313cba9146105c15780637cb64759146105d657600080fd5b80636c0360eb1461057757806370a082311461058c57600080fd5b80633100a5351161021c5780634f6ccce7116101d05780636352211e116101b55780636352211e1461051d57806368428a1b1461053d5780636a61e5fc1461055757600080fd5b80634f6ccce7146104dd57806355f804b3146104fd57600080fd5b80633574a2dd116102015780633574a2dd146104885780633ccfd60b146104a857806342842e0e146104bd57600080fd5b80633100a535146104535780633423e5481461046857600080fd5b806318160ddd116102735780632a55205a116102585780632a55205a146103de5780632eb4a7ab1461041d5780632f745c591461043357600080fd5b806318160ddd1461038457806323b872dd146103be57600080fd5b8063081812fc116102a4578063081812fc14610317578063095ea7b31461034f57806316755b571461037157600080fd5b806301ffc9a7146102c057806306fdde03146102f5575b600080fd5b3480156102cc57600080fd5b506102e06102db366004612741565b6107ea565b60405190151581526020015b60405180910390f35b34801561030157600080fd5b5061030a61080a565b6040516102ec91906127b6565b34801561032357600080fd5b506103376103323660046127c9565b61089c565b6040516001600160a01b0390911681526020016102ec565b34801561035b57600080fd5b5061036f61036a3660046127fe565b6108e7565b005b61036f61037f36600461283a565b610975565b34801561039057600080fd5b5060005461ffff600160b01b82048116600160a01b909204811691909103165b6040519081526020016102ec565b3480156103ca57600080fd5b5061036f6103d9366004612855565b610b1e565b3480156103ea57600080fd5b506103fe6103f9366004612891565b610b29565b604080516001600160a01b0390931683526020830191909152016102ec565b34801561042957600080fd5b506103b0600a5481565b34801561043f57600080fd5b506103b061044e3660046127fe565b610b7e565b34801561045f57600080fd5b5061036f610c38565b34801561047457600080fd5b506102e06104833660046128fa565b610c94565b34801561049457600080fd5b5061036f6104a3366004612a0d565b610ca9565b3480156104b457600080fd5b5061036f610d08565b3480156104c957600080fd5b5061036f6104d8366004612855565b610e4f565b3480156104e957600080fd5b506103b06104f83660046127c9565b610e6a565b34801561050957600080fd5b5061036f610518366004612a0d565b610edd565b34801561052957600080fd5b506103376105383660046127c9565b610f38565b34801561054957600080fd5b50600b546102e09060ff1681565b34801561056357600080fd5b5061036f6105723660046127c9565b610f4a565b34801561058357600080fd5b5061030a610f97565b34801561059857600080fd5b506103b06105a7366004612a56565b611025565b3480156105b857600080fd5b5061036f6110bc565b3480156105cd57600080fd5b5061030a611110565b3480156105e257600080fd5b5061036f6105f13660046127c9565b61111d565b34801561060257600080fd5b506103b060085481565b34801561061857600080fd5b5061062c610627366004612a56565b61116a565b6040516102ec9190612a71565b34801561064557600080fd5b5061036f6106543660046127fe565b61129c565b34801561066557600080fd5b506000546001600160a01b0316610337565b34801561068357600080fd5b5061030a611344565b34801561069857600080fd5b5061036f6106a7366004612ab5565b611353565b3480156106b857600080fd5b5061036f6106c7366004612af1565b6113e9565b3480156106d857600080fd5b5061036f6106e736600461283a565b61143a565b3480156106f857600080fd5b5061030a6107073660046127c9565b6114a6565b34801561071857600080fd5b506107216115fa565b6040516102ec9190612b6d565b34801561073a57600080fd5b506102e0610749366004612b9e565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b61036f610785366004612bd1565b611655565b34801561079657600080fd5b5061036f6107a5366004612c57565b6118c1565b3480156107b657600080fd5b5061036f6107c5366004612a56565b611999565b3480156107d657600080fd5b506103376107e53660046127c9565b611a69565b60006107f582611b07565b80610804575061080482611b57565b92915050565b60606001805461081990612c73565b80601f016020809104026020016040519081016040528092919081815260200182805461084590612c73565b80156108925780601f1061086757610100808354040283529160200191610892565b820191906000526020600020905b81548152906001019060200180831161087557829003601f168201915b5050505050905090565b6000816108a881611b8d565b6108c5576040516333d1c03960e21b815260040160405180910390fd5b61ffff166000908152600460205260409020546001600160a01b031692915050565b60006108f282610f38565b9050806001600160a01b0316836001600160a01b031614156109275760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b0382161480159061094757506109458133610749565b155b15610965576040516367d9dca160e11b815260040160405180910390fd5b610970838383611bcb565b505050565b600b5460ff166109cc5760405162461bcd60e51b815260206004820152601860248201527f4661726d76657273653a20496e76616c6964207374617465000000000000000060448201526064015b60405180910390fd5b600954819061ffff16816109eb60005461ffff600160a01b9091041690565b6109f59190612cc4565b61ffff1610610a525760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b818061ffff16600854610a659190612cea565b3414610ab35760405162461bcd60e51b815260206004820152601e60248201527f4661726d76657273653a20496e76616c69642045746865722076616c7565000060448201526064016109c3565b600561ffff84161115610b145760405162461bcd60e51b8152602060048201526024808201527f4661726d76657273653a2045786365656473207472616e73616374696f6e206c6044820152631a5b5a5d60e21b60648201526084016109c3565b6109703384611c3a565b610970838383611c54565b604080518082019091526006546001600160a01b038116808352600160a01b90910462ffffff1660208301819052909160009161271090610b6a9086612cea565b610b749190612d1f565b9150509250929050565b600080805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff16158015610be45750846001600160a01b0316610bd98261ffff16610f38565b6001600160a01b0316145b15610c0c5783821415610bfe5761ffff1691506108049050565b81610c0881612d33565b9250505b80610c1681612d4e565b915050610b83565b506040516329c8c00760e21b815260040160405180910390fd5b6000546001600160a01b03163314610c805760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600b805460ff19811660ff90911615179055565b6000610ca1828585611e48565b949350505050565b6000546001600160a01b03163314610cf15760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b8051610d0490600d906020840190612674565b5050565b60026007541415610d5b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016109c3565b60026007556000546001600160a01b03163314610dba5760405162461bcd60e51b815260206004820152601860248201527f50617961626c653a204c6f636b6564207769746864726177000000000000000060448201526064016109c3565b47610de3735a74ec34857bec78e79f22a4f4f66e6a53126750610dde601484612d1f565b611e5e565b610e06738bffc7415b1f8cea3bf9e1f36ebb2ff15d175cf5610dde600884612d1f565b610e29734c54b734471ef8080c5c252e5588f625d2e5e93e610dde600a84612d1f565b610e4773a9f14b1542c9b5ace7596ac25ade6fae82d9dda247611e5e565b506001600755565b610970838383604051806020016040528060008152506113e9565b600080805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff16610ecb5783821415610ebd5761ffff169392505050565b81610ec781612d33565b9250505b80610ed581612d4e565b915050610e6f565b6000546001600160a01b03163314610f255760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b8051610d0490600c906020840190612674565b6000610f4382611f77565b5192915050565b6000546001600160a01b03163314610f925760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600855565b600c8054610fa490612c73565b80601f0160208091040260200160405190810160405280929190818152602001828054610fd090612c73565b801561101d5780601f10610ff25761010080835404028352916020019161101d565b820191906000526020600020905b81548152906001019060200180831161100057829003601f168201915b505050505081565b60006001600160a01b03821661104e576040516323d3ad8160e21b815260040160405180910390fd5b6000805b60005461ffff600160a01b909104811690821610156110b157836001600160a01b03166110828261ffff16610f38565b6001600160a01b0316141561109f578161109b81612d4e565b9250505b806110a981612d4e565b915050611052565b5061ffff1692915050565b6000546001600160a01b031633146111045760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b61110e60006120ac565b565b600d8054610fa490612c73565b6000546001600160a01b031633146111655760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600a55565b6060600061117783611025565b9050806111985760408051600080825260208201909252905b509392505050565b60008167ffffffffffffffff8111156111b3576111b36128b3565b6040519080825280602002602001820160405280156111dc578160200160208202803683370190505b5090506000805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff161580156112445750856001600160a01b03166112398261ffff16610f38565b6001600160a01b0316145b1561128a578061ffff1683838151811061126057611260612d70565b60209081029190910101528161127581612d33565b9250508382141561128a575090949350505050565b8061129481612d4e565b9150506111e3565b6000546001600160a01b031633146112e45760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b6001600160a01b03821661133a5760405162461bcd60e51b815260206004820152600c60248201527f7a65726f2061646472657373000000000000000000000000000000000000000060448201526064016109c3565b610d048282612109565b60606002805461081990612c73565b6001600160a01b03821633141561137d5760405163b06307db60e01b815260040160405180910390fd5b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6113f4848484611c54565b6001600160a01b0383163b151580156114165750611414848484846121bd565b155b15611434576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6000546001600160a01b031633146114825760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b61148d816001612cc4565b6009805461ffff191661ffff9290921691909117905550565b60606114b182611b8d565b6115235760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201527f6e6578697374656e7420746f6b656e000000000000000000000000000000000060648201526084016109c3565b600061152d6122b4565b905060008151116115c857600d805461154590612c73565b80601f016020809104026020016040519081016040528092919081815260200182805461157190612c73565b80156115be5780601f10611593576101008083540402835291602001916115be565b820191906000526020600020905b8154815290600101906020018083116115a157829003601f168201915b50505050506115f3565b806115d2846122c3565b6040516020016115e3929190612d86565b6040516020818303038152906040525b9392505050565b6116026126f8565b604080516060810190915260095481906116229060019061ffff16612ddd565b61ffff9081168252600054600160b01b81048216600160a01b909104821603166020820152600854604090910152919050565b600b5460ff166116a75760405162461bcd60e51b815260206004820152601860248201527f4661726d76657273653a20496e76616c6964207374617465000000000000000060448201526064016109c3565b600954839061ffff16816116c660005461ffff600160a01b9091041690565b6116d09190612cc4565b61ffff161061172d5760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b838061ffff166008546117409190612cea565b341461178e5760405162461bcd60e51b815260206004820152601e60248201527f4661726d76657273653a20496e76616c69642045746865722076616c7565000060448201526064016109c3565b61179a60056002612e00565b61ffff168561ffff1611156117fd5760405162461bcd60e51b8152602060048201526024808201527f4661726d76657273653a2045786365656473207472616e73616374696f6e206c6044820152631a5b5a5d60e21b60648201526084016109c3565b6040805133602082015260009101604051602081830303815290604052805190602001209050611863600a5482878780806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250610c9492505050565b6118af5760405162461bcd60e51b815260206004820152601c60248201527f4661726d76657273653a204e6f7420612076616c69642070726f6f660000000060448201526064016109c3565b6118b93387611c3a565b505050505050565b6000546001600160a01b031633146119095760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600954829061ffff168161192860005461ffff600160a01b9091041690565b6119329190612cc4565b61ffff161061198f5760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b6109708284611c3a565b6000546001600160a01b031633146119e15760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b6001600160a01b038116611a5d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016109c3565b611a66816120ac565b50565b61ffff81166000908152600360209081526040808320815160608101835290546001600160a01b0381168252600160a01b810467ffffffffffffffff1693820193909352600160e01b90920460ff1615801591830191909152611adf57604051636f96cda160e11b815260040160405180910390fd5b80516001600160a01b0316610f435760405163a47c070d60e01b815260040160405180910390fd5b60006001600160e01b031982166380ac58cd60e01b1480611b3857506001600160e01b03198216635b5e139f60e01b145b8061080457506301ffc9a760e01b6001600160e01b0319831614610804565b60006001600160e01b0319821663152a902d60e11b148061080457506001600160e01b031982166301ffc9a760e01b1492915050565b6000805461ffff600160a01b909104811690831610801561080457505061ffff16600090815260036020526040902054600160e01b900460ff161590565b61ffff8216600081815260046020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0388811691821790925591519192908516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259190a4505050565b610d048282604051806020016040528060008152506123d9565b6000611c638261ffff16611f77565b80519091506000906001600160a01b0316336001600160a01b03161480611c9157508151611c919033610749565b80611cb0575033611ca561ffff851661089c565b6001600160a01b0316145b905080611cd057604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b031614611d055760405162a1148160e81b815260040160405180910390fd5b6001600160a01b038416611d2c57604051633a954ecd60e21b815260040160405180910390fd5b611d3c6000848460000151611bcb565b61ffff83811660009081526003602052604080822080546001600160a01b038981166001600160e01b031990921691909117600160a01b4267ffffffffffffffff16021790915560018701938416835291205416611dfa5760005461ffff600160a01b90910481169082161015611dfa57825161ffff8216600090815260036020908152604090912080549186015167ffffffffffffffff16600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b508261ffff16846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b5050505050565b600082611e5585846123e6565b14949350505050565b80471015611eae5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016109c3565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114611efb576040519150601f19603f3d011682016040523d82523d6000602084013e611f00565b606091505b50509050806109705760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016109c3565b60408051606081018252600080825260208201819052918101919091528160005461ffff600160a01b909104811690821610156120935761ffff8116600090815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b810467ffffffffffffffff1692820192909252600160e01b90910460ff161515918101829052906120915780516001600160a01b031615612022579392505050565b506000190161ffff8116600090815260036020908152604091829020825160608101845290546001600160a01b038116808352600160a01b820467ffffffffffffffff1693830193909352600160e01b900460ff161515928101929092521561208c579392505050565b612022565b505b604051636f96cda160e11b815260040160405180910390fd5b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b61271081111561215b5760405162461bcd60e51b815260206004820152601a60248201527f45524332393831526f79616c746965733a20546f6f206869676800000000000060448201526064016109c3565b604080518082019091526001600160a01b0390921680835262ffffff909116602090920182905260068054600160a01b9093027fffffffffffffffffff0000000000000000000000000000000000000000000000909316909117919091179055565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a02906121f2903390899088908890600401612e2a565b602060405180830381600087803b15801561220c57600080fd5b505af192505050801561223c575060408051601f3d908101601f1916820190925261223991810190612e66565b60015b612297573d80801561226a576040519150601f19603f3d011682016040523d82523d6000602084013e61226f565b606091505b50805161228f576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b6060600c805461081990612c73565b6060816122e75750506040805180820190915260018152600360fc1b602082015290565b8160005b811561231157806122fb81612d33565b915061230a9050600a83612d1f565b91506122eb565b60008167ffffffffffffffff81111561232c5761232c6128b3565b6040519080825280601f01601f191660200182016040528015612356576020820181803683370190505b5090505b8415610ca15761236b600183612e83565b9150612378600a86612e9a565b612383906030612eae565b60f81b81838151811061239857612398612d70565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506123d2600a86612d1f565b945061235a565b610970838383600161248a565b600081815b845181101561119057600085828151811061240857612408612d70565b6020026020010151905080831161244a576040805160208101859052908101829052606001604051602081830303815290604052805190602001209250612477565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061248281612d33565b9150506123eb565b600054600160a01b900461ffff166001600160a01b0385166124be57604051622e076360e81b815260040160405180910390fd5b61ffff84166124e05760405163b562e8dd60e01b815260040160405180910390fd5b61ffff81166000908152600360205260409020805467ffffffffffffffff4216600160a01b026001600160e01b03199091166001600160a01b038816171790558084810183801561253a57506001600160a01b0387163b15155b156125e1575b60405161ffff8316906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a46125936000888480600101955061ffff16886121bd565b6125b0576040516368d2bf6b60e11b815260040160405180910390fd5b8061ffff168261ffff1614156125405760005461ffff848116600160a01b90920416146125dc57600080fd5b612633565b5b604051600183019261ffff16906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48061ffff168261ffff1614156125e2575b506000805461ffff92909216600160a01b027fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff909216919091179055611e41565b82805461268090612c73565b90600052602060002090601f0160209004810192826126a257600085556126e8565b82601f106126bb57805160ff19168380011785556126e8565b828001600101855582156126e8579182015b828111156126e85782518255916020019190600101906126cd565b506126f4929150612716565b5090565b60405180606001604052806003906020820280368337509192915050565b5b808211156126f45760008155600101612717565b6001600160e01b031981168114611a6657600080fd5b60006020828403121561275357600080fd5b81356115f38161272b565b60005b83811015612779578181015183820152602001612761565b838111156114345750506000910152565b600081518084526127a281602086016020860161275e565b601f01601f19169290920160200192915050565b6020815260006115f3602083018461278a565b6000602082840312156127db57600080fd5b5035919050565b80356001600160a01b03811681146127f957600080fd5b919050565b6000806040838503121561281157600080fd5b61281a836127e2565b946020939093013593505050565b803561ffff811681146127f957600080fd5b60006020828403121561284c57600080fd5b6115f382612828565b60008060006060848603121561286a57600080fd5b612873846127e2565b9250612881602085016127e2565b9150604084013590509250925092565b600080604083850312156128a457600080fd5b50508035926020909101359150565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156128f2576128f26128b3565b604052919050565b60008060006060848603121561290f57600080fd5b833592506020808501359250604085013567ffffffffffffffff8082111561293657600080fd5b818701915087601f83011261294a57600080fd5b81358181111561295c5761295c6128b3565b8060051b915061296d8483016128c9565b818152918301840191848101908a84111561298757600080fd5b938501935b838510156129a55784358252938501939085019061298c565b8096505050505050509250925092565b600067ffffffffffffffff8311156129cf576129cf6128b3565b6129e2601f8401601f19166020016128c9565b90508281528383830111156129f657600080fd5b828260208301376000602084830101529392505050565b600060208284031215612a1f57600080fd5b813567ffffffffffffffff811115612a3657600080fd5b8201601f81018413612a4757600080fd5b610ca1848235602084016129b5565b600060208284031215612a6857600080fd5b6115f3826127e2565b6020808252825182820181905260009190848201906040850190845b81811015612aa957835183529284019291840191600101612a8d565b50909695505050505050565b60008060408385031215612ac857600080fd5b612ad1836127e2565b915060208301358015158114612ae657600080fd5b809150509250929050565b60008060008060808587031215612b0757600080fd5b612b10856127e2565b9350612b1e602086016127e2565b925060408501359150606085013567ffffffffffffffff811115612b4157600080fd5b8501601f81018713612b5257600080fd5b612b61878235602084016129b5565b91505092959194509250565b60608101818360005b6003811015612b95578151835260209283019290910190600101612b76565b50505092915050565b60008060408385031215612bb157600080fd5b612bba836127e2565b9150612bc8602084016127e2565b90509250929050565b600080600060408486031215612be657600080fd5b612bef84612828565b9250602084013567ffffffffffffffff80821115612c0c57600080fd5b818601915086601f830112612c2057600080fd5b813581811115612c2f57600080fd5b8760208260051b8501011115612c4457600080fd5b6020830194508093505050509250925092565b60008060408385031215612c6a57600080fd5b612bba83612828565b600181811c90821680612c8757607f821691505b60208210811415612ca857634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600061ffff808316818516808303821115612ce157612ce1612cae565b01949350505050565b6000816000190483118215151615612d0457612d04612cae565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612d2e57612d2e612d09565b500490565b6000600019821415612d4757612d47612cae565b5060010190565b600061ffff80831681811415612d6657612d66612cae565b6001019392505050565b634e487b7160e01b600052603260045260246000fd5b60008351612d9881846020880161275e565b835190830190612dac81836020880161275e565b7f2e6a736f6e0000000000000000000000000000000000000000000000000000009101908152600501949350505050565b600061ffff83811690831681811015612df857612df8612cae565b039392505050565b600061ffff80831681851681830481118215151615612e2157612e21612cae565b02949350505050565b60006001600160a01b03808716835280861660208401525083604083015260806060830152612e5c608083018461278a565b9695505050505050565b600060208284031215612e7857600080fd5b81516115f38161272b565b600082821015612e9557612e95612cae565b500390565b600082612ea957612ea9612d09565b500690565b60008219821115612ec157612ec1612cae565b50019056fe4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a164736f6c6343000809000a

Deployed Bytecode

0x6080604052600436106102bb5760003560e01c80636c0360eb1161016e578063a22cb465116100cb578063e985e9c51161007f578063f1545cf311610064578063f1545cf31461078a578063f2fde38b146107aa578063f8d0762e146107ca57600080fd5b8063e985e9c51461072e578063ea2aa8221461077757600080fd5b8063bf153822116100b0578063bf153822146106cc578063c87b56dd146106ec578063d25539fb1461070c57600080fd5b8063a22cb4651461068c578063b88d4fde146106ac57600080fd5b80637ff9b596116101225780638c7ea24b116101075780638c7ea24b146106395780638da5cb5b1461065957806395d89b411461067757600080fd5b80637ff9b596146105f65780638462151c1461060c57600080fd5b8063715018a611610153578063715018a6146105ac5780637313cba9146105c15780637cb64759146105d657600080fd5b80636c0360eb1461057757806370a082311461058c57600080fd5b80633100a5351161021c5780634f6ccce7116101d05780636352211e116101b55780636352211e1461051d57806368428a1b1461053d5780636a61e5fc1461055757600080fd5b80634f6ccce7146104dd57806355f804b3146104fd57600080fd5b80633574a2dd116102015780633574a2dd146104885780633ccfd60b146104a857806342842e0e146104bd57600080fd5b80633100a535146104535780633423e5481461046857600080fd5b806318160ddd116102735780632a55205a116102585780632a55205a146103de5780632eb4a7ab1461041d5780632f745c591461043357600080fd5b806318160ddd1461038457806323b872dd146103be57600080fd5b8063081812fc116102a4578063081812fc14610317578063095ea7b31461034f57806316755b571461037157600080fd5b806301ffc9a7146102c057806306fdde03146102f5575b600080fd5b3480156102cc57600080fd5b506102e06102db366004612741565b6107ea565b60405190151581526020015b60405180910390f35b34801561030157600080fd5b5061030a61080a565b6040516102ec91906127b6565b34801561032357600080fd5b506103376103323660046127c9565b61089c565b6040516001600160a01b0390911681526020016102ec565b34801561035b57600080fd5b5061036f61036a3660046127fe565b6108e7565b005b61036f61037f36600461283a565b610975565b34801561039057600080fd5b5060005461ffff600160b01b82048116600160a01b909204811691909103165b6040519081526020016102ec565b3480156103ca57600080fd5b5061036f6103d9366004612855565b610b1e565b3480156103ea57600080fd5b506103fe6103f9366004612891565b610b29565b604080516001600160a01b0390931683526020830191909152016102ec565b34801561042957600080fd5b506103b0600a5481565b34801561043f57600080fd5b506103b061044e3660046127fe565b610b7e565b34801561045f57600080fd5b5061036f610c38565b34801561047457600080fd5b506102e06104833660046128fa565b610c94565b34801561049457600080fd5b5061036f6104a3366004612a0d565b610ca9565b3480156104b457600080fd5b5061036f610d08565b3480156104c957600080fd5b5061036f6104d8366004612855565b610e4f565b3480156104e957600080fd5b506103b06104f83660046127c9565b610e6a565b34801561050957600080fd5b5061036f610518366004612a0d565b610edd565b34801561052957600080fd5b506103376105383660046127c9565b610f38565b34801561054957600080fd5b50600b546102e09060ff1681565b34801561056357600080fd5b5061036f6105723660046127c9565b610f4a565b34801561058357600080fd5b5061030a610f97565b34801561059857600080fd5b506103b06105a7366004612a56565b611025565b3480156105b857600080fd5b5061036f6110bc565b3480156105cd57600080fd5b5061030a611110565b3480156105e257600080fd5b5061036f6105f13660046127c9565b61111d565b34801561060257600080fd5b506103b060085481565b34801561061857600080fd5b5061062c610627366004612a56565b61116a565b6040516102ec9190612a71565b34801561064557600080fd5b5061036f6106543660046127fe565b61129c565b34801561066557600080fd5b506000546001600160a01b0316610337565b34801561068357600080fd5b5061030a611344565b34801561069857600080fd5b5061036f6106a7366004612ab5565b611353565b3480156106b857600080fd5b5061036f6106c7366004612af1565b6113e9565b3480156106d857600080fd5b5061036f6106e736600461283a565b61143a565b3480156106f857600080fd5b5061030a6107073660046127c9565b6114a6565b34801561071857600080fd5b506107216115fa565b6040516102ec9190612b6d565b34801561073a57600080fd5b506102e0610749366004612b9e565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205460ff1690565b61036f610785366004612bd1565b611655565b34801561079657600080fd5b5061036f6107a5366004612c57565b6118c1565b3480156107b657600080fd5b5061036f6107c5366004612a56565b611999565b3480156107d657600080fd5b506103376107e53660046127c9565b611a69565b60006107f582611b07565b80610804575061080482611b57565b92915050565b60606001805461081990612c73565b80601f016020809104026020016040519081016040528092919081815260200182805461084590612c73565b80156108925780601f1061086757610100808354040283529160200191610892565b820191906000526020600020905b81548152906001019060200180831161087557829003601f168201915b5050505050905090565b6000816108a881611b8d565b6108c5576040516333d1c03960e21b815260040160405180910390fd5b61ffff166000908152600460205260409020546001600160a01b031692915050565b60006108f282610f38565b9050806001600160a01b0316836001600160a01b031614156109275760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b0382161480159061094757506109458133610749565b155b15610965576040516367d9dca160e11b815260040160405180910390fd5b610970838383611bcb565b505050565b600b5460ff166109cc5760405162461bcd60e51b815260206004820152601860248201527f4661726d76657273653a20496e76616c6964207374617465000000000000000060448201526064015b60405180910390fd5b600954819061ffff16816109eb60005461ffff600160a01b9091041690565b6109f59190612cc4565b61ffff1610610a525760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b818061ffff16600854610a659190612cea565b3414610ab35760405162461bcd60e51b815260206004820152601e60248201527f4661726d76657273653a20496e76616c69642045746865722076616c7565000060448201526064016109c3565b600561ffff84161115610b145760405162461bcd60e51b8152602060048201526024808201527f4661726d76657273653a2045786365656473207472616e73616374696f6e206c6044820152631a5b5a5d60e21b60648201526084016109c3565b6109703384611c3a565b610970838383611c54565b604080518082019091526006546001600160a01b038116808352600160a01b90910462ffffff1660208301819052909160009161271090610b6a9086612cea565b610b749190612d1f565b9150509250929050565b600080805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff16158015610be45750846001600160a01b0316610bd98261ffff16610f38565b6001600160a01b0316145b15610c0c5783821415610bfe5761ffff1691506108049050565b81610c0881612d33565b9250505b80610c1681612d4e565b915050610b83565b506040516329c8c00760e21b815260040160405180910390fd5b6000546001600160a01b03163314610c805760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600b805460ff19811660ff90911615179055565b6000610ca1828585611e48565b949350505050565b6000546001600160a01b03163314610cf15760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b8051610d0490600d906020840190612674565b5050565b60026007541415610d5b5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064016109c3565b60026007556000546001600160a01b03163314610dba5760405162461bcd60e51b815260206004820152601860248201527f50617961626c653a204c6f636b6564207769746864726177000000000000000060448201526064016109c3565b47610de3735a74ec34857bec78e79f22a4f4f66e6a53126750610dde601484612d1f565b611e5e565b610e06738bffc7415b1f8cea3bf9e1f36ebb2ff15d175cf5610dde600884612d1f565b610e29734c54b734471ef8080c5c252e5588f625d2e5e93e610dde600a84612d1f565b610e4773a9f14b1542c9b5ace7596ac25ade6fae82d9dda247611e5e565b506001600755565b610970838383604051806020016040528060008152506113e9565b600080805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff16610ecb5783821415610ebd5761ffff169392505050565b81610ec781612d33565b9250505b80610ed581612d4e565b915050610e6f565b6000546001600160a01b03163314610f255760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b8051610d0490600c906020840190612674565b6000610f4382611f77565b5192915050565b6000546001600160a01b03163314610f925760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600855565b600c8054610fa490612c73565b80601f0160208091040260200160405190810160405280929190818152602001828054610fd090612c73565b801561101d5780601f10610ff25761010080835404028352916020019161101d565b820191906000526020600020905b81548152906001019060200180831161100057829003601f168201915b505050505081565b60006001600160a01b03821661104e576040516323d3ad8160e21b815260040160405180910390fd5b6000805b60005461ffff600160a01b909104811690821610156110b157836001600160a01b03166110828261ffff16610f38565b6001600160a01b0316141561109f578161109b81612d4e565b9250505b806110a981612d4e565b915050611052565b5061ffff1692915050565b6000546001600160a01b031633146111045760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b61110e60006120ac565b565b600d8054610fa490612c73565b6000546001600160a01b031633146111655760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600a55565b6060600061117783611025565b9050806111985760408051600080825260208201909252905b509392505050565b60008167ffffffffffffffff8111156111b3576111b36128b3565b6040519080825280602002602001820160405280156111dc578160200160208202803683370190505b5090506000805b60005461ffff600160a01b90910481169082161015610c1e5761ffff8116600090815260036020526040902054600160e01b900460ff161580156112445750856001600160a01b03166112398261ffff16610f38565b6001600160a01b0316145b1561128a578061ffff1683838151811061126057611260612d70565b60209081029190910101528161127581612d33565b9250508382141561128a575090949350505050565b8061129481612d4e565b9150506111e3565b6000546001600160a01b031633146112e45760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b6001600160a01b03821661133a5760405162461bcd60e51b815260206004820152600c60248201527f7a65726f2061646472657373000000000000000000000000000000000000000060448201526064016109c3565b610d048282612109565b60606002805461081990612c73565b6001600160a01b03821633141561137d5760405163b06307db60e01b815260040160405180910390fd5b3360008181526005602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6113f4848484611c54565b6001600160a01b0383163b151580156114165750611414848484846121bd565b155b15611434576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6000546001600160a01b031633146114825760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b61148d816001612cc4565b6009805461ffff191661ffff9290921691909117905550565b60606114b182611b8d565b6115235760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201527f6e6578697374656e7420746f6b656e000000000000000000000000000000000060648201526084016109c3565b600061152d6122b4565b905060008151116115c857600d805461154590612c73565b80601f016020809104026020016040519081016040528092919081815260200182805461157190612c73565b80156115be5780601f10611593576101008083540402835291602001916115be565b820191906000526020600020905b8154815290600101906020018083116115a157829003601f168201915b50505050506115f3565b806115d2846122c3565b6040516020016115e3929190612d86565b6040516020818303038152906040525b9392505050565b6116026126f8565b604080516060810190915260095481906116229060019061ffff16612ddd565b61ffff9081168252600054600160b01b81048216600160a01b909104821603166020820152600854604090910152919050565b600b5460ff166116a75760405162461bcd60e51b815260206004820152601860248201527f4661726d76657273653a20496e76616c6964207374617465000000000000000060448201526064016109c3565b600954839061ffff16816116c660005461ffff600160a01b9091041690565b6116d09190612cc4565b61ffff161061172d5760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b838061ffff166008546117409190612cea565b341461178e5760405162461bcd60e51b815260206004820152601e60248201527f4661726d76657273653a20496e76616c69642045746865722076616c7565000060448201526064016109c3565b61179a60056002612e00565b61ffff168561ffff1611156117fd5760405162461bcd60e51b8152602060048201526024808201527f4661726d76657273653a2045786365656473207472616e73616374696f6e206c6044820152631a5b5a5d60e21b60648201526084016109c3565b6040805133602082015260009101604051602081830303815290604052805190602001209050611863600a5482878780806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250610c9492505050565b6118af5760405162461bcd60e51b815260206004820152601c60248201527f4661726d76657273653a204e6f7420612076616c69642070726f6f660000000060448201526064016109c3565b6118b93387611c3a565b505050505050565b6000546001600160a01b031633146119095760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b600954829061ffff168161192860005461ffff600160a01b9091041690565b6119329190612cc4565b61ffff161061198f5760405162461bcd60e51b815260206004820152602360248201527f4661726d76657273653a204578636565647320617661696c61626c6520746f6b604482015262656e7360e81b60648201526084016109c3565b6109708284611c3a565b6000546001600160a01b031633146119e15760405162461bcd60e51b81526020600482018190526024820152600080516020612ec783398151915260448201526064016109c3565b6001600160a01b038116611a5d5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016109c3565b611a66816120ac565b50565b61ffff81166000908152600360209081526040808320815160608101835290546001600160a01b0381168252600160a01b810467ffffffffffffffff1693820193909352600160e01b90920460ff1615801591830191909152611adf57604051636f96cda160e11b815260040160405180910390fd5b80516001600160a01b0316610f435760405163a47c070d60e01b815260040160405180910390fd5b60006001600160e01b031982166380ac58cd60e01b1480611b3857506001600160e01b03198216635b5e139f60e01b145b8061080457506301ffc9a760e01b6001600160e01b0319831614610804565b60006001600160e01b0319821663152a902d60e11b148061080457506001600160e01b031982166301ffc9a760e01b1492915050565b6000805461ffff600160a01b909104811690831610801561080457505061ffff16600090815260036020526040902054600160e01b900460ff161590565b61ffff8216600081815260046020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0388811691821790925591519192908516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259190a4505050565b610d048282604051806020016040528060008152506123d9565b6000611c638261ffff16611f77565b80519091506000906001600160a01b0316336001600160a01b03161480611c9157508151611c919033610749565b80611cb0575033611ca561ffff851661089c565b6001600160a01b0316145b905080611cd057604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b031614611d055760405162a1148160e81b815260040160405180910390fd5b6001600160a01b038416611d2c57604051633a954ecd60e21b815260040160405180910390fd5b611d3c6000848460000151611bcb565b61ffff83811660009081526003602052604080822080546001600160a01b038981166001600160e01b031990921691909117600160a01b4267ffffffffffffffff16021790915560018701938416835291205416611dfa5760005461ffff600160a01b90910481169082161015611dfa57825161ffff8216600090815260036020908152604090912080549186015167ffffffffffffffff16600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b508261ffff16846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b5050505050565b600082611e5585846123e6565b14949350505050565b80471015611eae5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064016109c3565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114611efb576040519150601f19603f3d011682016040523d82523d6000602084013e611f00565b606091505b50509050806109705760405162461bcd60e51b815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d6179206861766520726576657274656400000000000060648201526084016109c3565b60408051606081018252600080825260208201819052918101919091528160005461ffff600160a01b909104811690821610156120935761ffff8116600090815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b810467ffffffffffffffff1692820192909252600160e01b90910460ff161515918101829052906120915780516001600160a01b031615612022579392505050565b506000190161ffff8116600090815260036020908152604091829020825160608101845290546001600160a01b038116808352600160a01b820467ffffffffffffffff1693830193909352600160e01b900460ff161515928101929092521561208c579392505050565b612022565b505b604051636f96cda160e11b815260040160405180910390fd5b600080546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b61271081111561215b5760405162461bcd60e51b815260206004820152601a60248201527f45524332393831526f79616c746965733a20546f6f206869676800000000000060448201526064016109c3565b604080518082019091526001600160a01b0390921680835262ffffff909116602090920182905260068054600160a01b9093027fffffffffffffffffff0000000000000000000000000000000000000000000000909316909117919091179055565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a02906121f2903390899088908890600401612e2a565b602060405180830381600087803b15801561220c57600080fd5b505af192505050801561223c575060408051601f3d908101601f1916820190925261223991810190612e66565b60015b612297573d80801561226a576040519150601f19603f3d011682016040523d82523d6000602084013e61226f565b606091505b50805161228f576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b6060600c805461081990612c73565b6060816122e75750506040805180820190915260018152600360fc1b602082015290565b8160005b811561231157806122fb81612d33565b915061230a9050600a83612d1f565b91506122eb565b60008167ffffffffffffffff81111561232c5761232c6128b3565b6040519080825280601f01601f191660200182016040528015612356576020820181803683370190505b5090505b8415610ca15761236b600183612e83565b9150612378600a86612e9a565b612383906030612eae565b60f81b81838151811061239857612398612d70565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506123d2600a86612d1f565b945061235a565b610970838383600161248a565b600081815b845181101561119057600085828151811061240857612408612d70565b6020026020010151905080831161244a576040805160208101859052908101829052606001604051602081830303815290604052805190602001209250612477565b60408051602081018390529081018490526060016040516020818303038152906040528051906020012092505b508061248281612d33565b9150506123eb565b600054600160a01b900461ffff166001600160a01b0385166124be57604051622e076360e81b815260040160405180910390fd5b61ffff84166124e05760405163b562e8dd60e01b815260040160405180910390fd5b61ffff81166000908152600360205260409020805467ffffffffffffffff4216600160a01b026001600160e01b03199091166001600160a01b038816171790558084810183801561253a57506001600160a01b0387163b15155b156125e1575b60405161ffff8316906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a46125936000888480600101955061ffff16886121bd565b6125b0576040516368d2bf6b60e11b815260040160405180910390fd5b8061ffff168261ffff1614156125405760005461ffff848116600160a01b90920416146125dc57600080fd5b612633565b5b604051600183019261ffff16906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48061ffff168261ffff1614156125e2575b506000805461ffff92909216600160a01b027fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff909216919091179055611e41565b82805461268090612c73565b90600052602060002090601f0160209004810192826126a257600085556126e8565b82601f106126bb57805160ff19168380011785556126e8565b828001600101855582156126e8579182015b828111156126e85782518255916020019190600101906126cd565b506126f4929150612716565b5090565b60405180606001604052806003906020820280368337509192915050565b5b808211156126f45760008155600101612717565b6001600160e01b031981168114611a6657600080fd5b60006020828403121561275357600080fd5b81356115f38161272b565b60005b83811015612779578181015183820152602001612761565b838111156114345750506000910152565b600081518084526127a281602086016020860161275e565b601f01601f19169290920160200192915050565b6020815260006115f3602083018461278a565b6000602082840312156127db57600080fd5b5035919050565b80356001600160a01b03811681146127f957600080fd5b919050565b6000806040838503121561281157600080fd5b61281a836127e2565b946020939093013593505050565b803561ffff811681146127f957600080fd5b60006020828403121561284c57600080fd5b6115f382612828565b60008060006060848603121561286a57600080fd5b612873846127e2565b9250612881602085016127e2565b9150604084013590509250925092565b600080604083850312156128a457600080fd5b50508035926020909101359150565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156128f2576128f26128b3565b604052919050565b60008060006060848603121561290f57600080fd5b833592506020808501359250604085013567ffffffffffffffff8082111561293657600080fd5b818701915087601f83011261294a57600080fd5b81358181111561295c5761295c6128b3565b8060051b915061296d8483016128c9565b818152918301840191848101908a84111561298757600080fd5b938501935b838510156129a55784358252938501939085019061298c565b8096505050505050509250925092565b600067ffffffffffffffff8311156129cf576129cf6128b3565b6129e2601f8401601f19166020016128c9565b90508281528383830111156129f657600080fd5b828260208301376000602084830101529392505050565b600060208284031215612a1f57600080fd5b813567ffffffffffffffff811115612a3657600080fd5b8201601f81018413612a4757600080fd5b610ca1848235602084016129b5565b600060208284031215612a6857600080fd5b6115f3826127e2565b6020808252825182820181905260009190848201906040850190845b81811015612aa957835183529284019291840191600101612a8d565b50909695505050505050565b60008060408385031215612ac857600080fd5b612ad1836127e2565b915060208301358015158114612ae657600080fd5b809150509250929050565b60008060008060808587031215612b0757600080fd5b612b10856127e2565b9350612b1e602086016127e2565b925060408501359150606085013567ffffffffffffffff811115612b4157600080fd5b8501601f81018713612b5257600080fd5b612b61878235602084016129b5565b91505092959194509250565b60608101818360005b6003811015612b95578151835260209283019290910190600101612b76565b50505092915050565b60008060408385031215612bb157600080fd5b612bba836127e2565b9150612bc8602084016127e2565b90509250929050565b600080600060408486031215612be657600080fd5b612bef84612828565b9250602084013567ffffffffffffffff80821115612c0c57600080fd5b818601915086601f830112612c2057600080fd5b813581811115612c2f57600080fd5b8760208260051b8501011115612c4457600080fd5b6020830194508093505050509250925092565b60008060408385031215612c6a57600080fd5b612bba83612828565b600181811c90821680612c8757607f821691505b60208210811415612ca857634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600061ffff808316818516808303821115612ce157612ce1612cae565b01949350505050565b6000816000190483118215151615612d0457612d04612cae565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612d2e57612d2e612d09565b500490565b6000600019821415612d4757612d47612cae565b5060010190565b600061ffff80831681811415612d6657612d66612cae565b6001019392505050565b634e487b7160e01b600052603260045260246000fd5b60008351612d9881846020880161275e565b835190830190612dac81836020880161275e565b7f2e6a736f6e0000000000000000000000000000000000000000000000000000009101908152600501949350505050565b600061ffff83811690831681811015612df857612df8612cae565b039392505050565b600061ffff80831681851681830481118215151615612e2157612e21612cae565b02949350505050565b60006001600160a01b03808716835280861660208401525083604083015260806060830152612e5c608083018461278a565b9695505050505050565b600060208284031215612e7857600080fd5b81516115f38161272b565b600082821015612e9557612e95612cae565b500390565b600082612ea957612ea9612d09565b500690565b60008219821115612ec157612ec1612cae565b50019056fe4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a164736f6c6343000809000a

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.