ETH Price: $3,418.57 (-7.37%)

Token

ikon-1 (IKON)
 

Overview

Max Total Supply

0 IKON

Holders

384

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
2 IKON
0xcdbab8ff4de3c9ab024c4f17cb10b82e25ae16a3
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:
Ikon1

Compiler Version
v0.8.7+commit.e28d00a7

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 21 : ikon-1.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// artist: Nick Knight
/// title: ikon-1
/// @author: manifold.xyz

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//                                                                                                              //
//                                                                                                              //
//                                                                                                              //
//                                                       &@@@@@@,                                               //
//                                                   .@@@@@@@@@@@@@@,                                           //
//                                                  #@@@@@@@@@@@@@@@@.                                          //
//                                                 .@@@@@@@@@@@@@@@@@(                                          //
//                                                 .@@@@@@@@@@@@@@@@@(                                          //
//                                                  @@@@#&@@@@@@@@@@@  .&                                       //
//                                              ,% *@/@@@@@@@@@@@@@@@@ @/                                       //
//                                               @.%@@@@@@@@@@@@@@@@@&/@.                                       //
//                                                @ @@@@@@%@@@@@@@@@@ *                                         //
//                                                  .@@@@@@@@@@@@@@@&                                           //
//                                                   .%@@@@@@@@@@@@.                                            //
//                                                    ...@@@@@@@@@..                                            //
//                                                     @#.@@@@@@@@@.                                            //
//                                                     .@@@@@@@@@@@@.                                           //
//                                                      @@@@@@@@@@@@@@@.                                        //
//                                                      @@@@@@@@@@@@@(@@@@@&@@@@@@.                             //
//                                                   %.(.@@@@@@/#@@@///@@@@@@@@@@@@@@.                          //
//                                             .   %..@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@#                         //
//                                    .  .,@@@.@@@@&@@@@@@@@@(@@@@@@@@@@@@@@@@@@@@@@@@@.                        //
//                               .@@@@@@@@@@@@@@@@*.  .&@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@                        //
//                              %@@@@@@@@@@@@@@@@&@@@@@@&@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@.                       //
//                            .@@@@@@@@@@@@@@@@&#@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@,                       //
//                           /@@@@@*.&@@@*@@@@#@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&                       //
//                          @@@@@@@%@@@@@@@@/@@@&@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@                       //
//                        *@@@@@@@/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@                       //
//                       @@@@@@@(*@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/@@@@@@@@@@@@.                      //
//                     .@@@@@@@( @@/..@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/   *@@@@@@@@@@@                      //
//                     @@@@@@@@ ,@/@ (@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/,     %@@@@@@@@@@                      //
//                    .@@@@@@@, .@   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@(&        @@@@@@@@@@                      //
//                    @@@@@@&%      @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@#.         *@@@@@@@@@.                     //
//                    (@@@@&.       @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&#            @@@@@@@@@#                     //
//                     .&          .@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@&              %@@@@@@@@@                     //
//                                  %@@@@@@@@@@@@@@@@@@@@@@@@@@@%                ,@@@@@@@@@                     //
//                                 .@@@@@@@@@@@@@@@@@@@@@@@@@@%.                  @@@@@@@@@.                    //
//                                .@@@@@@@@@@@@@@@@@@@@@@@@@@@                    /@@@@@@@@@                    //
//                                &@@@,@@@@@@@@@@@@@@@@@@@@&/                     *@@@@@@@@@                    //
//                                @@@@.@@@@@@@@@@@@@@@@@@@@@.                      //@@@@@@@                    //
//                                @@@%@@@@@@@@@@@@@@@@@@@@@#@                      ./@@@@@@@/                   //
//                             .  @@@@@@@@@@@@@@@@@@@@@@@@@@((                     ./@@@@@@@%                   //
//                             . .%@@@@@@@@@@@@@@@@@@@@@@@@@@@,.                   .%@@@@@@@&                   //
//                                .@@@@@@@@@@@@@@@@@@@@@@@@@@@@&                   .@@@@@@@@(                   //
//                               . *@@@@@@@@@@@@@@@@@@@@@@@@@@&@,                   @@@@@@@@,                   //
//                                ..@@@@@@@@@@@@@@@@@@@@@@@@@@@@@                   @@@@@@@@.                   //
//                            . .   @@@@@@@@@@@@@@@@@@@@@@@@@@@@@.                  @@@@@@@@                    //
//                            *@@.. .@@@@@@@@@@@@@@@@@@@@@@@@@@@@&                  #@@@@@@@                    //
//                .@@%      @@@                                                              @@@                //
//                          @@@                  &&*                &&.                  @@@@@@@                //
//                .@@&      @@@   #@@@       @@@/   @@@       .@@@&   @@@                    @@@                //
//                .@@@      @@@  @@@        @@@       @@      .@@      @@/                   @@@                //
//                .@@@      @@@ @@@         @@(       @@*     .@@      @@/     @@@@@@@@      @@@                //
//                .@@@      @@@   @@@.      &@@.     @@@      .@@      @@(                   @@@                //
//                .@@@      @@@     @@@@      &@@@@@@@        .@@      @@(                   @@@                //
//                                                                                                              //
//                                                                                                              //
//                                                                                                              //
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////

import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@manifoldxyz/libraries-solidity/contracts/access/AdminControl.sol";

import "./ERC721CollectionBase.sol";
import "./CrossmintPayable.sol";

contract Ikon1 is ERC721CollectionBase, ERC721, AdminControl, CrossmintPayable {
    constructor(address signingAddress) ERC721("ikon-1", "IKON") {
        _initialize(
            // Total supply
            8000,
            // Purchase price (0.2 ETH)
            200000000000000000,
            // Purchase limit 
            0,
            // Transaction limit 
            0,
            // Presale purchase price (0.15 ETH)
            150000000000000000,
            // Presale purchase limit 
            3,
            signingAddress,
            // Use dynamic presale purchase limit
            false
        );
    }

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

    /**
     * @dev See {IERC721Collection-withdraw}.
     */
    function withdraw(address payable recipient, uint256 amount)
        external
        override
        adminRequired
    {
        _withdraw(recipient, amount);
    }

    /**
     * @dev See {IERC721Collection-setTransferLocked}.
     */
    function setTransferLocked(bool locked) external override adminRequired {
        _setTransferLocked(locked);
    }

    /**
     * @dev See {IERC721Collection-premint}.
     */
    function premint(uint16 amount) external override adminRequired {
        _premint(amount, owner());
    }

    /**
     * @dev See {IERC721Collection-premint}.
     */
    function premint(address[] calldata addresses)
        external
        override
        adminRequired
    {
        _premint(addresses);
    }

    /**
     * @dev Purchase function for Crossmint
     */
    function purchaseCrossmint(
        address to,
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) external payable onlyCrossmint {
        _purchase(to, amount, message, signature, nonce);
        emit PurchaseCrossmint(nonce);
    }

    /**
     * @dev See {IERC721Collection-activate}.
     */
    function activate(
        uint256 startTime_,
        uint256 duration,
        uint256 presaleInterval_,
        uint256 claimStartTime_,
        uint256 claimEndTime_
    ) external override adminRequired {
        _activate(
            startTime_,
            duration,
            presaleInterval_,
            claimStartTime_,
            claimEndTime_
        );
    }

    /**
     * @dev See {IERC721Collection-deactivate}.
     */
    function deactivate() external override adminRequired {
        _deactivate();
    }

    /**
     *  @dev See {IERC721Collection-setTokenURIPrefix}.
     */
    function setTokenURIPrefix(string calldata prefix)
        external
        override
        adminRequired
    {
        _setTokenURIPrefix(prefix);
    }

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

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner)
        public
        view
        virtual
        override(ERC721, ERC721CollectionBase)
        returns (uint256)
    {
        return ERC721.balanceOf(owner);
    }

    /**
     * @dev mint implementation
     */
    function _mint(address to, uint256 tokenId)
        internal
        override(ERC721, ERC721CollectionBase)
    {
        ERC721._mint(to, tokenId);
    }

    /**
     * @dev See {ERC721-_beforeTokenTranfser}.
     */
    function _beforeTokenTransfer(
        address from,
        address,
        uint256,
        uint256
    ) internal virtual override {
        _validateTokenTransferability(from);
    }

    /**
     * @dev Update royalties
     */
    function updateRoyalties(address payable recipient, uint256 bps)
        external
        adminRequired
    {
        _updateRoyalties(recipient, bps);
    }
}

File 2 of 21 : CrossmintPayable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@manifoldxyz/libraries-solidity/contracts/access/AdminControl.sol";

/**
 * Crossmint purchase library - allows Crossmint to call purchase function to mint pieces of a collection.
 */
abstract contract CrossmintPayable is AdminControl {
    event PurchaseCrossmint(bytes32 indexed nonce);

    address public crossmintAddress =
        0xdAb1a1854214684acE522439684a145E62505233;

    /**
     * @dev Modifier for Crossmint only purchase function
     */
    modifier onlyCrossmint() {
        require(msg.sender == crossmintAddress, "Only callable by Crossmint");
        _;
    }

    /**
     * @dev Set the crossmint address
     */
    function setCrossmintAddress(address crossmintAddress_)
        external
        adminRequired
    {
        crossmintAddress = crossmintAddress_;
    }
}

File 3 of 21 : ERC721CollectionBase.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@openzeppelin/contracts/utils/Strings.sol";

import "./IERC721Collection.sol";
import "./CollectionBase.sol";

/**
 * ERC721 Collection Drop Contract (Base)
 */
abstract contract ERC721CollectionBase is CollectionBase, IERC721Collection {
    using Strings for uint256;

    // Immutable variables that should only be set by the constructor or initializer
    uint16 public transactionLimit;
    uint16 public purchaseMax;
    uint16 public purchaseLimit;
    uint256 public purchasePrice;
    uint16 public presalePurchaseLimit;
    uint256 public presalePurchasePrice;
    bool public useDynamicPresalePurchaseLimit;

    // Minted token information
    uint16 public purchaseCount;
    mapping(address => uint16) internal _addressMintCount;

    // Token URI configuration
    string internal _prefixURI;

    uint256 private _royaltyBps;
    address payable private _royaltyRecipient;
    bytes4 private constant _INTERFACE_ID_ROYALTIES_CREATORCORE = 0xbb3bafd6;
    bytes4 private constant _INTERFACE_ID_ROYALTIES_EIP2981 = 0x2a55205a;
    bytes4 private constant _INTERFACE_ID_ROYALTIES_RARIBLE = 0xb7799584;

    // Transfer lock
    bool public transferLocked;

    function _initialize(
        uint16 purchaseMax_,
        uint256 purchasePrice_,
        uint16 purchaseLimit_,
        uint16 transactionLimit_,
        uint256 presalePurchasePrice_,
        uint16 presalePurchaseLimit_,
        address signingAddress,
        bool useDynamicPresalePurchaseLimit_
    ) internal {
        require(_signingAddress == address(0), "Already initialized");
        purchaseMax = purchaseMax_;
        purchasePrice = purchasePrice_;
        purchaseLimit = purchaseLimit_;
        transactionLimit = transactionLimit_;
        presalePurchasePrice = presalePurchasePrice_;
        presalePurchaseLimit = presalePurchaseLimit_;
        _signingAddress = signingAddress;
        useDynamicPresalePurchaseLimit = useDynamicPresalePurchaseLimit_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId)
        public
        view
        virtual
        override(IERC165)
        returns (bool)
    {
        return
            interfaceId == type(IERC721Collection).interfaceId ||
            interfaceId == _INTERFACE_ID_ROYALTIES_CREATORCORE ||
            interfaceId == _INTERFACE_ID_ROYALTIES_EIP2981 ||
            interfaceId == _INTERFACE_ID_ROYALTIES_RARIBLE;
    }

    /**
     * Premint tokens to the owner.  Sale must not be active.
     */
    function _premint(uint16 amount, address owner) internal virtual {
        require(!active, "Already active");
        // Check amounts
        require(amount <= purchaseRemaining(), "Too many requested");
        for (uint256 i = 0; i < amount; ) {
            _mint(owner);
            unchecked {
                i++;
            }
        }
    }

    /**
     * Premint tokens to the list of addresses.  Sale must not be active.
     */
    function _premint(address[] calldata addresses) internal virtual {
        require(!active, "Already active");
        // Check amounts
        require(addresses.length <= purchaseRemaining(), "Too many requested");
        for (uint256 i = 0; i < addresses.length; ) {
            _mint(addresses[i]);
            unchecked {
                i++;
            }
        }
    }

    /**
     * @dev override if you want to perform different mint functionality
     */
    function _mint(address to) internal virtual {
        purchaseCount++;

        // Mint token
        _mint(to, purchaseCount);

        emit Unveil(purchaseCount, address(this), purchaseCount);
    }

    /**
     * @dev override to define mint functionality
     */
    function _mint(address to, uint256 tokenId) internal virtual;

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual returns (uint256);

    /**
     * @dev Use a prefix uri for all tokens (<PREFIX><TOKEN_ID>).
     */
    function _setTokenURIPrefix(string calldata prefix) internal virtual {
        _prefixURI = prefix;
    }

    /**
     * Validate price (override for custom pricing mechanics)
     */
    function _validatePrice(uint16 amount) internal virtual {
        require(
            msg.value == amount * purchasePrice,
            "Invalid purchase amount sent"
        );
    }

    /**
     * Validate price (override for custom pricing mechanics)
     */
    function _validatePresalePrice(uint16 amount) internal virtual {
        require(
            msg.value == amount * presalePurchasePrice,
            "Invalid purchase amount sent"
        );
    }

    /**
     * If enabled, lock token transfers until admin unlocks.
     */
    function _validateTokenTransferability(address from) internal view {
        require(
            !transferLocked || from == address(0),
            "Transfer locked until sale ends"
        );
    }

    /**
     * Set whether or not token transfers are locked till end of sale
     */
    function _setTransferLocked(bool locked) internal {
        transferLocked = locked;
    }

    /**
     * @dev See {IERC721Collection-claim}.
     */
    function claim(
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) external virtual override {
        _validateClaimRestrictions();
        _validateClaimRequest(message, signature, nonce, amount);
        for (uint256 i = 0; i < amount; ) {
            _mint(msg.sender);
            unchecked {
                i++;
            }
        }
    }

    /**
     * @dev See {IERC721Collection-purchase}.
     */
    function purchase(
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) public payable virtual override {
        _purchase(msg.sender, amount, message, signature, nonce);
    }

    /**
     * Purchase tokens and mint to the specified address
     */
    function _purchase(
        address to,
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) internal virtual {
        _validatePurchaseRestrictions();

        bool isPresale = _isPresale();

        // Check purchase amounts
        require(
            amount <= purchaseRemaining() &&
                ((isPresale && useDynamicPresalePurchaseLimit) ||
                    transactionLimit == 0 ||
                    amount <= transactionLimit),
            "Too many requested"
        );

        if (isPresale) {
            if (!useDynamicPresalePurchaseLimit) {
                // Make sure we are not over presalePurchaseLimit
                if (presalePurchaseLimit != 0) {
                    uint16 mintCount = _addressMintCount[to];
                    require(
                        presalePurchaseLimit > mintCount &&
                            amount <= (presalePurchaseLimit - mintCount),
                        "Too many requested"
                    );
                }
                // Make sure we are not over purchaseLimit
                if (purchaseLimit != 0) {
                    uint16 mintCount = _addressMintCount[to];
                    require(
                        purchaseLimit > mintCount &&
                            amount <= (purchaseLimit - mintCount),
                        "Too many requested"
                    );
                }
            }
            _validatePresalePrice(amount);
            // Only track mint count if needed
            if (
                !useDynamicPresalePurchaseLimit &&
                (presalePurchaseLimit != 0 || purchaseLimit != 0)
            ) {
                _addressMintCount[to] += amount;
            }
        } else {
            // Make sure we are not over purchaseLimit
            if (purchaseLimit != 0) {
                uint16 mintCount = _addressMintCount[to];
                require(
                    purchaseLimit > mintCount &&
                        amount <= (purchaseLimit - mintCount),
                    "Too many requested"
                );
            }
            _validatePrice(amount);
            if (purchaseLimit != 0) {
                _addressMintCount[to] += amount;
            }
        }

        if (isPresale && useDynamicPresalePurchaseLimit) {
            _validatePurchaseRequestWithAmount(
                message,
                signature,
                nonce,
                amount
            );
        } else {
            _validatePurchaseRequest(message, signature, nonce);
        }

        for (uint256 i = 0; i < amount; ) {
            _mint(to);
            unchecked {
                i++;
            }
        }
    }

    /**
     * @dev See {IERC721Collection-state}
     */
    function state() external view override returns (CollectionState memory) {
        return
            CollectionState(
                transactionLimit,
                purchaseMax,
                purchaseRemaining(),
                purchasePrice,
                purchaseLimit,
                presalePurchasePrice,
                presalePurchaseLimit,
                _addressMintCount[msg.sender],
                active,
                startTime,
                endTime,
                presaleInterval,
                claimStartTime,
                claimEndTime,
                useDynamicPresalePurchaseLimit
            );
    }

    /**
     * @dev See {IERC721Collection-purchaseRemaining}.
     */
    function purchaseRemaining() public view virtual override returns (uint16) {
        return purchaseMax - purchaseCount;
    }

    /**
     * ROYALTY FUNCTIONS
     */
    function getRoyalties(uint256)
        external
        view
        returns (address payable[] memory recipients, uint256[] memory bps)
    {
        if (_royaltyRecipient != address(0x0)) {
            recipients = new address payable[](1);
            recipients[0] = _royaltyRecipient;
            bps = new uint256[](1);
            bps[0] = _royaltyBps;
        }
        return (recipients, bps);
    }

    function getFeeRecipients(uint256)
        external
        view
        returns (address payable[] memory recipients)
    {
        if (_royaltyRecipient != address(0x0)) {
            recipients = new address payable[](1);
            recipients[0] = _royaltyRecipient;
        }
        return recipients;
    }

    function getFeeBps(uint256) external view returns (uint256[] memory bps) {
        if (_royaltyRecipient != address(0x0)) {
            bps = new uint256[](1);
            bps[0] = _royaltyBps;
        }
        return bps;
    }

    function royaltyInfo(uint256, uint256 value)
        external
        view
        returns (address, uint256)
    {
        return (_royaltyRecipient, (value * _royaltyBps) / 10000);
    }

    /**
     * @dev Update royalties
     */
    function _updateRoyalties(address payable recipient, uint256 bps) internal {
        _royaltyRecipient = recipient;
        _royaltyBps = bps;
    }
}

File 4 of 21 : AdminControl.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@openzeppelin/contracts/utils/introspection/ERC165.sol";
import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "./IAdminControl.sol";

abstract contract AdminControl is Ownable, IAdminControl, ERC165 {
    using EnumerableSet for EnumerableSet.AddressSet;

    // Track registered admins
    EnumerableSet.AddressSet private _admins;

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

    /**
     * @dev Only allows approved admins to call the specified function
     */
    modifier adminRequired() {
        require(owner() == msg.sender || _admins.contains(msg.sender), "AdminControl: Must be owner or admin");
        _;
    }   

    /**
     * @dev See {IAdminControl-getAdmins}.
     */
    function getAdmins() external view override returns (address[] memory admins) {
        admins = new address[](_admins.length());
        for (uint i = 0; i < _admins.length(); i++) {
            admins[i] = _admins.at(i);
        }
        return admins;
    }

    /**
     * @dev See {IAdminControl-approveAdmin}.
     */
    function approveAdmin(address admin) external override onlyOwner {
        if (!_admins.contains(admin)) {
            emit AdminApproved(admin, msg.sender);
            _admins.add(admin);
        }
    }

    /**
     * @dev See {IAdminControl-revokeAdmin}.
     */
    function revokeAdmin(address admin) external override onlyOwner {
        if (_admins.contains(admin)) {
            emit AdminRevoked(admin, msg.sender);
            _admins.remove(admin);
        }
    }

    /**
     * @dev See {IAdminControl-isAdmin}.
     */
    function isAdmin(address admin) public override view returns (bool) {
        return (owner() == admin || _admins.contains(admin));
    }

}

File 5 of 21 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.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: address zero is not a valid owner");
        return _balances[owner];
    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        address owner = _ownerOf(tokenId);
        require(owner != address(0), "ERC721: invalid token ID");
        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) {
        _requireMinted(tokenId);

        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 token owner or approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        _requireMinted(tokenId);

        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: caller is not token owner or 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: caller is not token owner or 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 the owner of the `tokenId`. Does NOT revert if token doesn't exist
     */
    function _ownerOf(uint256 tokenId) internal view virtual returns (address) {
        return _owners[tokenId];
    }

    /**
     * @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 _ownerOf(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) {
        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, 1);

        // Check that tokenId was not minted by `_beforeTokenTransfer` hook
        require(!_exists(tokenId), "ERC721: token already minted");

        unchecked {
            // Will not overflow unless all 2**256 token ids are minted to the same owner.
            // Given that tokens are minted one by one, it is impossible in practice that
            // this ever happens. Might change if we allow batch minting.
            // The ERC fails to describe this case.
            _balances[to] += 1;
        }

        _owners[tokenId] = to;

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

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

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     * This is an internal function that does not check if the sender is authorized to operate on the token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

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

        // Update ownership in case tokenId was transferred by `_beforeTokenTransfer` hook
        owner = ERC721.ownerOf(tokenId);

        // Clear approvals
        delete _tokenApprovals[tokenId];

        unchecked {
            // Cannot overflow, as that would require more tokens to be burned/transferred
            // out than the owner initially received through minting and transferring in.
            _balances[owner] -= 1;
        }
        delete _owners[tokenId];

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

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

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

        // Check that tokenId was not transferred by `_beforeTokenTransfer` hook
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");

        // Clear approvals from the previous owner
        delete _tokenApprovals[tokenId];

        unchecked {
            // `_balances[from]` cannot overflow for the same reason as described in `_burn`:
            // `from`'s balance is the number of token held, which is at least one before the current
            // transfer.
            // `_balances[to]` could overflow in the conditions described in `_mint`. That would require
            // all 2**256 token ids to be minted, which in practice is impossible.
            _balances[from] -= 1;
            _balances[to] += 1;
        }
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId, 1);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits an {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 an {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 Reverts if the `tokenId` has not been minted yet.
     */
    function _requireMinted(uint256 tokenId) internal view virtual {
        require(_exists(tokenId), "ERC721: invalid token ID");
    }

    /**
     * @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 {
                    /// @solidity memory-safe-assembly
                    assembly {
                        revert(add(32, reason), mload(reason))
                    }
                }
            }
        } else {
            return true;
        }
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting and burning. If {ERC721Consecutive} is
     * used, the hook may be called as part of a consecutive (batch) mint, as indicated by `batchSize` greater than 1.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s tokens will be transferred to `to`.
     * - When `from` is zero, the tokens will be minted for `to`.
     * - When `to` is zero, ``from``'s tokens will be burned.
     * - `from` and `to` are never both zero.
     * - `batchSize` is non-zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256, /* firstTokenId */
        uint256 batchSize
    ) internal virtual {
        if (batchSize > 1) {
            if (from != address(0)) {
                _balances[from] -= batchSize;
            }
            if (to != address(0)) {
                _balances[to] += batchSize;
            }
        }
    }

    /**
     * @dev Hook that is called after any token transfer. This includes minting and burning. If {ERC721Consecutive} is
     * used, the hook may be called as part of a consecutive (batch) mint, as indicated by `batchSize` greater than 1.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s tokens were transferred to `to`.
     * - When `from` is zero, the tokens were minted for `to`.
     * - When `to` is zero, ``from``'s tokens were burned.
     * - `from` and `to` are never both zero.
     * - `batchSize` is non-zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 firstTokenId,
        uint256 batchSize
    ) internal virtual {}
}

File 6 of 21 : CollectionBase.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol";

import "./ICollectionBase.sol";

/**
 * Collection Drop Contract (Base)
 */
abstract contract CollectionBase is ICollectionBase {
    using ECDSA for bytes32;

    // Immutable variables that should only be set by the constructor or initializer
    address internal _signingAddress;

    // Message nonces
    mapping(bytes32 => bool) private _usedNonces;

    // Sale start/end control
    bool public active;
    uint256 public startTime;
    uint256 public endTime;
    uint256 public presaleInterval;

    // Claim period start/end control
    uint256 public claimStartTime;
    uint256 public claimEndTime;

    /**
     * Withdraw funds
     */
    function _withdraw(address payable recipient, uint256 amount) internal {
        (bool success, ) = recipient.call{value: amount}("");
        require(success);
    }

    /**
     * Activate the sale
     */
    function _activate(
        uint256 startTime_,
        uint256 duration,
        uint256 presaleInterval_,
        uint256 claimStartTime_,
        uint256 claimEndTime_
    ) internal virtual {
        require(!active, "Already active");
        require(startTime_ > block.timestamp, "Cannot activate in the past");
        require(
            presaleInterval_ <= duration,
            "Presale Interval cannot be longer than the sale"
        );
        require(
            claimStartTime_ <= claimEndTime_ && claimEndTime_ <= startTime_,
            "Invalid claim times"
        );
        startTime = startTime_;
        endTime = startTime + duration;
        presaleInterval = presaleInterval_;
        claimStartTime = claimStartTime_;
        claimEndTime = claimEndTime_;
        active = true;

        emit CollectionActivated(
            startTime,
            endTime,
            presaleInterval,
            claimStartTime,
            claimEndTime
        );
    }

    /**
     * Deactivate the sale
     */
    function _deactivate() internal virtual {
        startTime = 0;
        endTime = 0;
        active = false;
        claimStartTime = 0;
        claimEndTime = 0;

        emit CollectionDeactivated();
    }

    /**
     * Validate claim signature
     */
    function _validateClaimRequest(
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce,
        uint16 amount
    ) internal virtual {
        _validatePurchaseRequestWithAmount(message, signature, nonce, amount);
    }

    /**
     * Validate claim restrictions
     */
    function _validateClaimRestrictions() internal virtual {
        require(active, "Inactive");
        require(
            block.timestamp >= claimStartTime &&
                block.timestamp <= claimEndTime,
            "Outside claim period."
        );
    }

    /**
     * Validate purchase signature
     */
    function _validatePurchaseRequest(
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) internal virtual {
        // Verify nonce usage/re-use
        require(!_usedNonces[nonce], "Cannot replay transaction");
        // Verify valid message based on input variables
        bytes32 expectedMessage = keccak256(
            abi.encodePacked(
                "\x19Ethereum Signed Message:\n52",
                msg.sender,
                nonce
            )
        );
        require(message == expectedMessage, "Malformed message");
        // Verify signature was performed by the expected signing address
        address signer = message.recover(signature);
        require(signer == _signingAddress, "Invalid signature");

        _usedNonces[nonce] = true;
    }

    /**
     * Validate purchase signature with amount
     */
    function _validatePurchaseRequestWithAmount(
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce,
        uint16 amount
    ) internal virtual {
        // Verify nonce usage/re-use
        require(!_usedNonces[nonce], "Cannot replay transaction");
        // Verify valid message based on input variables
        bytes32 expectedMessage = keccak256(
            abi.encodePacked(
                "\x19Ethereum Signed Message:\n54",
                msg.sender,
                nonce,
                amount
            )
        );
        require(message == expectedMessage, "Malformed message");
        // Verify signature was performed by the expected signing address
        address signer = message.recover(signature);
        require(signer == _signingAddress, "Invalid signature");

        _usedNonces[nonce] = true;
    }

    /**
     * Perform purchase restriciton checks. Override if more logic is needed
     */
    function _validatePurchaseRestrictions() internal virtual {
        require(active, "Inactive");
        require(block.timestamp >= startTime, "Purchasing not active");
    }

    /**
     * @dev See {ICollectionBase-nonceUsed}.
     */
    function nonceUsed(bytes32 nonce) external view override returns (bool) {
        return _usedNonces[nonce];
    }

    /**
     * @dev Check if currently in presale
     */
    function _isPresale() internal view returns (bool) {
        return
            block.timestamp > startTime &&
            block.timestamp - startTime < presaleInterval;
    }
}

File 7 of 21 : IERC721Collection.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@openzeppelin/contracts/utils/introspection/IERC165.sol";

import "./ICollectionBase.sol";

/**
 * @dev ERC721 Collection Interface
 */
interface IERC721Collection is ICollectionBase, IERC165 {
    event Unveil(uint256 collectibleId, address tokenAddress, uint256 tokenId);

    struct CollectionState {
        uint16 transactionLimit;
        uint16 purchaseMax;
        uint16 purchaseRemaining;
        uint256 purchasePrice;
        uint16 purchaseLimit;
        uint256 presalePurchasePrice;
        uint16 presalePurchaseLimit;
        uint16 purchaseCount;
        bool active;
        uint256 startTime;
        uint256 endTime;
        uint256 presaleInterval;
        uint256 claimStartTime;
        uint256 claimEndTime;
        bool useDynamicPresalePurchaseLimit;
    }

    /**
     * @dev Pre-mint
     */
    function premint(uint16 amount) external;

    function premint(address[] calldata addresses) external;

    /**
     *  @dev set the tokenURI prefix
     */
    function setTokenURIPrefix(string calldata prefix) external;

    /**
     * @dev Withdraw funds
     */
    function withdraw(address payable recipient, uint256 amount) external;

    /**
     * @dev Set whether or not token transfers are locked until end of sale.
     * @param locked Whether or not transfers are locked
     */
    function setTransferLocked(bool locked) external;

    /**
     * @dev Activate the contract
     */
    function activate(
        uint256 startTime_,
        uint256 duration,
        uint256 presaleInterval_,
        uint256 claimStartTime_,
        uint256 claimEndTime_
    ) external;

    /**
     * @dev Deactivate the contract
     */
    function deactivate() external;

    /**
     * @dev claim
     */
    function claim(
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) external;

    /**
     * @dev purchase
     */
    function purchase(
        uint16 amount,
        bytes32 message,
        bytes calldata signature,
        bytes32 nonce
    ) external payable;

    /**
     * @dev returns the collection state
     */
    function state() external view returns (CollectionState memory);

    /**
     * @dev Get number of tokens left
     */
    function purchaseRemaining() external view returns (uint16);
}

File 8 of 21 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol)

pragma solidity ^0.8.0;

import "./math/Math.sol";

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _SYMBOLS = "0123456789abcdef";
    uint8 private constant _ADDRESS_LENGTH = 20;

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        unchecked {
            uint256 length = Math.log10(value) + 1;
            string memory buffer = new string(length);
            uint256 ptr;
            /// @solidity memory-safe-assembly
            assembly {
                ptr := add(buffer, add(32, length))
            }
            while (true) {
                ptr--;
                /// @solidity memory-safe-assembly
                assembly {
                    mstore8(ptr, byte(mod(value, 10), _SYMBOLS))
                }
                value /= 10;
                if (value == 0) break;
            }
            return buffer;
        }
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        unchecked {
            return toHexString(value, Math.log256(value) + 1);
        }
    }

    /**
     * @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] = _SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }

    /**
     * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation.
     */
    function toHexString(address addr) internal pure returns (string memory) {
        return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH);
    }
}

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

pragma solidity ^0.8.0;

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

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

File 11 of 21 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.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 functionCallWithValue(target, data, 0, "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");
        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResultFromTarget(target, 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) {
        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResultFromTarget(target, 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) {
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResultFromTarget(target, success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling
     * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract.
     *
     * _Available since v4.8._
     */
    function verifyCallResultFromTarget(
        address target,
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        if (success) {
            if (returndata.length == 0) {
                // only check isContract if the call was successful and the return data is empty
                // otherwise we already know that it was a contract
                require(isContract(target), "Address: call to non-contract");
            }
            return returndata;
        } else {
            _revert(returndata, errorMessage);
        }
    }

    /**
     * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason or 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 {
            _revert(returndata, errorMessage);
        }
    }

    function _revert(bytes memory returndata, string memory errorMessage) private pure {
        // 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
            /// @solidity memory-safe-assembly
            assembly {
                let returndata_size := mload(returndata)
                revert(add(32, returndata), returndata_size)
            }
        } else {
            revert(errorMessage);
        }
    }
}

File 12 of 21 : 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 13 of 21 : 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 21 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.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 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: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721
     * or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
     * understand this adds an external call which potentially creates a reentrancy vulnerability.
     *
     * 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 15 of 21 : IAdminControl.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

import "@openzeppelin/contracts/utils/introspection/IERC165.sol";

/**
 * @dev Interface for admin control
 */
interface IAdminControl is IERC165 {

    event AdminApproved(address indexed account, address indexed sender);
    event AdminRevoked(address indexed account, address indexed sender);

    /**
     * @dev gets address of all admins
     */
    function getAdmins() external view returns (address[] memory);

    /**
     * @dev add an admin.  Can only be called by contract owner.
     */
    function approveAdmin(address admin) external;

    /**
     * @dev remove an admin.  Can only be called by contract owner.
     */
    function revokeAdmin(address admin) external;

    /**
     * @dev checks whether or not given address is an admin
     * Returns True if they are
     */
    function isAdmin(address admin) external view returns (bool);

}

File 16 of 21 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (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 Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        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 17 of 21 : EnumerableSet.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/structs/EnumerableSet.sol)
// This file was procedurally generated from scripts/generate/templates/EnumerableSet.js.

pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 *
 * [WARNING]
 * ====
 * Trying to delete such a structure from storage will likely result in data corruption, rendering the structure
 * unusable.
 * See https://github.com/ethereum/solidity/pull/11843[ethereum/solidity#11843] for more info.
 *
 * In order to clean an EnumerableSet, you can either remove all elements one by one or create a fresh instance using an
 * array of EnumerableSet.
 * ====
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;
        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) {
            // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastValue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastValue;
                // Update the index for the moved value
                set._indexes[lastValue] = valueIndex; // Replace lastValue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        return set._values[index];
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function _values(Set storage set) private view returns (bytes32[] memory) {
        return set._values;
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
        bytes32[] memory store = _values(set._inner);
        bytes32[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(AddressSet storage set) internal view returns (address[] memory) {
        bytes32[] memory store = _values(set._inner);
        address[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }

    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(UintSet storage set) internal view returns (uint256[] memory) {
        bytes32[] memory store = _values(set._inner);
        uint256[] memory result;

        /// @solidity memory-safe-assembly
        assembly {
            result := store
        }

        return result;
    }
}

File 18 of 21 : ICollectionBase.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/// @author: manifold.xyz

/**
 * @dev Collection Interface
 */
interface ICollectionBase {
    event CollectionActivated(
        uint256 startTime,
        uint256 endTime,
        uint256 presaleInterval,
        uint256 claimStartTime,
        uint256 claimEndTime
    );
    event CollectionDeactivated();

    /**
     * @dev Check if nonce has been used
     */
    function nonceUsed(bytes32 nonce) external view returns (bool);
}

File 19 of 21 : 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 20 of 21 : ECDSA.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol)

pragma solidity ^0.8.0;

import "../Strings.sol";

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

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

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

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

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

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

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

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

        return (signer, RecoverError.NoError);
    }

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

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

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

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

File 21 of 21 : Math.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol)

pragma solidity ^0.8.0;

/**
 * @dev Standard math utilities missing in the Solidity language.
 */
library Math {
    enum Rounding {
        Down, // Toward negative infinity
        Up, // Toward infinity
        Zero // Toward zero
    }

    /**
     * @dev Returns the largest of two numbers.
     */
    function max(uint256 a, uint256 b) internal pure returns (uint256) {
        return a > b ? a : b;
    }

    /**
     * @dev Returns the smallest of two numbers.
     */
    function min(uint256 a, uint256 b) internal pure returns (uint256) {
        return a < b ? a : b;
    }

    /**
     * @dev Returns the average of two numbers. The result is rounded towards
     * zero.
     */
    function average(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b) / 2 can overflow.
        return (a & b) + (a ^ b) / 2;
    }

    /**
     * @dev Returns the ceiling of the division of two numbers.
     *
     * This differs from standard division with `/` in that it rounds up instead
     * of rounding down.
     */
    function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) {
        // (a + b - 1) / b can overflow on addition, so we distribute.
        return a == 0 ? 0 : (a - 1) / b + 1;
    }

    /**
     * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0
     * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv)
     * with further edits by Uniswap Labs also under MIT license.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator
    ) internal pure returns (uint256 result) {
        unchecked {
            // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use
            // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256
            // variables such that product = prod1 * 2^256 + prod0.
            uint256 prod0; // Least significant 256 bits of the product
            uint256 prod1; // Most significant 256 bits of the product
            assembly {
                let mm := mulmod(x, y, not(0))
                prod0 := mul(x, y)
                prod1 := sub(sub(mm, prod0), lt(mm, prod0))
            }

            // Handle non-overflow cases, 256 by 256 division.
            if (prod1 == 0) {
                return prod0 / denominator;
            }

            // Make sure the result is less than 2^256. Also prevents denominator == 0.
            require(denominator > prod1);

            ///////////////////////////////////////////////
            // 512 by 256 division.
            ///////////////////////////////////////////////

            // Make division exact by subtracting the remainder from [prod1 prod0].
            uint256 remainder;
            assembly {
                // Compute remainder using mulmod.
                remainder := mulmod(x, y, denominator)

                // Subtract 256 bit number from 512 bit number.
                prod1 := sub(prod1, gt(remainder, prod0))
                prod0 := sub(prod0, remainder)
            }

            // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1.
            // See https://cs.stackexchange.com/q/138556/92363.

            // Does not overflow because the denominator cannot be zero at this stage in the function.
            uint256 twos = denominator & (~denominator + 1);
            assembly {
                // Divide denominator by twos.
                denominator := div(denominator, twos)

                // Divide [prod1 prod0] by twos.
                prod0 := div(prod0, twos)

                // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one.
                twos := add(div(sub(0, twos), twos), 1)
            }

            // Shift in bits from prod1 into prod0.
            prod0 |= prod1 * twos;

            // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such
            // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for
            // four bits. That is, denominator * inv = 1 mod 2^4.
            uint256 inverse = (3 * denominator) ^ 2;

            // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works
            // in modular arithmetic, doubling the correct bits in each step.
            inverse *= 2 - denominator * inverse; // inverse mod 2^8
            inverse *= 2 - denominator * inverse; // inverse mod 2^16
            inverse *= 2 - denominator * inverse; // inverse mod 2^32
            inverse *= 2 - denominator * inverse; // inverse mod 2^64
            inverse *= 2 - denominator * inverse; // inverse mod 2^128
            inverse *= 2 - denominator * inverse; // inverse mod 2^256

            // Because the division is now exact we can divide by multiplying with the modular inverse of denominator.
            // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is
            // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1
            // is no longer required.
            result = prod0 * inverse;
            return result;
        }
    }

    /**
     * @notice Calculates x * y / denominator with full precision, following the selected rounding direction.
     */
    function mulDiv(
        uint256 x,
        uint256 y,
        uint256 denominator,
        Rounding rounding
    ) internal pure returns (uint256) {
        uint256 result = mulDiv(x, y, denominator);
        if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) {
            result += 1;
        }
        return result;
    }

    /**
     * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down.
     *
     * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11).
     */
    function sqrt(uint256 a) internal pure returns (uint256) {
        if (a == 0) {
            return 0;
        }

        // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target.
        //
        // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have
        // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`.
        //
        // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)`
        // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))`
        // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)`
        //
        // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit.
        uint256 result = 1 << (log2(a) >> 1);

        // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128,
        // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at
        // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision
        // into the expected uint128 result.
        unchecked {
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            result = (result + a / result) >> 1;
            return min(result, a / result);
        }
    }

    /**
     * @notice Calculates sqrt(a), following the selected rounding direction.
     */
    function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = sqrt(a);
            return result + (rounding == Rounding.Up && result * result < a ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 2, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 128;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 64;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 32;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 16;
            }
            if (value >> 8 > 0) {
                value >>= 8;
                result += 8;
            }
            if (value >> 4 > 0) {
                value >>= 4;
                result += 4;
            }
            if (value >> 2 > 0) {
                value >>= 2;
                result += 2;
            }
            if (value >> 1 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 2, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log2(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log2(value);
            return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 10, rounded down, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >= 10**64) {
                value /= 10**64;
                result += 64;
            }
            if (value >= 10**32) {
                value /= 10**32;
                result += 32;
            }
            if (value >= 10**16) {
                value /= 10**16;
                result += 16;
            }
            if (value >= 10**8) {
                value /= 10**8;
                result += 8;
            }
            if (value >= 10**4) {
                value /= 10**4;
                result += 4;
            }
            if (value >= 10**2) {
                value /= 10**2;
                result += 2;
            }
            if (value >= 10**1) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log10(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log10(value);
            return result + (rounding == Rounding.Up && 10**result < value ? 1 : 0);
        }
    }

    /**
     * @dev Return the log in base 256, rounded down, of a positive value.
     * Returns 0 if given 0.
     *
     * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string.
     */
    function log256(uint256 value) internal pure returns (uint256) {
        uint256 result = 0;
        unchecked {
            if (value >> 128 > 0) {
                value >>= 128;
                result += 16;
            }
            if (value >> 64 > 0) {
                value >>= 64;
                result += 8;
            }
            if (value >> 32 > 0) {
                value >>= 32;
                result += 4;
            }
            if (value >> 16 > 0) {
                value >>= 16;
                result += 2;
            }
            if (value >> 8 > 0) {
                result += 1;
            }
        }
        return result;
    }

    /**
     * @dev Return the log in base 10, following the selected rounding direction, of a positive value.
     * Returns 0 if given 0.
     */
    function log256(uint256 value, Rounding rounding) internal pure returns (uint256) {
        unchecked {
            uint256 result = log256(value);
            return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0);
        }
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"signingAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"AdminApproved","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"AdminRevoked","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":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"endTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"presaleInterval","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"claimStartTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"claimEndTime","type":"uint256"}],"name":"CollectionActivated","type":"event"},{"anonymous":false,"inputs":[],"name":"CollectionDeactivated","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":"bytes32","name":"nonce","type":"bytes32"}],"name":"PurchaseCrossmint","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"collectibleId","type":"uint256"},{"indexed":false,"internalType":"address","name":"tokenAddress","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Unveil","type":"event"},{"inputs":[{"internalType":"uint256","name":"startTime_","type":"uint256"},{"internalType":"uint256","name":"duration","type":"uint256"},{"internalType":"uint256","name":"presaleInterval_","type":"uint256"},{"internalType":"uint256","name":"claimStartTime_","type":"uint256"},{"internalType":"uint256","name":"claimEndTime_","type":"uint256"}],"name":"activate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"active","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":"admin","type":"address"}],"name":"approveAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"amount","type":"uint16"},{"internalType":"bytes32","name":"message","type":"bytes32"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimEndTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimStartTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"crossmintAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"deactivate","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"endTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAdmins","outputs":[{"internalType":"address[]","name":"admins","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"getFeeBps","outputs":[{"internalType":"uint256[]","name":"bps","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"getFeeRecipients","outputs":[{"internalType":"address payable[]","name":"recipients","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"getRoyalties","outputs":[{"internalType":"address payable[]","name":"recipients","type":"address[]"},{"internalType":"uint256[]","name":"bps","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"isAdmin","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":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"nonceUsed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"amount","type":"uint16"}],"name":"premint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"premint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"presaleInterval","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presalePurchaseLimit","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presalePurchasePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint16","name":"amount","type":"uint16"},{"internalType":"bytes32","name":"message","type":"bytes32"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"purchase","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"purchaseCount","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint16","name":"amount","type":"uint16"},{"internalType":"bytes32","name":"message","type":"bytes32"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"bytes32","name":"nonce","type":"bytes32"}],"name":"purchaseCrossmint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"purchaseLimit","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"purchaseMax","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"purchasePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"purchaseRemaining","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"revokeAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"crossmintAddress_","type":"address"}],"name":"setCrossmintAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"prefix","type":"string"}],"name":"setTokenURIPrefix","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"locked","type":"bool"}],"name":"setTransferLocked","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"state","outputs":[{"components":[{"internalType":"uint16","name":"transactionLimit","type":"uint16"},{"internalType":"uint16","name":"purchaseMax","type":"uint16"},{"internalType":"uint16","name":"purchaseRemaining","type":"uint16"},{"internalType":"uint256","name":"purchasePrice","type":"uint256"},{"internalType":"uint16","name":"purchaseLimit","type":"uint16"},{"internalType":"uint256","name":"presalePurchasePrice","type":"uint256"},{"internalType":"uint16","name":"presalePurchaseLimit","type":"uint16"},{"internalType":"uint16","name":"purchaseCount","type":"uint16"},{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint256","name":"startTime","type":"uint256"},{"internalType":"uint256","name":"endTime","type":"uint256"},{"internalType":"uint256","name":"presaleInterval","type":"uint256"},{"internalType":"uint256","name":"claimStartTime","type":"uint256"},{"internalType":"uint256","name":"claimEndTime","type":"uint256"},{"internalType":"bool","name":"useDynamicPresalePurchaseLimit","type":"bool"}],"internalType":"struct IERC721Collection.CollectionState","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"transactionLimit","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"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":[],"name":"transferLocked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"recipient","type":"address"},{"internalType":"uint256","name":"bps","type":"uint256"}],"name":"updateRoyalties","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"useDynamicPresalePurchaseLimit","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address payable","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6080604052601980546001600160a01b03191673dab1a1854214684ace522439684a145e625052331790553480156200003757600080fd5b50604051620041f2380380620041f28339810160408190526200005a916200030b565b60405180604001604052806006815260200165696b6f6e2d3160d01b8152506040518060400160405280600481526020016324a5a7a760e11b815250620000b0620000aa6200011260201b60201c565b62000116565b8151620000c590601190602085019062000265565b508051620000db90601290602084019062000265565b5050506200010b611f406702c68af0bb140000600080670214e8348c4f000060038760006200016860201b60201c565b506200037a565b3390565b600880546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000546001600160a01b031615620001c65760405162461bcd60e51b815260206004820152601360248201527f416c726561647920696e697469616c697a656400000000000000000000000000604482015260640160405180910390fd5b6008805460099890985563ffffffff60b01b19909716600160b01b61ffff998a160261ffff60c01b191617600160c01b968916969096029590951761ffff60a01b1916600160a01b9488169490940293909317909455600b55600a805461ffff19169390941692909217909255600080546001600160a01b0319166001600160a01b03909216919091179055600c805460ff1916911515919091179055565b82805462000273906200033d565b90600052602060002090601f016020900481019282620002975760008555620002e2565b82601f10620002b257805160ff1916838001178555620002e2565b82800160010185558215620002e2579182015b82811115620002e2578251825591602001919060010190620002c5565b50620002f0929150620002f4565b5090565b5b80821115620002f05760008155600101620002f5565b6000602082840312156200031e57600080fd5b81516001600160a01b03811681146200033657600080fd5b9392505050565b600181811c908216806200035257607f821691505b602082108114156200037457634e487b7160e01b600052602260045260246000fd5b50919050565b613e68806200038a6000396000f3fe6080604052600436106103505760003560e01c8063715018a6116101c6578063b9c4d9fb116100f7578063e59bb7a811610095578063f2fde38b1161006f578063f2fde38b146109da578063f3fef3a3146109fa578063f474307014610a1a578063fe73ad7714610a3557600080fd5b8063e59bb7a814610978578063e985e9c514610998578063f19605d6146109b857600080fd5b8063c87b56dd116100d1578063c87b56dd1461090a578063c8a84a821461092a578063defd6c5f1461094c578063e3b9398b1461096257600080fd5b8063b9c4d9fb1461088d578063bb3bafd6146108ba578063c19d93fb146108e857600080fd5b806395d89b4111610164578063a22cb4651161013e578063a22cb46514610824578063a6a11bb114610844578063b36dd30c1461085a578063b88d4fde1461086d57600080fd5b806395d89b41146107cf57806399755624146107e457806399e0dd7c1461080457600080fd5b806381960b5c116101a057806381960b5c1461075b578063850217d8146107715780638da5cb5b14610791578063956447d8146107af57600080fd5b8063715018a61461071057806378e979251461072557806379070afa1461073b57600080fd5b80633197cbb6116102a05780635b2a55e41161023e5780636741f24a116102185780636741f24a1461069d5780636c2f5acd146106b05780636d73e669146106d057806370a08231146106f057600080fd5b80635b2a55e41461062d57806361a4422b1461064d5780636352211e1461067d57600080fd5b806340d1d2551161027a57806340d1d255146105c857806342842e0e146105de57806351b42b00146105fe57806355461d6d1461061357600080fd5b80633197cbb61461056257806331ae450b1461058657806335e60bd4146105a857600080fd5b806312686aae1161030d57806324d7806c116102e757806324d7806c146104c35780632a55205a146104e35780632b85ed9c146105225780632d3456701461054257600080fd5b806312686aae1461044d578063188866571461046e57806323b872dd146104a357600080fd5b806301ffc9a71461035557806302fb0c5e1461038a57806306fdde03146103a4578063081812fc146103c6578063095ea7b3146103fe5780630ebd4c7f14610420575b600080fd5b34801561036157600080fd5b506103756103703660046136cc565b610a4a565b60405190151581526020015b60405180910390f35b34801561039657600080fd5b506002546103759060ff1681565b3480156103b057600080fd5b506103b9610a79565b60405161038191906139cf565b3480156103d257600080fd5b506103e66103e13660046136b3565b610b0b565b6040516001600160a01b039091168152602001610381565b34801561040a57600080fd5b5061041e6104193660046133ef565b610b32565b005b34801561042c57600080fd5b5061044061043b3660046136b3565b610c4d565b60405161038191906139bc565b34801561045957600080fd5b5060105461037590600160a01b900460ff1681565b34801561047a57600080fd5b5060085461049090600160c01b900461ffff1681565b60405161ffff9091168152602001610381565b3480156104af57600080fd5b5061041e6104be366004613454565b610ca9565b3480156104cf57600080fd5b506103756104de3660046133d2565b610cda565b3480156104ef57600080fd5b506105036104fe3660046137c5565b610d13565b604080516001600160a01b039093168352602083019190915201610381565b34801561052e57600080fd5b50600c5461049090610100900461ffff1681565b34801561054e57600080fd5b5061041e61055d3660046133d2565b610d4e565b34801561056e57600080fd5b5061057860045481565b604051908152602001610381565b34801561059257600080fd5b5061059b610dac565b604051610381919061392e565b3480156105b457600080fd5b5061041e6105c3366004613698565b610e5b565b3480156105d457600080fd5b5061057860075481565b3480156105ea57600080fd5b5061041e6105f9366004613454565b610ebf565b34801561060a57600080fd5b5061041e610eda565b34801561061f57600080fd5b50600c546103759060ff1681565b34801561063957600080fd5b506019546103e6906001600160a01b031681565b34801561065957600080fd5b506103756106683660046136b3565b60009081526001602052604090205460ff1690565b34801561068957600080fd5b506103e66106983660046136b3565b610f2e565b61041e6106ab366004613763565b610f8e565b3480156106bc57600080fd5b5061041e6106cb3660046133ef565b610fa3565b3480156106dc57600080fd5b5061041e6106eb3660046133d2565b611012565b3480156106fc57600080fd5b5061057861070b3660046133d2565b61106a565b34801561071c57600080fd5b5061041e611075565b34801561073157600080fd5b5061057860035481565b34801561074757600080fd5b5061041e610756366004613763565b611087565b34801561076757600080fd5b50610578600b5481565b34801561077d57600080fd5b5061041e61078c366004613748565b6110c4565b34801561079d57600080fd5b506008546001600160a01b03166103e6565b3480156107bb57600080fd5b5061041e6107ca3660046137e7565b611129565b3480156107db57600080fd5b506103b9611180565b3480156107f057600080fd5b5061041e6107ff3660046133d2565b61118f565b34801561081057600080fd5b5061041e61081f366004613706565b6111fb565b34801561083057600080fd5b5061041e61083f366004613575565b61124f565b34801561085057600080fd5b5061057860065481565b61041e6108683660046135aa565b61125a565b34801561087957600080fd5b5061041e610888366004613495565b6112f5565b34801561089957600080fd5b506108ad6108a83660046136b3565b61132d565b604051610381919061397b565b3480156108c657600080fd5b506108da6108d53660046136b3565b6113a6565b60405161038192919061398e565b3480156108f457600080fd5b506108fd61145a565b6040516103819190613b5e565b34801561091657600080fd5b506103b96109253660046136b3565b6115a4565b34801561093657600080fd5b5060085461049090600160b01b900461ffff1681565b34801561095857600080fd5b5061057860095481565b34801561096e57600080fd5b5061057860055481565b34801561098457600080fd5b5061041e610993366004613623565b61160b565b3480156109a457600080fd5b506103756109b336600461341b565b61165f565b3480156109c457600080fd5b5060085461049090600160a01b900461ffff1681565b3480156109e657600080fd5b5061041e6109f53660046133d2565b61168d565b348015610a0657600080fd5b5061041e610a153660046133ef565b611703565b348015610a2657600080fd5b50600a546104909061ffff1681565b348015610a4157600080fd5b50610490611757565b6000610a5582611783565b80610a645750610a64826117ef565b80610a735750610a738261183f565b92915050565b606060118054610a8890613d21565b80601f0160208091040260200160405190810160405280929190818152602001828054610ab490613d21565b8015610b015780601f10610ad657610100808354040283529160200191610b01565b820191906000526020600020905b815481529060010190602001808311610ae457829003601f168201915b5050505050905090565b6000610b1682611864565b506000908152601560205260409020546001600160a01b031690565b6000610b3d82610f2e565b9050806001600160a01b0316836001600160a01b03161415610bb05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b0382161480610bcc5750610bcc813361165f565b610c3e5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c0000006064820152608401610ba7565b610c4883836118c3565b505050565b6010546060906001600160a01b031615610ca4576040805160018082528183019092529060208083019080368337019050509050600f5481600081518110610c9757610c97613ddb565b6020026020010181815250505b919050565b610cb33382611931565b610ccf5760405162461bcd60e51b8152600401610ba7906139e2565b610c48838383611990565b6000816001600160a01b0316610cf86008546001600160a01b031690565b6001600160a01b03161480610a735750610a73601783611b01565b601054600f5460009182916001600160a01b039091169061271090610d389086613c9c565b610d429190613c7a565b915091505b9250929050565b610d56611b23565b610d61601782611b01565b15610da95760405133906001600160a01b038316907f7c0c3c84c67c85fcac635147348bfe374c24a1a93d0366d1cfe9d8853cbf89d590600090a3610da7601782611b7d565b505b50565b6060610db86017611b92565b67ffffffffffffffff811115610dd057610dd0613df1565b604051908082528060200260200182016040528015610df9578160200160208202803683370190505b50905060005b610e096017611b92565b811015610e5757610e1b601782611b9c565b828281518110610e2d57610e2d613ddb565b6001600160a01b039092166020928302919091019091015280610e4f81613d7e565b915050610dff565b5090565b33610e6e6008546001600160a01b031690565b6001600160a01b03161480610e895750610e89601733611b01565b610ea55760405162461bcd60e51b8152600401610ba790613b1a565b6010805460ff60a01b1916600160a01b8315150217905550565b610c48838383604051806020016040528060008152506112f5565b33610eed6008546001600160a01b031690565b6001600160a01b03161480610f085750610f08601733611b01565b610f245760405162461bcd60e51b8152600401610ba790613b1a565b610f2c611ba8565b565b6000818152601360205260408120546001600160a01b031680610a735760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610ba7565b610f9c338686868686611bf1565b5050505050565b33610fb66008546001600160a01b031690565b6001600160a01b03161480610fd15750610fd1601733611b01565b610fed5760405162461bcd60e51b8152600401610ba790613b1a565b601080546001600160a01b0319166001600160a01b038416179055600f819055610da7565b61101a611b23565b611025601782611b01565b610da95760405133906001600160a01b038316907f7e1a1a08d52e4ba0e21554733d66165fd5151f99460116223d9e3a608eec5cb190600090a3610da7601782611f5e565b6000610a7382611f73565b61107d611b23565b610f2c6000611ff9565b61108f61204b565b61109c84848484896120e0565b60005b8561ffff168110156110bc576110b4336120ed565b60010161109f565b505050505050565b336110d76008546001600160a01b031690565b6001600160a01b031614806110f257506110f2601733611b01565b61110e5760405162461bcd60e51b8152600401610ba790613b1a565b610da9816111246008546001600160a01b031690565b612183565b3361113c6008546001600160a01b031690565b6001600160a01b031614806111575750611157601733611b01565b6111735760405162461bcd60e51b8152600401610ba790613b1a565b610f9c85858585856121f5565b606060128054610a8890613d21565b336111a26008546001600160a01b031690565b6001600160a01b031614806111bd57506111bd601733611b01565b6111d95760405162461bcd60e51b8152600401610ba790613b1a565b601980546001600160a01b0319166001600160a01b0392909216919091179055565b3361120e6008546001600160a01b031690565b6001600160a01b031614806112295750611229601733611b01565b6112455760405162461bcd60e51b8152600401610ba790613b1a565b610da782826123ab565b610da73383836123b7565b6019546001600160a01b031633146112b45760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c652062792043726f73736d696e740000000000006044820152606401610ba7565b6112c2868686868686611bf1565b60405181907f9c371b7d58cdc700de754bf2d561ec949d14f8050329e9fd001d6daf76e36ff090600090a2505050505050565b6112ff3383611931565b61131b5760405162461bcd60e51b8152600401610ba7906139e2565b61132784848484612486565b50505050565b6010546060906001600160a01b031615610ca4576040805160018082528183019092529060208083019080368337505060105482519293506001600160a01b03169183915060009061138157611381613ddb565b60200260200101906001600160a01b031690816001600160a01b031681525050919050565b60105460609081906001600160a01b031615611455576040805160018082528183019092529060208083019080368337505060105482519294506001600160a01b0316918491506000906113fc576113fc613ddb565b6001600160a01b0392909216602092830291909101820152604080516001808252818301909252918281019080368337019050509050600f548160008151811061144857611448613ddb565b6020026020010181815250505b915091565b604080516101e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101829052610160810182905261018081018290526101a081018290526101c0810191909152604080516101e08101825260085461ffff600160a01b820481168352600160b01b909104166020820152908101611508611757565b61ffff9081168252600954602080840191909152600854600160c01b90048216604080850191909152600b546060850152600a5483166080850152336000908152600d9092529020541660a082015260025460ff908116151560c083015260035460e0830152600454610100830152600554610120830152600654610140830152600754610160830152600c5416151561018090910152919050565b60606115af82611864565b60006115b96124b9565b905060008151116115d95760405180602001604052806000815250611604565b806115e3846124c8565b6040516020016115f49291906138c2565b6040516020818303038152906040525b9392505050565b3361161e6008546001600160a01b031690565b6001600160a01b031614806116395750611639601733611b01565b6116555760405162461bcd60e51b8152600401610ba790613b1a565b610da78282612565565b6001600160a01b03918216600090815260166020908152604080832093909416825291909152205460ff1690565b611695611b23565b6001600160a01b0381166116fa5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ba7565b610da981611ff9565b336117166008546001600160a01b031690565b6001600160a01b031614806117315750611731601733611b01565b61174d5760405162461bcd60e51b8152600401610ba790613b1a565b610da782826125f5565b600c5460085460009161177e9161ffff610100909204821691600160b01b90910416613cbb565b905090565b60006001600160e01b0319821663da192f9f60e01b14806117b457506001600160e01b03198216635d9dd7eb60e11b145b806117cf57506001600160e01b0319821663152a902d60e11b145b80610a7357506001600160e01b03198216632dde656160e21b1492915050565b60006001600160e01b031982166380ac58cd60e01b148061182057506001600160e01b03198216635b5e139f60e01b145b80610a7357506301ffc9a760e01b6001600160e01b0319831614610a73565b60006001600160e01b03198216632a9f3abf60e11b1480610a735750610a73826117ef565b6000818152601360205260409020546001600160a01b0316610da95760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610ba7565b600081815260156020526040902080546001600160a01b0319166001600160a01b03841690811790915581906118f882610f2e565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061193d83610f2e565b9050806001600160a01b0316846001600160a01b031614806119645750611964818561165f565b806119885750836001600160a01b031661197d84610b0b565b6001600160a01b0316145b949350505050565b826001600160a01b03166119a382610f2e565b6001600160a01b0316146119c95760405162461bcd60e51b8152600401610ba790613a81565b6001600160a01b038216611a2b5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610ba7565b611a388383836001612655565b826001600160a01b0316611a4b82610f2e565b6001600160a01b031614611a715760405162461bcd60e51b8152600401610ba790613a81565b600081815260156020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260148552838620805460001901905590871680865283862080546001019055868652601390945282852080549092168417909155905184937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6001600160a01b03811660009081526001830160205260408120541515611604565b6008546001600160a01b03163314610f2c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ba7565b6000611604836001600160a01b03841661265e565b6000610a73825490565b60006116048383612751565b6000600381905560048190556002805460ff19169055600681905560078190556040517fb02389feab3af620e2374d4d559b436ea226b1e6c9c31fe77dfbff3d40cbe9ba9190a1565b611bf961277b565b6000611c03612802565b9050611c0d611757565b61ffff168661ffff1611158015611c605750808015611c2e5750600c5460ff165b80611c445750600854600160a01b900461ffff16155b80611c60575060085461ffff600160a01b909104811690871611155b611c7c5760405162461bcd60e51b8152600401610ba790613ac6565b8015611e1457600c5460ff16611d8c57600a5461ffff1615611d01576001600160a01b0387166000908152600d6020526040902054600a5461ffff918216911681108015611ce35750600a54611cd790829061ffff16613cbb565b61ffff168761ffff1611155b611cff5760405162461bcd60e51b8152600401610ba790613ac6565b505b600854600160c01b900461ffff1615611d8c576001600160a01b0387166000908152600d602052604090205460085461ffff91821691600160c01b9091041681108015611d6e5750600854611d62908290600160c01b900461ffff16613cbb565b61ffff168761ffff1611155b611d8a5760405162461bcd60e51b8152600401610ba790613ac6565b505b611d9586612826565b600c5460ff16158015611dc35750600a5461ffff16151580611dc35750600854600160c01b900461ffff1615155b15611e0f576001600160a01b0387166000908152600d602052604081208054889290611df490849061ffff16613c45565b92506101000a81548161ffff021916908361ffff1602179055505b611f02565b600854600160c01b900461ffff1615611e9f576001600160a01b0387166000908152600d602052604090205460085461ffff91821691600160c01b9091041681108015611e815750600854611e75908290600160c01b900461ffff16613cbb565b61ffff168761ffff1611155b611e9d5760405162461bcd60e51b8152600401610ba790613ac6565b505b611ea886612885565b600854600160c01b900461ffff1615611f02576001600160a01b0387166000908152600d602052604081208054889290611ee790849061ffff16613c45565b92506101000a81548161ffff021916908361ffff1602179055505b808015611f115750600c5460ff165b15611f2857611f23858585858a612896565b611f34565b611f3485858585612a6a565b60005b8661ffff16811015611f5457611f4c886120ed565b600101611f37565b5050505050505050565b6000611604836001600160a01b038416612c29565b60006001600160a01b038216611fdd5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610ba7565b506001600160a01b031660009081526014602052604090205490565b600880546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60025460ff166120885760405162461bcd60e51b8152602060048201526008602482015267496e61637469766560c01b6044820152606401610ba7565b600654421015801561209c57506007544211155b610f2c5760405162461bcd60e51b815260206004820152601560248201527427baba39b4b2329031b630b4b6903832b934b7b21760591b6044820152606401610ba7565b610f9c8585858585612896565b600c8054610100900461ffff1690600161210683613d5c565b825461ffff91821661010093840a9081029083021990911617909255600c546121359350849291900416612c78565b600c546040805161010090920461ffff16808352306020840152908201527f7a607f1ab973d85727d0ff44300699ee672c0e1d76f35013f36c02772f524ba39060600160405180910390a150565b60025460ff16156121a65760405162461bcd60e51b8152600401610ba790613af2565b6121ae611757565b61ffff168261ffff1611156121d55760405162461bcd60e51b8152600401610ba790613ac6565b60005b8261ffff16811015610c48576121ed826120ed565b6001016121d8565b60025460ff16156122185760405162461bcd60e51b8152600401610ba790613af2565b4285116122675760405162461bcd60e51b815260206004820152601b60248201527f43616e6e6f7420616374697661746520696e20746865207061737400000000006044820152606401610ba7565b838311156122cf5760405162461bcd60e51b815260206004820152602f60248201527f50726573616c6520496e74657276616c2063616e6e6f74206265206c6f6e676560448201526e72207468616e207468652073616c6560881b6064820152608401610ba7565b8082111580156122df5750848111155b6123215760405162461bcd60e51b8152602060048201526013602482015272496e76616c696420636c61696d2074696d657360681b6044820152606401610ba7565b60038590556123308486613c62565b60048190556005849055600683905560078290556002805460ff1916600117905560035460408051918252602082019290925290810184905260608101839052608081018290527fe512d106f8172b08abfd2fc5ddfdb7e2401381780ae29e29f1352b862f1d27319060a00160405180910390a15050505050565b610c48600e83836132de565b816001600160a01b0316836001600160a01b031614156124195760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610ba7565b6001600160a01b03838116600081815260166020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b612491848484611990565b61249d84848484612c82565b6113275760405162461bcd60e51b8152600401610ba790613a2f565b6060600e8054610a8890613d21565b606060006124d583612d8f565b600101905060008167ffffffffffffffff8111156124f5576124f5613df1565b6040519080825280601f01601f19166020018201604052801561251f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a85049450846125585761255d565b612529565b509392505050565b60025460ff16156125885760405162461bcd60e51b8152600401610ba790613af2565b612590611757565b61ffff168111156125b35760405162461bcd60e51b8152600401610ba790613ac6565b60005b81811015610c48576125ed8383838181106125d3576125d3613ddb565b90506020020160208101906125e891906133d2565b6120ed565b6001016125b6565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612642576040519150601f19603f3d011682016040523d82523d6000602084013e612647565b606091505b5050905080610c4857600080fd5b61132784612e67565b60008181526001830160205260408120548015612747576000612682600183613cde565b855490915060009061269690600190613cde565b90508181146126fb5760008660000182815481106126b6576126b6613ddb565b90600052602060002001549050808760000184815481106126d9576126d9613ddb565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061270c5761270c613dc5565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a73565b6000915050610a73565b600082600001828154811061276857612768613ddb565b9060005260206000200154905092915050565b60025460ff166127b85760405162461bcd60e51b8152602060048201526008602482015267496e61637469766560c01b6044820152606401610ba7565b600354421015610f2c5760405162461bcd60e51b815260206004820152601560248201527450757263686173696e67206e6f742061637469766560581b6044820152606401610ba7565b60006003544211801561177e57506005546003546128209042613cde565b10905090565b600b546128379061ffff8316613c9c565b3414610da95760405162461bcd60e51b815260206004820152601c60248201527f496e76616c696420707572636861736520616d6f756e742073656e74000000006044820152606401610ba7565b6009546128379061ffff8316613c9c565b60008281526001602052604090205460ff16156128f15760405162461bcd60e51b815260206004820152601960248201527821b0b73737ba103932b83630bc903a3930b739b0b1ba34b7b760391b6044820152606401610ba7565b6040517f19457468657265756d205369676e6564204d6573736167653a0a35340000000060208201526bffffffffffffffffffffffff193360601b16603c820152605081018390526001600160f01b031960f083901b1660708201526000906072016040516020818303038152906040528051906020012090508086146129ae5760405162461bcd60e51b81526020600482015260116024820152704d616c666f726d6564206d65737361676560781b6044820152606401610ba7565b60006129f286868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b93925050612ed39050565b6000549091506001600160a01b03808316911614612a465760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610ba7565b5050506000908152600160208190526040909120805460ff19169091179055505050565b60008181526001602052604090205460ff1615612ac55760405162461bcd60e51b815260206004820152601960248201527821b0b73737ba103932b83630bc903a3930b739b0b1ba34b7b760391b6044820152606401610ba7565b6040517f19457468657265756d205369676e6564204d6573736167653a0a35320000000060208201526bffffffffffffffffffffffff193360601b16603c82015260508101829052600090607001604051602081830303815290604052805190602001209050808514612b6e5760405162461bcd60e51b81526020600482015260116024820152704d616c666f726d6564206d65737361676560781b6044820152606401610ba7565b6000612bb285858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a93925050612ed39050565b6000549091506001600160a01b03808316911614612c065760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610ba7565b50506000908152600160208190526040909120805460ff19169091179055505050565b6000818152600183016020526040812054612c7057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a73565b506000610a73565b610da78282612eef565b60006001600160a01b0384163b15612d8457604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612cc69033908990889088906004016138f1565b602060405180830381600087803b158015612ce057600080fd5b505af1925050508015612d10575060408051601f3d908101601f19168201909252612d0d918101906136e9565b60015b612d6a573d808015612d3e576040519150601f19603f3d011682016040523d82523d6000602084013e612d43565b606091505b508051612d625760405162461bcd60e51b8152600401610ba790613a2f565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611988565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b8310612dce5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310612dfa576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc100008310612e1857662386f26fc10000830492506010015b6305f5e1008310612e30576305f5e100830492506008015b6127108310612e4457612710830492506004015b60648310612e56576064830492506002015b600a8310610a735760010192915050565b601054600160a01b900460ff161580612e8757506001600160a01b038116155b610da95760405162461bcd60e51b815260206004820152601f60248201527f5472616e73666572206c6f636b656420756e74696c2073616c6520656e6473006044820152606401610ba7565b6000806000612ee28585613089565b9150915061255d816130cc565b6001600160a01b038216612f455760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610ba7565b6000818152601360205260409020546001600160a01b031615612faa5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610ba7565b612fb8600083836001612655565b6000818152601360205260409020546001600160a01b03161561301d5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610ba7565b6001600160a01b038216600081815260146020908152604080832080546001019055848352601390915280822080546001600160a01b0319168417905551839291907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4610da7565b6000808251604114156130c05760208301516040840151606085015160001a6130b48782858561321a565b94509450505050610d47565b50600090506002610d47565b60008160048111156130e0576130e0613daf565b14156130e95750565b60018160048111156130fd576130fd613daf565b141561314b5760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610ba7565b600281600481111561315f5761315f613daf565b14156131ad5760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610ba7565b60038160048111156131c1576131c1613daf565b1415610da95760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610ba7565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561325157506000905060036132d5565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156132a5573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166132ce576000600192509250506132d5565b9150600090505b94509492505050565b8280546132ea90613d21565b90600052602060002090601f01602090048101928261330c5760008555613352565b82601f106133255782800160ff19823516178555613352565b82800160010185558215613352579182015b82811115613352578235825591602001919060010190613337565b50610e579291505b80821115610e57576000815560010161335a565b80358015158114610ca457600080fd5b60008083601f84011261339057600080fd5b50813567ffffffffffffffff8111156133a857600080fd5b602083019150836020828501011115610d4757600080fd5b803561ffff81168114610ca457600080fd5b6000602082840312156133e457600080fd5b813561160481613e07565b6000806040838503121561340257600080fd5b823561340d81613e07565b946020939093013593505050565b6000806040838503121561342e57600080fd5b823561343981613e07565b9150602083013561344981613e07565b809150509250929050565b60008060006060848603121561346957600080fd5b833561347481613e07565b9250602084013561348481613e07565b929592945050506040919091013590565b600080600080608085870312156134ab57600080fd5b84356134b681613e07565b935060208501356134c681613e07565b925060408501359150606085013567ffffffffffffffff808211156134ea57600080fd5b818701915087601f8301126134fe57600080fd5b81358181111561351057613510613df1565b604051601f8201601f19908116603f0116810190838211818310171561353857613538613df1565b816040528281528a602084870101111561355157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b6000806040838503121561358857600080fd5b823561359381613e07565b91506135a16020840161336e565b90509250929050565b60008060008060008060a087890312156135c357600080fd5b86356135ce81613e07565b95506135dc602088016133c0565b945060408701359350606087013567ffffffffffffffff8111156135ff57600080fd5b61360b89828a0161337e565b979a9699509497949695608090950135949350505050565b6000806020838503121561363657600080fd5b823567ffffffffffffffff8082111561364e57600080fd5b818501915085601f83011261366257600080fd5b81358181111561367157600080fd5b8660208260051b850101111561368657600080fd5b60209290920196919550909350505050565b6000602082840312156136aa57600080fd5b6116048261336e565b6000602082840312156136c557600080fd5b5035919050565b6000602082840312156136de57600080fd5b813561160481613e1c565b6000602082840312156136fb57600080fd5b815161160481613e1c565b6000806020838503121561371957600080fd5b823567ffffffffffffffff81111561373057600080fd5b61373c8582860161337e565b90969095509350505050565b60006020828403121561375a57600080fd5b611604826133c0565b60008060008060006080868803121561377b57600080fd5b613784866133c0565b945060208601359350604086013567ffffffffffffffff8111156137a757600080fd5b6137b38882890161337e565b96999598509660600135949350505050565b600080604083850312156137d857600080fd5b50508035926020909101359150565b600080600080600060a086880312156137ff57600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b600081518084526020808501945080840160005b8381101561385b5781516001600160a01b031687529582019590820190600101613836565b509495945050505050565b600081518084526020808501945080840160005b8381101561385b5781518752958201959082019060010161387a565b600081518084526138ae816020860160208601613cf5565b601f01601f19169290920160200192915050565b600083516138d4818460208801613cf5565b8351908301906138e8818360208801613cf5565b01949350505050565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061392490830184613896565b9695505050505050565b6020808252825182820181905260009190848201906040850190845b8181101561396f5783516001600160a01b03168352928401929184019160010161394a565b50909695505050505050565b6020815260006116046020830184613822565b6040815260006139a16040830185613822565b82810360208401526139b38185613866565b95945050505050565b6020815260006116046020830184613866565b6020815260006116046020830184613896565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b602080825260129082015271151bdbc81b585b9e481c995c5d595cdd195960721b604082015260600190565b6020808252600e908201526d416c72656164792061637469766560901b604082015260600190565b60208082526024908201527f41646d696e436f6e74726f6c3a204d757374206265206f776e6572206f7220616040820152633236b4b760e11b606082015260800190565b815161ffff1681526101e081016020830151613b80602084018261ffff169052565b506040830151613b96604084018261ffff169052565b50606083015160608301526080830151613bb6608084018261ffff169052565b5060a083015160a083015260c0830151613bd660c084018261ffff169052565b5060e0830151613bec60e084018261ffff169052565b506101008381015115159083015261012080840151908301526101408084015190830152610160808401519083015261018080840151908301526101a080840151908301526101c0928301511515929091019190915290565b600061ffff8083168185168083038211156138e8576138e8613d99565b60008219821115613c7557613c75613d99565b500190565b600082613c9757634e487b7160e01b600052601260045260246000fd5b500490565b6000816000190483118215151615613cb657613cb6613d99565b500290565b600061ffff83811690831681811015613cd657613cd6613d99565b039392505050565b600082821015613cf057613cf0613d99565b500390565b60005b83811015613d10578181015183820152602001613cf8565b838111156113275750506000910152565b600181811c90821680613d3557607f821691505b60208210811415613d5657634e487b7160e01b600052602260045260246000fd5b50919050565b600061ffff80831681811415613d7457613d74613d99565b6001019392505050565b6000600019821415613d9257613d92613d99565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610da957600080fd5b6001600160e01b031981168114610da957600080fdfea26469706673582212200a63321bf00b4ef9e507f2d2ba3b7cecd5687a0d269297ce4f980d264903ac7764736f6c634300080700330000000000000000000000000b670c096d475b2706034bcdbe98408592909236

Deployed Bytecode

0x6080604052600436106103505760003560e01c8063715018a6116101c6578063b9c4d9fb116100f7578063e59bb7a811610095578063f2fde38b1161006f578063f2fde38b146109da578063f3fef3a3146109fa578063f474307014610a1a578063fe73ad7714610a3557600080fd5b8063e59bb7a814610978578063e985e9c514610998578063f19605d6146109b857600080fd5b8063c87b56dd116100d1578063c87b56dd1461090a578063c8a84a821461092a578063defd6c5f1461094c578063e3b9398b1461096257600080fd5b8063b9c4d9fb1461088d578063bb3bafd6146108ba578063c19d93fb146108e857600080fd5b806395d89b4111610164578063a22cb4651161013e578063a22cb46514610824578063a6a11bb114610844578063b36dd30c1461085a578063b88d4fde1461086d57600080fd5b806395d89b41146107cf57806399755624146107e457806399e0dd7c1461080457600080fd5b806381960b5c116101a057806381960b5c1461075b578063850217d8146107715780638da5cb5b14610791578063956447d8146107af57600080fd5b8063715018a61461071057806378e979251461072557806379070afa1461073b57600080fd5b80633197cbb6116102a05780635b2a55e41161023e5780636741f24a116102185780636741f24a1461069d5780636c2f5acd146106b05780636d73e669146106d057806370a08231146106f057600080fd5b80635b2a55e41461062d57806361a4422b1461064d5780636352211e1461067d57600080fd5b806340d1d2551161027a57806340d1d255146105c857806342842e0e146105de57806351b42b00146105fe57806355461d6d1461061357600080fd5b80633197cbb61461056257806331ae450b1461058657806335e60bd4146105a857600080fd5b806312686aae1161030d57806324d7806c116102e757806324d7806c146104c35780632a55205a146104e35780632b85ed9c146105225780632d3456701461054257600080fd5b806312686aae1461044d578063188866571461046e57806323b872dd146104a357600080fd5b806301ffc9a71461035557806302fb0c5e1461038a57806306fdde03146103a4578063081812fc146103c6578063095ea7b3146103fe5780630ebd4c7f14610420575b600080fd5b34801561036157600080fd5b506103756103703660046136cc565b610a4a565b60405190151581526020015b60405180910390f35b34801561039657600080fd5b506002546103759060ff1681565b3480156103b057600080fd5b506103b9610a79565b60405161038191906139cf565b3480156103d257600080fd5b506103e66103e13660046136b3565b610b0b565b6040516001600160a01b039091168152602001610381565b34801561040a57600080fd5b5061041e6104193660046133ef565b610b32565b005b34801561042c57600080fd5b5061044061043b3660046136b3565b610c4d565b60405161038191906139bc565b34801561045957600080fd5b5060105461037590600160a01b900460ff1681565b34801561047a57600080fd5b5060085461049090600160c01b900461ffff1681565b60405161ffff9091168152602001610381565b3480156104af57600080fd5b5061041e6104be366004613454565b610ca9565b3480156104cf57600080fd5b506103756104de3660046133d2565b610cda565b3480156104ef57600080fd5b506105036104fe3660046137c5565b610d13565b604080516001600160a01b039093168352602083019190915201610381565b34801561052e57600080fd5b50600c5461049090610100900461ffff1681565b34801561054e57600080fd5b5061041e61055d3660046133d2565b610d4e565b34801561056e57600080fd5b5061057860045481565b604051908152602001610381565b34801561059257600080fd5b5061059b610dac565b604051610381919061392e565b3480156105b457600080fd5b5061041e6105c3366004613698565b610e5b565b3480156105d457600080fd5b5061057860075481565b3480156105ea57600080fd5b5061041e6105f9366004613454565b610ebf565b34801561060a57600080fd5b5061041e610eda565b34801561061f57600080fd5b50600c546103759060ff1681565b34801561063957600080fd5b506019546103e6906001600160a01b031681565b34801561065957600080fd5b506103756106683660046136b3565b60009081526001602052604090205460ff1690565b34801561068957600080fd5b506103e66106983660046136b3565b610f2e565b61041e6106ab366004613763565b610f8e565b3480156106bc57600080fd5b5061041e6106cb3660046133ef565b610fa3565b3480156106dc57600080fd5b5061041e6106eb3660046133d2565b611012565b3480156106fc57600080fd5b5061057861070b3660046133d2565b61106a565b34801561071c57600080fd5b5061041e611075565b34801561073157600080fd5b5061057860035481565b34801561074757600080fd5b5061041e610756366004613763565b611087565b34801561076757600080fd5b50610578600b5481565b34801561077d57600080fd5b5061041e61078c366004613748565b6110c4565b34801561079d57600080fd5b506008546001600160a01b03166103e6565b3480156107bb57600080fd5b5061041e6107ca3660046137e7565b611129565b3480156107db57600080fd5b506103b9611180565b3480156107f057600080fd5b5061041e6107ff3660046133d2565b61118f565b34801561081057600080fd5b5061041e61081f366004613706565b6111fb565b34801561083057600080fd5b5061041e61083f366004613575565b61124f565b34801561085057600080fd5b5061057860065481565b61041e6108683660046135aa565b61125a565b34801561087957600080fd5b5061041e610888366004613495565b6112f5565b34801561089957600080fd5b506108ad6108a83660046136b3565b61132d565b604051610381919061397b565b3480156108c657600080fd5b506108da6108d53660046136b3565b6113a6565b60405161038192919061398e565b3480156108f457600080fd5b506108fd61145a565b6040516103819190613b5e565b34801561091657600080fd5b506103b96109253660046136b3565b6115a4565b34801561093657600080fd5b5060085461049090600160b01b900461ffff1681565b34801561095857600080fd5b5061057860095481565b34801561096e57600080fd5b5061057860055481565b34801561098457600080fd5b5061041e610993366004613623565b61160b565b3480156109a457600080fd5b506103756109b336600461341b565b61165f565b3480156109c457600080fd5b5060085461049090600160a01b900461ffff1681565b3480156109e657600080fd5b5061041e6109f53660046133d2565b61168d565b348015610a0657600080fd5b5061041e610a153660046133ef565b611703565b348015610a2657600080fd5b50600a546104909061ffff1681565b348015610a4157600080fd5b50610490611757565b6000610a5582611783565b80610a645750610a64826117ef565b80610a735750610a738261183f565b92915050565b606060118054610a8890613d21565b80601f0160208091040260200160405190810160405280929190818152602001828054610ab490613d21565b8015610b015780601f10610ad657610100808354040283529160200191610b01565b820191906000526020600020905b815481529060010190602001808311610ae457829003601f168201915b5050505050905090565b6000610b1682611864565b506000908152601560205260409020546001600160a01b031690565b6000610b3d82610f2e565b9050806001600160a01b0316836001600160a01b03161415610bb05760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b0382161480610bcc5750610bcc813361165f565b610c3e5760405162461bcd60e51b815260206004820152603d60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206f7220617070726f76656420666f7220616c6c0000006064820152608401610ba7565b610c4883836118c3565b505050565b6010546060906001600160a01b031615610ca4576040805160018082528183019092529060208083019080368337019050509050600f5481600081518110610c9757610c97613ddb565b6020026020010181815250505b919050565b610cb33382611931565b610ccf5760405162461bcd60e51b8152600401610ba7906139e2565b610c48838383611990565b6000816001600160a01b0316610cf86008546001600160a01b031690565b6001600160a01b03161480610a735750610a73601783611b01565b601054600f5460009182916001600160a01b039091169061271090610d389086613c9c565b610d429190613c7a565b915091505b9250929050565b610d56611b23565b610d61601782611b01565b15610da95760405133906001600160a01b038316907f7c0c3c84c67c85fcac635147348bfe374c24a1a93d0366d1cfe9d8853cbf89d590600090a3610da7601782611b7d565b505b50565b6060610db86017611b92565b67ffffffffffffffff811115610dd057610dd0613df1565b604051908082528060200260200182016040528015610df9578160200160208202803683370190505b50905060005b610e096017611b92565b811015610e5757610e1b601782611b9c565b828281518110610e2d57610e2d613ddb565b6001600160a01b039092166020928302919091019091015280610e4f81613d7e565b915050610dff565b5090565b33610e6e6008546001600160a01b031690565b6001600160a01b03161480610e895750610e89601733611b01565b610ea55760405162461bcd60e51b8152600401610ba790613b1a565b6010805460ff60a01b1916600160a01b8315150217905550565b610c48838383604051806020016040528060008152506112f5565b33610eed6008546001600160a01b031690565b6001600160a01b03161480610f085750610f08601733611b01565b610f245760405162461bcd60e51b8152600401610ba790613b1a565b610f2c611ba8565b565b6000818152601360205260408120546001600160a01b031680610a735760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610ba7565b610f9c338686868686611bf1565b5050505050565b33610fb66008546001600160a01b031690565b6001600160a01b03161480610fd15750610fd1601733611b01565b610fed5760405162461bcd60e51b8152600401610ba790613b1a565b601080546001600160a01b0319166001600160a01b038416179055600f819055610da7565b61101a611b23565b611025601782611b01565b610da95760405133906001600160a01b038316907f7e1a1a08d52e4ba0e21554733d66165fd5151f99460116223d9e3a608eec5cb190600090a3610da7601782611f5e565b6000610a7382611f73565b61107d611b23565b610f2c6000611ff9565b61108f61204b565b61109c84848484896120e0565b60005b8561ffff168110156110bc576110b4336120ed565b60010161109f565b505050505050565b336110d76008546001600160a01b031690565b6001600160a01b031614806110f257506110f2601733611b01565b61110e5760405162461bcd60e51b8152600401610ba790613b1a565b610da9816111246008546001600160a01b031690565b612183565b3361113c6008546001600160a01b031690565b6001600160a01b031614806111575750611157601733611b01565b6111735760405162461bcd60e51b8152600401610ba790613b1a565b610f9c85858585856121f5565b606060128054610a8890613d21565b336111a26008546001600160a01b031690565b6001600160a01b031614806111bd57506111bd601733611b01565b6111d95760405162461bcd60e51b8152600401610ba790613b1a565b601980546001600160a01b0319166001600160a01b0392909216919091179055565b3361120e6008546001600160a01b031690565b6001600160a01b031614806112295750611229601733611b01565b6112455760405162461bcd60e51b8152600401610ba790613b1a565b610da782826123ab565b610da73383836123b7565b6019546001600160a01b031633146112b45760405162461bcd60e51b815260206004820152601a60248201527f4f6e6c792063616c6c61626c652062792043726f73736d696e740000000000006044820152606401610ba7565b6112c2868686868686611bf1565b60405181907f9c371b7d58cdc700de754bf2d561ec949d14f8050329e9fd001d6daf76e36ff090600090a2505050505050565b6112ff3383611931565b61131b5760405162461bcd60e51b8152600401610ba7906139e2565b61132784848484612486565b50505050565b6010546060906001600160a01b031615610ca4576040805160018082528183019092529060208083019080368337505060105482519293506001600160a01b03169183915060009061138157611381613ddb565b60200260200101906001600160a01b031690816001600160a01b031681525050919050565b60105460609081906001600160a01b031615611455576040805160018082528183019092529060208083019080368337505060105482519294506001600160a01b0316918491506000906113fc576113fc613ddb565b6001600160a01b0392909216602092830291909101820152604080516001808252818301909252918281019080368337019050509050600f548160008151811061144857611448613ddb565b6020026020010181815250505b915091565b604080516101e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101829052610160810182905261018081018290526101a081018290526101c0810191909152604080516101e08101825260085461ffff600160a01b820481168352600160b01b909104166020820152908101611508611757565b61ffff9081168252600954602080840191909152600854600160c01b90048216604080850191909152600b546060850152600a5483166080850152336000908152600d9092529020541660a082015260025460ff908116151560c083015260035460e0830152600454610100830152600554610120830152600654610140830152600754610160830152600c5416151561018090910152919050565b60606115af82611864565b60006115b96124b9565b905060008151116115d95760405180602001604052806000815250611604565b806115e3846124c8565b6040516020016115f49291906138c2565b6040516020818303038152906040525b9392505050565b3361161e6008546001600160a01b031690565b6001600160a01b031614806116395750611639601733611b01565b6116555760405162461bcd60e51b8152600401610ba790613b1a565b610da78282612565565b6001600160a01b03918216600090815260166020908152604080832093909416825291909152205460ff1690565b611695611b23565b6001600160a01b0381166116fa5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610ba7565b610da981611ff9565b336117166008546001600160a01b031690565b6001600160a01b031614806117315750611731601733611b01565b61174d5760405162461bcd60e51b8152600401610ba790613b1a565b610da782826125f5565b600c5460085460009161177e9161ffff610100909204821691600160b01b90910416613cbb565b905090565b60006001600160e01b0319821663da192f9f60e01b14806117b457506001600160e01b03198216635d9dd7eb60e11b145b806117cf57506001600160e01b0319821663152a902d60e11b145b80610a7357506001600160e01b03198216632dde656160e21b1492915050565b60006001600160e01b031982166380ac58cd60e01b148061182057506001600160e01b03198216635b5e139f60e01b145b80610a7357506301ffc9a760e01b6001600160e01b0319831614610a73565b60006001600160e01b03198216632a9f3abf60e11b1480610a735750610a73826117ef565b6000818152601360205260409020546001600160a01b0316610da95760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b6044820152606401610ba7565b600081815260156020526040902080546001600160a01b0319166001600160a01b03841690811790915581906118f882610f2e565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60008061193d83610f2e565b9050806001600160a01b0316846001600160a01b031614806119645750611964818561165f565b806119885750836001600160a01b031661197d84610b0b565b6001600160a01b0316145b949350505050565b826001600160a01b03166119a382610f2e565b6001600160a01b0316146119c95760405162461bcd60e51b8152600401610ba790613a81565b6001600160a01b038216611a2b5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610ba7565b611a388383836001612655565b826001600160a01b0316611a4b82610f2e565b6001600160a01b031614611a715760405162461bcd60e51b8152600401610ba790613a81565b600081815260156020908152604080832080546001600160a01b03199081169091556001600160a01b0387811680865260148552838620805460001901905590871680865283862080546001019055868652601390945282852080549092168417909155905184937fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6001600160a01b03811660009081526001830160205260408120541515611604565b6008546001600160a01b03163314610f2c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ba7565b6000611604836001600160a01b03841661265e565b6000610a73825490565b60006116048383612751565b6000600381905560048190556002805460ff19169055600681905560078190556040517fb02389feab3af620e2374d4d559b436ea226b1e6c9c31fe77dfbff3d40cbe9ba9190a1565b611bf961277b565b6000611c03612802565b9050611c0d611757565b61ffff168661ffff1611158015611c605750808015611c2e5750600c5460ff165b80611c445750600854600160a01b900461ffff16155b80611c60575060085461ffff600160a01b909104811690871611155b611c7c5760405162461bcd60e51b8152600401610ba790613ac6565b8015611e1457600c5460ff16611d8c57600a5461ffff1615611d01576001600160a01b0387166000908152600d6020526040902054600a5461ffff918216911681108015611ce35750600a54611cd790829061ffff16613cbb565b61ffff168761ffff1611155b611cff5760405162461bcd60e51b8152600401610ba790613ac6565b505b600854600160c01b900461ffff1615611d8c576001600160a01b0387166000908152600d602052604090205460085461ffff91821691600160c01b9091041681108015611d6e5750600854611d62908290600160c01b900461ffff16613cbb565b61ffff168761ffff1611155b611d8a5760405162461bcd60e51b8152600401610ba790613ac6565b505b611d9586612826565b600c5460ff16158015611dc35750600a5461ffff16151580611dc35750600854600160c01b900461ffff1615155b15611e0f576001600160a01b0387166000908152600d602052604081208054889290611df490849061ffff16613c45565b92506101000a81548161ffff021916908361ffff1602179055505b611f02565b600854600160c01b900461ffff1615611e9f576001600160a01b0387166000908152600d602052604090205460085461ffff91821691600160c01b9091041681108015611e815750600854611e75908290600160c01b900461ffff16613cbb565b61ffff168761ffff1611155b611e9d5760405162461bcd60e51b8152600401610ba790613ac6565b505b611ea886612885565b600854600160c01b900461ffff1615611f02576001600160a01b0387166000908152600d602052604081208054889290611ee790849061ffff16613c45565b92506101000a81548161ffff021916908361ffff1602179055505b808015611f115750600c5460ff165b15611f2857611f23858585858a612896565b611f34565b611f3485858585612a6a565b60005b8661ffff16811015611f5457611f4c886120ed565b600101611f37565b5050505050505050565b6000611604836001600160a01b038416612c29565b60006001600160a01b038216611fdd5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b6064820152608401610ba7565b506001600160a01b031660009081526014602052604090205490565b600880546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60025460ff166120885760405162461bcd60e51b8152602060048201526008602482015267496e61637469766560c01b6044820152606401610ba7565b600654421015801561209c57506007544211155b610f2c5760405162461bcd60e51b815260206004820152601560248201527427baba39b4b2329031b630b4b6903832b934b7b21760591b6044820152606401610ba7565b610f9c8585858585612896565b600c8054610100900461ffff1690600161210683613d5c565b825461ffff91821661010093840a9081029083021990911617909255600c546121359350849291900416612c78565b600c546040805161010090920461ffff16808352306020840152908201527f7a607f1ab973d85727d0ff44300699ee672c0e1d76f35013f36c02772f524ba39060600160405180910390a150565b60025460ff16156121a65760405162461bcd60e51b8152600401610ba790613af2565b6121ae611757565b61ffff168261ffff1611156121d55760405162461bcd60e51b8152600401610ba790613ac6565b60005b8261ffff16811015610c48576121ed826120ed565b6001016121d8565b60025460ff16156122185760405162461bcd60e51b8152600401610ba790613af2565b4285116122675760405162461bcd60e51b815260206004820152601b60248201527f43616e6e6f7420616374697661746520696e20746865207061737400000000006044820152606401610ba7565b838311156122cf5760405162461bcd60e51b815260206004820152602f60248201527f50726573616c6520496e74657276616c2063616e6e6f74206265206c6f6e676560448201526e72207468616e207468652073616c6560881b6064820152608401610ba7565b8082111580156122df5750848111155b6123215760405162461bcd60e51b8152602060048201526013602482015272496e76616c696420636c61696d2074696d657360681b6044820152606401610ba7565b60038590556123308486613c62565b60048190556005849055600683905560078290556002805460ff1916600117905560035460408051918252602082019290925290810184905260608101839052608081018290527fe512d106f8172b08abfd2fc5ddfdb7e2401381780ae29e29f1352b862f1d27319060a00160405180910390a15050505050565b610c48600e83836132de565b816001600160a01b0316836001600160a01b031614156124195760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610ba7565b6001600160a01b03838116600081815260166020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b612491848484611990565b61249d84848484612c82565b6113275760405162461bcd60e51b8152600401610ba790613a2f565b6060600e8054610a8890613d21565b606060006124d583612d8f565b600101905060008167ffffffffffffffff8111156124f5576124f5613df1565b6040519080825280601f01601f19166020018201604052801561251f576020820181803683370190505b5090508181016020015b600019016f181899199a1a9b1b9c1cb0b131b232b360811b600a86061a8153600a85049450846125585761255d565b612529565b509392505050565b60025460ff16156125885760405162461bcd60e51b8152600401610ba790613af2565b612590611757565b61ffff168111156125b35760405162461bcd60e51b8152600401610ba790613ac6565b60005b81811015610c48576125ed8383838181106125d3576125d3613ddb565b90506020020160208101906125e891906133d2565b6120ed565b6001016125b6565b6000826001600160a01b03168260405160006040518083038185875af1925050503d8060008114612642576040519150601f19603f3d011682016040523d82523d6000602084013e612647565b606091505b5050905080610c4857600080fd5b61132784612e67565b60008181526001830160205260408120548015612747576000612682600183613cde565b855490915060009061269690600190613cde565b90508181146126fb5760008660000182815481106126b6576126b6613ddb565b90600052602060002001549050808760000184815481106126d9576126d9613ddb565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061270c5761270c613dc5565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a73565b6000915050610a73565b600082600001828154811061276857612768613ddb565b9060005260206000200154905092915050565b60025460ff166127b85760405162461bcd60e51b8152602060048201526008602482015267496e61637469766560c01b6044820152606401610ba7565b600354421015610f2c5760405162461bcd60e51b815260206004820152601560248201527450757263686173696e67206e6f742061637469766560581b6044820152606401610ba7565b60006003544211801561177e57506005546003546128209042613cde565b10905090565b600b546128379061ffff8316613c9c565b3414610da95760405162461bcd60e51b815260206004820152601c60248201527f496e76616c696420707572636861736520616d6f756e742073656e74000000006044820152606401610ba7565b6009546128379061ffff8316613c9c565b60008281526001602052604090205460ff16156128f15760405162461bcd60e51b815260206004820152601960248201527821b0b73737ba103932b83630bc903a3930b739b0b1ba34b7b760391b6044820152606401610ba7565b6040517f19457468657265756d205369676e6564204d6573736167653a0a35340000000060208201526bffffffffffffffffffffffff193360601b16603c820152605081018390526001600160f01b031960f083901b1660708201526000906072016040516020818303038152906040528051906020012090508086146129ae5760405162461bcd60e51b81526020600482015260116024820152704d616c666f726d6564206d65737361676560781b6044820152606401610ba7565b60006129f286868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b93925050612ed39050565b6000549091506001600160a01b03808316911614612a465760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610ba7565b5050506000908152600160208190526040909120805460ff19169091179055505050565b60008181526001602052604090205460ff1615612ac55760405162461bcd60e51b815260206004820152601960248201527821b0b73737ba103932b83630bc903a3930b739b0b1ba34b7b760391b6044820152606401610ba7565b6040517f19457468657265756d205369676e6564204d6573736167653a0a35320000000060208201526bffffffffffffffffffffffff193360601b16603c82015260508101829052600090607001604051602081830303815290604052805190602001209050808514612b6e5760405162461bcd60e51b81526020600482015260116024820152704d616c666f726d6564206d65737361676560781b6044820152606401610ba7565b6000612bb285858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508a93925050612ed39050565b6000549091506001600160a01b03808316911614612c065760405162461bcd60e51b8152602060048201526011602482015270496e76616c6964207369676e617475726560781b6044820152606401610ba7565b50506000908152600160208190526040909120805460ff19169091179055505050565b6000818152600183016020526040812054612c7057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a73565b506000610a73565b610da78282612eef565b60006001600160a01b0384163b15612d8457604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612cc69033908990889088906004016138f1565b602060405180830381600087803b158015612ce057600080fd5b505af1925050508015612d10575060408051601f3d908101601f19168201909252612d0d918101906136e9565b60015b612d6a573d808015612d3e576040519150601f19603f3d011682016040523d82523d6000602084013e612d43565b606091505b508051612d625760405162461bcd60e51b8152600401610ba790613a2f565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611988565b506001949350505050565b60008072184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b8310612dce5772184f03e93ff9f4daa797ed6e38ed64bf6a1f0160401b830492506040015b6d04ee2d6d415b85acef81000000008310612dfa576d04ee2d6d415b85acef8100000000830492506020015b662386f26fc100008310612e1857662386f26fc10000830492506010015b6305f5e1008310612e30576305f5e100830492506008015b6127108310612e4457612710830492506004015b60648310612e56576064830492506002015b600a8310610a735760010192915050565b601054600160a01b900460ff161580612e8757506001600160a01b038116155b610da95760405162461bcd60e51b815260206004820152601f60248201527f5472616e73666572206c6f636b656420756e74696c2073616c6520656e6473006044820152606401610ba7565b6000806000612ee28585613089565b9150915061255d816130cc565b6001600160a01b038216612f455760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610ba7565b6000818152601360205260409020546001600160a01b031615612faa5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610ba7565b612fb8600083836001612655565b6000818152601360205260409020546001600160a01b03161561301d5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610ba7565b6001600160a01b038216600081815260146020908152604080832080546001019055848352601390915280822080546001600160a01b0319168417905551839291907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4610da7565b6000808251604114156130c05760208301516040840151606085015160001a6130b48782858561321a565b94509450505050610d47565b50600090506002610d47565b60008160048111156130e0576130e0613daf565b14156130e95750565b60018160048111156130fd576130fd613daf565b141561314b5760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610ba7565b600281600481111561315f5761315f613daf565b14156131ad5760405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610ba7565b60038160048111156131c1576131c1613daf565b1415610da95760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c604482015261756560f01b6064820152608401610ba7565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561325157506000905060036132d5565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156132a5573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381166132ce576000600192509250506132d5565b9150600090505b94509492505050565b8280546132ea90613d21565b90600052602060002090601f01602090048101928261330c5760008555613352565b82601f106133255782800160ff19823516178555613352565b82800160010185558215613352579182015b82811115613352578235825591602001919060010190613337565b50610e579291505b80821115610e57576000815560010161335a565b80358015158114610ca457600080fd5b60008083601f84011261339057600080fd5b50813567ffffffffffffffff8111156133a857600080fd5b602083019150836020828501011115610d4757600080fd5b803561ffff81168114610ca457600080fd5b6000602082840312156133e457600080fd5b813561160481613e07565b6000806040838503121561340257600080fd5b823561340d81613e07565b946020939093013593505050565b6000806040838503121561342e57600080fd5b823561343981613e07565b9150602083013561344981613e07565b809150509250929050565b60008060006060848603121561346957600080fd5b833561347481613e07565b9250602084013561348481613e07565b929592945050506040919091013590565b600080600080608085870312156134ab57600080fd5b84356134b681613e07565b935060208501356134c681613e07565b925060408501359150606085013567ffffffffffffffff808211156134ea57600080fd5b818701915087601f8301126134fe57600080fd5b81358181111561351057613510613df1565b604051601f8201601f19908116603f0116810190838211818310171561353857613538613df1565b816040528281528a602084870101111561355157600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b6000806040838503121561358857600080fd5b823561359381613e07565b91506135a16020840161336e565b90509250929050565b60008060008060008060a087890312156135c357600080fd5b86356135ce81613e07565b95506135dc602088016133c0565b945060408701359350606087013567ffffffffffffffff8111156135ff57600080fd5b61360b89828a0161337e565b979a9699509497949695608090950135949350505050565b6000806020838503121561363657600080fd5b823567ffffffffffffffff8082111561364e57600080fd5b818501915085601f83011261366257600080fd5b81358181111561367157600080fd5b8660208260051b850101111561368657600080fd5b60209290920196919550909350505050565b6000602082840312156136aa57600080fd5b6116048261336e565b6000602082840312156136c557600080fd5b5035919050565b6000602082840312156136de57600080fd5b813561160481613e1c565b6000602082840312156136fb57600080fd5b815161160481613e1c565b6000806020838503121561371957600080fd5b823567ffffffffffffffff81111561373057600080fd5b61373c8582860161337e565b90969095509350505050565b60006020828403121561375a57600080fd5b611604826133c0565b60008060008060006080868803121561377b57600080fd5b613784866133c0565b945060208601359350604086013567ffffffffffffffff8111156137a757600080fd5b6137b38882890161337e565b96999598509660600135949350505050565b600080604083850312156137d857600080fd5b50508035926020909101359150565b600080600080600060a086880312156137ff57600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b600081518084526020808501945080840160005b8381101561385b5781516001600160a01b031687529582019590820190600101613836565b509495945050505050565b600081518084526020808501945080840160005b8381101561385b5781518752958201959082019060010161387a565b600081518084526138ae816020860160208601613cf5565b601f01601f19169290920160200192915050565b600083516138d4818460208801613cf5565b8351908301906138e8818360208801613cf5565b01949350505050565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061392490830184613896565b9695505050505050565b6020808252825182820181905260009190848201906040850190845b8181101561396f5783516001600160a01b03168352928401929184019160010161394a565b50909695505050505050565b6020815260006116046020830184613822565b6040815260006139a16040830185613822565b82810360208401526139b38185613866565b95945050505050565b6020815260006116046020830184613866565b6020815260006116046020830184613896565b6020808252602d908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526c1c881bdc88185c1c1c9bdd9959609a1b606082015260800190565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60208082526025908201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060408201526437bbb732b960d91b606082015260800190565b602080825260129082015271151bdbc81b585b9e481c995c5d595cdd195960721b604082015260600190565b6020808252600e908201526d416c72656164792061637469766560901b604082015260600190565b60208082526024908201527f41646d696e436f6e74726f6c3a204d757374206265206f776e6572206f7220616040820152633236b4b760e11b606082015260800190565b815161ffff1681526101e081016020830151613b80602084018261ffff169052565b506040830151613b96604084018261ffff169052565b50606083015160608301526080830151613bb6608084018261ffff169052565b5060a083015160a083015260c0830151613bd660c084018261ffff169052565b5060e0830151613bec60e084018261ffff169052565b506101008381015115159083015261012080840151908301526101408084015190830152610160808401519083015261018080840151908301526101a080840151908301526101c0928301511515929091019190915290565b600061ffff8083168185168083038211156138e8576138e8613d99565b60008219821115613c7557613c75613d99565b500190565b600082613c9757634e487b7160e01b600052601260045260246000fd5b500490565b6000816000190483118215151615613cb657613cb6613d99565b500290565b600061ffff83811690831681811015613cd657613cd6613d99565b039392505050565b600082821015613cf057613cf0613d99565b500390565b60005b83811015613d10578181015183820152602001613cf8565b838111156113275750506000910152565b600181811c90821680613d3557607f821691505b60208210811415613d5657634e487b7160e01b600052602260045260246000fd5b50919050565b600061ffff80831681811415613d7457613d74613d99565b6001019392505050565b6000600019821415613d9257613d92613d99565b5060010190565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052602160045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610da957600080fd5b6001600160e01b031981168114610da957600080fdfea26469706673582212200a63321bf00b4ef9e507f2d2ba3b7cecd5687a0d269297ce4f980d264903ac7764736f6c63430008070033

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

0000000000000000000000000b670c096d475b2706034bcdbe98408592909236

-----Decoded View---------------
Arg [0] : signingAddress (address): 0x0b670C096d475B2706034bcDbE98408592909236

-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 0000000000000000000000000b670c096d475b2706034bcdbe98408592909236


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.