ETH Price: $3,669.94 (+2.29%)
Gas: 7.83 Gwei

Token

ERC-20: BeachBums (BUMS)
 

Overview

Max Total Supply

133 BUMS

Holders

86

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Filtered by Token Holder
avalle.eth
Balance
1 BUMS
0xb05Fab01652a033ae49380968e5B4f6411Dcd9f1
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:
NounsToken

Compiler Version
v0.8.6+commit.11564f7e

Optimization Enabled:
Yes with 10000 runs

Other Settings:
default evmVersion
File 1 of 20 : NounsToken.sol
// SPDX-License-Identifier: GPL-3.0

/// @title The BeachBum ERC-721 token

// NounsToken.sol modifies Nouns NounsToken.sol:
// https://github.com/nounsDAO/nouns-monorepo/blob/076cd753307632ce8efeb65a07f1bd797a5ecb4d/packages/nouns-contracts/contracts/NounsToken.sol
//
// MODIFICATIONS:
// Stripped of all DAO-related functionality, added Merkle Drop, public mint, and royalty.

pragma solidity ^0.8.6;

import { Ownable } from '@openzeppelin/contracts/access/Ownable.sol';
import { ERC721 } from '@openzeppelin/contracts/token/ERC721/ERC721.sol';
import { ERC721Enumerable } from '@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol';
import { IERC721 } from '@openzeppelin/contracts/token/ERC721/IERC721.sol';
import { IERC20 } from '@openzeppelin/contracts/token/ERC20/IERC20.sol';
import '@openzeppelin/contracts/utils/cryptography/MerkleProof.sol';
import { INounsDescriptor } from './interfaces/INounsDescriptor.sol';
import { INounsSeeder } from './interfaces/INounsSeeder.sol';
import { INounsToken } from './interfaces/INounsToken.sol';
import { IProxyRegistry } from './external/opensea/IProxyRegistry.sol';

contract NounsToken is INounsToken, Ownable, ERC721Enumerable {
    // An address who has admin permissions
    address public admin;

    // Mint fee
    uint256 public mintFee;

    // Royalty basis
    uint256 public royaltyBasis;

    // Max supply
    uint256 public immutable maxSupply;

    // Merkle root
    bytes32 public root;

    // Number of accounts in merkle drop
    uint256 public merkleQuantity;

    // Claims from merkle drop
    mapping(address => bool) merkleClaims;

    // The Nouns token URI descriptor
    INounsDescriptor public descriptor;

    // The Nouns token seeder
    INounsSeeder public seeder;

    // Whether the admin can be updated
    bool public isAdminLocked;

    // Whether the public mint is enabled
    bool public isMintEnabled;

    // The noun seeds
    mapping(uint256 => INounsSeeder.Seed) public seeds;

    // The internal noun ID tracker
    uint256 private _currentNounId;

    // IPFS content hash of contract-level metadata
    string private _contractURIHash = 'bafkreia6f76hnnnmnjdawhelgy7sojfr6bcctd5cy6bsnlnsq777tviedi';

    // OpenSea's Proxy Registry
    IProxyRegistry public immutable proxyRegistry;

    /**
     * @notice Require that the sender is the admin.
     */
    modifier onlyAdminOrOwner() {
        require(
            ((msg.sender == admin) && !isAdminLocked) || (msg.sender == owner()),
            'Sender is not the owner or admin'
        );
        _;
    }

    /**
     * @notice Require that the mint is enabled
     */
    modifier mintEnabled() {
        require(isMintEnabled, 'Mint is disabled');
        _;
    }

    constructor(
        address _admin,
        uint256 _mintFee,
        uint256 _royaltyBasis,
        uint256 _maxSupply,
        bytes32 _root,
        uint256 _merkleQuantity,
        INounsDescriptor _descriptor,
        INounsSeeder _seeder,
        IProxyRegistry _proxyRegistry
    ) ERC721('BeachBums', 'BUMS') {
        admin = _admin;
        mintFee = _mintFee;
        royaltyBasis = _royaltyBasis;
        maxSupply = _maxSupply;
        root = _root;
        merkleQuantity = _merkleQuantity;
        descriptor = _descriptor;
        seeder = _seeder;
        proxyRegistry = _proxyRegistry;
    }

    /**
     * @notice The IPFS URI of contract-level metadata.
     */
    function contractURI() public view returns (string memory) {
        return string(abi.encodePacked('ipfs://', _contractURIHash));
    }

    /**
     * @notice Set the _contractURIHash.
     * @dev Only callable by the owner.
     */
    function setContractURIHash(string memory newContractURIHash) external onlyOwner {
        _contractURIHash = newContractURIHash;
    }

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

    /**
     * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of
     * exchange. The royalty amount is denominated and should be payed in that same unit of exchange.
     */
    function royaltyInfo(uint256, uint256 salePrice)
        external
        view
        override
        returns (address receiver, uint256 royaltyAmount)
    {
        return (address(this), ((salePrice * royaltyBasis) / 10000));
    }

    /**
     * @notice Withdraw balance of contract to owner
     */
    function withdraw() external override onlyOwner {
        payable(owner()).transfer(address(this).balance);
    }

    /**
     * @notice Withdraw ERC20 balance of contract to owner
     */
    function withdrawERC20Balance(address erc20ContractAddress) external override onlyOwner {
        IERC20(erc20ContractAddress).transfer(owner(), IERC20(erc20ContractAddress).balanceOf(address(this)));
    }

    /**
     * @notice Mint a Noun to address
     * @dev Call _mintTo with the to address(es).
     */
    function mint(address account) public payable override mintEnabled returns (uint256) {
        require(msg.value >= mintFee, 'Insufficient mint fee');
        require(_currentNounId + merkleQuantity < maxSupply, 'Max supply reached');
        return _mintTo(account, _currentNounId++);
    }

    /**
     * @notice Mint multiple Nouns to address
     * @dev Call _mintTo with the to address(es).
     */
    function mintBatch(address account, uint256 quantity)
        public
        payable
        override
        mintEnabled
        returns (uint256, uint256)
    {
        require(msg.value >= mintFee * quantity, 'Insufficient mint fee');
        require(_currentNounId + quantity + merkleQuantity < maxSupply, 'Max supply reached');
        uint256 startId = _currentNounId;
        for (uint256 i = 0; i < quantity; i++) {
            _mintTo(account, _currentNounId++);
        }
        return (startId, _currentNounId - 1);
    }

    /**
     * @notice Mint a Noun to address in merkle drop
     */
    function redeem(address account, bytes32[] calldata proof) public override returns (uint256) {
        require(_verify(_leaf(account), proof), 'Invalid proof');
        require(_currentNounId < maxSupply, 'Max supply reached');
        require(!merkleClaims[account], 'Already claimed');
        merkleClaims[account] = true;
        return _mintTo(account, _currentNounId++);
    }

    function _leaf(address account) internal pure returns (bytes32) {
        return keccak256(abi.encodePacked(account));
    }

    function _verify(bytes32 leaf, bytes32[] memory proof) internal view returns (bool) {
        return MerkleProof.verify(proof, root, leaf);
    }

    /**
     * @notice A distinct Uniform Resource Identifier (URI) for a given asset.
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view override returns (string memory) {
        require(_exists(tokenId), 'NounsToken: URI query for nonexistent token');
        return descriptor.tokenURI(tokenId, seeds[tokenId]);
    }

    /**
     * @notice Similar to `tokenURI`, but always serves a base64 encoded data URI
     * with the JSON contents directly inlined.
     */
    function dataURI(uint256 tokenId) public view override returns (string memory) {
        require(_exists(tokenId), 'NounsToken: URI query for nonexistent token');
        return descriptor.dataURI(tokenId, seeds[tokenId]);
    }

    /**
     * @notice Set merkle root
     * @dev Only callable by admin or owner
     */
    function setRoot(bytes32 merkleRoot, uint256 quantity) external override onlyAdminOrOwner {
        root = merkleRoot;
        merkleQuantity = quantity;
    }

    /**
     * @notice Set mint fee
     * @dev Only callable by admin or owner
     */
    function setMintFee(uint256 fee) external override onlyAdminOrOwner {
        mintFee = fee;
    }

    /**
     * @notice Set mint fee
     * @dev Only callable by admin or owner
     */
    function toggleMint() external override onlyAdminOrOwner {
        isMintEnabled = !isMintEnabled;
    }

    /**
     * @notice Set royalty basis
     * @dev Only callable by admin or owner
     */
    function setRoyalty(uint256 _royaltyBasis) external override onlyAdminOrOwner {
        require(_royaltyBasis <= 10000, 'Royalty cannot exceed 100%');
        royaltyBasis = _royaltyBasis;
    }

    /**
     * @notice Set the token admin.
     * @dev Only callable by the owner when not locked.
     */
    function setAdmin(address _admin) external override onlyOwner {
        admin = _admin;

        emit AdminUpdated(_admin);
    }

    /**
     * @notice Lock the admin.
     * @dev This cannot be reversed and is only callable by the owner when not locked.
     */
    function lockAdmin() external override onlyOwner {
        isAdminLocked = true;

        emit AdminLocked();
    }

    /**
     * @notice Mint a BeachBum with `nounId` to the provided `to` address.
     */
    function _mintTo(address to, uint256 nounId) internal returns (uint256) {
        INounsSeeder.Seed memory seed = seeds[nounId] = seeder.generateSeed(nounId, descriptor);

        _safeMint(to, nounId);
        emit BeachBumCreated(nounId, seed);

        return nounId;
    }
}

File 2 of 20 : 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 3 of 20 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

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

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

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

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

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

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

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

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

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

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

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

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

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

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

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

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

        _approve(to, tokenId);
    }

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

        return _tokenApprovals[tokenId];
    }

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

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

    /**
     * @dev See {IERC721-transferFrom}.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public virtual override {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");

        _transfer(from, to, tokenId);
    }

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

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

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * `_data` is additional data, it has no specified format and it is sent in call to `to`.
     *
     * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
     * implement alternative mechanisms to perform token transfer, such as signature-based.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeTransfer(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _transfer(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
    }

    /**
     * @dev Returns whether `tokenId` exists.
     *
     * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
     *
     * Tokens start existing when they are minted (`_mint`),
     * and stop existing when they are burned (`_burn`).
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool) {
        return _owners[tokenId] != address(0);
    }

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

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

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

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

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

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

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

        _afterTokenTransfer(address(0), to, tokenId);
    }

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

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

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

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

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

        _afterTokenTransfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

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

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

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

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

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits a {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC721: approve to caller");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

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

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

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 4 of 20 : ERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

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

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}

File 5 of 20 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

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

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

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

File 6 of 20 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @dev Emitted when `value` tokens are moved from one account (`from`) to
     * another (`to`).
     *
     * Note that `value` may be zero.
     */
    event Transfer(address indexed from, address indexed to, uint256 value);

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

    /**
     * @dev Returns the amount of tokens in existence.
     */
    function totalSupply() external view returns (uint256);

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

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

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

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

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

File 7 of 20 : 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 8 of 20 : INounsDescriptor.sol
// SPDX-License-Identifier: GPL-3.0

/// @title Interface for NounsDescriptor

/*********************************
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░██░░░████░░██░░░████░░░ *
 * ░░██████░░░████████░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 *********************************/

pragma solidity ^0.8.6;

import { INounsSeeder } from './INounsSeeder.sol';

interface INounsDescriptor {
    event PartsLocked();

    event DataURIToggled(bool enabled);

    event BaseURIUpdated(string baseURI);

    function arePartsLocked() external returns (bool);

    function isDataURIEnabled() external returns (bool);

    function baseURI() external returns (string memory);

    function palettes(uint8 paletteIndex, uint256 colorIndex) external view returns (string memory);

    function backgrounds(uint256 index) external view returns (string memory);

    function bodies(uint256 index) external view returns (bytes memory);

    function accessories(uint256 index) external view returns (bytes memory);

    function heads(uint256 index) external view returns (bytes memory);

    function glasses(uint256 index) external view returns (bytes memory);

    function backgroundCount() external view returns (uint256);

    function bodyCount() external view returns (uint256);

    function accessoryCount() external view returns (uint256);

    function headCount() external view returns (uint256);

    function glassesCount() external view returns (uint256);

    function addManyColorsToPalette(uint8 paletteIndex, string[] calldata newColors) external;

    function addManyBackgrounds(string[] calldata backgrounds) external;

    function addManyBodies(bytes[] calldata bodies) external;

    function addManyAccessories(bytes[] calldata accessories) external;

    function addManyHeads(bytes[] calldata heads) external;

    function addManyGlasses(bytes[] calldata glasses) external;

    function addColorToPalette(uint8 paletteIndex, string calldata color) external;

    function addBackground(string calldata background) external;

    function addBody(bytes calldata body) external;

    function addAccessory(bytes calldata accessory) external;

    function addHead(bytes calldata head) external;

    function addGlasses(bytes calldata glasses) external;

    function lockParts() external;

    function toggleDataURIEnabled() external;

    function setBaseURI(string calldata baseURI) external;

    function tokenURI(uint256 tokenId, INounsSeeder.Seed memory seed) external view returns (string memory);

    function dataURI(uint256 tokenId, INounsSeeder.Seed memory seed) external view returns (string memory);

    function genericDataURI(
        string calldata name,
        string calldata description,
        INounsSeeder.Seed memory seed
    ) external view returns (string memory);

    function generateSVGImage(INounsSeeder.Seed memory seed) external view returns (string memory);
}

File 9 of 20 : INounsSeeder.sol
// SPDX-License-Identifier: GPL-3.0

/// @title Interface for NounsSeeder

/*********************************
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░██░░░████░░██░░░████░░░ *
 * ░░██████░░░████████░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 *********************************/

pragma solidity ^0.8.6;

import { INounsDescriptor } from './INounsDescriptor.sol';

interface INounsSeeder {
    struct Seed {
        uint48 background;
        uint48 body;
        uint48 accessory;
        uint48 head;
        uint48 glasses;
    }

    function generateSeed(uint256 nounId, INounsDescriptor descriptor) external view returns (Seed memory);
}

File 10 of 20 : INounsToken.sol
// SPDX-License-Identifier: GPL-3.0

/// @title Interface for NounsToken

/*********************************
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░██░░░████░░██░░░████░░░ *
 * ░░██████░░░████████░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░██░░██░░░████░░██░░░████░░░ *
 * ░░░░░░█████████░░█████████░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 * ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ *
 *********************************/

pragma solidity ^0.8.6;

import { IERC721 } from '@openzeppelin/contracts/token/ERC721/IERC721.sol';
import { IERC2981 } from '@openzeppelin/contracts/interfaces/IERC2981.sol';
import { INounsDescriptor } from './INounsDescriptor.sol';
import { INounsSeeder } from './INounsSeeder.sol';

interface INounsToken is IERC721, IERC2981 {
    event BeachBumCreated(uint256 indexed tokenId, INounsSeeder.Seed seed);

    event AdminUpdated(address minter);

    event AdminLocked();

    function withdraw() external;

    function withdrawERC20Balance(address erc20ContractAddress) external;

    function mint(address account) external payable returns (uint256);

    function mintBatch(address account, uint256 quantity) external payable returns (uint256, uint256);

    function redeem(address account, bytes32[] calldata proof) external returns (uint256);

    function dataURI(uint256 tokenId) external returns (string memory);

    function setRoot(bytes32 merkleRoot, uint256 quantity) external;

    function setMintFee(uint256 fee) external;

    function toggleMint() external;

    function setAdmin(address minter) external;

    function setRoyalty(uint256 royaltyBasis) external;

    function lockAdmin() external;
}

File 11 of 20 : IProxyRegistry.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.6;

interface IProxyRegistry {
    function proxies(address) external view returns (address);
}

File 12 of 20 : 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 13 of 20 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

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

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

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

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

pragma solidity ^0.8.0;

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

File 19 of 20 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

File 20 of 20 : IERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (interfaces/IERC2981.sol)

pragma solidity ^0.8.0;

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

/**
 * @dev Interface for the NFT Royalty Standard.
 *
 * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal
 * support for royalty payments across all NFT marketplaces and ecosystem participants.
 *
 * _Available since v4.5._
 */
interface IERC2981 is IERC165 {
    /**
     * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of
     * exchange. The royalty amount is denominated and should be paid in that same unit of exchange.
     */
    function royaltyInfo(uint256 tokenId, uint256 salePrice)
        external
        view
        returns (address receiver, uint256 royaltyAmount);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_admin","type":"address"},{"internalType":"uint256","name":"_mintFee","type":"uint256"},{"internalType":"uint256","name":"_royaltyBasis","type":"uint256"},{"internalType":"uint256","name":"_maxSupply","type":"uint256"},{"internalType":"bytes32","name":"_root","type":"bytes32"},{"internalType":"uint256","name":"_merkleQuantity","type":"uint256"},{"internalType":"contract INounsDescriptor","name":"_descriptor","type":"address"},{"internalType":"contract INounsSeeder","name":"_seeder","type":"address"},{"internalType":"contract IProxyRegistry","name":"_proxyRegistry","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[],"name":"AdminLocked","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"minter","type":"address"}],"name":"AdminUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"},{"components":[{"internalType":"uint48","name":"background","type":"uint48"},{"internalType":"uint48","name":"body","type":"uint48"},{"internalType":"uint48","name":"accessory","type":"uint48"},{"internalType":"uint48","name":"head","type":"uint48"},{"internalType":"uint48","name":"glasses","type":"uint48"}],"indexed":false,"internalType":"struct INounsSeeder.Seed","name":"seed","type":"tuple"}],"name":"BeachBumCreated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"admin","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"dataURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"descriptor","outputs":[{"internalType":"contract INounsDescriptor","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isAdminLocked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isMintEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"lockAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleQuantity","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"mint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"mintBatch","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintFee","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":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"proxyRegistry","outputs":[{"internalType":"contract IProxyRegistry","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"redeem","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"root","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"royaltyBasis","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint256","name":"royaltyAmount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"seeder","outputs":[{"internalType":"contract INounsSeeder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"seeds","outputs":[{"internalType":"uint48","name":"background","type":"uint48"},{"internalType":"uint48","name":"body","type":"uint48"},{"internalType":"uint48","name":"accessory","type":"uint48"},{"internalType":"uint48","name":"head","type":"uint48"},{"internalType":"uint48","name":"glasses","type":"uint48"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_admin","type":"address"}],"name":"setAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newContractURIHash","type":"string"}],"name":"setContractURIHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"fee","type":"uint256"}],"name":"setMintFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"setRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_royaltyBasis","type":"uint256"}],"name":"setRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"erc20ContractAddress","type":"address"}],"name":"withdrawERC20Balance","outputs":[],"stateMutability":"nonpayable","type":"function"}]

610120604052603b60c08181529062003e9060e03980516200002a91601591602090910190620001a4565b503480156200003857600080fd5b5060405162003ecb38038062003ecb8339810160408190526200005b916200024a565b60405180604001604052806009815260200168426561636842756d7360b81b8152506040518060400160405280600481526020016342554d5360e01b815250620000b4620000ae6200015060201b60201c565b62000154565b8151620000c9906001906020850190620001a4565b508051620000df906002906020840190620001a4565b5050600b80546001600160a01b03199081166001600160a01b039c8d1617909155600c9990995550600d96909655608094909452600e92909255600f5560118054851691861691909117905560128054909316931692909217905560601b6001600160601b03191660a0526200033c565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b828054620001b290620002e6565b90600052602060002090601f016020900481019282620001d6576000855562000221565b82601f10620001f157805160ff191683800117855562000221565b8280016001018555821562000221579182015b828111156200022157825182559160200191906001019062000204565b506200022f92915062000233565b5090565b5b808211156200022f576000815560010162000234565b60008060008060008060008060006101208a8c0312156200026a57600080fd5b8951620002778162000323565b8099505060208a0151975060408a0151965060608a0151955060808a0151945060a08a0151935060c08a0151620002ae8162000323565b60e08b0151909350620002c18162000323565b6101008b0151909250620002d58162000323565b809150509295985092959850929598565b600181811c90821680620002fb57607f821691505b602082108114156200031d57634e487b7160e01b600052602260045260246000fd5b50919050565b6001600160a01b03811681146200033957600080fd5b50565b60805160a05160601c613b0f62000381600039600081816107050152611d580152600081816107c401528181610e7e0152818161155901526118980152613b0f6000f3fe6080604052600436106102fd5760003560e01c806370a082311161018f578063c87b56dd116100e1578063ebf0c7171161008a578063f0503e8011610064578063f0503e8014610891578063f2fde38b14610959578063f851a4401461097957600080fd5b8063ebf0c7171461083b578063edbe2a2114610851578063eddd0d9c1461087157600080fd5b8063e8a3d485116100bb578063e8a3d485146107e6578063e985e9c5146107fb578063ea4b81751461081b57600080fd5b8063c87b56dd1461077d578063d3dd5fe01461079d578063d5abeb01146107b257600080fd5b8063a0e6c8d311610143578063b88d4fde1161011d578063b88d4fde14610727578063baedc1c414610747578063c6ec69091461076757600080fd5b8063a0e6c8d3146106bd578063a22cb465146106d3578063b50cbd9f146106f357600080fd5b80637a607ce6116101745780637a607ce61461066a5780638da5cb5b1461068a57806395d89b41146106a857600080fd5b806370a0823114610635578063715018a61461065557600080fd5b8063303e74df116102535780634f6ccce7116101fc578063684931ed116101d6578063684931ed146105e25780636a62784214610602578063704b6c021461061557600080fd5b80634f6ccce7146105825780635ac1e3bb146105a25780636352211e146105c257600080fd5b80633ccfd60b1161022d5780633ccfd60b1461052d5780634209a2e11461054257806342842e0e1461056257600080fd5b8063303e74df146104a857806330aa2f74146104c8578063346de50a146104fa57600080fd5b806316fd265d116102b5578063248b71fc1161028f578063248b71fc146104215780632a55205a146104495780632f745c591461048857600080fd5b806316fd265d146103d757806318160ddd146103ec57806323b872dd1461040157600080fd5b8063081812fc116102e6578063081812fc14610359578063095ea7b31461039157806313966db5146103b357600080fd5b806301ffc9a71461030257806306fdde0314610337575b600080fd5b34801561030e57600080fd5b5061032261031d366004613482565b610999565b60405190151581526020015b60405180910390f35b34801561034357600080fd5b5061034c6109f5565b60405161032e91906137c4565b34801561036557600080fd5b5061037961037436600461360a565b610a87565b6040516001600160a01b03909116815260200161032e565b34801561039d57600080fd5b506103b16103ac366004613417565b610b32565b005b3480156103bf57600080fd5b506103c9600c5481565b60405190815260200161032e565b3480156103e357600080fd5b506103b1610c64565b3480156103f857600080fd5b506009546103c9565b34801561040d57600080fd5b506103b161041c3660046132a0565b610d28565b61043461042f366004613417565b610daf565b6040805192835260208301919091520161032e565b34801561045557600080fd5b50610469610464366004613460565b610f62565b604080516001600160a01b03909316835260208301919091520161032e565b34801561049457600080fd5b506103c96104a3366004613417565b610f8c565b3480156104b457600080fd5b50601154610379906001600160a01b031681565b3480156104d457600080fd5b506012546103229074010000000000000000000000000000000000000000900460ff1681565b34801561050657600080fd5b50601254610322907501000000000000000000000000000000000000000000900460ff1681565b34801561053957600080fd5b506103b1611034565b34801561054e57600080fd5b506103b161055d36600461360a565b6110cb565b34801561056e57600080fd5b506103b161057d3660046132a0565b6111b8565b34801561058e57600080fd5b506103c961059d36600461360a565b6111d3565b3480156105ae57600080fd5b5061034c6105bd36600461360a565b611277565b3480156105ce57600080fd5b506103796105dd36600461360a565b61140c565b3480156105ee57600080fd5b50601254610379906001600160a01b031681565b6103c961061036600461322d565b611497565b34801561062157600080fd5b506103b161063036600461322d565b6115f0565b34801561064157600080fd5b506103c961065036600461322d565b6116b6565b34801561066157600080fd5b506103b1611750565b34801561067657600080fd5b506103c9610685366004613361565b6117b6565b34801561069657600080fd5b506000546001600160a01b0316610379565b3480156106b457600080fd5b5061034c6119cd565b3480156106c957600080fd5b506103c9600f5481565b3480156106df57600080fd5b506103b16106ee3660046133e9565b6119dc565b3480156106ff57600080fd5b506103797f000000000000000000000000000000000000000000000000000000000000000081565b34801561073357600080fd5b506103b16107423660046132e1565b6119eb565b34801561075357600080fd5b506103b16107623660046134bc565b611a79565b34801561077357600080fd5b506103c9600d5481565b34801561078957600080fd5b5061034c61079836600461360a565b611ae6565b3480156107a957600080fd5b506103b1611c0d565b3480156107be57600080fd5b506103c97f000000000000000000000000000000000000000000000000000000000000000081565b3480156107f257600080fd5b5061034c611cf1565b34801561080757600080fd5b50610322610816366004613267565b611d19565b34801561082757600080fd5b506103b161083636600461322d565b611e1a565b34801561084757600080fd5b506103c9600e5481565b34801561085d57600080fd5b506103b161086c366004613460565b611fbb565b34801561087d57600080fd5b506103b161088c36600461360a565b61205c565b34801561089d57600080fd5b506109206108ac36600461360a565b60136020526000908152604090205465ffffffffffff80821691660100000000000081048216916c0100000000000000000000000082048116917201000000000000000000000000000000000000810482169178010000000000000000000000000000000000000000000000009091041685565b6040805165ffffffffffff968716815294861660208601529285169284019290925283166060830152909116608082015260a00161032e565b34801561096557600080fd5b506103b161097436600461322d565b6120f7565b34801561098557600080fd5b50600b54610379906001600160a01b031681565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f780e9d630000000000000000000000000000000000000000000000000000000014806109ef57506109ef826121d6565b92915050565b606060018054610a049061393f565b80601f0160208091040260200160405190810160405280929190818152602001828054610a309061393f565b8015610a7d5780601f10610a5257610100808354040283529160200191610a7d565b820191906000526020600020905b815481529060010190602001808311610a6057829003601f168201915b5050505050905090565b6000818152600360205260408120546001600160a01b0316610b165760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6000610b3d8261140c565b9050806001600160a01b0316836001600160a01b03161415610bc75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610b0d565b336001600160a01b0382161480610be35750610be38133611d19565b610c555760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b0d565b610c5f83836122b9565b505050565b6000546001600160a01b03163314610cbe5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000001790556040517f2ebfa3b1768cf63c3a13ff624298bc3f4d8a98ea5a6a2a4dd0c64c1dd3fc9c3790600090a1565b610d32338261233f565b610da45760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610b0d565b610c5f838383612426565b60125460009081907501000000000000000000000000000000000000000000900460ff16610e1f5760405162461bcd60e51b815260206004820152601060248201527f4d696e742069732064697361626c6564000000000000000000000000000000006044820152606401610b0d565b82600c54610e2d91906138bf565b341015610e7c5760405162461bcd60e51b815260206004820152601560248201527f496e73756666696369656e74206d696e742066656500000000000000000000006044820152606401610b0d565b7f0000000000000000000000000000000000000000000000000000000000000000600f5484601454610eae919061386c565b610eb8919061386c565b10610f055760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b60145460005b84811015610f455760148054610f32918891906000610f2983613993565b91905055612616565b5080610f3d81613993565b915050610f0b565b50806001601454610f5691906138fc565b92509250509250929050565b60008030612710600d5485610f7791906138bf565b610f819190613884565b915091509250929050565b6000610f97836116b6565b821061100b5760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610b0d565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b6000546001600160a01b0316331461108e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b600080546040516001600160a01b03909116914780156108fc02929091818181858888f193505050501580156110c8573d6000803e3d6000fd5b50565b600b546001600160a01b031633148015611100575060125474010000000000000000000000000000000000000000900460ff16155b8061111557506000546001600160a01b031633145b6111615760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b6127108111156111b35760405162461bcd60e51b815260206004820152601a60248201527f526f79616c74792063616e6e6f742065786365656420313030250000000000006044820152606401610b0d565b600d55565b610c5f838383604051806020016040528060008152506119eb565b60006111de60095490565b82106112525760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610b0d565b6009828154811061126557611265613a2a565b90600052602060002001549050919050565b6000818152600360205260409020546060906001600160a01b03166113045760405162461bcd60e51b815260206004820152602b60248201527f4e6f756e73546f6b656e3a2055524920717565727920666f72206e6f6e65786960448201527f7374656e7420746f6b656e0000000000000000000000000000000000000000006064820152608401610b0d565b6011546000838152601360205260409081902090517f638ac27000000000000000000000000000000000000000000000000000000000815260048101859052905465ffffffffffff8082166024840152603082901c81166044840152606082901c81166064840152609082901c8116608484015260c09190911c1660a48201526001600160a01b039091169063638ac2709060c4015b60006040518083038186803b1580156113b257600080fd5b505afa1580156113c6573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526109ef9190810190613505565b6000818152600360205260408120546001600160a01b0316806109ef5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610b0d565b6012546000907501000000000000000000000000000000000000000000900460ff166115055760405162461bcd60e51b815260206004820152601060248201527f4d696e742069732064697361626c6564000000000000000000000000000000006044820152606401610b0d565b600c543410156115575760405162461bcd60e51b815260206004820152601560248201527f496e73756666696369656e74206d696e742066656500000000000000000000006044820152606401610b0d565b7f0000000000000000000000000000000000000000000000000000000000000000600f54601454611588919061386c565b106115d55760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b601480546109ef918491906000610f2983613993565b919050565b6000546001600160a01b0316331461164a5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b600b80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040519081527f54e4612788f90384e6843298d7854436f3a585b2c3831ab66abf1de63bfa6c2d9060200160405180910390a150565b60006001600160a01b0382166117345760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610b0d565b506001600160a01b031660009081526004602052604090205490565b6000546001600160a01b031633146117aa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b6117b460006128ad565b565b600061184a611811856040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606083901b166020820152600090603401604051602081830303815290604052805190602001209050919050565b84848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525061291592505050565b6118965760405162461bcd60e51b815260206004820152600d60248201527f496e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610b0d565b7f0000000000000000000000000000000000000000000000000000000000000000601454106119075760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b6001600160a01b03841660009081526010602052604090205460ff16156119705760405162461bcd60e51b815260206004820152600f60248201527f416c726561647920636c61696d656400000000000000000000000000000000006044820152606401610b0d565b6001600160a01b038416600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055601480546119c592879290610f2983613993565b949350505050565b606060028054610a049061393f565b6119e7338383612924565b5050565b6119f5338361233f565b611a675760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610b0d565b611a7384848484612a11565b50505050565b6000546001600160a01b03163314611ad35760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b80516119e7906015906020840190613140565b6000818152600360205260409020546060906001600160a01b0316611b735760405162461bcd60e51b815260206004820152602b60248201527f4e6f756e73546f6b656e3a2055524920717565727920666f72206e6f6e65786960448201527f7374656e7420746f6b656e0000000000000000000000000000000000000000006064820152608401610b0d565b6011546000838152601360205260409081902090517f3cfdafd300000000000000000000000000000000000000000000000000000000815260048101859052905465ffffffffffff8082166024840152603082901c81166044840152606082901c81166064840152609082901c8116608484015260c09190911c1660a48201526001600160a01b0390911690633cfdafd39060c40161139a565b600b546001600160a01b031633148015611c42575060125474010000000000000000000000000000000000000000900460ff16155b80611c5757506000546001600160a01b031633145b611ca35760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b601280547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff811675010000000000000000000000000000000000000000009182900460ff1615909102179055565b60606015604051602001611d059190613686565b604051602081830303815290604052905090565b6040517fc45527910000000000000000000000000000000000000000000000000000000081526001600160a01b038381166004830152600091818416917f0000000000000000000000000000000000000000000000000000000000000000169063c45527919060240160206040518083038186803b158015611d9a57600080fd5b505afa158015611dae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dd2919061324a565b6001600160a01b03161415611de9575060016109ef565b6001600160a01b0380841660009081526006602090815260408083209386168352929052205460ff165b9392505050565b6000546001600160a01b03163314611e745760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b806001600160a01b031663a9059cbb611e956000546001600160a01b031690565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038516906370a082319060240160206040518083038186803b158015611eed57600080fd5b505afa158015611f01573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f259190613623565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b158015611f8357600080fd5b505af1158015611f97573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119e79190613443565b600b546001600160a01b031633148015611ff0575060125474010000000000000000000000000000000000000000900460ff16155b8061200557506000546001600160a01b031633145b6120515760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b600e91909155600f55565b600b546001600160a01b031633148015612091575060125474010000000000000000000000000000000000000000900460ff16155b806120a657506000546001600160a01b031633145b6120f25760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b600c55565b6000546001600160a01b031633146121515760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b6001600160a01b0381166121cd5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610b0d565b6110c8816128ad565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd00000000000000000000000000000000000000000000000000000000148061226957507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806109ef57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146109ef565b600081815260056020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03841690811790915581906123068261140c565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600360205260408120546001600160a01b03166123c95760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610b0d565b60006123d48361140c565b9050806001600160a01b0316846001600160a01b031614806123fb57506123fb8185611d19565b806119c55750836001600160a01b031661241484610a87565b6001600160a01b031614949350505050565b826001600160a01b03166124398261140c565b6001600160a01b0316146124b55760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152608401610b0d565b6001600160a01b0382166125305760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610b0d565b61253b838383612a9a565b6125466000826122b9565b6001600160a01b038316600090815260046020526040812080546001929061256f9084906138fc565b90915550506001600160a01b038216600090815260046020526040812080546001929061259d90849061386c565b909155505060008181526003602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6012546011546040517f422e2e99000000000000000000000000000000000000000000000000000000008152600481018490526001600160a01b0391821660248201526000928392169063422e2e999060440160a06040518083038186803b15801561268157600080fd5b505afa158015612695573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126b9919061357c565b6000848152601360209081526040918290208351815485840151868601516060808901516080998a015165ffffffffffff9687167fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009096169590951766010000000000009487168502177fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c0100000000000000000000000093871684027fffffffffffffffff000000000000ffffffffffffffffffffffffffffffffffff161772010000000000000000000000000000000000009187168202177fffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff811678010000000000000000000000000000000000000000000000009688168702908117988990558a5160a081018c5291881690881617815293870486169784019790975290850484169682019690965293830482169484019490945292900490911691810191909152905061282c8484612b52565b827f502bf3a06fe3e4ec5021a2e5761584b4d203aa9245e29c81d0971510f81e3cbf8260405161289d9190815165ffffffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608092830151169181019190915260a00190565b60405180910390a2509092915050565b600080546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000611e1382600e5485612b6c565b816001600160a01b0316836001600160a01b031614156129865760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b0d565b6001600160a01b0383811660008181526006602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b612a1c848484612426565b612a2884848484612b82565b611a735760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b6001600160a01b038316612af557612af081600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b612b18565b816001600160a01b0316836001600160a01b031614612b1857612b188382612d4d565b6001600160a01b038216612b2f57610c5f81612dea565b826001600160a01b0316826001600160a01b031614610c5f57610c5f8282612e99565b6119e7828260405180602001604052806000815250612edd565b600082612b798584612f66565b14949350505050565b60006001600160a01b0384163b15612d42576040517f150b7a020000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063150b7a0290612bdf903390899088908890600401613788565b602060405180830381600087803b158015612bf957600080fd5b505af1925050508015612c47575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252612c449181019061349f565b60015b612cf7573d808015612c75576040519150601f19603f3d011682016040523d82523d6000602084013e612c7a565b606091505b508051612cef5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a02000000000000000000000000000000000000000000000000000000001490506119c5565b506001949350505050565b60006001612d5a846116b6565b612d6491906138fc565b600083815260086020526040902054909150808214612db7576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090612dfc906001906138fc565b6000838152600a602052604081205460098054939450909284908110612e2457612e24613a2a565b906000526020600020015490508060098381548110612e4557612e45613a2a565b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480612e7d57612e7d6139fb565b6001900381819060005260206000200160009055905550505050565b6000612ea4836116b6565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b612ee78383612fda565b612ef46000848484612b82565b610c5f5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b600081815b8451811015612fd2576000858281518110612f8857612f88613a2a565b60200260200101519050808311612fae5760008381526020829052604090209250612fbf565b600081815260208490526040902092505b5080612fca81613993565b915050612f6b565b509392505050565b6001600160a01b0382166130305760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b0d565b6000818152600360205260409020546001600160a01b0316156130955760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b0d565b6130a160008383612a9a565b6001600160a01b03821660009081526004602052604081208054600192906130ca90849061386c565b909155505060008181526003602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b82805461314c9061393f565b90600052602060002090601f01602090048101928261316e57600085556131b4565b82601f1061318757805160ff19168380011785556131b4565b828001600101855582156131b4579182015b828111156131b4578251825591602001919060010190613199565b506131c09291506131c4565b5090565b5b808211156131c057600081556001016131c5565b60006131ec6131e784613826565b6137d7565b905082815283838301111561320057600080fd5b828260208301376000602084830101529392505050565b805165ffffffffffff811681146115eb57600080fd5b60006020828403121561323f57600080fd5b8135611e1381613a88565b60006020828403121561325c57600080fd5b8151611e1381613a88565b6000806040838503121561327a57600080fd5b823561328581613a88565b9150602083013561329581613a88565b809150509250929050565b6000806000606084860312156132b557600080fd5b83356132c081613a88565b925060208401356132d081613a88565b929592945050506040919091013590565b600080600080608085870312156132f757600080fd5b843561330281613a88565b9350602085013561331281613a88565b925060408501359150606085013567ffffffffffffffff81111561333557600080fd5b8501601f8101871361334657600080fd5b613355878235602084016131d9565b91505092959194509250565b60008060006040848603121561337657600080fd5b833561338181613a88565b9250602084013567ffffffffffffffff8082111561339e57600080fd5b818601915086601f8301126133b257600080fd5b8135818111156133c157600080fd5b8760208260051b85010111156133d657600080fd5b6020830194508093505050509250925092565b600080604083850312156133fc57600080fd5b823561340781613a88565b9150602083013561329581613a9d565b6000806040838503121561342a57600080fd5b823561343581613a88565b946020939093013593505050565b60006020828403121561345557600080fd5b8151611e1381613a9d565b6000806040838503121561347357600080fd5b50508035926020909101359150565b60006020828403121561349457600080fd5b8135611e1381613aab565b6000602082840312156134b157600080fd5b8151611e1381613aab565b6000602082840312156134ce57600080fd5b813567ffffffffffffffff8111156134e557600080fd5b8201601f810184136134f657600080fd5b6119c5848235602084016131d9565b60006020828403121561351757600080fd5b815167ffffffffffffffff81111561352e57600080fd5b8201601f8101841361353f57600080fd5b805161354d6131e782613826565b81815285602083850101111561356257600080fd5b613573826020830160208601613913565b95945050505050565b600060a0828403121561358e57600080fd5b60405160a0810181811067ffffffffffffffff821117156135b1576135b1613a59565b6040526135bd83613217565b81526135cb60208401613217565b60208201526135dc60408401613217565b60408201526135ed60608401613217565b60608201526135fe60808401613217565b60808201529392505050565b60006020828403121561361c57600080fd5b5035919050565b60006020828403121561363557600080fd5b5051919050565b60008151808452613654816020860160208601613913565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f697066733a2f2f000000000000000000000000000000000000000000000000008152600060076000845481600182811c9150808316806136c857607f831692505b6020808410821415613701577f4e487b710000000000000000000000000000000000000000000000000000000086526022600452602486fd5b818015613715576001811461374857613779565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616888b015287858b01019650613779565b60008b81526020902060005b8681101561376f5781548c82018b0152908501908301613754565b505087858b010196505b50949998505050505050505050565b60006001600160a01b038087168352808616602084015250836040830152608060608301526137ba608083018461363c565b9695505050505050565b602081526000611e13602083018461363c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561381e5761381e613a59565b604052919050565b600067ffffffffffffffff82111561384057613840613a59565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b6000821982111561387f5761387f6139cc565b500190565b6000826138ba577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156138f7576138f76139cc565b500290565b60008282101561390e5761390e6139cc565b500390565b60005b8381101561392e578181015183820152602001613916565b83811115611a735750506000910152565b600181811c9082168061395357607f821691505b6020821081141561398d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156139c5576139c56139cc565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6001600160a01b03811681146110c857600080fd5b80151581146110c857600080fd5b7fffffffff00000000000000000000000000000000000000000000000000000000811681146110c857600080fdfea264697066735822122089c5dbe7d132ab69515c0c7bf1db38194f33c125d56224a5d7f16866673f99d664736f6c634300080600336261666b7265696136663736686e6e6e6d6e6a64617768656c677937736f6a66723662636374643563793662736e6c6e73713737377476696564690000000000000000000000005f2c241092d589af5dd8c0f3f9663cd91fb62f99000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002bc000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c8000000000000000000000000c1801078b577c7df4b34853ec2834ee61ef5bc61000000000000000000000000f471077fd111bccbbe4fa57e212bb5770693267d000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1

Deployed Bytecode

0x6080604052600436106102fd5760003560e01c806370a082311161018f578063c87b56dd116100e1578063ebf0c7171161008a578063f0503e8011610064578063f0503e8014610891578063f2fde38b14610959578063f851a4401461097957600080fd5b8063ebf0c7171461083b578063edbe2a2114610851578063eddd0d9c1461087157600080fd5b8063e8a3d485116100bb578063e8a3d485146107e6578063e985e9c5146107fb578063ea4b81751461081b57600080fd5b8063c87b56dd1461077d578063d3dd5fe01461079d578063d5abeb01146107b257600080fd5b8063a0e6c8d311610143578063b88d4fde1161011d578063b88d4fde14610727578063baedc1c414610747578063c6ec69091461076757600080fd5b8063a0e6c8d3146106bd578063a22cb465146106d3578063b50cbd9f146106f357600080fd5b80637a607ce6116101745780637a607ce61461066a5780638da5cb5b1461068a57806395d89b41146106a857600080fd5b806370a0823114610635578063715018a61461065557600080fd5b8063303e74df116102535780634f6ccce7116101fc578063684931ed116101d6578063684931ed146105e25780636a62784214610602578063704b6c021461061557600080fd5b80634f6ccce7146105825780635ac1e3bb146105a25780636352211e146105c257600080fd5b80633ccfd60b1161022d5780633ccfd60b1461052d5780634209a2e11461054257806342842e0e1461056257600080fd5b8063303e74df146104a857806330aa2f74146104c8578063346de50a146104fa57600080fd5b806316fd265d116102b5578063248b71fc1161028f578063248b71fc146104215780632a55205a146104495780632f745c591461048857600080fd5b806316fd265d146103d757806318160ddd146103ec57806323b872dd1461040157600080fd5b8063081812fc116102e6578063081812fc14610359578063095ea7b31461039157806313966db5146103b357600080fd5b806301ffc9a71461030257806306fdde0314610337575b600080fd5b34801561030e57600080fd5b5061032261031d366004613482565b610999565b60405190151581526020015b60405180910390f35b34801561034357600080fd5b5061034c6109f5565b60405161032e91906137c4565b34801561036557600080fd5b5061037961037436600461360a565b610a87565b6040516001600160a01b03909116815260200161032e565b34801561039d57600080fd5b506103b16103ac366004613417565b610b32565b005b3480156103bf57600080fd5b506103c9600c5481565b60405190815260200161032e565b3480156103e357600080fd5b506103b1610c64565b3480156103f857600080fd5b506009546103c9565b34801561040d57600080fd5b506103b161041c3660046132a0565b610d28565b61043461042f366004613417565b610daf565b6040805192835260208301919091520161032e565b34801561045557600080fd5b50610469610464366004613460565b610f62565b604080516001600160a01b03909316835260208301919091520161032e565b34801561049457600080fd5b506103c96104a3366004613417565b610f8c565b3480156104b457600080fd5b50601154610379906001600160a01b031681565b3480156104d457600080fd5b506012546103229074010000000000000000000000000000000000000000900460ff1681565b34801561050657600080fd5b50601254610322907501000000000000000000000000000000000000000000900460ff1681565b34801561053957600080fd5b506103b1611034565b34801561054e57600080fd5b506103b161055d36600461360a565b6110cb565b34801561056e57600080fd5b506103b161057d3660046132a0565b6111b8565b34801561058e57600080fd5b506103c961059d36600461360a565b6111d3565b3480156105ae57600080fd5b5061034c6105bd36600461360a565b611277565b3480156105ce57600080fd5b506103796105dd36600461360a565b61140c565b3480156105ee57600080fd5b50601254610379906001600160a01b031681565b6103c961061036600461322d565b611497565b34801561062157600080fd5b506103b161063036600461322d565b6115f0565b34801561064157600080fd5b506103c961065036600461322d565b6116b6565b34801561066157600080fd5b506103b1611750565b34801561067657600080fd5b506103c9610685366004613361565b6117b6565b34801561069657600080fd5b506000546001600160a01b0316610379565b3480156106b457600080fd5b5061034c6119cd565b3480156106c957600080fd5b506103c9600f5481565b3480156106df57600080fd5b506103b16106ee3660046133e9565b6119dc565b3480156106ff57600080fd5b506103797f000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c181565b34801561073357600080fd5b506103b16107423660046132e1565b6119eb565b34801561075357600080fd5b506103b16107623660046134bc565b611a79565b34801561077357600080fd5b506103c9600d5481565b34801561078957600080fd5b5061034c61079836600461360a565b611ae6565b3480156107a957600080fd5b506103b1611c0d565b3480156107be57600080fd5b506103c97f00000000000000000000000000000000000000000000000000000000000002bc81565b3480156107f257600080fd5b5061034c611cf1565b34801561080757600080fd5b50610322610816366004613267565b611d19565b34801561082757600080fd5b506103b161083636600461322d565b611e1a565b34801561084757600080fd5b506103c9600e5481565b34801561085d57600080fd5b506103b161086c366004613460565b611fbb565b34801561087d57600080fd5b506103b161088c36600461360a565b61205c565b34801561089d57600080fd5b506109206108ac36600461360a565b60136020526000908152604090205465ffffffffffff80821691660100000000000081048216916c0100000000000000000000000082048116917201000000000000000000000000000000000000810482169178010000000000000000000000000000000000000000000000009091041685565b6040805165ffffffffffff968716815294861660208601529285169284019290925283166060830152909116608082015260a00161032e565b34801561096557600080fd5b506103b161097436600461322d565b6120f7565b34801561098557600080fd5b50600b54610379906001600160a01b031681565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f780e9d630000000000000000000000000000000000000000000000000000000014806109ef57506109ef826121d6565b92915050565b606060018054610a049061393f565b80601f0160208091040260200160405190810160405280929190818152602001828054610a309061393f565b8015610a7d5780601f10610a5257610100808354040283529160200191610a7d565b820191906000526020600020905b815481529060010190602001808311610a6057829003601f168201915b5050505050905090565b6000818152600360205260408120546001600160a01b0316610b165760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6000610b3d8261140c565b9050806001600160a01b0316836001600160a01b03161415610bc75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610b0d565b336001600160a01b0382161480610be35750610be38133611d19565b610c555760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b0d565b610c5f83836122b9565b505050565b6000546001600160a01b03163314610cbe5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b601280547fffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff16740100000000000000000000000000000000000000001790556040517f2ebfa3b1768cf63c3a13ff624298bc3f4d8a98ea5a6a2a4dd0c64c1dd3fc9c3790600090a1565b610d32338261233f565b610da45760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610b0d565b610c5f838383612426565b60125460009081907501000000000000000000000000000000000000000000900460ff16610e1f5760405162461bcd60e51b815260206004820152601060248201527f4d696e742069732064697361626c6564000000000000000000000000000000006044820152606401610b0d565b82600c54610e2d91906138bf565b341015610e7c5760405162461bcd60e51b815260206004820152601560248201527f496e73756666696369656e74206d696e742066656500000000000000000000006044820152606401610b0d565b7f00000000000000000000000000000000000000000000000000000000000002bc600f5484601454610eae919061386c565b610eb8919061386c565b10610f055760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b60145460005b84811015610f455760148054610f32918891906000610f2983613993565b91905055612616565b5080610f3d81613993565b915050610f0b565b50806001601454610f5691906138fc565b92509250509250929050565b60008030612710600d5485610f7791906138bf565b610f819190613884565b915091509250929050565b6000610f97836116b6565b821061100b5760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610b0d565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b6000546001600160a01b0316331461108e5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b600080546040516001600160a01b03909116914780156108fc02929091818181858888f193505050501580156110c8573d6000803e3d6000fd5b50565b600b546001600160a01b031633148015611100575060125474010000000000000000000000000000000000000000900460ff16155b8061111557506000546001600160a01b031633145b6111615760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b6127108111156111b35760405162461bcd60e51b815260206004820152601a60248201527f526f79616c74792063616e6e6f742065786365656420313030250000000000006044820152606401610b0d565b600d55565b610c5f838383604051806020016040528060008152506119eb565b60006111de60095490565b82106112525760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610b0d565b6009828154811061126557611265613a2a565b90600052602060002001549050919050565b6000818152600360205260409020546060906001600160a01b03166113045760405162461bcd60e51b815260206004820152602b60248201527f4e6f756e73546f6b656e3a2055524920717565727920666f72206e6f6e65786960448201527f7374656e7420746f6b656e0000000000000000000000000000000000000000006064820152608401610b0d565b6011546000838152601360205260409081902090517f638ac27000000000000000000000000000000000000000000000000000000000815260048101859052905465ffffffffffff8082166024840152603082901c81166044840152606082901c81166064840152609082901c8116608484015260c09190911c1660a48201526001600160a01b039091169063638ac2709060c4015b60006040518083038186803b1580156113b257600080fd5b505afa1580156113c6573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526109ef9190810190613505565b6000818152600360205260408120546001600160a01b0316806109ef5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610b0d565b6012546000907501000000000000000000000000000000000000000000900460ff166115055760405162461bcd60e51b815260206004820152601060248201527f4d696e742069732064697361626c6564000000000000000000000000000000006044820152606401610b0d565b600c543410156115575760405162461bcd60e51b815260206004820152601560248201527f496e73756666696369656e74206d696e742066656500000000000000000000006044820152606401610b0d565b7f00000000000000000000000000000000000000000000000000000000000002bc600f54601454611588919061386c565b106115d55760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b601480546109ef918491906000610f2983613993565b919050565b6000546001600160a01b0316331461164a5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b600b80547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0383169081179091556040519081527f54e4612788f90384e6843298d7854436f3a585b2c3831ab66abf1de63bfa6c2d9060200160405180910390a150565b60006001600160a01b0382166117345760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610b0d565b506001600160a01b031660009081526004602052604090205490565b6000546001600160a01b031633146117aa5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b6117b460006128ad565b565b600061184a611811856040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606083901b166020820152600090603401604051602081830303815290604052805190602001209050919050565b84848080602002602001604051908101604052809392919081815260200183836020028082843760009201919091525061291592505050565b6118965760405162461bcd60e51b815260206004820152600d60248201527f496e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610b0d565b7f00000000000000000000000000000000000000000000000000000000000002bc601454106119075760405162461bcd60e51b815260206004820152601260248201527f4d617820737570706c79207265616368656400000000000000000000000000006044820152606401610b0d565b6001600160a01b03841660009081526010602052604090205460ff16156119705760405162461bcd60e51b815260206004820152600f60248201527f416c726561647920636c61696d656400000000000000000000000000000000006044820152606401610b0d565b6001600160a01b038416600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055601480546119c592879290610f2983613993565b949350505050565b606060028054610a049061393f565b6119e7338383612924565b5050565b6119f5338361233f565b611a675760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610b0d565b611a7384848484612a11565b50505050565b6000546001600160a01b03163314611ad35760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b80516119e7906015906020840190613140565b6000818152600360205260409020546060906001600160a01b0316611b735760405162461bcd60e51b815260206004820152602b60248201527f4e6f756e73546f6b656e3a2055524920717565727920666f72206e6f6e65786960448201527f7374656e7420746f6b656e0000000000000000000000000000000000000000006064820152608401610b0d565b6011546000838152601360205260409081902090517f3cfdafd300000000000000000000000000000000000000000000000000000000815260048101859052905465ffffffffffff8082166024840152603082901c81166044840152606082901c81166064840152609082901c8116608484015260c09190911c1660a48201526001600160a01b0390911690633cfdafd39060c40161139a565b600b546001600160a01b031633148015611c42575060125474010000000000000000000000000000000000000000900460ff16155b80611c5757506000546001600160a01b031633145b611ca35760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b601280547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff811675010000000000000000000000000000000000000000009182900460ff1615909102179055565b60606015604051602001611d059190613686565b604051602081830303815290604052905090565b6040517fc45527910000000000000000000000000000000000000000000000000000000081526001600160a01b038381166004830152600091818416917f000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1169063c45527919060240160206040518083038186803b158015611d9a57600080fd5b505afa158015611dae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dd2919061324a565b6001600160a01b03161415611de9575060016109ef565b6001600160a01b0380841660009081526006602090815260408083209386168352929052205460ff165b9392505050565b6000546001600160a01b03163314611e745760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b806001600160a01b031663a9059cbb611e956000546001600160a01b031690565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526001600160a01b038516906370a082319060240160206040518083038186803b158015611eed57600080fd5b505afa158015611f01573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f259190613623565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b1681526001600160a01b0390921660048301526024820152604401602060405180830381600087803b158015611f8357600080fd5b505af1158015611f97573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119e79190613443565b600b546001600160a01b031633148015611ff0575060125474010000000000000000000000000000000000000000900460ff16155b8061200557506000546001600160a01b031633145b6120515760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b600e91909155600f55565b600b546001600160a01b031633148015612091575060125474010000000000000000000000000000000000000000900460ff16155b806120a657506000546001600160a01b031633145b6120f25760405162461bcd60e51b815260206004820181905260248201527f53656e646572206973206e6f7420746865206f776e6572206f722061646d696e6044820152606401610b0d565b600c55565b6000546001600160a01b031633146121515760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610b0d565b6001600160a01b0381166121cd5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610b0d565b6110c8816128ad565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd00000000000000000000000000000000000000000000000000000000148061226957507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b806109ef57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff000000000000000000000000000000000000000000000000000000008316146109ef565b600081815260056020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03841690811790915581906123068261140c565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600360205260408120546001600160a01b03166123c95760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610b0d565b60006123d48361140c565b9050806001600160a01b0316846001600160a01b031614806123fb57506123fb8185611d19565b806119c55750836001600160a01b031661241484610a87565b6001600160a01b031614949350505050565b826001600160a01b03166124398261140c565b6001600160a01b0316146124b55760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201527f6f776e65720000000000000000000000000000000000000000000000000000006064820152608401610b0d565b6001600160a01b0382166125305760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610b0d565b61253b838383612a9a565b6125466000826122b9565b6001600160a01b038316600090815260046020526040812080546001929061256f9084906138fc565b90915550506001600160a01b038216600090815260046020526040812080546001929061259d90849061386c565b909155505060008181526003602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6012546011546040517f422e2e99000000000000000000000000000000000000000000000000000000008152600481018490526001600160a01b0391821660248201526000928392169063422e2e999060440160a06040518083038186803b15801561268157600080fd5b505afa158015612695573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126b9919061357c565b6000848152601360209081526040918290208351815485840151868601516060808901516080998a015165ffffffffffff9687167fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009096169590951766010000000000009487168502177fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c0100000000000000000000000093871684027fffffffffffffffff000000000000ffffffffffffffffffffffffffffffffffff161772010000000000000000000000000000000000009187168202177fffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff811678010000000000000000000000000000000000000000000000009688168702908117988990558a5160a081018c5291881690881617815293870486169784019790975290850484169682019690965293830482169484019490945292900490911691810191909152905061282c8484612b52565b827f502bf3a06fe3e4ec5021a2e5761584b4d203aa9245e29c81d0971510f81e3cbf8260405161289d9190815165ffffffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608092830151169181019190915260a00190565b60405180910390a2509092915050565b600080546001600160a01b038381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6000611e1382600e5485612b6c565b816001600160a01b0316836001600160a01b031614156129865760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b0d565b6001600160a01b0383811660008181526006602090815260408083209487168084529482529182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b612a1c848484612426565b612a2884848484612b82565b611a735760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b6001600160a01b038316612af557612af081600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b612b18565b816001600160a01b0316836001600160a01b031614612b1857612b188382612d4d565b6001600160a01b038216612b2f57610c5f81612dea565b826001600160a01b0316826001600160a01b031614610c5f57610c5f8282612e99565b6119e7828260405180602001604052806000815250612edd565b600082612b798584612f66565b14949350505050565b60006001600160a01b0384163b15612d42576040517f150b7a020000000000000000000000000000000000000000000000000000000081526001600160a01b0385169063150b7a0290612bdf903390899088908890600401613788565b602060405180830381600087803b158015612bf957600080fd5b505af1925050508015612c47575060408051601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201909252612c449181019061349f565b60015b612cf7573d808015612c75576040519150601f19603f3d011682016040523d82523d6000602084013e612c7a565b606091505b508051612cef5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a02000000000000000000000000000000000000000000000000000000001490506119c5565b506001949350505050565b60006001612d5a846116b6565b612d6491906138fc565b600083815260086020526040902054909150808214612db7576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090612dfc906001906138fc565b6000838152600a602052604081205460098054939450909284908110612e2457612e24613a2a565b906000526020600020015490508060098381548110612e4557612e45613a2a565b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480612e7d57612e7d6139fb565b6001900381819060005260206000200160009055905550505050565b6000612ea4836116b6565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b612ee78383612fda565b612ef46000848484612b82565b610c5f5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610b0d565b600081815b8451811015612fd2576000858281518110612f8857612f88613a2a565b60200260200101519050808311612fae5760008381526020829052604090209250612fbf565b600081815260208490526040902092505b5080612fca81613993565b915050612f6b565b509392505050565b6001600160a01b0382166130305760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b0d565b6000818152600360205260409020546001600160a01b0316156130955760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b0d565b6130a160008383612a9a565b6001600160a01b03821660009081526004602052604081208054600192906130ca90849061386c565b909155505060008181526003602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b82805461314c9061393f565b90600052602060002090601f01602090048101928261316e57600085556131b4565b82601f1061318757805160ff19168380011785556131b4565b828001600101855582156131b4579182015b828111156131b4578251825591602001919060010190613199565b506131c09291506131c4565b5090565b5b808211156131c057600081556001016131c5565b60006131ec6131e784613826565b6137d7565b905082815283838301111561320057600080fd5b828260208301376000602084830101529392505050565b805165ffffffffffff811681146115eb57600080fd5b60006020828403121561323f57600080fd5b8135611e1381613a88565b60006020828403121561325c57600080fd5b8151611e1381613a88565b6000806040838503121561327a57600080fd5b823561328581613a88565b9150602083013561329581613a88565b809150509250929050565b6000806000606084860312156132b557600080fd5b83356132c081613a88565b925060208401356132d081613a88565b929592945050506040919091013590565b600080600080608085870312156132f757600080fd5b843561330281613a88565b9350602085013561331281613a88565b925060408501359150606085013567ffffffffffffffff81111561333557600080fd5b8501601f8101871361334657600080fd5b613355878235602084016131d9565b91505092959194509250565b60008060006040848603121561337657600080fd5b833561338181613a88565b9250602084013567ffffffffffffffff8082111561339e57600080fd5b818601915086601f8301126133b257600080fd5b8135818111156133c157600080fd5b8760208260051b85010111156133d657600080fd5b6020830194508093505050509250925092565b600080604083850312156133fc57600080fd5b823561340781613a88565b9150602083013561329581613a9d565b6000806040838503121561342a57600080fd5b823561343581613a88565b946020939093013593505050565b60006020828403121561345557600080fd5b8151611e1381613a9d565b6000806040838503121561347357600080fd5b50508035926020909101359150565b60006020828403121561349457600080fd5b8135611e1381613aab565b6000602082840312156134b157600080fd5b8151611e1381613aab565b6000602082840312156134ce57600080fd5b813567ffffffffffffffff8111156134e557600080fd5b8201601f810184136134f657600080fd5b6119c5848235602084016131d9565b60006020828403121561351757600080fd5b815167ffffffffffffffff81111561352e57600080fd5b8201601f8101841361353f57600080fd5b805161354d6131e782613826565b81815285602083850101111561356257600080fd5b613573826020830160208601613913565b95945050505050565b600060a0828403121561358e57600080fd5b60405160a0810181811067ffffffffffffffff821117156135b1576135b1613a59565b6040526135bd83613217565b81526135cb60208401613217565b60208201526135dc60408401613217565b60408201526135ed60608401613217565b60608201526135fe60808401613217565b60808201529392505050565b60006020828403121561361c57600080fd5b5035919050565b60006020828403121561363557600080fd5b5051919050565b60008151808452613654816020860160208601613913565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f697066733a2f2f000000000000000000000000000000000000000000000000008152600060076000845481600182811c9150808316806136c857607f831692505b6020808410821415613701577f4e487b710000000000000000000000000000000000000000000000000000000086526022600452602486fd5b818015613715576001811461374857613779565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616888b015287858b01019650613779565b60008b81526020902060005b8681101561376f5781548c82018b0152908501908301613754565b505087858b010196505b50949998505050505050505050565b60006001600160a01b038087168352808616602084015250836040830152608060608301526137ba608083018461363c565b9695505050505050565b602081526000611e13602083018461363c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561381e5761381e613a59565b604052919050565b600067ffffffffffffffff82111561384057613840613a59565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b6000821982111561387f5761387f6139cc565b500190565b6000826138ba577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156138f7576138f76139cc565b500290565b60008282101561390e5761390e6139cc565b500390565b60005b8381101561392e578181015183820152602001613916565b83811115611a735750506000910152565b600181811c9082168061395357607f821691505b6020821081141561398d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156139c5576139c56139cc565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6001600160a01b03811681146110c857600080fd5b80151581146110c857600080fd5b7fffffffff00000000000000000000000000000000000000000000000000000000811681146110c857600080fdfea264697066735822122089c5dbe7d132ab69515c0c7bf1db38194f33c125d56224a5d7f16866673f99d664736f6c63430008060033

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

0000000000000000000000005f2c241092d589af5dd8c0f3f9663cd91fb62f99000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002bc000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c8000000000000000000000000c1801078b577c7df4b34853ec2834ee61ef5bc61000000000000000000000000f471077fd111bccbbe4fa57e212bb5770693267d000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1

-----Decoded View---------------
Arg [0] : _admin (address): 0x5f2c241092d589af5Dd8c0f3f9663cD91fB62F99
Arg [1] : _mintFee (uint256): 100000000000000000
Arg [2] : _royaltyBasis (uint256): 0
Arg [3] : _maxSupply (uint256): 700
Arg [4] : _root (bytes32): 0x0000000000000000000000000000000000000000000000000000000000000000
Arg [5] : _merkleQuantity (uint256): 200
Arg [6] : _descriptor (address): 0xC1801078B577C7dF4b34853Ec2834ee61EF5Bc61
Arg [7] : _seeder (address): 0xf471077fd111bcCBBe4fa57E212bb5770693267D
Arg [8] : _proxyRegistry (address): 0xa5409ec958C83C3f309868babACA7c86DCB077c1

-----Encoded View---------------
9 Constructor Arguments found :
Arg [0] : 0000000000000000000000005f2c241092d589af5dd8c0f3f9663cd91fb62f99
Arg [1] : 000000000000000000000000000000000000000000000000016345785d8a0000
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [3] : 00000000000000000000000000000000000000000000000000000000000002bc
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000000
Arg [5] : 00000000000000000000000000000000000000000000000000000000000000c8
Arg [6] : 000000000000000000000000c1801078b577c7df4b34853ec2834ee61ef5bc61
Arg [7] : 000000000000000000000000f471077fd111bccbbe4fa57e212bb5770693267d
Arg [8] : 000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1


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.