ETH Price: $4,048.87 (+3.89%)

Token

Laundry Ticket (LT)
 

Overview

Max Total Supply

318 LT

Holders

260

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
0x85e8505b9c139e48a7bb1e20cdaa9efa9379a68f
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:
LaundryTicket

Compiler Version
v0.8.17+commit.8df45f5f

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 15 : LaundryTicket.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.17;

import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol";
import "@openzeppelin/contracts/utils/Strings.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";
import "operator-filter-registry/src/DefaultOperatorFilterer.sol";

//   _____     _____   _   _    _____ 
//  |  __ \   / ____| | \ | |  / ____|
//  | |  | | | |  __  |  \| | | (___  
//  | |  | | | | |_ | | . ` |  \___ \ 
//  | |__| | | |__| | | |\  |  ____) |
//  |_____/   \_____| |_| \_| |_____/ 
                                                              
contract LaundryTicket is ERC1155, Ownable, DefaultOperatorFilterer {
    using Strings for uint256;
    
    address public DiDContract;
    string public baseURI;
    string public name = "Laundry Ticket";
    string public symbol = "LT";
    bytes32 public merkleRoot;
    bytes32 public goldMerkleRoot;
    bool public mintEnabled = false;
    bool public burnEnabled = false;
    uint256 public maxPerWallet = 1;
    uint256 public maxGoldPerWallet = 1;
    uint256 public maxTickets = 0;
    uint256 public maxGoldTickets = 0;
    uint256 public tickets = 0;
    uint256 public goldTickets = 0;
    uint256 public endTime = 0;
    uint256 public mintWindow = 0;

    mapping(uint256 => bool) public ticketTypes;
    mapping(address => mapping(uint256 => uint256)) private _walletMints;
    mapping(address => mapping(uint256 => uint256)) private _walletGoldMints;

    constructor() ERC1155("") {
        ticketTypes[1] = true;
        ticketTypes[2] = true;
        ticketTypes[3] = true;
        ticketTypes[4] = true;
    }

    function mint(uint256 amount, address to, bytes32[] calldata merkleProof) external {
        require(mintEnabled, "Mint closed for now");
        require(block.timestamp < endTime, "Mint closed for now");
        require(msg.sender == tx.origin, "No contracts");
        require(MerkleProof.verify(merkleProof, merkleRoot, keccak256(abi.encodePacked(to))), "Not allowed to mint");
        require(tickets + amount <= maxTickets, "No more available right now");
        require(amount > 0, "Must mint at least one ticket");
        require(_walletMints[to][mintWindow] + amount <= maxPerWallet, "Limit for this wallet reached");

        _walletMints[to][mintWindow] += amount;
        tickets += amount;
        _mint(to, 1, amount, "");
    }

    function mintGold(uint256 amount, address to, bytes32[] calldata merkleProof) external {
        require(mintEnabled, "Mint closed for now");
        require(block.timestamp < endTime, "Mint closed for now");
        require(msg.sender == tx.origin, "No contracts");
        require(MerkleProof.verify(merkleProof, goldMerkleRoot, keccak256(abi.encodePacked(to))), "Not allowed to mint");
        require(goldTickets + amount <= maxGoldTickets, "No more available right now");
        require(amount > 0, "Must mint at least one ticket");
        require(_walletGoldMints[to][mintWindow] + amount <= maxPerWallet, "Limit for this wallet reached");

        _walletGoldMints[to][mintWindow] += amount;
        goldTickets += amount;
        _mint(to, 2, amount, "");
    }

    function toggleMinting() external onlyOwner {
        mintEnabled = !mintEnabled;
    }

    function toggleBurning() external onlyOwner {
        burnEnabled = !burnEnabled;
    }

    function enableMint(uint256 _newMaxTickets, uint256 _newMaxGoldTickets, uint256 _endTime, uint256 _mintWindow) external onlyOwner {
        mintEnabled = true;
        maxTickets = _newMaxTickets;
        maxGoldTickets = _newMaxGoldTickets;
        endTime = _endTime;
        mintWindow = _mintWindow;
    }

    function mintBatch(uint256[] memory ids, uint256[] memory amounts) external onlyOwner {
        _mintBatch(owner(), ids, amounts, "");
    }

    function setDiDContractAddress(address DiDContractAddress) external onlyOwner {
        DiDContract = DiDContractAddress;
    }

    function setMaxPerWallet(uint256 _newMaxPerWallet, uint256 _newMaxGoldPerWallet) external onlyOwner {
        maxPerWallet = _newMaxPerWallet;
        maxGoldPerWallet = _newMaxGoldPerWallet;
    }

    function setMaxSupply(uint256 _newMaxTickets, uint256 _newMaxGoldTickets) external onlyOwner {
        maxTickets = _newMaxTickets;
        maxGoldTickets = _newMaxGoldTickets;
    }

    function setEndTime(uint256 _endTime) external onlyOwner {
        endTime = _endTime;
    }

    function setMintWindow(uint256 _mintWindow) external onlyOwner {
        mintWindow = _mintWindow;
    }

    function setMerkleRoot(bytes32 _merkleRoot) external onlyOwner {
        merkleRoot = _merkleRoot;
    }

    function setGoldMerkleRoot(bytes32 _goldMerkleRoot) external onlyOwner {
        goldMerkleRoot = _goldMerkleRoot;
    }

    function updateBaseUri(string memory _baseURI) external onlyOwner {
        baseURI = _baseURI;
    }

    function withdraw() public onlyOwner {
        address _address = msg.sender;
        (bool success, ) = _address.call{value: address(this).balance}("");
        require(success, "Failed to withdraw");
    }

    function burnTickets(uint256 typeId, address minter, uint256 amount) external {
        require(burnEnabled, "Burn not open");
        require(msg.sender == DiDContract, "Invalid burner address");
        require(amount > 0, "Must burn at least 1");
        require(ticketTypes[typeId], "Not a valid ticket type" );
        _burn(minter, typeId, amount);
        _mint(minter, typeId + 2, amount, "");
    }

    function uri(uint256 typeId) public view override returns (string memory) {
        require(ticketTypes[typeId], "Not a valid ticket type" );
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, typeId.toString(), ".json")) : baseURI;
    }

    function setApprovalForAll(address operator, bool approved) public override onlyAllowedOperatorApproval(operator) {
        super.setApprovalForAll(operator, approved);
    }

    function safeTransferFrom(address from, address to, uint256 tokenId, uint256 amount, bytes memory data)
        public
        override
        onlyAllowedOperator(from)
    {
        super.safeTransferFrom(from, to, tokenId, amount, data);
    }

    function safeBatchTransferFrom(
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) public virtual override onlyAllowedOperator(from) {
        super.safeBatchTransferFrom(from, to, ids, amounts, data);
    }
}

File 2 of 15 : DefaultOperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {OperatorFilterer} from "./OperatorFilterer.sol";

/**
 * @title  DefaultOperatorFilterer
 * @notice Inherits from OperatorFilterer and automatically subscribes to the default OpenSea subscription.
 */
abstract contract DefaultOperatorFilterer is OperatorFilterer {
    address constant DEFAULT_SUBSCRIPTION = address(0x3cc6CddA760b79bAfa08dF41ECFA224f810dCeB6);

    constructor() OperatorFilterer(DEFAULT_SUBSCRIPTION, true) {}
}

File 3 of 15 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (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.
 *
 * WARNING: You should avoid using leaf values that are 64 bytes long prior to
 * hashing, or use a hash function other than keccak256 for hashing leaves.
 * This is because the concatenation of a sorted pair of internal nodes in
 * the merkle tree could be reinterpreted as a leaf value.
 */
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 Merkle 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 = _efficientHash(computedHash, proofElement);
            } else {
                // Hash(current element of the proof + current computed hash)
                computedHash = _efficientHash(proofElement, computedHash);
            }
        }
        return computedHash;
    }

    function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) {
        assembly {
            mstore(0x00, a)
            mstore(0x20, b)
            value := keccak256(0x00, 0x40)
        }
    }
}

File 4 of 15 : 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 5 of 15 : 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 6 of 15 : ERC1155.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC1155/ERC1155.sol)

pragma solidity ^0.8.0;

import "./IERC1155.sol";
import "./IERC1155Receiver.sol";
import "./extensions/IERC1155MetadataURI.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of the basic standard multi-token.
 * See https://eips.ethereum.org/EIPS/eip-1155
 * Originally based on code by Enjin: https://github.com/enjin/erc-1155
 *
 * _Available since v3.1._
 */
contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI {
    using Address for address;

    // Mapping from token ID to account balances
    mapping(uint256 => mapping(address => uint256)) private _balances;

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

    // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json
    string private _uri;

    /**
     * @dev See {_setURI}.
     */
    constructor(string memory uri_) {
        _setURI(uri_);
    }

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

    /**
     * @dev See {IERC1155MetadataURI-uri}.
     *
     * This implementation returns the same URI for *all* token types. It relies
     * on the token type ID substitution mechanism
     * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP].
     *
     * Clients calling this function must replace the `\{id\}` substring with the
     * actual token type ID.
     */
    function uri(uint256) public view virtual override returns (string memory) {
        return _uri;
    }

    /**
     * @dev See {IERC1155-balanceOf}.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function balanceOf(address account, uint256 id) public view virtual override returns (uint256) {
        require(account != address(0), "ERC1155: address zero is not a valid owner");
        return _balances[id][account];
    }

    /**
     * @dev See {IERC1155-balanceOfBatch}.
     *
     * Requirements:
     *
     * - `accounts` and `ids` must have the same length.
     */
    function balanceOfBatch(address[] memory accounts, uint256[] memory ids)
        public
        view
        virtual
        override
        returns (uint256[] memory)
    {
        require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch");

        uint256[] memory batchBalances = new uint256[](accounts.length);

        for (uint256 i = 0; i < accounts.length; ++i) {
            batchBalances[i] = balanceOf(accounts[i], ids[i]);
        }

        return batchBalances;
    }

    /**
     * @dev See {IERC1155-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        _setApprovalForAll(_msgSender(), operator, approved);
    }

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

    /**
     * @dev See {IERC1155-safeTransferFrom}.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) public virtual override {
        require(
            from == _msgSender() || isApprovedForAll(from, _msgSender()),
            "ERC1155: caller is not token owner nor approved"
        );
        _safeTransferFrom(from, to, id, amount, data);
    }

    /**
     * @dev See {IERC1155-safeBatchTransferFrom}.
     */
    function safeBatchTransferFrom(
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) public virtual override {
        require(
            from == _msgSender() || isApprovedForAll(from, _msgSender()),
            "ERC1155: caller is not token owner nor approved"
        );
        _safeBatchTransferFrom(from, to, ids, amounts, data);
    }

    /**
     * @dev Transfers `amount` tokens of token type `id` from `from` to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `from` must have a balance of tokens of type `id` of at least `amount`.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function _safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: transfer to the zero address");

        address operator = _msgSender();
        uint256[] memory ids = _asSingletonArray(id);
        uint256[] memory amounts = _asSingletonArray(amount);

        _beforeTokenTransfer(operator, from, to, ids, amounts, data);

        uint256 fromBalance = _balances[id][from];
        require(fromBalance >= amount, "ERC1155: insufficient balance for transfer");
        unchecked {
            _balances[id][from] = fromBalance - amount;
        }
        _balances[id][to] += amount;

        emit TransferSingle(operator, from, to, id, amount);

        _afterTokenTransfer(operator, from, to, ids, amounts, data);

        _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data);
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function _safeBatchTransferFrom(
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");
        require(to != address(0), "ERC1155: transfer to the zero address");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, to, ids, amounts, data);

        for (uint256 i = 0; i < ids.length; ++i) {
            uint256 id = ids[i];
            uint256 amount = amounts[i];

            uint256 fromBalance = _balances[id][from];
            require(fromBalance >= amount, "ERC1155: insufficient balance for transfer");
            unchecked {
                _balances[id][from] = fromBalance - amount;
            }
            _balances[id][to] += amount;
        }

        emit TransferBatch(operator, from, to, ids, amounts);

        _afterTokenTransfer(operator, from, to, ids, amounts, data);

        _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data);
    }

    /**
     * @dev Sets a new URI for all token types, by relying on the token type ID
     * substitution mechanism
     * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP].
     *
     * By this mechanism, any occurrence of the `\{id\}` substring in either the
     * URI or any of the amounts in the JSON file at said URI will be replaced by
     * clients with the token type ID.
     *
     * For example, the `https://token-cdn-domain/\{id\}.json` URI would be
     * interpreted by clients as
     * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json`
     * for token type ID 0x4cce0.
     *
     * See {uri}.
     *
     * Because these URIs cannot be meaningfully represented by the {URI} event,
     * this function emits no events.
     */
    function _setURI(string memory newuri) internal virtual {
        _uri = newuri;
    }

    /**
     * @dev Creates `amount` tokens of token type `id`, and assigns them to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function _mint(
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: mint to the zero address");

        address operator = _msgSender();
        uint256[] memory ids = _asSingletonArray(id);
        uint256[] memory amounts = _asSingletonArray(amount);

        _beforeTokenTransfer(operator, address(0), to, ids, amounts, data);

        _balances[id][to] += amount;
        emit TransferSingle(operator, address(0), to, id, amount);

        _afterTokenTransfer(operator, address(0), to, ids, amounts, data);

        _doSafeTransferAcceptanceCheck(operator, address(0), to, id, amount, data);
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function _mintBatch(
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {
        require(to != address(0), "ERC1155: mint to the zero address");
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, address(0), to, ids, amounts, data);

        for (uint256 i = 0; i < ids.length; i++) {
            _balances[ids[i]][to] += amounts[i];
        }

        emit TransferBatch(operator, address(0), to, ids, amounts);

        _afterTokenTransfer(operator, address(0), to, ids, amounts, data);

        _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data);
    }

    /**
     * @dev Destroys `amount` tokens of token type `id` from `from`
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `from` must have at least `amount` tokens of token type `id`.
     */
    function _burn(
        address from,
        uint256 id,
        uint256 amount
    ) internal virtual {
        require(from != address(0), "ERC1155: burn from the zero address");

        address operator = _msgSender();
        uint256[] memory ids = _asSingletonArray(id);
        uint256[] memory amounts = _asSingletonArray(amount);

        _beforeTokenTransfer(operator, from, address(0), ids, amounts, "");

        uint256 fromBalance = _balances[id][from];
        require(fromBalance >= amount, "ERC1155: burn amount exceeds balance");
        unchecked {
            _balances[id][from] = fromBalance - amount;
        }

        emit TransferSingle(operator, from, address(0), id, amount);

        _afterTokenTransfer(operator, from, address(0), ids, amounts, "");
    }

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     */
    function _burnBatch(
        address from,
        uint256[] memory ids,
        uint256[] memory amounts
    ) internal virtual {
        require(from != address(0), "ERC1155: burn from the zero address");
        require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch");

        address operator = _msgSender();

        _beforeTokenTransfer(operator, from, address(0), ids, amounts, "");

        for (uint256 i = 0; i < ids.length; i++) {
            uint256 id = ids[i];
            uint256 amount = amounts[i];

            uint256 fromBalance = _balances[id][from];
            require(fromBalance >= amount, "ERC1155: burn amount exceeds balance");
            unchecked {
                _balances[id][from] = fromBalance - amount;
            }
        }

        emit TransferBatch(operator, from, address(0), ids, amounts);

        _afterTokenTransfer(operator, from, address(0), ids, amounts, "");
    }

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits an {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC1155: setting approval status for self");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning, as well as batched variants.
     *
     * The same hook is called on both single and batched variants. For single
     * transfers, the length of the `ids` and `amounts` arrays will be 1.
     *
     * Calling conditions (for each `id` and `amount` pair):
     *
     * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * of token type `id` will be  transferred to `to`.
     * - When `from` is zero, `amount` tokens of token type `id` will be minted
     * for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens of token type `id`
     * will be burned.
     * - `from` and `to` are never both zero.
     * - `ids` and `amounts` have the same, non-zero length.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address operator,
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {}

    /**
     * @dev Hook that is called after any token transfer. This includes minting
     * and burning, as well as batched variants.
     *
     * The same hook is called on both single and batched variants. For single
     * transfers, the length of the `id` and `amount` arrays will be 1.
     *
     * Calling conditions (for each `id` and `amount` pair):
     *
     * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * of token type `id` will be  transferred to `to`.
     * - When `from` is zero, `amount` tokens of token type `id` will be minted
     * for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens of token type `id`
     * will be burned.
     * - `from` and `to` are never both zero.
     * - `ids` and `amounts` have the same, non-zero length.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address operator,
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) internal virtual {}

    function _doSafeTransferAcceptanceCheck(
        address operator,
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes memory data
    ) private {
        if (to.isContract()) {
            try IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) {
                if (response != IERC1155Receiver.onERC1155Received.selector) {
                    revert("ERC1155: ERC1155Receiver rejected tokens");
                }
            } catch Error(string memory reason) {
                revert(reason);
            } catch {
                revert("ERC1155: transfer to non ERC1155Receiver implementer");
            }
        }
    }

    function _doSafeBatchTransferAcceptanceCheck(
        address operator,
        address from,
        address to,
        uint256[] memory ids,
        uint256[] memory amounts,
        bytes memory data
    ) private {
        if (to.isContract()) {
            try IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns (
                bytes4 response
            ) {
                if (response != IERC1155Receiver.onERC1155BatchReceived.selector) {
                    revert("ERC1155: ERC1155Receiver rejected tokens");
                }
            } catch Error(string memory reason) {
                revert(reason);
            } catch {
                revert("ERC1155: transfer to non ERC1155Receiver implementer");
            }
        }
    }

    function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) {
        uint256[] memory array = new uint256[](1);
        array[0] = element;

        return array;
    }
}

File 7 of 15 : OperatorFilterer.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

import {IOperatorFilterRegistry} from "./IOperatorFilterRegistry.sol";

/**
 * @title  OperatorFilterer
 * @notice Abstract contract whose constructor automatically registers and optionally subscribes to or copies another
 *         registrant's entries in the OperatorFilterRegistry.
 * @dev    This smart contract is meant to be inherited by token contracts so they can use the following:
 *         - `onlyAllowedOperator` modifier for `transferFrom` and `safeTransferFrom` methods.
 *         - `onlyAllowedOperatorApproval` modifier for `approve` and `setApprovalForAll` methods.
 */
abstract contract OperatorFilterer {
    error OperatorNotAllowed(address operator);

    IOperatorFilterRegistry public constant OPERATOR_FILTER_REGISTRY =
        IOperatorFilterRegistry(0x000000000000AAeB6D7670E522A718067333cd4E);

    constructor(address subscriptionOrRegistrantToCopy, bool subscribe) {
        // If an inheriting token contract is deployed to a network without the registry deployed, the modifier
        // will not revert, but the contract will need to be registered with the registry once it is deployed in
        // order for the modifier to filter addresses.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (subscribe) {
                OPERATOR_FILTER_REGISTRY.registerAndSubscribe(address(this), subscriptionOrRegistrantToCopy);
            } else {
                if (subscriptionOrRegistrantToCopy != address(0)) {
                    OPERATOR_FILTER_REGISTRY.registerAndCopyEntries(address(this), subscriptionOrRegistrantToCopy);
                } else {
                    OPERATOR_FILTER_REGISTRY.register(address(this));
                }
            }
        }
    }

    modifier onlyAllowedOperator(address from) virtual {
        // Allow spending tokens from addresses with balance
        // Note that this still allows listings and marketplaces with escrow to transfer tokens if transferred
        // from an EOA.
        if (from != msg.sender) {
            _checkFilterOperator(msg.sender);
        }
        _;
    }

    modifier onlyAllowedOperatorApproval(address operator) virtual {
        _checkFilterOperator(operator);
        _;
    }

    function _checkFilterOperator(address operator) internal view virtual {
        // Check registry code length to facilitate testing in environments without a deployed registry.
        if (address(OPERATOR_FILTER_REGISTRY).code.length > 0) {
            if (!OPERATOR_FILTER_REGISTRY.isOperatorAllowed(address(this), operator)) {
                revert OperatorNotAllowed(operator);
            }
        }
    }
}

File 8 of 15 : 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 9 of 15 : 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 10 of 15 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

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

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

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

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

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

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

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

File 11 of 15 : IERC1155MetadataURI.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/IERC1155MetadataURI.sol)

pragma solidity ^0.8.0;

import "../IERC1155.sol";

/**
 * @dev Interface of the optional ERC1155MetadataExtension interface, as defined
 * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP].
 *
 * _Available since v3.1._
 */
interface IERC1155MetadataURI is IERC1155 {
    /**
     * @dev Returns the URI for token type `id`.
     *
     * If the `\{id\}` substring is present in the URI, it must be replaced by
     * clients with the actual token type ID.
     */
    function uri(uint256 id) external view returns (string memory);
}

File 12 of 15 : IERC1155Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev _Available since v3.1._
 */
interface IERC1155Receiver is IERC165 {
    /**
     * @dev Handles the receipt of a single ERC1155 token type. This function is
     * called at the end of a `safeTransferFrom` after the balance has been updated.
     *
     * NOTE: To accept the transfer, this must return
     * `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))`
     * (i.e. 0xf23a6e61, or its own function selector).
     *
     * @param operator The address which initiated the transfer (i.e. msg.sender)
     * @param from The address which previously owned the token
     * @param id The ID of the token being transferred
     * @param value The amount of tokens being transferred
     * @param data Additional data with no specified format
     * @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed
     */
    function onERC1155Received(
        address operator,
        address from,
        uint256 id,
        uint256 value,
        bytes calldata data
    ) external returns (bytes4);

    /**
     * @dev Handles the receipt of a multiple ERC1155 token types. This function
     * is called at the end of a `safeBatchTransferFrom` after the balances have
     * been updated.
     *
     * NOTE: To accept the transfer(s), this must return
     * `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))`
     * (i.e. 0xbc197c81, or its own function selector).
     *
     * @param operator The address which initiated the batch transfer (i.e. msg.sender)
     * @param from The address which previously owned the token
     * @param ids An array containing ids of each token being transferred (order and length must match values array)
     * @param values An array containing amounts of each token being transferred (order and length must match ids array)
     * @param data Additional data with no specified format
     * @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed
     */
    function onERC1155BatchReceived(
        address operator,
        address from,
        uint256[] calldata ids,
        uint256[] calldata values,
        bytes calldata data
    ) external returns (bytes4);
}

File 13 of 15 : IERC1155.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC1155/IERC1155.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev Required interface of an ERC1155 compliant contract, as defined in the
 * https://eips.ethereum.org/EIPS/eip-1155[EIP].
 *
 * _Available since v3.1._
 */
interface IERC1155 is IERC165 {
    /**
     * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`.
     */
    event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value);

    /**
     * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all
     * transfers.
     */
    event TransferBatch(
        address indexed operator,
        address indexed from,
        address indexed to,
        uint256[] ids,
        uint256[] values
    );

    /**
     * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to
     * `approved`.
     */
    event ApprovalForAll(address indexed account, address indexed operator, bool approved);

    /**
     * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI.
     *
     * If an {URI} event was emitted for `id`, the standard
     * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value
     * returned by {IERC1155MetadataURI-uri}.
     */
    event URI(string value, uint256 indexed id);

    /**
     * @dev Returns the amount of tokens of token type `id` owned by `account`.
     *
     * Requirements:
     *
     * - `account` cannot be the zero address.
     */
    function balanceOf(address account, uint256 id) external view returns (uint256);

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}.
     *
     * Requirements:
     *
     * - `accounts` and `ids` must have the same length.
     */
    function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids)
        external
        view
        returns (uint256[] memory);

    /**
     * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`,
     *
     * Emits an {ApprovalForAll} event.
     *
     * Requirements:
     *
     * - `operator` cannot be the caller.
     */
    function setApprovalForAll(address operator, bool approved) external;

    /**
     * @dev Returns true if `operator` is approved to transfer ``account``'s tokens.
     *
     * See {setApprovalForAll}.
     */
    function isApprovedForAll(address account, address operator) external view returns (bool);

    /**
     * @dev Transfers `amount` tokens of token type `id` from `from` to `to`.
     *
     * Emits a {TransferSingle} event.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - If the caller is not `from`, it must have been approved to spend ``from``'s tokens via {setApprovalForAll}.
     * - `from` must have a balance of tokens of type `id` of at least `amount`.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the
     * acceptance magic value.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 id,
        uint256 amount,
        bytes calldata data
    ) external;

    /**
     * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}.
     *
     * Emits a {TransferBatch} event.
     *
     * Requirements:
     *
     * - `ids` and `amounts` must have the same length.
     * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the
     * acceptance magic value.
     */
    function safeBatchTransferFrom(
        address from,
        address to,
        uint256[] calldata ids,
        uint256[] calldata amounts,
        bytes calldata data
    ) external;
}

File 14 of 15 : IOperatorFilterRegistry.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.13;

interface IOperatorFilterRegistry {
    function isOperatorAllowed(address registrant, address operator) external view returns (bool);
    function register(address registrant) external;
    function registerAndSubscribe(address registrant, address subscription) external;
    function registerAndCopyEntries(address registrant, address registrantToCopy) external;
    function unregister(address addr) external;
    function updateOperator(address registrant, address operator, bool filtered) external;
    function updateOperators(address registrant, address[] calldata operators, bool filtered) external;
    function updateCodeHash(address registrant, bytes32 codehash, bool filtered) external;
    function updateCodeHashes(address registrant, bytes32[] calldata codeHashes, bool filtered) external;
    function subscribe(address registrant, address registrantToSubscribe) external;
    function unsubscribe(address registrant, bool copyExistingEntries) external;
    function subscriptionOf(address addr) external returns (address registrant);
    function subscribers(address registrant) external returns (address[] memory);
    function subscriberAt(address registrant, uint256 index) external returns (address);
    function copyEntriesOf(address registrant, address registrantToCopy) external;
    function isOperatorFiltered(address registrant, address operator) external returns (bool);
    function isCodeHashOfFiltered(address registrant, address operatorWithCode) external returns (bool);
    function isCodeHashFiltered(address registrant, bytes32 codeHash) external returns (bool);
    function filteredOperators(address addr) external returns (address[] memory);
    function filteredCodeHashes(address addr) external returns (bytes32[] memory);
    function filteredOperatorAt(address registrant, uint256 index) external returns (address);
    function filteredCodeHashAt(address registrant, uint256 index) external returns (bytes32);
    function isRegistered(address addr) external returns (bool);
    function codeHashOf(address addr) external returns (bytes32);
}

File 15 of 15 : 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);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"operator","type":"address"}],"name":"OperatorNotAllowed","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","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":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[],"name":"DiDContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"OPERATOR_FILTER_REGISTRY","outputs":[{"internalType":"contract IOperatorFilterRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"burnEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"typeId","type":"uint256"},{"internalType":"address","name":"minter","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burnTickets","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxTickets","type":"uint256"},{"internalType":"uint256","name":"_newMaxGoldTickets","type":"uint256"},{"internalType":"uint256","name":"_endTime","type":"uint256"},{"internalType":"uint256","name":"_mintWindow","type":"uint256"}],"name":"enableMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"endTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"goldMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"goldTickets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxGoldPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxGoldTickets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxTickets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"mintBatch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"mintGold","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"mintWindow","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","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":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"DiDContractAddress","type":"address"}],"name":"setDiDContractAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_endTime","type":"uint256"}],"name":"setEndTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_goldMerkleRoot","type":"bytes32"}],"name":"setGoldMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxPerWallet","type":"uint256"},{"internalType":"uint256","name":"_newMaxGoldPerWallet","type":"uint256"}],"name":"setMaxPerWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_newMaxTickets","type":"uint256"},{"internalType":"uint256","name":"_newMaxGoldTickets","type":"uint256"}],"name":"setMaxSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintWindow","type":"uint256"}],"name":"setMintWindow","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"ticketTypes","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tickets","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleBurning","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleMinting","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_baseURI","type":"string"}],"name":"updateBaseUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"typeId","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60c0604052600e60809081526d13185d5b991c9e48151a58dad95d60921b60a0526006906200002f9082620003eb565b50604080518082019091526002815261131560f21b6020820152600790620000589082620003eb565b50600a805461ffff191690556001600b819055600c556000600d819055600e819055600f819055601081905560118190556012553480156200009957600080fd5b50733cc6cdda760b79bafa08df41ecfa224f810dceb6600160405180602001604052806000815250620000d281620002e260201b60201c565b50620000de33620002f4565b6daaeb6d7670e522a718067333cd4e3b15620002235780156200017157604051633e9f1edf60e11b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e90637d3e3dbe906044015b600060405180830381600087803b1580156200015257600080fd5b505af115801562000167573d6000803e3d6000fd5b5050505062000223565b6001600160a01b03821615620001c25760405163a0af290360e01b81523060048201526001600160a01b03831660248201526daaeb6d7670e522a718067333cd4e9063a0af29039060440162000137565b604051632210724360e11b81523060048201526daaeb6d7670e522a718067333cd4e90634420e48690602401600060405180830381600087803b1580156200020957600080fd5b505af11580156200021e573d6000803e3d6000fd5b505050505b505060136020527f4155c2f711f2cdd34f8262ab8fb9b7020a700fe7b6948222152f7670d1fdf34d8054600160ff1991821681179092557f0b9d2c0c271bb30544eb78c59bdaebdae2728e5f65814c07768a0abe90ed192380548216831790557f0d2a6872ef858a7f8ead18dc4f3f2e8d35c853d47e2816cbb9cdd49202554e0c805482168317905560046000527f01413ff7a3b1d5b6c016c061d48e2c7014700c777a29fcd068fff04265813d5d80549091169091179055620004b7565b6002620002f08282620003eb565b5050565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200037157607f821691505b6020821081036200039257634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620003e657600081815260208120601f850160051c81016020861015620003c15750805b601f850160051c820191505b81811015620003e257828155600101620003cd565b5050505b505050565b81516001600160401b0381111562000407576200040762000346565b6200041f816200041884546200035c565b8462000398565b602080601f8311600181146200045757600084156200043e5750858301515b600019600386901b1c1916600185901b178555620003e2565b600085815260208120601f198616915b82811015620004885788860151825594840194600190910190840162000467565b5085821015620004a75787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b612f6d80620004c76000396000f3fe608060405234801561001057600080fd5b506004361061027e5760003560e01c80636c0360eb1161015c578063c6b80b78116100ce578063e985e9c511610087578063e985e9c514610507578063e9dbebce14610543578063f242432a14610566578063f2fde38b14610579578063f64d5eaa1461058c578063f68902fc1461059f57600080fd5b8063c6b80b78146104af578063ccb98ffc146104b8578063d1239730146104cb578063d351cfdc146104d8578063d3c21fe2146104eb578063e613d8aa146104fe57600080fd5b806395d89b411161012057806395d89b411461045c5780639b894703146104645780639ce93edf1461046d578063a22cb46514610476578063a85af0e714610489578063aa2c63df1461049c57600080fd5b80636c0360eb14610420578063715018a6146104285780637cb64759146104305780637d55094d146104435780638da5cb5b1461044b57600080fd5b806337da577c116101f557806347c699d1116101b957806347c699d1146103ac5780634e1273f4146103bf57806351ceab34146103df57806356ad15f6146103e857806357df96d8146103fb5780635dc96d161461040e57600080fd5b806337da577c1461036057806339f7e37f146103735780633ccfd60b1461038657806341f434341461038e578063453c2310146103a357600080fd5b80631d3d830a116102475780631d3d830a1461031f578063218585211461032857806322dcb0a7146103315780632eb2c2d61461033b5780632eb4a7ab1461034e5780633197cbb61461035757600080fd5b8062fdd58e1461028357806301ffc9a7146102a957806306fdde03146102cc5780630e89341c146102e15780631b40bcf1146102f4575b600080fd5b610296610291366004612266565b6105b2565b6040519081526020015b60405180910390f35b6102bc6102b73660046122a6565b61064b565b60405190151581526020016102a0565b6102d461069b565b6040516102a0919061231a565b6102d46102ef36600461232d565b610729565b600454610307906001600160a01b031681565b6040516001600160a01b0390911681526020016102a0565b61029660105481565b610296600f5481565b61033961085b565b005b610339610349366004612499565b6108a2565b61029660085481565b61029660115481565b61033961036e366004612542565b6108d1565b610339610381366004612564565b610906565b610339610940565b6103076daaeb6d7670e522a718067333cd4e81565b610296600b5481565b6103396103ba3660046125ac565b6109f9565b6103d26103cd366004612635565b610cdb565b6040516102a0919061273a565b610296600e5481565b6103396103f6366004612542565b610e04565b61033961040936600461232d565b610e39565b600a546102bc90610100900460ff1681565b6102d4610e68565b610339610e75565b61033961043e36600461232d565b610eab565b610339610eda565b6003546001600160a01b0316610307565b6102d4610f18565b610296600d5481565b61029660125481565b61033961048436600461275b565b610f25565b610339610497366004612792565b610f3e565b6103396104aa3660046127c4565b610f89565b610296600c5481565b6103396104c636600461232d565b610fd5565b600a546102bc9060ff1681565b6103396104e63660046127df565b611004565b6103396104f93660046125ac565b61105a565b61029660095481565b6102bc61051536600461282b565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b6102bc61055136600461232d565b60136020526000908152604090205460ff1681565b61033961057436600461285e565b61131f565b6103396105873660046127c4565b611346565b61033961059a36600461232d565b6113e1565b6103396105ad3660046128c2565b611410565b60006001600160a01b0383166106225760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b506000818152602081815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b148061067c57506001600160e01b031982166303a24d0760e21b145b8061064557506301ffc9a760e01b6001600160e01b0319831614610645565b600680546106a8906128f7565b80601f01602080910402602001604051908101604052809291908181526020018280546106d4906128f7565b80156107215780601f106106f657610100808354040283529160200191610721565b820191906000526020600020905b81548152906001019060200180831161070457829003601f168201915b505050505081565b60008181526013602052604090205460609060ff166107845760405162461bcd60e51b81526020600482015260176024820152764e6f7420612076616c6964207469636b6574207479706560481b6044820152606401610619565b600060058054610793906128f7565b90501161082a57600580546107a7906128f7565b80601f01602080910402602001604051908101604052809291908181526020018280546107d3906128f7565b80156108205780601f106107f557610100808354040283529160200191610820565b820191906000526020600020905b81548152906001019060200180831161080357829003601f168201915b5050505050610645565b600561083583611579565b604051602001610846929190612931565b60405160208183030381529060405292915050565b6003546001600160a01b031633146108855760405162461bcd60e51b8152600401610619906129c8565b600a805461ff001981166101009182900460ff1615909102179055565b846001600160a01b03811633146108bc576108bc33611681565b6108c9868686868661173a565b505050505050565b6003546001600160a01b031633146108fb5760405162461bcd60e51b8152600401610619906129c8565b600d91909155600e55565b6003546001600160a01b031633146109305760405162461bcd60e51b8152600401610619906129c8565b600561093c8282612a43565b5050565b6003546001600160a01b0316331461096a5760405162461bcd60e51b8152600401610619906129c8565b6040513390600090829047908381818185875af1925050503d80600081146109ae576040519150601f19603f3d011682016040523d82523d6000602084013e6109b3565b606091505b505090508061093c5760405162461bcd60e51b81526020600482015260126024820152714661696c656420746f20776974686472617760701b6044820152606401610619565b600a5460ff16610a1b5760405162461bcd60e51b815260040161061990612b02565b6011544210610a3c5760405162461bcd60e51b815260040161061990612b02565b333214610a7a5760405162461bcd60e51b815260206004820152600c60248201526b4e6f20636f6e74726163747360a01b6044820152606401610619565b610af1828280806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506008546040516bffffffffffffffffffffffff1960608a901b16602082015290925060340190505b60405160208183030381529060405280519060200120611786565b610b335760405162461bcd60e51b8152602060048201526013602482015272139bdd08185b1b1bddd959081d1bc81b5a5b9d606a1b6044820152606401610619565b600d5484600f54610b449190612b45565b1115610b925760405162461bcd60e51b815260206004820152601b60248201527f4e6f206d6f726520617661696c61626c65207269676874206e6f7700000000006044820152606401610619565b60008411610be25760405162461bcd60e51b815260206004820152601d60248201527f4d757374206d696e74206174206c65617374206f6e65207469636b65740000006044820152606401610619565b600b546001600160a01b03841660009081526014602090815260408083206012548452909152902054610c16908690612b45565b1115610c645760405162461bcd60e51b815260206004820152601d60248201527f4c696d697420666f7220746869732077616c6c657420726561636865640000006044820152606401610619565b6001600160a01b0383166000908152601460209081526040808320601254845290915281208054869290610c99908490612b45565b9250508190555083600f6000828254610cb29190612b45565b92505081905550610cd5836001866040518060200160405280600081525061179c565b50505050565b60608151835114610d405760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610619565b600083516001600160401b03811115610d5b57610d5b612346565b604051908082528060200260200182016040528015610d84578160200160208202803683370190505b50905060005b8451811015610dfc57610dcf858281518110610da857610da8612b58565b6020026020010151858381518110610dc257610dc2612b58565b60200260200101516105b2565b828281518110610de157610de1612b58565b6020908102919091010152610df581612b6e565b9050610d8a565b509392505050565b6003546001600160a01b03163314610e2e5760405162461bcd60e51b8152600401610619906129c8565b600b91909155600c55565b6003546001600160a01b03163314610e635760405162461bcd60e51b8152600401610619906129c8565b600955565b600580546106a8906128f7565b6003546001600160a01b03163314610e9f5760405162461bcd60e51b8152600401610619906129c8565b610ea96000611876565b565b6003546001600160a01b03163314610ed55760405162461bcd60e51b8152600401610619906129c8565b600855565b6003546001600160a01b03163314610f045760405162461bcd60e51b8152600401610619906129c8565b600a805460ff19811660ff90911615179055565b600780546106a8906128f7565b81610f2f81611681565b610f3983836118c8565b505050565b6003546001600160a01b03163314610f685760405162461bcd60e51b8152600401610619906129c8565b600a805460ff19166001179055600d93909355600e91909155601155601255565b6003546001600160a01b03163314610fb35760405162461bcd60e51b8152600401610619906129c8565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6003546001600160a01b03163314610fff5760405162461bcd60e51b8152600401610619906129c8565b601155565b6003546001600160a01b0316331461102e5760405162461bcd60e51b8152600401610619906129c8565b61093c6110436003546001600160a01b031690565b8383604051806020016040528060008152506118d3565b600a5460ff1661107c5760405162461bcd60e51b815260040161061990612b02565b601154421061109d5760405162461bcd60e51b815260040161061990612b02565b3332146110db5760405162461bcd60e51b815260206004820152600c60248201526b4e6f20636f6e74726163747360a01b6044820152606401610619565b61113b828280806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506009546040516bffffffffffffffffffffffff1960608a901b1660208201529092506034019050610ad6565b61117d5760405162461bcd60e51b8152602060048201526013602482015272139bdd08185b1b1bddd959081d1bc81b5a5b9d606a1b6044820152606401610619565b600e548460105461118e9190612b45565b11156111dc5760405162461bcd60e51b815260206004820152601b60248201527f4e6f206d6f726520617661696c61626c65207269676874206e6f7700000000006044820152606401610619565b6000841161122c5760405162461bcd60e51b815260206004820152601d60248201527f4d757374206d696e74206174206c65617374206f6e65207469636b65740000006044820152606401610619565b600b546001600160a01b03841660009081526015602090815260408083206012548452909152902054611260908690612b45565b11156112ae5760405162461bcd60e51b815260206004820152601d60248201527f4c696d697420666f7220746869732077616c6c657420726561636865640000006044820152606401610619565b6001600160a01b03831660009081526015602090815260408083206012548452909152812080548692906112e3908490612b45565b9250508190555083601060008282546112fc9190612b45565b92505081905550610cd5836002866040518060200160405280600081525061179c565b846001600160a01b03811633146113395761133933611681565b6108c98686868686611a1e565b6003546001600160a01b031633146113705760405162461bcd60e51b8152600401610619906129c8565b6001600160a01b0381166113d55760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610619565b6113de81611876565b50565b6003546001600160a01b0316331461140b5760405162461bcd60e51b8152600401610619906129c8565b601255565b600a54610100900460ff166114575760405162461bcd60e51b815260206004820152600d60248201526c213ab937103737ba1037b832b760991b6044820152606401610619565b6004546001600160a01b031633146114aa5760405162461bcd60e51b8152602060048201526016602482015275496e76616c6964206275726e6572206164647265737360501b6044820152606401610619565b600081116114f15760405162461bcd60e51b81526020600482015260146024820152734d757374206275726e206174206c65617374203160601b6044820152606401610619565b60008381526013602052604090205460ff166115495760405162461bcd60e51b81526020600482015260176024820152764e6f7420612076616c6964207469636b6574207479706560481b6044820152606401610619565b611554828483611a63565b610f3982611563856002612b45565b836040518060200160405280600081525061179c565b6060816000036115a05750506040805180820190915260018152600360fc1b602082015290565b8160005b81156115ca57806115b481612b6e565b91506115c39050600a83612b9d565b91506115a4565b6000816001600160401b038111156115e4576115e4612346565b6040519080825280601f01601f19166020018201604052801561160e576020820181803683370190505b5090505b841561167957611623600183612bb1565b9150611630600a86612bc4565b61163b906030612b45565b60f81b81838151811061165057611650612b58565b60200101906001600160f81b031916908160001a905350611672600a86612b9d565b9450611612565b949350505050565b6daaeb6d7670e522a718067333cd4e3b156113de57604051633185c44d60e21b81523060048201526001600160a01b03821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156116ee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117129190612bd8565b6113de57604051633b79c77360e21b81526001600160a01b0382166004820152602401610619565b6001600160a01b03851633148061175657506117568533610515565b6117725760405162461bcd60e51b815260040161061990612bf5565b61177f8585858585611bdf565b5050505050565b6000826117938584611d73565b14949350505050565b6001600160a01b0384166117c25760405162461bcd60e51b815260040161061990612c44565b3360006117ce85611ddf565b905060006117db85611ddf565b90506000868152602081815260408083206001600160a01b038b1684529091528120805487929061180d908490612b45565b909155505060408051878152602081018790526001600160a01b03808a1692600092918716917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461186d83600089898989611e2a565b50505050505050565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b61093c338383611f85565b6001600160a01b0384166118f95760405162461bcd60e51b815260040161061990612c44565b815183511461191a5760405162461bcd60e51b815260040161061990612c85565b3360005b84518110156119b65783818151811061193957611939612b58565b602002602001015160008087848151811061195657611956612b58565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b03168152602001908152602001600020600082825461199e9190612b45565b909155508190506119ae81612b6e565b91505061191e565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611a07929190612ccd565b60405180910390a461177f81600087878787612065565b6001600160a01b038516331480611a3a5750611a3a8533610515565b611a565760405162461bcd60e51b815260040161061990612bf5565b61177f8585858585612120565b6001600160a01b038316611ac55760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610619565b336000611ad184611ddf565b90506000611ade84611ddf565b60408051602080820183526000918290528882528181528282206001600160a01b038b1683529052205490915084811015611b675760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610619565b6000868152602081815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a90529092908816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a460408051602081019091526000905261186d565b8151835114611c005760405162461bcd60e51b815260040161061990612c85565b6001600160a01b038416611c265760405162461bcd60e51b815260040161061990612cfb565b3360005b8451811015611d0d576000858281518110611c4757611c47612b58565b602002602001015190506000858381518110611c6557611c65612b58565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015611cb55760405162461bcd60e51b815260040161061990612d40565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290611cf2908490612b45565b9250508190555050505080611d0690612b6e565b9050611c2a565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611d5d929190612ccd565b60405180910390a46108c9818787878787612065565b600081815b8451811015610dfc576000858281518110611d9557611d95612b58565b60200260200101519050808311611dbb5760008381526020829052604090209250611dcc565b600081815260208490526040902092505b5080611dd781612b6e565b915050611d78565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110611e1957611e19612b58565b602090810291909101015292915050565b6001600160a01b0384163b156108c95760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611e6e9089908990889088908890600401612d8a565b6020604051808303816000875af1925050508015611ea9575060408051601f3d908101601f19168201909252611ea691810190612dcf565b60015b611f5557611eb5612dec565b806308c379a003611eee5750611ec9612e08565b80611ed45750611ef0565b8060405162461bcd60e51b8152600401610619919061231a565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610619565b6001600160e01b0319811663f23a6e6160e01b1461186d5760405162461bcd60e51b815260040161061990612e91565b816001600160a01b0316836001600160a01b031603611ff85760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610619565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384163b156108c95760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906120a99089908990889088908890600401612ed9565b6020604051808303816000875af19250505080156120e4575060408051601f3d908101601f191682019092526120e191810190612dcf565b60015b6120f057611eb5612dec565b6001600160e01b0319811663bc197c8160e01b1461186d5760405162461bcd60e51b815260040161061990612e91565b6001600160a01b0384166121465760405162461bcd60e51b815260040161061990612cfb565b33600061215285611ddf565b9050600061215f85611ddf565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156121a25760405162461bcd60e51b815260040161061990612d40565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906121df908490612b45565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461223f848a8a8a8a8a611e2a565b505050505050505050565b80356001600160a01b038116811461226157600080fd5b919050565b6000806040838503121561227957600080fd5b6122828361224a565b946020939093013593505050565b6001600160e01b0319811681146113de57600080fd5b6000602082840312156122b857600080fd5b81356122c381612290565b9392505050565b60005b838110156122e55781810151838201526020016122cd565b50506000910152565b600081518084526123068160208601602086016122ca565b601f01601f19169290920160200192915050565b6020815260006122c360208301846122ee565b60006020828403121561233f57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b038111828210171561238157612381612346565b6040525050565b60006001600160401b038211156123a1576123a1612346565b5060051b60200190565b600082601f8301126123bc57600080fd5b813560206123c982612388565b6040516123d6828261235c565b83815260059390931b85018201928281019150868411156123f657600080fd5b8286015b8481101561241157803583529183019183016123fa565b509695505050505050565b60006001600160401b0383111561243557612435612346565b60405161244c601f8501601f19166020018261235c565b80915083815284848401111561246157600080fd5b83836020830137600060208583010152509392505050565b600082601f83011261248a57600080fd5b6122c38383356020850161241c565b600080600080600060a086880312156124b157600080fd5b6124ba8661224a565b94506124c86020870161224a565b935060408601356001600160401b03808211156124e457600080fd5b6124f089838a016123ab565b9450606088013591508082111561250657600080fd5b61251289838a016123ab565b9350608088013591508082111561252857600080fd5b5061253588828901612479565b9150509295509295909350565b6000806040838503121561255557600080fd5b50508035926020909101359150565b60006020828403121561257657600080fd5b81356001600160401b0381111561258c57600080fd5b8201601f8101841361259d57600080fd5b6116798482356020840161241c565b600080600080606085870312156125c257600080fd5b843593506125d26020860161224a565b925060408501356001600160401b03808211156125ee57600080fd5b818701915087601f83011261260257600080fd5b81358181111561261157600080fd5b8860208260051b850101111561262657600080fd5b95989497505060200194505050565b6000806040838503121561264857600080fd5b82356001600160401b038082111561265f57600080fd5b818501915085601f83011261267357600080fd5b8135602061268082612388565b60405161268d828261235c565b83815260059390931b85018201928281019150898411156126ad57600080fd5b948201945b838610156126d2576126c38661224a565b825294820194908201906126b2565b965050860135925050808211156126e857600080fd5b506126f5858286016123ab565b9150509250929050565b600081518084526020808501945080840160005b8381101561272f57815187529582019590820190600101612713565b509495945050505050565b6020815260006122c360208301846126ff565b80151581146113de57600080fd5b6000806040838503121561276e57600080fd5b6127778361224a565b915060208301356127878161274d565b809150509250929050565b600080600080608085870312156127a857600080fd5b5050823594602084013594506040840135936060013592509050565b6000602082840312156127d657600080fd5b6122c38261224a565b600080604083850312156127f257600080fd5b82356001600160401b038082111561280957600080fd5b612815868387016123ab565b935060208501359150808211156126e857600080fd5b6000806040838503121561283e57600080fd5b6128478361224a565b91506128556020840161224a565b90509250929050565b600080600080600060a0868803121561287657600080fd5b61287f8661224a565b945061288d6020870161224a565b9350604086013592506060860135915060808601356001600160401b038111156128b657600080fd5b61253588828901612479565b6000806000606084860312156128d757600080fd5b833592506128e76020850161224a565b9150604084013590509250925092565b600181811c9082168061290b57607f821691505b60208210810361292b57634e487b7160e01b600052602260045260246000fd5b50919050565b600080845461293f816128f7565b60018281168015612957576001811461296c5761299b565b60ff198416875282151583028701945061299b565b8860005260208060002060005b858110156129925781548a820152908401908201612979565b50505082870194505b5050505083516129af8183602088016122ca565b64173539b7b760d91b9101908152600501949350505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b601f821115610f3957600081815260208120601f850160051c81016020861015612a245750805b601f850160051c820191505b818110156108c957828155600101612a30565b81516001600160401b03811115612a5c57612a5c612346565b612a7081612a6a84546128f7565b846129fd565b602080601f831160018114612aa55760008415612a8d5750858301515b600019600386901b1c1916600185901b1785556108c9565b600085815260208120601f198616915b82811015612ad457888601518255948401946001909101908401612ab5565b5085821015612af25787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6020808252601390820152724d696e7420636c6f73656420666f72206e6f7760681b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561064557610645612b2f565b634e487b7160e01b600052603260045260246000fd5b600060018201612b8057612b80612b2f565b5060010190565b634e487b7160e01b600052601260045260246000fd5b600082612bac57612bac612b87565b500490565b8181038181111561064557610645612b2f565b600082612bd357612bd3612b87565b500690565b600060208284031215612bea57600080fd5b81516122c38161274d565b6020808252602f908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526e195c881b9bdc88185c1c1c9bdd9959608a1b606082015260800190565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b604081526000612ce060408301856126ff565b8281036020840152612cf281856126ff565b95945050505050565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090612dc4908301846122ee565b979650505050505050565b600060208284031215612de157600080fd5b81516122c381612290565b600060033d1115612e055760046000803e5060005160e01c5b90565b600060443d1015612e165790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715612e4557505050505090565b8285019150815181811115612e5d5750505050505090565b843d8701016020828501011115612e775750505050505090565b612e866020828601018761235c565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a060408201819052600090612f05908301866126ff565b8281036060840152612f1781866126ff565b90508281036080840152612f2b81856122ee565b9897505050505050505056fea264697066735822122061419cd23a06f8a682495699d870fb04022fe8526fde236aee97a4862039ca6e64736f6c63430008110033

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061027e5760003560e01c80636c0360eb1161015c578063c6b80b78116100ce578063e985e9c511610087578063e985e9c514610507578063e9dbebce14610543578063f242432a14610566578063f2fde38b14610579578063f64d5eaa1461058c578063f68902fc1461059f57600080fd5b8063c6b80b78146104af578063ccb98ffc146104b8578063d1239730146104cb578063d351cfdc146104d8578063d3c21fe2146104eb578063e613d8aa146104fe57600080fd5b806395d89b411161012057806395d89b411461045c5780639b894703146104645780639ce93edf1461046d578063a22cb46514610476578063a85af0e714610489578063aa2c63df1461049c57600080fd5b80636c0360eb14610420578063715018a6146104285780637cb64759146104305780637d55094d146104435780638da5cb5b1461044b57600080fd5b806337da577c116101f557806347c699d1116101b957806347c699d1146103ac5780634e1273f4146103bf57806351ceab34146103df57806356ad15f6146103e857806357df96d8146103fb5780635dc96d161461040e57600080fd5b806337da577c1461036057806339f7e37f146103735780633ccfd60b1461038657806341f434341461038e578063453c2310146103a357600080fd5b80631d3d830a116102475780631d3d830a1461031f578063218585211461032857806322dcb0a7146103315780632eb2c2d61461033b5780632eb4a7ab1461034e5780633197cbb61461035757600080fd5b8062fdd58e1461028357806301ffc9a7146102a957806306fdde03146102cc5780630e89341c146102e15780631b40bcf1146102f4575b600080fd5b610296610291366004612266565b6105b2565b6040519081526020015b60405180910390f35b6102bc6102b73660046122a6565b61064b565b60405190151581526020016102a0565b6102d461069b565b6040516102a0919061231a565b6102d46102ef36600461232d565b610729565b600454610307906001600160a01b031681565b6040516001600160a01b0390911681526020016102a0565b61029660105481565b610296600f5481565b61033961085b565b005b610339610349366004612499565b6108a2565b61029660085481565b61029660115481565b61033961036e366004612542565b6108d1565b610339610381366004612564565b610906565b610339610940565b6103076daaeb6d7670e522a718067333cd4e81565b610296600b5481565b6103396103ba3660046125ac565b6109f9565b6103d26103cd366004612635565b610cdb565b6040516102a0919061273a565b610296600e5481565b6103396103f6366004612542565b610e04565b61033961040936600461232d565b610e39565b600a546102bc90610100900460ff1681565b6102d4610e68565b610339610e75565b61033961043e36600461232d565b610eab565b610339610eda565b6003546001600160a01b0316610307565b6102d4610f18565b610296600d5481565b61029660125481565b61033961048436600461275b565b610f25565b610339610497366004612792565b610f3e565b6103396104aa3660046127c4565b610f89565b610296600c5481565b6103396104c636600461232d565b610fd5565b600a546102bc9060ff1681565b6103396104e63660046127df565b611004565b6103396104f93660046125ac565b61105a565b61029660095481565b6102bc61051536600461282b565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b6102bc61055136600461232d565b60136020526000908152604090205460ff1681565b61033961057436600461285e565b61131f565b6103396105873660046127c4565b611346565b61033961059a36600461232d565b6113e1565b6103396105ad3660046128c2565b611410565b60006001600160a01b0383166106225760405162461bcd60e51b815260206004820152602a60248201527f455243313135353a2061646472657373207a65726f206973206e6f742061207660448201526930b634b21037bbb732b960b11b60648201526084015b60405180910390fd5b506000818152602081815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b148061067c57506001600160e01b031982166303a24d0760e21b145b8061064557506301ffc9a760e01b6001600160e01b0319831614610645565b600680546106a8906128f7565b80601f01602080910402602001604051908101604052809291908181526020018280546106d4906128f7565b80156107215780601f106106f657610100808354040283529160200191610721565b820191906000526020600020905b81548152906001019060200180831161070457829003601f168201915b505050505081565b60008181526013602052604090205460609060ff166107845760405162461bcd60e51b81526020600482015260176024820152764e6f7420612076616c6964207469636b6574207479706560481b6044820152606401610619565b600060058054610793906128f7565b90501161082a57600580546107a7906128f7565b80601f01602080910402602001604051908101604052809291908181526020018280546107d3906128f7565b80156108205780601f106107f557610100808354040283529160200191610820565b820191906000526020600020905b81548152906001019060200180831161080357829003601f168201915b5050505050610645565b600561083583611579565b604051602001610846929190612931565b60405160208183030381529060405292915050565b6003546001600160a01b031633146108855760405162461bcd60e51b8152600401610619906129c8565b600a805461ff001981166101009182900460ff1615909102179055565b846001600160a01b03811633146108bc576108bc33611681565b6108c9868686868661173a565b505050505050565b6003546001600160a01b031633146108fb5760405162461bcd60e51b8152600401610619906129c8565b600d91909155600e55565b6003546001600160a01b031633146109305760405162461bcd60e51b8152600401610619906129c8565b600561093c8282612a43565b5050565b6003546001600160a01b0316331461096a5760405162461bcd60e51b8152600401610619906129c8565b6040513390600090829047908381818185875af1925050503d80600081146109ae576040519150601f19603f3d011682016040523d82523d6000602084013e6109b3565b606091505b505090508061093c5760405162461bcd60e51b81526020600482015260126024820152714661696c656420746f20776974686472617760701b6044820152606401610619565b600a5460ff16610a1b5760405162461bcd60e51b815260040161061990612b02565b6011544210610a3c5760405162461bcd60e51b815260040161061990612b02565b333214610a7a5760405162461bcd60e51b815260206004820152600c60248201526b4e6f20636f6e74726163747360a01b6044820152606401610619565b610af1828280806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506008546040516bffffffffffffffffffffffff1960608a901b16602082015290925060340190505b60405160208183030381529060405280519060200120611786565b610b335760405162461bcd60e51b8152602060048201526013602482015272139bdd08185b1b1bddd959081d1bc81b5a5b9d606a1b6044820152606401610619565b600d5484600f54610b449190612b45565b1115610b925760405162461bcd60e51b815260206004820152601b60248201527f4e6f206d6f726520617661696c61626c65207269676874206e6f7700000000006044820152606401610619565b60008411610be25760405162461bcd60e51b815260206004820152601d60248201527f4d757374206d696e74206174206c65617374206f6e65207469636b65740000006044820152606401610619565b600b546001600160a01b03841660009081526014602090815260408083206012548452909152902054610c16908690612b45565b1115610c645760405162461bcd60e51b815260206004820152601d60248201527f4c696d697420666f7220746869732077616c6c657420726561636865640000006044820152606401610619565b6001600160a01b0383166000908152601460209081526040808320601254845290915281208054869290610c99908490612b45565b9250508190555083600f6000828254610cb29190612b45565b92505081905550610cd5836001866040518060200160405280600081525061179c565b50505050565b60608151835114610d405760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610619565b600083516001600160401b03811115610d5b57610d5b612346565b604051908082528060200260200182016040528015610d84578160200160208202803683370190505b50905060005b8451811015610dfc57610dcf858281518110610da857610da8612b58565b6020026020010151858381518110610dc257610dc2612b58565b60200260200101516105b2565b828281518110610de157610de1612b58565b6020908102919091010152610df581612b6e565b9050610d8a565b509392505050565b6003546001600160a01b03163314610e2e5760405162461bcd60e51b8152600401610619906129c8565b600b91909155600c55565b6003546001600160a01b03163314610e635760405162461bcd60e51b8152600401610619906129c8565b600955565b600580546106a8906128f7565b6003546001600160a01b03163314610e9f5760405162461bcd60e51b8152600401610619906129c8565b610ea96000611876565b565b6003546001600160a01b03163314610ed55760405162461bcd60e51b8152600401610619906129c8565b600855565b6003546001600160a01b03163314610f045760405162461bcd60e51b8152600401610619906129c8565b600a805460ff19811660ff90911615179055565b600780546106a8906128f7565b81610f2f81611681565b610f3983836118c8565b505050565b6003546001600160a01b03163314610f685760405162461bcd60e51b8152600401610619906129c8565b600a805460ff19166001179055600d93909355600e91909155601155601255565b6003546001600160a01b03163314610fb35760405162461bcd60e51b8152600401610619906129c8565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6003546001600160a01b03163314610fff5760405162461bcd60e51b8152600401610619906129c8565b601155565b6003546001600160a01b0316331461102e5760405162461bcd60e51b8152600401610619906129c8565b61093c6110436003546001600160a01b031690565b8383604051806020016040528060008152506118d3565b600a5460ff1661107c5760405162461bcd60e51b815260040161061990612b02565b601154421061109d5760405162461bcd60e51b815260040161061990612b02565b3332146110db5760405162461bcd60e51b815260206004820152600c60248201526b4e6f20636f6e74726163747360a01b6044820152606401610619565b61113b828280806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506009546040516bffffffffffffffffffffffff1960608a901b1660208201529092506034019050610ad6565b61117d5760405162461bcd60e51b8152602060048201526013602482015272139bdd08185b1b1bddd959081d1bc81b5a5b9d606a1b6044820152606401610619565b600e548460105461118e9190612b45565b11156111dc5760405162461bcd60e51b815260206004820152601b60248201527f4e6f206d6f726520617661696c61626c65207269676874206e6f7700000000006044820152606401610619565b6000841161122c5760405162461bcd60e51b815260206004820152601d60248201527f4d757374206d696e74206174206c65617374206f6e65207469636b65740000006044820152606401610619565b600b546001600160a01b03841660009081526015602090815260408083206012548452909152902054611260908690612b45565b11156112ae5760405162461bcd60e51b815260206004820152601d60248201527f4c696d697420666f7220746869732077616c6c657420726561636865640000006044820152606401610619565b6001600160a01b03831660009081526015602090815260408083206012548452909152812080548692906112e3908490612b45565b9250508190555083601060008282546112fc9190612b45565b92505081905550610cd5836002866040518060200160405280600081525061179c565b846001600160a01b03811633146113395761133933611681565b6108c98686868686611a1e565b6003546001600160a01b031633146113705760405162461bcd60e51b8152600401610619906129c8565b6001600160a01b0381166113d55760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610619565b6113de81611876565b50565b6003546001600160a01b0316331461140b5760405162461bcd60e51b8152600401610619906129c8565b601255565b600a54610100900460ff166114575760405162461bcd60e51b815260206004820152600d60248201526c213ab937103737ba1037b832b760991b6044820152606401610619565b6004546001600160a01b031633146114aa5760405162461bcd60e51b8152602060048201526016602482015275496e76616c6964206275726e6572206164647265737360501b6044820152606401610619565b600081116114f15760405162461bcd60e51b81526020600482015260146024820152734d757374206275726e206174206c65617374203160601b6044820152606401610619565b60008381526013602052604090205460ff166115495760405162461bcd60e51b81526020600482015260176024820152764e6f7420612076616c6964207469636b6574207479706560481b6044820152606401610619565b611554828483611a63565b610f3982611563856002612b45565b836040518060200160405280600081525061179c565b6060816000036115a05750506040805180820190915260018152600360fc1b602082015290565b8160005b81156115ca57806115b481612b6e565b91506115c39050600a83612b9d565b91506115a4565b6000816001600160401b038111156115e4576115e4612346565b6040519080825280601f01601f19166020018201604052801561160e576020820181803683370190505b5090505b841561167957611623600183612bb1565b9150611630600a86612bc4565b61163b906030612b45565b60f81b81838151811061165057611650612b58565b60200101906001600160f81b031916908160001a905350611672600a86612b9d565b9450611612565b949350505050565b6daaeb6d7670e522a718067333cd4e3b156113de57604051633185c44d60e21b81523060048201526001600160a01b03821660248201526daaeb6d7670e522a718067333cd4e9063c617113490604401602060405180830381865afa1580156116ee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117129190612bd8565b6113de57604051633b79c77360e21b81526001600160a01b0382166004820152602401610619565b6001600160a01b03851633148061175657506117568533610515565b6117725760405162461bcd60e51b815260040161061990612bf5565b61177f8585858585611bdf565b5050505050565b6000826117938584611d73565b14949350505050565b6001600160a01b0384166117c25760405162461bcd60e51b815260040161061990612c44565b3360006117ce85611ddf565b905060006117db85611ddf565b90506000868152602081815260408083206001600160a01b038b1684529091528120805487929061180d908490612b45565b909155505060408051878152602081018790526001600160a01b03808a1692600092918716917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461186d83600089898989611e2a565b50505050505050565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b61093c338383611f85565b6001600160a01b0384166118f95760405162461bcd60e51b815260040161061990612c44565b815183511461191a5760405162461bcd60e51b815260040161061990612c85565b3360005b84518110156119b65783818151811061193957611939612b58565b602002602001015160008087848151811061195657611956612b58565b602002602001015181526020019081526020016000206000886001600160a01b03166001600160a01b03168152602001908152602001600020600082825461199e9190612b45565b909155508190506119ae81612b6e565b91505061191e565b50846001600160a01b031660006001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611a07929190612ccd565b60405180910390a461177f81600087878787612065565b6001600160a01b038516331480611a3a5750611a3a8533610515565b611a565760405162461bcd60e51b815260040161061990612bf5565b61177f8585858585612120565b6001600160a01b038316611ac55760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610619565b336000611ad184611ddf565b90506000611ade84611ddf565b60408051602080820183526000918290528882528181528282206001600160a01b038b1683529052205490915084811015611b675760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610619565b6000868152602081815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a90529092908816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a460408051602081019091526000905261186d565b8151835114611c005760405162461bcd60e51b815260040161061990612c85565b6001600160a01b038416611c265760405162461bcd60e51b815260040161061990612cfb565b3360005b8451811015611d0d576000858281518110611c4757611c47612b58565b602002602001015190506000858381518110611c6557611c65612b58565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015611cb55760405162461bcd60e51b815260040161061990612d40565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290611cf2908490612b45565b9250508190555050505080611d0690612b6e565b9050611c2a565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051611d5d929190612ccd565b60405180910390a46108c9818787878787612065565b600081815b8451811015610dfc576000858281518110611d9557611d95612b58565b60200260200101519050808311611dbb5760008381526020829052604090209250611dcc565b600081815260208490526040902092505b5080611dd781612b6e565b915050611d78565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110611e1957611e19612b58565b602090810291909101015292915050565b6001600160a01b0384163b156108c95760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190611e6e9089908990889088908890600401612d8a565b6020604051808303816000875af1925050508015611ea9575060408051601f3d908101601f19168201909252611ea691810190612dcf565b60015b611f5557611eb5612dec565b806308c379a003611eee5750611ec9612e08565b80611ed45750611ef0565b8060405162461bcd60e51b8152600401610619919061231a565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610619565b6001600160e01b0319811663f23a6e6160e01b1461186d5760405162461bcd60e51b815260040161061990612e91565b816001600160a01b0316836001600160a01b031603611ff85760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610619565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384163b156108c95760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906120a99089908990889088908890600401612ed9565b6020604051808303816000875af19250505080156120e4575060408051601f3d908101601f191682019092526120e191810190612dcf565b60015b6120f057611eb5612dec565b6001600160e01b0319811663bc197c8160e01b1461186d5760405162461bcd60e51b815260040161061990612e91565b6001600160a01b0384166121465760405162461bcd60e51b815260040161061990612cfb565b33600061215285611ddf565b9050600061215f85611ddf565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156121a25760405162461bcd60e51b815260040161061990612d40565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a168252812080548892906121df908490612b45565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a461223f848a8a8a8a8a611e2a565b505050505050505050565b80356001600160a01b038116811461226157600080fd5b919050565b6000806040838503121561227957600080fd5b6122828361224a565b946020939093013593505050565b6001600160e01b0319811681146113de57600080fd5b6000602082840312156122b857600080fd5b81356122c381612290565b9392505050565b60005b838110156122e55781810151838201526020016122cd565b50506000910152565b600081518084526123068160208601602086016122ca565b601f01601f19169290920160200192915050565b6020815260006122c360208301846122ee565b60006020828403121561233f57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b038111828210171561238157612381612346565b6040525050565b60006001600160401b038211156123a1576123a1612346565b5060051b60200190565b600082601f8301126123bc57600080fd5b813560206123c982612388565b6040516123d6828261235c565b83815260059390931b85018201928281019150868411156123f657600080fd5b8286015b8481101561241157803583529183019183016123fa565b509695505050505050565b60006001600160401b0383111561243557612435612346565b60405161244c601f8501601f19166020018261235c565b80915083815284848401111561246157600080fd5b83836020830137600060208583010152509392505050565b600082601f83011261248a57600080fd5b6122c38383356020850161241c565b600080600080600060a086880312156124b157600080fd5b6124ba8661224a565b94506124c86020870161224a565b935060408601356001600160401b03808211156124e457600080fd5b6124f089838a016123ab565b9450606088013591508082111561250657600080fd5b61251289838a016123ab565b9350608088013591508082111561252857600080fd5b5061253588828901612479565b9150509295509295909350565b6000806040838503121561255557600080fd5b50508035926020909101359150565b60006020828403121561257657600080fd5b81356001600160401b0381111561258c57600080fd5b8201601f8101841361259d57600080fd5b6116798482356020840161241c565b600080600080606085870312156125c257600080fd5b843593506125d26020860161224a565b925060408501356001600160401b03808211156125ee57600080fd5b818701915087601f83011261260257600080fd5b81358181111561261157600080fd5b8860208260051b850101111561262657600080fd5b95989497505060200194505050565b6000806040838503121561264857600080fd5b82356001600160401b038082111561265f57600080fd5b818501915085601f83011261267357600080fd5b8135602061268082612388565b60405161268d828261235c565b83815260059390931b85018201928281019150898411156126ad57600080fd5b948201945b838610156126d2576126c38661224a565b825294820194908201906126b2565b965050860135925050808211156126e857600080fd5b506126f5858286016123ab565b9150509250929050565b600081518084526020808501945080840160005b8381101561272f57815187529582019590820190600101612713565b509495945050505050565b6020815260006122c360208301846126ff565b80151581146113de57600080fd5b6000806040838503121561276e57600080fd5b6127778361224a565b915060208301356127878161274d565b809150509250929050565b600080600080608085870312156127a857600080fd5b5050823594602084013594506040840135936060013592509050565b6000602082840312156127d657600080fd5b6122c38261224a565b600080604083850312156127f257600080fd5b82356001600160401b038082111561280957600080fd5b612815868387016123ab565b935060208501359150808211156126e857600080fd5b6000806040838503121561283e57600080fd5b6128478361224a565b91506128556020840161224a565b90509250929050565b600080600080600060a0868803121561287657600080fd5b61287f8661224a565b945061288d6020870161224a565b9350604086013592506060860135915060808601356001600160401b038111156128b657600080fd5b61253588828901612479565b6000806000606084860312156128d757600080fd5b833592506128e76020850161224a565b9150604084013590509250925092565b600181811c9082168061290b57607f821691505b60208210810361292b57634e487b7160e01b600052602260045260246000fd5b50919050565b600080845461293f816128f7565b60018281168015612957576001811461296c5761299b565b60ff198416875282151583028701945061299b565b8860005260208060002060005b858110156129925781548a820152908401908201612979565b50505082870194505b5050505083516129af8183602088016122ca565b64173539b7b760d91b9101908152600501949350505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b601f821115610f3957600081815260208120601f850160051c81016020861015612a245750805b601f850160051c820191505b818110156108c957828155600101612a30565b81516001600160401b03811115612a5c57612a5c612346565b612a7081612a6a84546128f7565b846129fd565b602080601f831160018114612aa55760008415612a8d5750858301515b600019600386901b1c1916600185901b1785556108c9565b600085815260208120601f198616915b82811015612ad457888601518255948401946001909101908401612ab5565b5085821015612af25787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6020808252601390820152724d696e7420636c6f73656420666f72206e6f7760681b604082015260600190565b634e487b7160e01b600052601160045260246000fd5b8082018082111561064557610645612b2f565b634e487b7160e01b600052603260045260246000fd5b600060018201612b8057612b80612b2f565b5060010190565b634e487b7160e01b600052601260045260246000fd5b600082612bac57612bac612b87565b500490565b8181038181111561064557610645612b2f565b600082612bd357612bd3612b87565b500690565b600060208284031215612bea57600080fd5b81516122c38161274d565b6020808252602f908201527f455243313135353a2063616c6c6572206973206e6f7420746f6b656e206f776e60408201526e195c881b9bdc88185c1c1c9bdd9959608a1b606082015260800190565b60208082526021908201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736040820152607360f81b606082015260800190565b60208082526028908201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206040820152670dad2e6dac2e8c6d60c31b606082015260800190565b604081526000612ce060408301856126ff565b8281036020840152612cf281856126ff565b95945050505050565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090612dc4908301846122ee565b979650505050505050565b600060208284031215612de157600080fd5b81516122c381612290565b600060033d1115612e055760046000803e5060005160e01c5b90565b600060443d1015612e165790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715612e4557505050505090565b8285019150815181811115612e5d5750505050505090565b843d8701016020828501011115612e775750505050505090565b612e866020828601018761235c565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b0386811682528516602082015260a060408201819052600090612f05908301866126ff565b8281036060840152612f1781866126ff565b90508281036080840152612f2b81856122ee565b9897505050505050505056fea264697066735822122061419cd23a06f8a682495699d870fb04022fe8526fde236aee97a4862039ca6e64736f6c63430008110033

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.