ETH Price: $3,264.51 (-0.72%)

Token

Little Darlings (LD)
 

Overview

Max Total Supply

226 LD

Holders

66

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Filtered by Token Holder
saarim.eth
Balance
3 LD
0x2795Aa71DcD63406E8655C3cf96Ee14Ba2123896
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:
LittleDarlings

Compiler Version
v0.8.24+commit.e11b9ed9

Optimization Enabled:
Yes with 800 runs

Other Settings:
paris EvmVersion
File 1 of 17 : LittleDarlings.sol
//      (                             (                                             (      
//      )\ )        )    )  (         )\ )              (                           )\ )   
//     (()/( (   ( /( ( /(  )\   (   (()/(      )  (    )\ (          (  (         (()/(   
//      /(_)))\  )\()))\())((_) ))\   /(_))  ( /(  )(  ((_))\   (     )\))(  (      /(_))  
//     (_)) ((_)(_))/(_))/  _  /((_) (_))_   )(_))(()\  _ ((_)  )\ ) ((_))\  )\   _(_))_   
//     | |   (_)| |_ | |_  | |(_))    |   \ ((_)_  ((_)| | (_) _(_/(  (()(_)((_) (_)|   \  
//     | |__ | ||  _||  _| | |/ -_)   | |) |/ _` || '_|| | | || ' \))/ _` | (_-<  _ | |) | 
//     |____||_| \__| \__| |_|\___|   |___/ \__,_||_|  |_| |_||_||_| \__, | /__/ (_)|___/  
//                                                                   |___/                 


// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.20;

import "erc721a/contracts/ERC721A.sol";
import "erc721a/contracts/extensions/ERC721AQueryable.sol";
import "erc721a/contracts/extensions/ERC721ABurnable.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/ReentrancyGuard.sol";
import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";
import "@openzeppelin/contracts/interfaces/IERC20.sol";
import "@openzeppelin/contracts/token/common/ERC2981.sol";

/**
 * @dev Minting contract for Little Darlings
 */
contract LittleDarlings is
    ERC721AQueryable,
    ERC721ABurnable,
    ReentrancyGuard,
    Ownable,
    ERC2981
{
    // Variables
    // ---------------------------------------------------------------

    uint256 private numUBAllowlistMint;
    uint256 private numAllowlistMint;
    bytes32 private merkleRootUBAllowlist;
    bytes32 private merkleRootAllowlist;

    bool private isUBAllowlistMintActive = false;
    bool private isAllowlistMintActive = false;
    bool private isMintActive = false;

    uint256 private collectionSize;
    uint256 private maxPerWalletUBAllowlist;
    uint256 private maxPerWalletAllowlist;
    uint256 private maxPerWallet;
    uint256 private allowlistUBMintPrice;
    uint256 private allowlistMintPrice;
    uint256 private publicMintPrice;
    address private devAddress;
    string private _baseTokenURI;

    // Helper functions
    // ---------------------------------------------------------------

    /**
     * @dev This function packs three uint16 values into a single uint64 value.
     * @param a: first uint16
     * @param b: second uint16
     * @param c: third uint16
     */
    function pack(uint16 a, uint16 b, uint16 c) internal pure returns (uint64) {
        return (uint64(a) << 32) | (uint64(b) << 16) | uint64(c);
    }

    /**
     * @dev This function unpacks a uint64 value into three uint16 values.
     * @param a: uint64 value
     */
    function unpack(uint64 a) internal pure returns (uint16, uint16, uint16) {
        return (uint16(a >> 32), uint16(a >> 16), uint16(a));
    }

    /**
     * @dev This function increases the number of UB allowlist mints for an address
     * @param account: address to increase UB allowlist mints for
     * @param quantity: number of UB allowlist mints to increase by
     */

    function increaseUBAllowlistMints(
        address account,
        uint256 quantity
    ) internal {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(account));
        _setAux(
            account,
            pack(
                senderAllowlistUBMints + uint16(quantity),
                senderAllowlistMints,
                senderGifts
            )
        );
    }

    /**
     * @dev This function increases the number of allowlist mints for an address
     * @param account: address to increase allowlist mints for
     * @param quantity: number of allowlist mints to increase by
     */

    function increaseAllowlistMints(
        address account,
        uint256 quantity
    ) internal {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(account));
        _setAux(
            account,
            pack(
                senderAllowlistUBMints,
                senderAllowlistMints + uint16(quantity),
                senderGifts
            )
        );
    }

    /**
     * @dev This function increases the number of gifts for an address
     * @param account: address to increase gifts for
     * @param quantity: number of gifts to increase by
     */

    function increaseGifts(address account, uint256 quantity) internal {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(account));
        _setAux(
            account,
            pack(
                senderAllowlistUBMints,
                senderAllowlistMints,
                senderGifts + uint16(quantity)
            )
        );
    }

    // Modifiers
    // ---------------------------------------------------------------

    /**
     * @dev This modifier ensures that the caller is a user and not a contract.
     */
    modifier callerIsUser() {
        require(tx.origin == msg.sender, "The caller is another contract.");
        _;
    }

    /**
     * @dev This modifier ensures that UB allowlist mint is open.
     */
    modifier UBAllowlistMintActive() {
        require(isUBAllowlistMintActive, "UB Allowlist mint is not open.");
        _;
    }

    /**
     * @dev This modifier ensures that allowlist mint is open.
     */
    modifier allowlistMintActive() {
        require(isAllowlistMintActive, "Allowlist mint is not open.");
        _;
    }

    /**
     * @dev This modifier ensures that public mint is open.
     */
    modifier publicMintActive() {
        require(isMintActive, "Mint is not open.");
        _;
    }

    /**
     * @dev This modifier checks that the merkle proof is valid.
     * @param merkleProof The merkle proof bytes32 array.
     */
    modifier isValidMerkleProof(bytes32[] calldata merkleProof, bytes32 root) {
        require(
            MerkleProof.verify(
                merkleProof,
                root,
                keccak256(abi.encodePacked(msg.sender))
            ),
            "Address does not exist in this allowlist."
        );
        _;
    }

    /**
     * @dev This modifier ensures that there are public mint tokens left.
     * @param quantity The number of tokens to be minted.
     */
    modifier mintLeft(uint256 quantity) {
        require(
            totalSupply() + quantity <= collectionSize,
            "There are no tokens left to mint."
        );
        _;
    }

    /**
     * @dev This modifier ensures that the caller does not mint more than the max number of allowlist tokens per wallet in the UB allowlist.
     * @param quantity The number of tokens to be minted.
     */
    modifier lessThanMaxPerWalletUBAllowlist(uint256 quantity) {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(msg.sender));
        require(
            senderAllowlistUBMints + quantity <= maxPerWalletUBAllowlist,
            "This wallet has reached its maximum allocation of UB allowlist tokens."
        );
        _;
    }

    /**
     * @dev This modifier ensures that the caller does not mint more than the max number of allowlist tokens per wallet.
     * @param quantity The number of tokens to be minted.
     */
    modifier lessThanMaxPerWalletAllowlist(uint256 quantity) {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(msg.sender));
        require(
            senderAllowlistUBMints + senderAllowlistMints + quantity <=
                maxPerWalletAllowlist,
            "This wallet has reached its maximum allocation of allowlist tokens."
        );
        _;
    }

    /**
     * @dev This modifier ensures that the caller does not mint more than the max number of tokens per wallet.
     * @param quantity The number of tokens to be minted.
     */
    modifier lessThanMaxPerWallet(uint256 quantity) {
        (
            uint16 senderAllowlistUBMints,
            uint16 senderAllowlistMints,
            uint16 senderGifts
        ) = unpack(_getAux(msg.sender));
        require(
            _numberMinted(msg.sender) + quantity <=
                maxPerWallet +
                    senderAllowlistUBMints +
                    senderAllowlistMints +
                    senderGifts,
            "This wallet has reached its maximum allocation of tokens."
        );
        _;
    }

    /**
     * @dev This modifier ensures that the caller has sent the correct amount of ETH.
     * @param price The price of the token.
     * @param quantity The number of tokens to be minted.
     */
    modifier isCorrectPayment(uint256 price, uint256 quantity) {
        require(price * quantity == msg.value, "Incorrect amount of ETH sent.");
        _;
    }

    // Constructor
    // ---------------------------------------------------------------

    /**
     * @dev This function is the constructor for the contract.
     * @param collectionSize_ The number of tokens in the collection.
     * @param maxPerWalletUBAllowlist_ The maximum number of tokens that can be minted per wallet in the UB allowlist phase.
     * @param maxPerWalletAllowlist_ The maximum number of tokens that can be minted per wallet.
     * @param maxPerWallet_ The maximum number of tokens that can be minted per wallet.
     * @param allowlistUBMintPrice_ The price of UB allowlist mint.
     * @param allowlistMintPrice_ The price of allowlist mint.
     * @param publicMintPrice_ The price of public mint.
     * @param devAddress_ The address of the dev that receives eth in the whithdraw() function.
     */
    constructor(
        uint256 collectionSize_,
        uint256 maxPerWalletUBAllowlist_,
        uint256 maxPerWalletAllowlist_,
        uint256 maxPerWallet_,
        uint256 allowlistUBMintPrice_,
        uint256 allowlistMintPrice_,
        uint256 publicMintPrice_,
        address devAddress_
    ) Ownable(msg.sender) ERC721A("Little Darlings", "LD") {
        collectionSize = collectionSize_;
        maxPerWalletUBAllowlist = maxPerWalletUBAllowlist_;
        maxPerWalletAllowlist = maxPerWalletAllowlist_;
        maxPerWallet = maxPerWallet_;
        allowlistUBMintPrice = allowlistUBMintPrice_;
        allowlistMintPrice = allowlistMintPrice_;
        publicMintPrice = publicMintPrice_;
        devAddress = devAddress_;

        // Set royalty receiver to the 0xSplits contract,
        // at 5% (default denominator is 10000).
        _setDefaultRoyalty(0x2717f3449736949c9472ff05FB46b833Cf4c32eC, 500);
    }

    // Public minting functions
    // ---------------------------------------------------------------

    /**
     * @notice Mint multiple tokens from UB allowlist paid mint.
     * @param quantity The number of tokens to be minted.
     * @param merkleProof The merkle proof bytes32 array.
     */
    function UBAllowlistMint(
        uint256 quantity,
        bytes32[] calldata merkleProof
    )
        external
        payable
        nonReentrant
        callerIsUser
        UBAllowlistMintActive
        isValidMerkleProof(merkleProof, merkleRootUBAllowlist)
        mintLeft(quantity)
        lessThanMaxPerWalletUBAllowlist(quantity)
        isCorrectPayment(allowlistUBMintPrice, quantity)
    {
        numUBAllowlistMint += quantity;
        increaseUBAllowlistMints(msg.sender, quantity);
        _safeMint(msg.sender, quantity);
    }

    /**
     * @notice Mint multiple tokens from allowlist paid mint.
     * @param quantity The number of tokens to be minted.
     * @param merkleProof The merkle proof bytes32 array.
     */
    function allowlistMint(
        uint256 quantity,
        bytes32[] calldata merkleProof
    )
        external
        payable
        nonReentrant
        callerIsUser
        allowlistMintActive
        isValidMerkleProof(merkleProof, merkleRootAllowlist)
        mintLeft(quantity)
        lessThanMaxPerWalletAllowlist(quantity)
        isCorrectPayment(allowlistMintPrice, quantity)
    {
        numAllowlistMint += quantity;
        increaseAllowlistMints(msg.sender, quantity);
        _safeMint(msg.sender, quantity);
    }

    /**
     * @notice Mint multiple tokens from public paid mint.
     * @param quantity The number of tokens to be minted.
     */
    function mint(
        uint256 quantity
    )
        external
        payable
        nonReentrant
        callerIsUser
        publicMintActive
        mintLeft(quantity)
        lessThanMaxPerWallet(quantity)
        isCorrectPayment(publicMintPrice, quantity)
    {
        _safeMint(msg.sender, quantity);
    }

    /**
     * @notice Mint a token to each address in an array.
     * @param addresses An array of addresses to mint to.
     */
    function gift(
        address[] calldata addresses
    ) external nonReentrant onlyOwner mintLeft(addresses.length) {
        uint256 numToGift = addresses.length;
        for (uint256 i = 0; i < numToGift; i++) {
            increaseGifts(addresses[i], 1);
            _safeMint(addresses[i], 1);
        }
    }

    /**
     * @notice Mint multiple tokens to each address in an array.
     * @param addresses An n-sized array of addresses to mint to.
     * @param quantities An n-sized array  quantities to mint to each corresponding address.
     */
    function giftMultiple(
        address[] calldata addresses,
        uint256[] calldata quantities
    ) external nonReentrant onlyOwner {
        require(
            addresses.length == quantities.length,
            "The number of recipients and quantities must be the same."
        );
        uint256 totalGifts = 0;
        for (uint256 i = 0; i < quantities.length; i++) {
            totalGifts += quantities[i];
        }
        require(
            totalSupply() + totalGifts <= collectionSize,
            "There are no tokens left to mint."
        );
        for (uint256 i = 0; i < addresses.length; i++) {
            increaseGifts(addresses[i], quantities[i]);
            _safeMint(addresses[i], quantities[i]);
        }
    }

    // Public read-only functions
    // ---------------------------------------------------------------

    /**
     * @notice Get the number of tokens minted by an address.
     * @param owner The address to check.
     * @return The number of tokens minted by the address.
     */
    function numberMinted(address owner) public view returns (uint256) {
        return _numberMinted(owner);
    }

    /**
     * @notice Get the number of tokens minted in the UB allowlist tier.
     * @return The number of tokens minted in the UB allowlist tier.
     */
    function getNumAllowlistMint() public view returns (uint256) {
        return numAllowlistMint;
    }

    /**
     * @notice Get the number of tokens minted in the allowlist tier.
     * @return The number of tokens minted in the allowlist tier.
     */
    function getNumUBAllowlistMint() public view returns (uint256) {
        return numUBAllowlistMint;
    }

    /**
     * @notice Get the merkle root for the UB allowlist.
     * @return The merkle root for the UB allowlist.
     */
    function getUBAllowlistMerkleRoot() public view returns (bytes32) {
        return merkleRootUBAllowlist;
    }

    /**
     * @notice Get the merkle root for the allowlist.
     * @return The merkle root for the allowlist.
     */
    function getAllowlistMerkleRoot() public view returns (bytes32) {
        return merkleRootAllowlist;
    }

    /**
     * @notice Get the UB allowlist mint status.
     * @return The UB allowlist mint status.
     */
    function getIsUBAllowlistMintActive() public view returns (bool) {
        return isUBAllowlistMintActive;
    }

    /**
     * @notice Get the allowlist mint status.
     * @return The allowlist mint status.
     */
    function getIsAllowlistMintActive() public view returns (bool) {
        return isAllowlistMintActive;
    }

    /**
     * @notice Get the mint status.
     * @return The mint status.
     */
    function getIsMintActive() public view returns (bool) {
        return isMintActive;
    }

    /**
     * @notice Get the total number of tokens that can ever be minted in the collection.
     * @return The total number of tokens.
     */
    function getCollectionSize() public view returns (uint256) {
        return collectionSize;
    }

    /**
     * @notice Get the maximum number of tokens that can be minted per wallet in the UB allowlist phase.
     * @return The maximum number of tokens that can be minted per wallet in the UB allowlist phase. These also count towrds the general allowlist.
     */
    function getMaxPerWalletUBAllowlist() public view returns (uint256) {
        return maxPerWalletUBAllowlist;
    }

    /**
     * @notice Get the maximum number of tokens that can be minted per wallet in the allowlist phase.
     * @return The maximum number of tokens that can be minted per wallet in the allowlist phase.
     */
    function getMaxPerWalletAllowlist() public view returns (uint256) {
        return maxPerWalletAllowlist;
    }

    /**
     * @notice Get the maximum number of tokens that can be minted per wallet in the public phase.
     * @return The maximum number of tokens that can be minted per wallet in the public phase.
     */
    function getMaxPerWallet() public view returns (uint256) {
        return maxPerWallet;
    }

    /**
     * @notice Get the mint price for UB allowlist sale.
     * @return The UB allowlist mint price.
     */
    function getAllowlistUBMintPrice() public view returns (uint256) {
        return allowlistUBMintPrice;
    }

    /**
     * @notice Get the mint price for allowlist sale.
     * @return The allowlist mint price.
     */
    function getAllowlistMintPrice() public view returns (uint256) {
        return allowlistMintPrice;
    }

    /**
     * @notice Get the mint price for public sale.
     * @return The public mint price.
     */
    function getPublicMintPrice() public view returns (uint256) {
        return publicMintPrice;
    }

    /**
     * @notice Get the address that gets funds distributed to in the withdraw() method.
     * @return The number of tokens minted by the contract.
     */
    function getDevAddress() public view returns (address) {
        return devAddress;
    }

    /**
     * @notice Get the number of tokens that address has minted from the UB allowlist.
     * @return The number of free mint tokens that address has  minted from the UB allowlist.
     */
    function getOwnerAllowlistUBMintCount(
        address owner
    ) public view returns (uint16) {
        (uint16 ownerAllowlistUBMints, , ) = unpack(_getAux(owner));
        return ownerAllowlistUBMints;
    }

    /**
     * @notice Get the number of tokens that address has minted from the allowlist.
     * @return The number of free mint tokens that address has  minted from the allowlist.
     */
    function getOwnerAllowlistMintCount(
        address owner
    ) public view returns (uint16) {
        (, uint16 ownerAllowlistMints, ) = unpack(_getAux(owner));
        return ownerAllowlistMints;
    }


    /**
     * @notice Get the number of tokens that address has been gifted.
     * @return The number of free mint tokens that address has been gifted.
     */
    function getOwnerGiftsCount(address owner) public view returns (uint16) {
        (, , uint16 ownerGifts) = unpack(_getAux(owner));
        return ownerGifts;
    }

    /**
     * @notice Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     * @param tokenId The token ID to query.
     */
    function tokenURI(
        uint256 tokenId
    ) public view virtual override(IERC721A, ERC721A) returns (string memory) {
        if (!_exists(tokenId)) revert URIQueryForNonexistentToken();
        string memory baseURI = _baseURI();
        return
            bytes(baseURI).length != 0
                ? string(abi.encodePacked(baseURI, _toString(tokenId), ".json"))
                : "";
    }

    // Internal read-only functions
    // ---------------------------------------------------------------

    /**
     * @dev Returns base token metadata URI.
     * @return Base token metadata URI.
     */
    function _baseURI() internal view virtual override returns (string memory) {
        return _baseTokenURI;
    }

    // Owner only administration functions
    // ---------------------------------------------------------------

    /**
     * @notice Set the merkle root for the UB paid mint allowlist.
     * @param _merkleRootUBAllowlist The new merkle root.
     */
    function setUBAllowlistMerkleRoot(
        bytes32 _merkleRootUBAllowlist
    ) external onlyOwner {
        merkleRootUBAllowlist = _merkleRootUBAllowlist;
    }

    /**
     * @notice Set the merkle root for the paid mint allowlist.
     * @param _merkleRootAllowlist The new merkle root.
     */
    function setAllowlistMerkleRoot(
        bytes32 _merkleRootAllowlist
    ) external onlyOwner {
        merkleRootAllowlist = _merkleRootAllowlist;
    }

    /**
     * @notice Set UB allowlist paid mint to active or inactive.
     * @param _isUBAllowlistMintActive True to set free mint to active, false to set to inactive.
     */
    function setUBAllowlistMintActive(
        bool _isUBAllowlistMintActive
    ) external onlyOwner {
        isUBAllowlistMintActive = _isUBAllowlistMintActive;
    }

    /**
     * @notice Set allowlist paid mint to active or inactive.
     * @param _isAllowlistMintActive True to set free mint to active, false to set to inactive.
     */
    function setAllowlistMintActive(
        bool _isAllowlistMintActive
    ) external onlyOwner {
        isAllowlistMintActive = _isAllowlistMintActive;
    }

    /**
     * @notice Set public mint to active or inactive.
     * @param _isMintActive True to set mint to active, false to set to inactive.
     */
    function setMintActive(bool _isMintActive) external onlyOwner {
        isMintActive = _isMintActive;
    }

    /**
     * @notice Reduce the number of tokens that can be minted.
     * @param _collectionSize The new number of total tokens that can ever be minted in the collection. Cannot be greater than the current collection size or smaller than the remaining tokens.
     */
    function setCollectionSize(uint256 _collectionSize) external onlyOwner {
        require(
            _collectionSize <= collectionSize,
            "Cannot increase collection size."
        );
        require(
            _collectionSize >= totalSupply(),
            "Cannot set collection size to less than the number of tokens already minted."
        );
        collectionSize = _collectionSize;
    }

    /**
     * @notice Set the maximum number of tokens that can be minted per wallet in the UB allowlist phase.
     * @param _maxPerWalletUBAllowlist The new maximum number of tokens that can be minted per wallet in the UB allowlist phase.
     */
    function setMaxPerWalletUBAllowlist(
        uint256 _maxPerWalletUBAllowlist
    ) external onlyOwner {
        maxPerWalletUBAllowlist = _maxPerWalletUBAllowlist;
    }

    /**
     * @notice Set the maximum number of tokens that can be minted per wallet in the allowlist phase.
     * @param _maxPerWalletAllowlist The new maximum number of tokens that can be minted per wallet in the allowlist phase.
     */
    function setMaxPerWalletAllowlist(
        uint256 _maxPerWalletAllowlist
    ) external onlyOwner {
        maxPerWalletAllowlist = _maxPerWalletAllowlist;
    }

    /**
     * @notice Set the maximum number of tokens that can be minted per wallet in the public phase.
     * @param _maxPerWallet The new maximum number of tokens that can be minted per wallet in the public phase.
     */
    function setMaxPerWallet(uint256 _maxPerWallet) external onlyOwner {
        maxPerWallet = _maxPerWallet;
    }

    /**
     * @notice Set the UB allowlist mint price.
     * @param _allowlistUBMintPrice The new mint price.
     */
    function setUBAllowlistMintPrice(
        uint256 _allowlistUBMintPrice
    ) external onlyOwner {
        allowlistUBMintPrice = _allowlistUBMintPrice;
    }

    /**
     * @notice Set the allowlist mint price.
     * @param _allowlistMintPrice The new mint price.
     */
    function setAllowlistMintPrice(
        uint256 _allowlistMintPrice
    ) external onlyOwner {
        allowlistMintPrice = _allowlistMintPrice;
    }

    /**
     * @notice Set the public mint price.
     * @param _publicMintPrice The new mint price.
     */
    function setPublicMintPrice(uint256 _publicMintPrice) external onlyOwner {
        publicMintPrice = _publicMintPrice;
    }

    /**
     * @notice Set the address that gets funds distributed to in the withdraw() method.
     * @param _devAddress The new dev address.
     */
    function setDevAddress(address _devAddress) external onlyOwner {
        devAddress = _devAddress;
    }

    /**
     * @notice Set the base metadata URI.
     * @param baseURI The new base metadata URI.
     */
    function setBaseURI(string calldata baseURI) external onlyOwner {
        _baseTokenURI = baseURI;
    }

    /**
     * @notice Withdraw ETH from the contract.
     * @dev 80% of the contract balance is sent to the owner and 20% is sent to the dev address.
     */
    function withdraw() external onlyOwner nonReentrant {
        (bool ownerWithdrawSuccess, ) = msg.sender.call{
            value: (address(this).balance * 8000) / 10000
        }("");
        require(ownerWithdrawSuccess, "Owner transfer failed");
        (bool devWithdrawSuccess, ) = devAddress.call{
            value: address(this).balance
        }("");
        require(devWithdrawSuccess, "Dev transfer failed");
    }

    /**
     * @notice Withdraw ERC-20 tokens from the contract.
     * @dev In case someone accidentally sends ERC-20 tokens to the contract.
     * @param token The token to withdraw.
     */
    function withdrawTokens(IERC20 token) external onlyOwner nonReentrant {
        token.transfer(msg.sender, token.balanceOf(address(this)));
    }

    function supportsInterface(
        bytes4 interfaceId
    ) public view virtual override(IERC721A, ERC721A, ERC2981) returns (bool) {
        return
            ERC721A.supportsInterface(interfaceId) ||
            ERC2981.supportsInterface(interfaceId);
    }

    function setDefaultRoyalty(
        address receiver,
        uint96 feeNumerator
    ) public onlyOwner {
        _setDefaultRoyalty(receiver, feeNumerator);
    }
}

File 2 of 17 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (access/Ownable.sol)

pragma solidity ^0.8.20;

import {Context} from "../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.
 *
 * The initial owner is set to the address provided by the deployer. 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;

    /**
     * @dev The caller account is not authorized to perform an operation.
     */
    error OwnableUnauthorizedAccount(address account);

    /**
     * @dev The owner is not a valid owner account. (eg. `address(0)`)
     */
    error OwnableInvalidOwner(address owner);

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the address provided by the deployer as the initial owner.
     */
    constructor(address initialOwner) {
        if (initialOwner == address(0)) {
            revert OwnableInvalidOwner(address(0));
        }
        _transferOwnership(initialOwner);
    }

    /**
     * @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 {
        if (owner() != _msgSender()) {
            revert OwnableUnauthorizedAccount(_msgSender());
        }
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby disabling 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 {
        if (newOwner == address(0)) {
            revert OwnableInvalidOwner(address(0));
        }
        _transferOwnership(newOwner);
    }

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

File 3 of 17 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC20.sol)

pragma solidity ^0.8.20;

import {IERC20} from "../token/ERC20/IERC20.sol";

File 4 of 17 : IERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (interfaces/IERC2981.sol)

pragma solidity ^0.8.20;

import {IERC165} from "../utils/introspection/IERC165.sol";

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

File 5 of 17 : ERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/common/ERC2981.sol)

pragma solidity ^0.8.20;

import {IERC2981} from "../../interfaces/IERC2981.sol";
import {IERC165, ERC165} from "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information.
 *
 * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for
 * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first.
 *
 * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the
 * fee is specified in basis points by default.
 *
 * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See
 * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to
 * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported.
 */
abstract contract ERC2981 is IERC2981, ERC165 {
    struct RoyaltyInfo {
        address receiver;
        uint96 royaltyFraction;
    }

    RoyaltyInfo private _defaultRoyaltyInfo;
    mapping(uint256 tokenId => RoyaltyInfo) private _tokenRoyaltyInfo;

    /**
     * @dev The default royalty set is invalid (eg. (numerator / denominator) >= 1).
     */
    error ERC2981InvalidDefaultRoyalty(uint256 numerator, uint256 denominator);

    /**
     * @dev The default royalty receiver is invalid.
     */
    error ERC2981InvalidDefaultRoyaltyReceiver(address receiver);

    /**
     * @dev The royalty set for an specific `tokenId` is invalid (eg. (numerator / denominator) >= 1).
     */
    error ERC2981InvalidTokenRoyalty(uint256 tokenId, uint256 numerator, uint256 denominator);

    /**
     * @dev The royalty receiver for `tokenId` is invalid.
     */
    error ERC2981InvalidTokenRoyaltyReceiver(uint256 tokenId, address receiver);

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

    /**
     * @inheritdoc IERC2981
     */
    function royaltyInfo(uint256 tokenId, uint256 salePrice) public view virtual returns (address, uint256) {
        RoyaltyInfo memory royalty = _tokenRoyaltyInfo[tokenId];

        if (royalty.receiver == address(0)) {
            royalty = _defaultRoyaltyInfo;
        }

        uint256 royaltyAmount = (salePrice * royalty.royaltyFraction) / _feeDenominator();

        return (royalty.receiver, royaltyAmount);
    }

    /**
     * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a
     * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an
     * override.
     */
    function _feeDenominator() internal pure virtual returns (uint96) {
        return 10000;
    }

    /**
     * @dev Sets the royalty information that all ids in this contract will default to.
     *
     * Requirements:
     *
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual {
        uint256 denominator = _feeDenominator();
        if (feeNumerator > denominator) {
            // Royalty fee will exceed the sale price
            revert ERC2981InvalidDefaultRoyalty(feeNumerator, denominator);
        }
        if (receiver == address(0)) {
            revert ERC2981InvalidDefaultRoyaltyReceiver(address(0));
        }

        _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Removes default royalty information.
     */
    function _deleteDefaultRoyalty() internal virtual {
        delete _defaultRoyaltyInfo;
    }

    /**
     * @dev Sets the royalty information for a specific token id, overriding the global default.
     *
     * Requirements:
     *
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setTokenRoyalty(uint256 tokenId, address receiver, uint96 feeNumerator) internal virtual {
        uint256 denominator = _feeDenominator();
        if (feeNumerator > denominator) {
            // Royalty fee will exceed the sale price
            revert ERC2981InvalidTokenRoyalty(tokenId, feeNumerator, denominator);
        }
        if (receiver == address(0)) {
            revert ERC2981InvalidTokenRoyaltyReceiver(tokenId, address(0));
        }

        _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Resets royalty information for the token id back to the global default.
     */
    function _resetTokenRoyalty(uint256 tokenId) internal virtual {
        delete _tokenRoyaltyInfo[tokenId];
    }
}

File 6 of 17 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.20;

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

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

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

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

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

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

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

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

File 7 of 17 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)

pragma solidity ^0.8.20;

/**
 * @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;
    }

    function _contextSuffixLength() internal view virtual returns (uint256) {
        return 0;
    }
}

File 8 of 17 : MerkleProof.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/cryptography/MerkleProof.sol)

pragma solidity ^0.8.20;

/**
 * @dev These functions deal with verification of Merkle Tree proofs.
 *
 * The tree and the proofs can be generated using our
 * https://github.com/OpenZeppelin/merkle-tree[JavaScript library].
 * You will find a quickstart guide in the readme.
 *
 * WARNING: You should avoid using leaf values that are 64 bytes long prior to
 * hashing, or use a hash function other than keccak256 for hashing leaves.
 * This is because the concatenation of a sorted pair of internal nodes in
 * the Merkle tree could be reinterpreted as a leaf value.
 * OpenZeppelin's JavaScript library generates Merkle trees that are safe
 * against this attack out of the box.
 */
library MerkleProof {
    /**
     *@dev The multiproof provided is not valid.
     */
    error MerkleProofInvalidMultiproof();

    /**
     * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree
     * defined by `root`. For this, a `proof` must be provided, containing
     * sibling hashes on the branch from the leaf to the root of the tree. Each
     * pair of leaves and each pair of pre-images are assumed to be sorted.
     */
    function verify(bytes32[] memory proof, bytes32 root, bytes32 leaf) internal pure returns (bool) {
        return processProof(proof, leaf) == root;
    }

    /**
     * @dev Calldata version of {verify}
     */
    function verifyCalldata(bytes32[] calldata proof, bytes32 root, bytes32 leaf) internal pure returns (bool) {
        return processProofCalldata(proof, leaf) == root;
    }

    /**
     * @dev Returns the rebuilt hash obtained by traversing a Merkle tree up
     * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt
     * hash matches the root of the tree. When processing the proof, the pairs
     * of leafs & pre-images are assumed to be sorted.
     */
    function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Calldata version of {processProof}
     */
    function processProofCalldata(bytes32[] calldata proof, bytes32 leaf) internal pure returns (bytes32) {
        bytes32 computedHash = leaf;
        for (uint256 i = 0; i < proof.length; i++) {
            computedHash = _hashPair(computedHash, proof[i]);
        }
        return computedHash;
    }

    /**
     * @dev Returns true if the `leaves` can be simultaneously proven to be a part of a Merkle tree defined by
     * `root`, according to `proof` and `proofFlags` as described in {processMultiProof}.
     *
     * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details.
     */
    function multiProofVerify(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProof(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Calldata version of {multiProofVerify}
     *
     * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details.
     */
    function multiProofVerifyCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32 root,
        bytes32[] memory leaves
    ) internal pure returns (bool) {
        return processMultiProofCalldata(proof, proofFlags, leaves) == root;
    }

    /**
     * @dev Returns the root of a tree reconstructed from `leaves` and sibling nodes in `proof`. The reconstruction
     * proceeds by incrementally reconstructing all inner nodes by combining a leaf/inner node with either another
     * leaf/inner node or a proof sibling node, depending on whether each `proofFlags` item is true or false
     * respectively.
     *
     * CAUTION: Not all Merkle trees admit multiproofs. To use multiproofs, it is sufficient to ensure that: 1) the tree
     * is complete (but not necessarily perfect), 2) the leaves to be proven are in the opposite order they are in the
     * tree (i.e., as seen from right to left starting at the deepest layer and continuing at the next layer).
     */
    function processMultiProof(
        bytes32[] memory proof,
        bool[] memory proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuilds the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the Merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 proofLen = proof.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        if (leavesLen + proofLen != totalHashes + 1) {
            revert MerkleProofInvalidMultiproof();
        }

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value from the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i]
                ? (leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++])
                : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            if (proofPos != proofLen) {
                revert MerkleProofInvalidMultiproof();
            }
            unchecked {
                return hashes[totalHashes - 1];
            }
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    /**
     * @dev Calldata version of {processMultiProof}.
     *
     * CAUTION: Not all Merkle trees admit multiproofs. See {processMultiProof} for details.
     */
    function processMultiProofCalldata(
        bytes32[] calldata proof,
        bool[] calldata proofFlags,
        bytes32[] memory leaves
    ) internal pure returns (bytes32 merkleRoot) {
        // This function rebuilds the root hash by traversing the tree up from the leaves. The root is rebuilt by
        // consuming and producing values on a queue. The queue starts with the `leaves` array, then goes onto the
        // `hashes` array. At the end of the process, the last hash in the `hashes` array should contain the root of
        // the Merkle tree.
        uint256 leavesLen = leaves.length;
        uint256 proofLen = proof.length;
        uint256 totalHashes = proofFlags.length;

        // Check proof validity.
        if (leavesLen + proofLen != totalHashes + 1) {
            revert MerkleProofInvalidMultiproof();
        }

        // The xxxPos values are "pointers" to the next value to consume in each array. All accesses are done using
        // `xxx[xxxPos++]`, which return the current value and increment the pointer, thus mimicking a queue's "pop".
        bytes32[] memory hashes = new bytes32[](totalHashes);
        uint256 leafPos = 0;
        uint256 hashPos = 0;
        uint256 proofPos = 0;
        // At each step, we compute the next hash using two values:
        // - a value from the "main queue". If not all leaves have been consumed, we get the next leaf, otherwise we
        //   get the next hash.
        // - depending on the flag, either another value from the "main queue" (merging branches) or an element from the
        //   `proof` array.
        for (uint256 i = 0; i < totalHashes; i++) {
            bytes32 a = leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++];
            bytes32 b = proofFlags[i]
                ? (leafPos < leavesLen ? leaves[leafPos++] : hashes[hashPos++])
                : proof[proofPos++];
            hashes[i] = _hashPair(a, b);
        }

        if (totalHashes > 0) {
            if (proofPos != proofLen) {
                revert MerkleProofInvalidMultiproof();
            }
            unchecked {
                return hashes[totalHashes - 1];
            }
        } else if (leavesLen > 0) {
            return leaves[0];
        } else {
            return proof[0];
        }
    }

    /**
     * @dev Sorts the pair (a, b) and hashes the result.
     */
    function _hashPair(bytes32 a, bytes32 b) private pure returns (bytes32) {
        return a < b ? _efficientHash(a, b) : _efficientHash(b, a);
    }

    /**
     * @dev Implementation of keccak256(abi.encode(a, b)) that doesn't allocate or expand memory.
     */
    function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) {
        /// @solidity memory-safe-assembly
        assembly {
            mstore(0x00, a)
            mstore(0x20, b)
            value := keccak256(0x00, 0x40)
        }
    }
}

File 9 of 17 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/ERC165.sol)

pragma solidity ^0.8.20;

import {IERC165} from "./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);
 * }
 * ```
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 10 of 17 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol)

pragma solidity ^0.8.20;

/**
 * @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 11 of 17 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/ReentrancyGuard.sol)

pragma solidity ^0.8.20;

/**
 * @dev Contract module that helps prevent reentrant calls to a function.
 *
 * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
 * available, which can be applied to functions to make sure there are no nested
 * (reentrant) calls to them.
 *
 * Note that because there is a single `nonReentrant` guard, functions marked as
 * `nonReentrant` may not call one another. This can be worked around by making
 * those functions `private`, and then adding `external` `nonReentrant` entry
 * points to them.
 *
 * TIP: If you would like to learn more about reentrancy and alternative ways
 * to protect against it, check out our blog post
 * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
 */
abstract contract ReentrancyGuard {
    // Booleans are more expensive than uint256 or any type that takes up a full
    // word because each write operation emits an extra SLOAD to first read the
    // slot's contents, replace the bits taken up by the boolean, and then write
    // back. This is the compiler's defense against contract upgrades and
    // pointer aliasing, and it cannot be disabled.

    // The values being non-zero value makes deployment a bit more expensive,
    // but in exchange the refund on every call to nonReentrant will be lower in
    // amount. Since refunds are capped to a percentage of the total
    // transaction's gas, it is best to keep them low in cases like this one, to
    // increase the likelihood of the full refund coming into effect.
    uint256 private constant NOT_ENTERED = 1;
    uint256 private constant ENTERED = 2;

    uint256 private _status;

    /**
     * @dev Unauthorized reentrant call.
     */
    error ReentrancyGuardReentrantCall();

    constructor() {
        _status = NOT_ENTERED;
    }

    /**
     * @dev Prevents a contract from calling itself, directly or indirectly.
     * Calling a `nonReentrant` function from another `nonReentrant`
     * function is not supported. It is possible to prevent this from happening
     * by making the `nonReentrant` function external, and making it call a
     * `private` function that does the actual work.
     */
    modifier nonReentrant() {
        _nonReentrantBefore();
        _;
        _nonReentrantAfter();
    }

    function _nonReentrantBefore() private {
        // On the first call to nonReentrant, _status will be NOT_ENTERED
        if (_status == ENTERED) {
            revert ReentrancyGuardReentrantCall();
        }

        // Any calls to nonReentrant after this point will fail
        _status = ENTERED;
    }

    function _nonReentrantAfter() private {
        // By storing the original value once again, a refund is triggered (see
        // https://eips.ethereum.org/EIPS/eip-2200)
        _status = NOT_ENTERED;
    }

    /**
     * @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a
     * `nonReentrant` function in the call stack.
     */
    function _reentrancyGuardEntered() internal view returns (bool) {
        return _status == ENTERED;
    }
}

File 12 of 17 : ERC721A.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import './IERC721A.sol';

/**
 * @dev Interface of ERC721 token receiver.
 */
interface ERC721A__IERC721Receiver {
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

/**
 * @title ERC721A
 *
 * @dev Implementation of the [ERC721](https://eips.ethereum.org/EIPS/eip-721)
 * Non-Fungible Token Standard, including the Metadata extension.
 * Optimized for lower gas during batch mints.
 *
 * Token IDs are minted in sequential order (e.g. 0, 1, 2, 3, ...)
 * starting from `_startTokenId()`.
 *
 * The `_sequentialUpTo()` function can be overriden to enable spot mints
 * (i.e. non-consecutive mints) for `tokenId`s greater than `_sequentialUpTo()`.
 *
 * Assumptions:
 *
 * - An owner cannot have more than 2**64 - 1 (max value of uint64) of supply.
 * - The maximum token ID cannot exceed 2**256 - 1 (max value of uint256).
 */
contract ERC721A is IERC721A {
    // Bypass for a `--via-ir` bug (https://github.com/chiru-labs/ERC721A/pull/364).
    struct TokenApprovalRef {
        address value;
    }

    // =============================================================
    //                           CONSTANTS
    // =============================================================

    // Mask of an entry in packed address data.
    uint256 private constant _BITMASK_ADDRESS_DATA_ENTRY = (1 << 64) - 1;

    // The bit position of `numberMinted` in packed address data.
    uint256 private constant _BITPOS_NUMBER_MINTED = 64;

    // The bit position of `numberBurned` in packed address data.
    uint256 private constant _BITPOS_NUMBER_BURNED = 128;

    // The bit position of `aux` in packed address data.
    uint256 private constant _BITPOS_AUX = 192;

    // Mask of all 256 bits in packed address data except the 64 bits for `aux`.
    uint256 private constant _BITMASK_AUX_COMPLEMENT = (1 << 192) - 1;

    // The bit position of `startTimestamp` in packed ownership.
    uint256 private constant _BITPOS_START_TIMESTAMP = 160;

    // The bit mask of the `burned` bit in packed ownership.
    uint256 private constant _BITMASK_BURNED = 1 << 224;

    // The bit position of the `nextInitialized` bit in packed ownership.
    uint256 private constant _BITPOS_NEXT_INITIALIZED = 225;

    // The bit mask of the `nextInitialized` bit in packed ownership.
    uint256 private constant _BITMASK_NEXT_INITIALIZED = 1 << 225;

    // The bit position of `extraData` in packed ownership.
    uint256 private constant _BITPOS_EXTRA_DATA = 232;

    // Mask of all 256 bits in a packed ownership except the 24 bits for `extraData`.
    uint256 private constant _BITMASK_EXTRA_DATA_COMPLEMENT = (1 << 232) - 1;

    // The mask of the lower 160 bits for addresses.
    uint256 private constant _BITMASK_ADDRESS = (1 << 160) - 1;

    // The maximum `quantity` that can be minted with {_mintERC2309}.
    // This limit is to prevent overflows on the address data entries.
    // For a limit of 5000, a total of 3.689e15 calls to {_mintERC2309}
    // is required to cause an overflow, which is unrealistic.
    uint256 private constant _MAX_MINT_ERC2309_QUANTITY_LIMIT = 5000;

    // The `Transfer` event signature is given by:
    // `keccak256(bytes("Transfer(address,address,uint256)"))`.
    bytes32 private constant _TRANSFER_EVENT_SIGNATURE =
        0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef;

    // =============================================================
    //                            STORAGE
    // =============================================================

    // The next token ID to be minted.
    uint256 private _currentIndex;

    // The number of tokens burned.
    uint256 private _burnCounter;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to ownership details
    // An empty struct value does not necessarily mean the token is unowned.
    // See {_packedOwnershipOf} implementation for details.
    //
    // Bits Layout:
    // - [0..159]   `addr`
    // - [160..223] `startTimestamp`
    // - [224]      `burned`
    // - [225]      `nextInitialized`
    // - [232..255] `extraData`
    mapping(uint256 => uint256) private _packedOwnerships;

    // Mapping owner address to address data.
    //
    // Bits Layout:
    // - [0..63]    `balance`
    // - [64..127]  `numberMinted`
    // - [128..191] `numberBurned`
    // - [192..255] `aux`
    mapping(address => uint256) private _packedAddressData;

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

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

    // The amount of tokens minted above `_sequentialUpTo()`.
    // We call these spot mints (i.e. non-sequential mints).
    uint256 private _spotMinted;

    // =============================================================
    //                          CONSTRUCTOR
    // =============================================================

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

        if (_sequentialUpTo() < _startTokenId()) _revert(SequentialUpToTooSmall.selector);
    }

    // =============================================================
    //                   TOKEN COUNTING OPERATIONS
    // =============================================================

    /**
     * @dev Returns the starting token ID for sequential mints.
     *
     * Override this function to change the starting token ID for sequential mints.
     *
     * Note: The value returned must never change after any tokens have been minted.
     */
    function _startTokenId() internal view virtual returns (uint256) {
        return 0;
    }

    /**
     * @dev Returns the maximum token ID (inclusive) for sequential mints.
     *
     * Override this function to return a value less than 2**256 - 1,
     * but greater than `_startTokenId()`, to enable spot (non-sequential) mints.
     *
     * Note: The value returned must never change after any tokens have been minted.
     */
    function _sequentialUpTo() internal view virtual returns (uint256) {
        return type(uint256).max;
    }

    /**
     * @dev Returns the next token ID to be minted.
     */
    function _nextTokenId() internal view virtual returns (uint256) {
        return _currentIndex;
    }

    /**
     * @dev Returns the total number of tokens in existence.
     * Burned tokens will reduce the count.
     * To get the total number of tokens minted, please see {_totalMinted}.
     */
    function totalSupply() public view virtual override returns (uint256 result) {
        // Counter underflow is impossible as `_burnCounter` cannot be incremented
        // more than `_currentIndex + _spotMinted - _startTokenId()` times.
        unchecked {
            // With spot minting, the intermediate `result` can be temporarily negative,
            // and the computation must be unchecked.
            result = _currentIndex - _burnCounter - _startTokenId();
            if (_sequentialUpTo() != type(uint256).max) result += _spotMinted;
        }
    }

    /**
     * @dev Returns the total amount of tokens minted in the contract.
     */
    function _totalMinted() internal view virtual returns (uint256 result) {
        // Counter underflow is impossible as `_currentIndex` does not decrement,
        // and it is initialized to `_startTokenId()`.
        unchecked {
            result = _currentIndex - _startTokenId();
            if (_sequentialUpTo() != type(uint256).max) result += _spotMinted;
        }
    }

    /**
     * @dev Returns the total number of tokens burned.
     */
    function _totalBurned() internal view virtual returns (uint256) {
        return _burnCounter;
    }

    /**
     * @dev Returns the total number of tokens that are spot-minted.
     */
    function _totalSpotMinted() internal view virtual returns (uint256) {
        return _spotMinted;
    }

    // =============================================================
    //                    ADDRESS DATA OPERATIONS
    // =============================================================

    /**
     * @dev Returns the number of tokens in `owner`'s account.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        if (owner == address(0)) _revert(BalanceQueryForZeroAddress.selector);
        return _packedAddressData[owner] & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the number of tokens minted by `owner`.
     */
    function _numberMinted(address owner) internal view returns (uint256) {
        return (_packedAddressData[owner] >> _BITPOS_NUMBER_MINTED) & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the number of tokens burned by or on behalf of `owner`.
     */
    function _numberBurned(address owner) internal view returns (uint256) {
        return (_packedAddressData[owner] >> _BITPOS_NUMBER_BURNED) & _BITMASK_ADDRESS_DATA_ENTRY;
    }

    /**
     * Returns the auxiliary data for `owner`. (e.g. number of whitelist mint slots used).
     */
    function _getAux(address owner) internal view returns (uint64) {
        return uint64(_packedAddressData[owner] >> _BITPOS_AUX);
    }

    /**
     * Sets the auxiliary data for `owner`. (e.g. number of whitelist mint slots used).
     * If there are multiple variables, please pack them into a uint64.
     */
    function _setAux(address owner, uint64 aux) internal virtual {
        uint256 packed = _packedAddressData[owner];
        uint256 auxCasted;
        // Cast `aux` with assembly to avoid redundant masking.
        assembly {
            auxCasted := aux
        }
        packed = (packed & _BITMASK_AUX_COMPLEMENT) | (auxCasted << _BITPOS_AUX);
        _packedAddressData[owner] = packed;
    }

    // =============================================================
    //                            IERC165
    // =============================================================

    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified)
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30000 gas.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        // The interface IDs are constants representing the first 4 bytes
        // of the XOR of all function selectors in the interface.
        // See: [ERC165](https://eips.ethereum.org/EIPS/eip-165)
        // (e.g. `bytes4(i.functionA.selector ^ i.functionB.selector ^ ...)`)
        return
            interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165.
            interfaceId == 0x80ac58cd || // ERC165 interface ID for ERC721.
            interfaceId == 0x5b5e139f; // ERC165 interface ID for ERC721Metadata.
    }

    // =============================================================
    //                        IERC721Metadata
    // =============================================================

    /**
     * @dev Returns the token collection name.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        if (!_exists(tokenId)) _revert(URIQueryForNonexistentToken.selector);

        string memory baseURI = _baseURI();
        return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, _toString(tokenId))) : '';
    }

    /**
     * @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, it can be overridden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return '';
    }

    // =============================================================
    //                     OWNERSHIPS OPERATIONS
    // =============================================================

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        return address(uint160(_packedOwnershipOf(tokenId)));
    }

    /**
     * @dev Gas spent here starts off proportional to the maximum mint batch size.
     * It gradually moves to O(1) as tokens get transferred around over time.
     */
    function _ownershipOf(uint256 tokenId) internal view virtual returns (TokenOwnership memory) {
        return _unpackedOwnership(_packedOwnershipOf(tokenId));
    }

    /**
     * @dev Returns the unpacked `TokenOwnership` struct at `index`.
     */
    function _ownershipAt(uint256 index) internal view virtual returns (TokenOwnership memory) {
        return _unpackedOwnership(_packedOwnerships[index]);
    }

    /**
     * @dev Returns whether the ownership slot at `index` is initialized.
     * An uninitialized slot does not necessarily mean that the slot has no owner.
     */
    function _ownershipIsInitialized(uint256 index) internal view virtual returns (bool) {
        return _packedOwnerships[index] != 0;
    }

    /**
     * @dev Initializes the ownership slot minted at `index` for efficiency purposes.
     */
    function _initializeOwnershipAt(uint256 index) internal virtual {
        if (_packedOwnerships[index] == 0) {
            _packedOwnerships[index] = _packedOwnershipOf(index);
        }
    }

    /**
     * @dev Returns the packed ownership data of `tokenId`.
     */
    function _packedOwnershipOf(uint256 tokenId) private view returns (uint256 packed) {
        if (_startTokenId() <= tokenId) {
            packed = _packedOwnerships[tokenId];

            if (tokenId > _sequentialUpTo()) {
                if (_packedOwnershipExists(packed)) return packed;
                _revert(OwnerQueryForNonexistentToken.selector);
            }

            // If the data at the starting slot does not exist, start the scan.
            if (packed == 0) {
                if (tokenId >= _currentIndex) _revert(OwnerQueryForNonexistentToken.selector);
                // Invariant:
                // There will always be an initialized ownership slot
                // (i.e. `ownership.addr != address(0) && ownership.burned == false`)
                // before an unintialized ownership slot
                // (i.e. `ownership.addr == address(0) && ownership.burned == false`)
                // Hence, `tokenId` will not underflow.
                //
                // We can directly compare the packed value.
                // If the address is zero, packed will be zero.
                for (;;) {
                    unchecked {
                        packed = _packedOwnerships[--tokenId];
                    }
                    if (packed == 0) continue;
                    if (packed & _BITMASK_BURNED == 0) return packed;
                    // Otherwise, the token is burned, and we must revert.
                    // This handles the case of batch burned tokens, where only the burned bit
                    // of the starting slot is set, and remaining slots are left uninitialized.
                    _revert(OwnerQueryForNonexistentToken.selector);
                }
            }
            // Otherwise, the data exists and we can skip the scan.
            // This is possible because we have already achieved the target condition.
            // This saves 2143 gas on transfers of initialized tokens.
            // If the token is not burned, return `packed`. Otherwise, revert.
            if (packed & _BITMASK_BURNED == 0) return packed;
        }
        _revert(OwnerQueryForNonexistentToken.selector);
    }

    /**
     * @dev Returns the unpacked `TokenOwnership` struct from `packed`.
     */
    function _unpackedOwnership(uint256 packed) private pure returns (TokenOwnership memory ownership) {
        ownership.addr = address(uint160(packed));
        ownership.startTimestamp = uint64(packed >> _BITPOS_START_TIMESTAMP);
        ownership.burned = packed & _BITMASK_BURNED != 0;
        ownership.extraData = uint24(packed >> _BITPOS_EXTRA_DATA);
    }

    /**
     * @dev Packs ownership data into a single uint256.
     */
    function _packOwnershipData(address owner, uint256 flags) private view returns (uint256 result) {
        assembly {
            // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean.
            owner := and(owner, _BITMASK_ADDRESS)
            // `owner | (block.timestamp << _BITPOS_START_TIMESTAMP) | flags`.
            result := or(owner, or(shl(_BITPOS_START_TIMESTAMP, timestamp()), flags))
        }
    }

    /**
     * @dev Returns the `nextInitialized` flag set if `quantity` equals 1.
     */
    function _nextInitializedFlag(uint256 quantity) private pure returns (uint256 result) {
        // For branchless setting of the `nextInitialized` flag.
        assembly {
            // `(quantity == 1) << _BITPOS_NEXT_INITIALIZED`.
            result := shl(_BITPOS_NEXT_INITIALIZED, eq(quantity, 1))
        }
    }

    // =============================================================
    //                      APPROVAL OPERATIONS
    // =============================================================

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account. See {ERC721A-_approve}.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     */
    function approve(address to, uint256 tokenId) public payable virtual override {
        _approve(to, tokenId, true);
    }

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        if (!_exists(tokenId)) _revert(ApprovalQueryForNonexistentToken.selector);

        return _tokenApprovals[tokenId].value;
    }

    /**
     * @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) public virtual override {
        _operatorApprovals[_msgSenderERC721A()][operator] = approved;
        emit ApprovalForAll(_msgSenderERC721A(), operator, approved);
    }

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

    /**
     * @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. See {_mint}.
     */
    function _exists(uint256 tokenId) internal view virtual returns (bool result) {
        if (_startTokenId() <= tokenId) {
            if (tokenId > _sequentialUpTo()) return _packedOwnershipExists(_packedOwnerships[tokenId]);

            if (tokenId < _currentIndex) {
                uint256 packed;
                while ((packed = _packedOwnerships[tokenId]) == 0) --tokenId;
                result = packed & _BITMASK_BURNED == 0;
            }
        }
    }

    /**
     * @dev Returns whether `packed` represents a token that exists.
     */
    function _packedOwnershipExists(uint256 packed) private pure returns (bool result) {
        assembly {
            // The following is equivalent to `owner != address(0) && burned == false`.
            // Symbolically tested.
            result := gt(and(packed, _BITMASK_ADDRESS), and(packed, _BITMASK_BURNED))
        }
    }

    /**
     * @dev Returns whether `msgSender` is equal to `approvedAddress` or `owner`.
     */
    function _isSenderApprovedOrOwner(
        address approvedAddress,
        address owner,
        address msgSender
    ) private pure returns (bool result) {
        assembly {
            // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean.
            owner := and(owner, _BITMASK_ADDRESS)
            // Mask `msgSender` to the lower 160 bits, in case the upper bits somehow aren't clean.
            msgSender := and(msgSender, _BITMASK_ADDRESS)
            // `msgSender == owner || msgSender == approvedAddress`.
            result := or(eq(msgSender, owner), eq(msgSender, approvedAddress))
        }
    }

    /**
     * @dev Returns the storage slot and value for the approved address of `tokenId`.
     */
    function _getApprovedSlotAndAddress(uint256 tokenId)
        private
        view
        returns (uint256 approvedAddressSlot, address approvedAddress)
    {
        TokenApprovalRef storage tokenApproval = _tokenApprovals[tokenId];
        // The following is equivalent to `approvedAddress = _tokenApprovals[tokenId].value`.
        assembly {
            approvedAddressSlot := tokenApproval.slot
            approvedAddress := sload(approvedAddressSlot)
        }
    }

    // =============================================================
    //                      TRANSFER OPERATIONS
    // =============================================================

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *
     * 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
    ) public payable virtual override {
        uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId);

        // Mask `from` to the lower 160 bits, in case the upper bits somehow aren't clean.
        from = address(uint160(uint256(uint160(from)) & _BITMASK_ADDRESS));

        if (address(uint160(prevOwnershipPacked)) != from) _revert(TransferFromIncorrectOwner.selector);

        (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId);

        // The nested ifs save around 20+ gas over a compound boolean condition.
        if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A()))
            if (!isApprovedForAll(from, _msgSenderERC721A())) _revert(TransferCallerNotOwnerNorApproved.selector);

        _beforeTokenTransfers(from, to, tokenId, 1);

        // Clear approvals from the previous owner.
        assembly {
            if approvedAddress {
                // This is equivalent to `delete _tokenApprovals[tokenId]`.
                sstore(approvedAddressSlot, 0)
            }
        }

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256.
        unchecked {
            // We can directly increment and decrement the balances.
            --_packedAddressData[from]; // Updates: `balance -= 1`.
            ++_packedAddressData[to]; // Updates: `balance += 1`.

            // Updates:
            // - `address` to the next owner.
            // - `startTimestamp` to the timestamp of transfering.
            // - `burned` to `false`.
            // - `nextInitialized` to `true`.
            _packedOwnerships[tokenId] = _packOwnershipData(
                to,
                _BITMASK_NEXT_INITIALIZED | _nextExtraData(from, to, prevOwnershipPacked)
            );

            // If the next slot may not have been initialized (i.e. `nextInitialized == false`) .
            if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) {
                uint256 nextTokenId = tokenId + 1;
                // If the next slot's address is zero and not burned (i.e. packed value is zero).
                if (_packedOwnerships[nextTokenId] == 0) {
                    // If the next slot is within bounds.
                    if (nextTokenId != _currentIndex) {
                        // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`.
                        _packedOwnerships[nextTokenId] = prevOwnershipPacked;
                    }
                }
            }
        }

        // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean.
        uint256 toMasked = uint256(uint160(to)) & _BITMASK_ADDRESS;
        assembly {
            // Emit the `Transfer` event.
            log4(
                0, // Start of data (0, since no data).
                0, // End of data (0, since no data).
                _TRANSFER_EVENT_SIGNATURE, // Signature.
                from, // `from`.
                toMasked, // `to`.
                tokenId // `tokenId`.
            )
        }
        if (toMasked == 0) _revert(TransferToZeroAddress.selector);

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

    /**
     * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public payable virtual override {
        safeTransferFrom(from, to, tokenId, '');
    }

    /**
     * @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 memory _data
    ) public payable virtual override {
        transferFrom(from, to, tokenId);
        if (to.code.length != 0)
            if (!_checkContractOnERC721Received(from, to, tokenId, _data)) {
                _revert(TransferToNonERC721ReceiverImplementer.selector);
            }
    }

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

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

    /**
     * @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target contract.
     *
     * `from` - Previous owner of the given token ID.
     * `to` - Target address that will receive the token.
     * `tokenId` - Token ID to be transferred.
     * `_data` - Optional data to send along with the call.
     *
     * Returns whether the call correctly returned the expected magic value.
     */
    function _checkContractOnERC721Received(
        address from,
        address to,
        uint256 tokenId,
        bytes memory _data
    ) private returns (bool) {
        try ERC721A__IERC721Receiver(to).onERC721Received(_msgSenderERC721A(), from, tokenId, _data) returns (
            bytes4 retval
        ) {
            return retval == ERC721A__IERC721Receiver(to).onERC721Received.selector;
        } catch (bytes memory reason) {
            if (reason.length == 0) {
                _revert(TransferToNonERC721ReceiverImplementer.selector);
            }
            assembly {
                revert(add(32, reason), mload(reason))
            }
        }
    }

    // =============================================================
    //                        MINT OPERATIONS
    // =============================================================

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {Transfer} event for each mint.
     */
    function _mint(address to, uint256 quantity) internal virtual {
        uint256 startTokenId = _currentIndex;
        if (quantity == 0) _revert(MintZeroQuantity.selector);

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

        // Overflows are incredibly unrealistic.
        // `balance` and `numberMinted` have a maximum limit of 2**64.
        // `tokenId` has a maximum limit of 2**256.
        unchecked {
            // Updates:
            // - `address` to the owner.
            // - `startTimestamp` to the timestamp of minting.
            // - `burned` to `false`.
            // - `nextInitialized` to `quantity == 1`.
            _packedOwnerships[startTokenId] = _packOwnershipData(
                to,
                _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0)
            );

            // Updates:
            // - `balance += quantity`.
            // - `numberMinted += quantity`.
            //
            // We can directly add to the `balance` and `numberMinted`.
            _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1);

            // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean.
            uint256 toMasked = uint256(uint160(to)) & _BITMASK_ADDRESS;

            if (toMasked == 0) _revert(MintToZeroAddress.selector);

            uint256 end = startTokenId + quantity;
            uint256 tokenId = startTokenId;

            if (end - 1 > _sequentialUpTo()) _revert(SequentialMintExceedsLimit.selector);

            do {
                assembly {
                    // Emit the `Transfer` event.
                    log4(
                        0, // Start of data (0, since no data).
                        0, // End of data (0, since no data).
                        _TRANSFER_EVENT_SIGNATURE, // Signature.
                        0, // `address(0)`.
                        toMasked, // `to`.
                        tokenId // `tokenId`.
                    )
                }
                // The `!=` check ensures that large values of `quantity`
                // that overflows uint256 will make the loop run out of gas.
            } while (++tokenId != end);

            _currentIndex = end;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

    /**
     * @dev Mints `quantity` tokens and transfers them to `to`.
     *
     * This function is intended for efficient minting only during contract creation.
     *
     * It emits only one {ConsecutiveTransfer} as defined in
     * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309),
     * instead of a sequence of {Transfer} event(s).
     *
     * Calling this function outside of contract creation WILL make your contract
     * non-compliant with the ERC721 standard.
     * For full ERC721 compliance, substituting ERC721 {Transfer} event(s) with the ERC2309
     * {ConsecutiveTransfer} event is only permissible during contract creation.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `quantity` must be greater than 0.
     *
     * Emits a {ConsecutiveTransfer} event.
     */
    function _mintERC2309(address to, uint256 quantity) internal virtual {
        uint256 startTokenId = _currentIndex;
        if (to == address(0)) _revert(MintToZeroAddress.selector);
        if (quantity == 0) _revert(MintZeroQuantity.selector);
        if (quantity > _MAX_MINT_ERC2309_QUANTITY_LIMIT) _revert(MintERC2309QuantityExceedsLimit.selector);

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

        // Overflows are unrealistic due to the above check for `quantity` to be below the limit.
        unchecked {
            // Updates:
            // - `balance += quantity`.
            // - `numberMinted += quantity`.
            //
            // We can directly add to the `balance` and `numberMinted`.
            _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1);

            // Updates:
            // - `address` to the owner.
            // - `startTimestamp` to the timestamp of minting.
            // - `burned` to `false`.
            // - `nextInitialized` to `quantity == 1`.
            _packedOwnerships[startTokenId] = _packOwnershipData(
                to,
                _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0)
            );

            if (startTokenId + quantity - 1 > _sequentialUpTo()) _revert(SequentialMintExceedsLimit.selector);

            emit ConsecutiveTransfer(startTokenId, startTokenId + quantity - 1, address(0), to);

            _currentIndex = startTokenId + quantity;
        }
        _afterTokenTransfers(address(0), to, startTokenId, quantity);
    }

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

        unchecked {
            if (to.code.length != 0) {
                uint256 end = _currentIndex;
                uint256 index = end - quantity;
                do {
                    if (!_checkContractOnERC721Received(address(0), to, index++, _data)) {
                        _revert(TransferToNonERC721ReceiverImplementer.selector);
                    }
                } while (index < end);
                // This prevents reentrancy to `_safeMint`.
                // It does not prevent reentrancy to `_safeMintSpot`.
                if (_currentIndex != end) revert();
            }
        }
    }

    /**
     * @dev Equivalent to `_safeMint(to, quantity, '')`.
     */
    function _safeMint(address to, uint256 quantity) internal virtual {
        _safeMint(to, quantity, '');
    }

    /**
     * @dev Mints a single token at `tokenId`.
     *
     * Note: A spot-minted `tokenId` that has been burned can be re-minted again.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` must be greater than `_sequentialUpTo()`.
     * - `tokenId` must not exist.
     *
     * Emits a {Transfer} event for each mint.
     */
    function _mintSpot(address to, uint256 tokenId) internal virtual {
        if (tokenId <= _sequentialUpTo()) _revert(SpotMintTokenIdTooSmall.selector);
        uint256 prevOwnershipPacked = _packedOwnerships[tokenId];
        if (_packedOwnershipExists(prevOwnershipPacked)) _revert(TokenAlreadyExists.selector);

        _beforeTokenTransfers(address(0), to, tokenId, 1);

        // Overflows are incredibly unrealistic.
        // The `numberMinted` for `to` is incremented by 1, and has a max limit of 2**64 - 1.
        // `_spotMinted` is incremented by 1, and has a max limit of 2**256 - 1.
        unchecked {
            // Updates:
            // - `address` to the owner.
            // - `startTimestamp` to the timestamp of minting.
            // - `burned` to `false`.
            // - `nextInitialized` to `true` (as `quantity == 1`).
            _packedOwnerships[tokenId] = _packOwnershipData(
                to,
                _nextInitializedFlag(1) | _nextExtraData(address(0), to, prevOwnershipPacked)
            );

            // Updates:
            // - `balance += 1`.
            // - `numberMinted += 1`.
            //
            // We can directly add to the `balance` and `numberMinted`.
            _packedAddressData[to] += (1 << _BITPOS_NUMBER_MINTED) | 1;

            // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean.
            uint256 toMasked = uint256(uint160(to)) & _BITMASK_ADDRESS;

            if (toMasked == 0) _revert(MintToZeroAddress.selector);

            assembly {
                // Emit the `Transfer` event.
                log4(
                    0, // Start of data (0, since no data).
                    0, // End of data (0, since no data).
                    _TRANSFER_EVENT_SIGNATURE, // Signature.
                    0, // `address(0)`.
                    toMasked, // `to`.
                    tokenId // `tokenId`.
                )
            }

            ++_spotMinted;
        }

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

    /**
     * @dev Safely mints a single token at `tokenId`.
     *
     * Note: A spot-minted `tokenId` that has been burned can be re-minted again.
     *
     * Requirements:
     *
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}.
     * - `tokenId` must be greater than `_sequentialUpTo()`.
     * - `tokenId` must not exist.
     *
     * See {_mintSpot}.
     *
     * Emits a {Transfer} event.
     */
    function _safeMintSpot(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _mintSpot(to, tokenId);

        unchecked {
            if (to.code.length != 0) {
                uint256 currentSpotMinted = _spotMinted;
                if (!_checkContractOnERC721Received(address(0), to, tokenId, _data)) {
                    _revert(TransferToNonERC721ReceiverImplementer.selector);
                }
                // This prevents reentrancy to `_safeMintSpot`.
                // It does not prevent reentrancy to `_safeMint`.
                if (_spotMinted != currentSpotMinted) revert();
            }
        }
    }

    /**
     * @dev Equivalent to `_safeMintSpot(to, tokenId, '')`.
     */
    function _safeMintSpot(address to, uint256 tokenId) internal virtual {
        _safeMintSpot(to, tokenId, '');
    }

    // =============================================================
    //                       APPROVAL OPERATIONS
    // =============================================================

    /**
     * @dev Equivalent to `_approve(to, tokenId, false)`.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _approve(to, tokenId, false);
    }

    /**
     * @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:
     *
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function _approve(
        address to,
        uint256 tokenId,
        bool approvalCheck
    ) internal virtual {
        address owner = ownerOf(tokenId);

        if (approvalCheck && _msgSenderERC721A() != owner)
            if (!isApprovedForAll(owner, _msgSenderERC721A())) {
                _revert(ApprovalCallerNotOwnerNorApproved.selector);
            }

        _tokenApprovals[tokenId].value = to;
        emit Approval(owner, to, tokenId);
    }

    // =============================================================
    //                        BURN OPERATIONS
    // =============================================================

    /**
     * @dev Equivalent to `_burn(tokenId, false)`.
     */
    function _burn(uint256 tokenId) internal virtual {
        _burn(tokenId, false);
    }

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

        address from = address(uint160(prevOwnershipPacked));

        (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId);

        if (approvalCheck) {
            // The nested ifs save around 20+ gas over a compound boolean condition.
            if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A()))
                if (!isApprovedForAll(from, _msgSenderERC721A())) _revert(TransferCallerNotOwnerNorApproved.selector);
        }

        _beforeTokenTransfers(from, address(0), tokenId, 1);

        // Clear approvals from the previous owner.
        assembly {
            if approvedAddress {
                // This is equivalent to `delete _tokenApprovals[tokenId]`.
                sstore(approvedAddressSlot, 0)
            }
        }

        // Underflow of the sender's balance is impossible because we check for
        // ownership above and the recipient's balance can't realistically overflow.
        // Counter overflow is incredibly unrealistic as `tokenId` would have to be 2**256.
        unchecked {
            // Updates:
            // - `balance -= 1`.
            // - `numberBurned += 1`.
            //
            // We can directly decrement the balance, and increment the number burned.
            // This is equivalent to `packed -= 1; packed += 1 << _BITPOS_NUMBER_BURNED;`.
            _packedAddressData[from] += (1 << _BITPOS_NUMBER_BURNED) - 1;

            // Updates:
            // - `address` to the last owner.
            // - `startTimestamp` to the timestamp of burning.
            // - `burned` to `true`.
            // - `nextInitialized` to `true`.
            _packedOwnerships[tokenId] = _packOwnershipData(
                from,
                (_BITMASK_BURNED | _BITMASK_NEXT_INITIALIZED) | _nextExtraData(from, address(0), prevOwnershipPacked)
            );

            // If the next slot may not have been initialized (i.e. `nextInitialized == false`) .
            if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) {
                uint256 nextTokenId = tokenId + 1;
                // If the next slot's address is zero and not burned (i.e. packed value is zero).
                if (_packedOwnerships[nextTokenId] == 0) {
                    // If the next slot is within bounds.
                    if (nextTokenId != _currentIndex) {
                        // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`.
                        _packedOwnerships[nextTokenId] = prevOwnershipPacked;
                    }
                }
            }
        }

        emit Transfer(from, address(0), tokenId);
        _afterTokenTransfers(from, address(0), tokenId, 1);

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

    // =============================================================
    //                     EXTRA DATA OPERATIONS
    // =============================================================

    /**
     * @dev Directly sets the extra data for the ownership data `index`.
     */
    function _setExtraDataAt(uint256 index, uint24 extraData) internal virtual {
        uint256 packed = _packedOwnerships[index];
        if (packed == 0) _revert(OwnershipNotInitializedForExtraData.selector);
        uint256 extraDataCasted;
        // Cast `extraData` with assembly to avoid redundant masking.
        assembly {
            extraDataCasted := extraData
        }
        packed = (packed & _BITMASK_EXTRA_DATA_COMPLEMENT) | (extraDataCasted << _BITPOS_EXTRA_DATA);
        _packedOwnerships[index] = packed;
    }

    /**
     * @dev Called during each token transfer to set the 24bit `extraData` field.
     * Intended to be overridden by the cosumer contract.
     *
     * `previousExtraData` - the value of `extraData` before transfer.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, `from`'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, `tokenId` will be burned by `from`.
     * - `from` and `to` are never both zero.
     */
    function _extraData(
        address from,
        address to,
        uint24 previousExtraData
    ) internal view virtual returns (uint24) {}

    /**
     * @dev Returns the next extra data for the packed ownership data.
     * The returned result is shifted into position.
     */
    function _nextExtraData(
        address from,
        address to,
        uint256 prevOwnershipPacked
    ) private view returns (uint256) {
        uint24 extraData = uint24(prevOwnershipPacked >> _BITPOS_EXTRA_DATA);
        return uint256(_extraData(from, to, extraData)) << _BITPOS_EXTRA_DATA;
    }

    // =============================================================
    //                       OTHER OPERATIONS
    // =============================================================

    /**
     * @dev Returns the message sender (defaults to `msg.sender`).
     *
     * If you are writing GSN compatible contracts, you need to override this function.
     */
    function _msgSenderERC721A() internal view virtual returns (address) {
        return msg.sender;
    }

    /**
     * @dev Converts a uint256 to its ASCII string decimal representation.
     */
    function _toString(uint256 value) internal pure virtual returns (string memory str) {
        assembly {
            // The maximum value of a uint256 contains 78 digits (1 byte per digit), but
            // we allocate 0xa0 bytes to keep the free memory pointer 32-byte word aligned.
            // We will need 1 word for the trailing zeros padding, 1 word for the length,
            // and 3 words for a maximum of 78 digits. Total: 5 * 0x20 = 0xa0.
            let m := add(mload(0x40), 0xa0)
            // Update the free memory pointer to allocate.
            mstore(0x40, m)
            // Assign the `str` to the end.
            str := sub(m, 0x20)
            // Zeroize the slot after the string.
            mstore(str, 0)

            // Cache the end of the memory to calculate the length later.
            let end := str

            // We write the string from rightmost digit to leftmost digit.
            // The following is essentially a do-while loop that also handles the zero case.
            // prettier-ignore
            for { let temp := value } 1 {} {
                str := sub(str, 1)
                // Write the character to the pointer.
                // The ASCII index of the '0' character is 48.
                mstore8(str, add(48, mod(temp, 10)))
                // Keep dividing `temp` until zero.
                temp := div(temp, 10)
                // prettier-ignore
                if iszero(temp) { break }
            }

            let length := sub(end, str)
            // Move the pointer 32 bytes leftwards to make room for the length.
            str := sub(str, 0x20)
            // Store the length.
            mstore(str, length)
        }
    }

    /**
     * @dev For more efficient reverts.
     */
    function _revert(bytes4 errorSelector) internal pure {
        assembly {
            mstore(0x00, errorSelector)
            revert(0x00, 0x04)
        }
    }
}

File 13 of 17 : ERC721ABurnable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import './IERC721ABurnable.sol';
import '../ERC721A.sol';

/**
 * @title ERC721ABurnable.
 *
 * @dev ERC721A token that can be irreversibly burned (destroyed).
 */
abstract contract ERC721ABurnable is ERC721A, IERC721ABurnable {
    /**
     * @dev Burns `tokenId`. See {ERC721A-_burn}.
     *
     * Requirements:
     *
     * - The caller must own `tokenId` or be an approved operator.
     */
    function burn(uint256 tokenId) public virtual override {
        _burn(tokenId, true);
    }
}

File 14 of 17 : ERC721AQueryable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import './IERC721AQueryable.sol';
import '../ERC721A.sol';

/**
 * @title ERC721AQueryable.
 *
 * @dev ERC721A subclass with convenience query functions.
 */
abstract contract ERC721AQueryable is ERC721A, IERC721AQueryable {
    /**
     * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting.
     *
     * If the `tokenId` is out of bounds:
     *
     * - `addr = address(0)`
     * - `startTimestamp = 0`
     * - `burned = false`
     * - `extraData = 0`
     *
     * If the `tokenId` is burned:
     *
     * - `addr = <Address of owner before token was burned>`
     * - `startTimestamp = <Timestamp when token was burned>`
     * - `burned = true`
     * - `extraData = <Extra data when token was burned>`
     *
     * Otherwise:
     *
     * - `addr = <Address of owner>`
     * - `startTimestamp = <Timestamp of start of ownership>`
     * - `burned = false`
     * - `extraData = <Extra data at start of ownership>`
     */
    function explicitOwnershipOf(uint256 tokenId)
        public
        view
        virtual
        override
        returns (TokenOwnership memory ownership)
    {
        unchecked {
            if (tokenId >= _startTokenId()) {
                if (tokenId > _sequentialUpTo()) return _ownershipAt(tokenId);

                if (tokenId < _nextTokenId()) {
                    // If the `tokenId` is within bounds,
                    // scan backwards for the initialized ownership slot.
                    while (!_ownershipIsInitialized(tokenId)) --tokenId;
                    return _ownershipAt(tokenId);
                }
            }
        }
    }

    /**
     * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order.
     * See {ERC721AQueryable-explicitOwnershipOf}
     */
    function explicitOwnershipsOf(uint256[] calldata tokenIds)
        external
        view
        virtual
        override
        returns (TokenOwnership[] memory)
    {
        TokenOwnership[] memory ownerships;
        uint256 i = tokenIds.length;
        assembly {
            // Grab the free memory pointer.
            ownerships := mload(0x40)
            // Store the length.
            mstore(ownerships, i)
            // Allocate one word for the length,
            // `tokenIds.length` words for the pointers.
            i := shl(5, i) // Multiply `i` by 32.
            mstore(0x40, add(add(ownerships, 0x20), i))
        }
        while (i != 0) {
            uint256 tokenId;
            assembly {
                i := sub(i, 0x20)
                tokenId := calldataload(add(tokenIds.offset, i))
            }
            TokenOwnership memory ownership = explicitOwnershipOf(tokenId);
            assembly {
                // Store the pointer of `ownership` in the `ownerships` array.
                mstore(add(add(ownerships, 0x20), i), ownership)
            }
        }
        return ownerships;
    }

    /**
     * @dev Returns an array of token IDs owned by `owner`,
     * in the range [`start`, `stop`)
     * (i.e. `start <= tokenId < stop`).
     *
     * This function allows for tokens to be queried if the collection
     * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}.
     *
     * Requirements:
     *
     * - `start < stop`
     */
    function tokensOfOwnerIn(
        address owner,
        uint256 start,
        uint256 stop
    ) external view virtual override returns (uint256[] memory) {
        return _tokensOfOwnerIn(owner, start, stop);
    }

    /**
     * @dev Returns an array of token IDs owned by `owner`.
     *
     * This function scans the ownership mapping and is O(`totalSupply`) in complexity.
     * It is meant to be called off-chain.
     *
     * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into
     * multiple smaller scans if the collection is large enough to cause
     * an out-of-gas error (10K collections should be fine).
     */
    function tokensOfOwner(address owner) external view virtual override returns (uint256[] memory) {
        // If spot mints are enabled, full-range scan is disabled.
        if (_sequentialUpTo() != type(uint256).max) _revert(NotCompatibleWithSpotMints.selector);
        uint256 start = _startTokenId();
        uint256 stop = _nextTokenId();
        uint256[] memory tokenIds;
        if (start != stop) tokenIds = _tokensOfOwnerIn(owner, start, stop);
        return tokenIds;
    }

    /**
     * @dev Helper function for returning an array of token IDs owned by `owner`.
     *
     * Note that this function is optimized for smaller bytecode size over runtime gas,
     * since it is meant to be called off-chain.
     */
    function _tokensOfOwnerIn(
        address owner,
        uint256 start,
        uint256 stop
    ) private view returns (uint256[] memory tokenIds) {
        unchecked {
            if (start >= stop) _revert(InvalidQueryRange.selector);
            // Set `start = max(start, _startTokenId())`.
            if (start < _startTokenId()) start = _startTokenId();
            uint256 nextTokenId = _nextTokenId();
            // If spot mints are enabled, scan all the way until the specified `stop`.
            uint256 stopLimit = _sequentialUpTo() != type(uint256).max ? stop : nextTokenId;
            // Set `stop = min(stop, stopLimit)`.
            if (stop >= stopLimit) stop = stopLimit;
            // Number of tokens to scan.
            uint256 tokenIdsMaxLength = balanceOf(owner);
            // Set `tokenIdsMaxLength` to zero if the range contains no tokens.
            if (start >= stop) tokenIdsMaxLength = 0;
            // If there are one or more tokens to scan.
            if (tokenIdsMaxLength != 0) {
                // Set `tokenIdsMaxLength = min(balanceOf(owner), tokenIdsMaxLength)`.
                if (stop - start <= tokenIdsMaxLength) tokenIdsMaxLength = stop - start;
                uint256 m; // Start of available memory.
                assembly {
                    // Grab the free memory pointer.
                    tokenIds := mload(0x40)
                    // Allocate one word for the length, and `tokenIdsMaxLength` words
                    // for the data. `shl(5, x)` is equivalent to `mul(32, x)`.
                    m := add(tokenIds, shl(5, add(tokenIdsMaxLength, 1)))
                    mstore(0x40, m)
                }
                // We need to call `explicitOwnershipOf(start)`,
                // because the slot at `start` may not be initialized.
                TokenOwnership memory ownership = explicitOwnershipOf(start);
                address currOwnershipAddr;
                // If the starting slot exists (i.e. not burned),
                // initialize `currOwnershipAddr`.
                // `ownership.address` will not be zero,
                // as `start` is clamped to the valid token ID range.
                if (!ownership.burned) currOwnershipAddr = ownership.addr;
                uint256 tokenIdsIdx;
                // Use a do-while, which is slightly more efficient for this case,
                // as the array will at least contain one element.
                do {
                    if (_sequentialUpTo() != type(uint256).max) {
                        // Skip the remaining unused sequential slots.
                        if (start == nextTokenId) start = _sequentialUpTo() + 1;
                        // Reset `currOwnershipAddr`, as each spot-minted token is a batch of one.
                        if (start > _sequentialUpTo()) currOwnershipAddr = address(0);
                    }
                    ownership = _ownershipAt(start); // This implicitly allocates memory.
                    assembly {
                        switch mload(add(ownership, 0x40))
                        // if `ownership.burned == false`.
                        case 0 {
                            // if `ownership.addr != address(0)`.
                            // The `addr` already has it's upper 96 bits clearned,
                            // since it is written to memory with regular Solidity.
                            if mload(ownership) {
                                currOwnershipAddr := mload(ownership)
                            }
                            // if `currOwnershipAddr == owner`.
                            // The `shl(96, x)` is to make the comparison agnostic to any
                            // dirty upper 96 bits in `owner`.
                            if iszero(shl(96, xor(currOwnershipAddr, owner))) {
                                tokenIdsIdx := add(tokenIdsIdx, 1)
                                mstore(add(tokenIds, shl(5, tokenIdsIdx)), start)
                            }
                        }
                        // Otherwise, reset `currOwnershipAddr`.
                        // This handles the case of batch burned tokens
                        // (burned bit of first slot set, remaining slots left uninitialized).
                        default {
                            currOwnershipAddr := 0
                        }
                        start := add(start, 1)
                        // Free temporary memory implicitly allocated for ownership
                        // to avoid quadratic memory expansion costs.
                        mstore(0x40, m)
                    }
                } while (!(start == stop || tokenIdsIdx == tokenIdsMaxLength));
                // Store the length of the array.
                assembly {
                    mstore(tokenIds, tokenIdsIdx)
                }
            }
        }
    }
}

File 15 of 17 : IERC721ABurnable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import '../IERC721A.sol';

/**
 * @dev Interface of ERC721ABurnable.
 */
interface IERC721ABurnable is IERC721A {
    /**
     * @dev Burns `tokenId`. See {ERC721A-_burn}.
     *
     * Requirements:
     *
     * - The caller must own `tokenId` or be an approved operator.
     */
    function burn(uint256 tokenId) external;
}

File 16 of 17 : IERC721AQueryable.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

import '../IERC721A.sol';

/**
 * @dev Interface of ERC721AQueryable.
 */
interface IERC721AQueryable is IERC721A {
    /**
     * Invalid query range (`start` >= `stop`).
     */
    error InvalidQueryRange();

    /**
     * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting.
     *
     * If the `tokenId` is out of bounds:
     *
     * - `addr = address(0)`
     * - `startTimestamp = 0`
     * - `burned = false`
     * - `extraData = 0`
     *
     * If the `tokenId` is burned:
     *
     * - `addr = <Address of owner before token was burned>`
     * - `startTimestamp = <Timestamp when token was burned>`
     * - `burned = true`
     * - `extraData = <Extra data when token was burned>`
     *
     * Otherwise:
     *
     * - `addr = <Address of owner>`
     * - `startTimestamp = <Timestamp of start of ownership>`
     * - `burned = false`
     * - `extraData = <Extra data at start of ownership>`
     */
    function explicitOwnershipOf(uint256 tokenId) external view returns (TokenOwnership memory);

    /**
     * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order.
     * See {ERC721AQueryable-explicitOwnershipOf}
     */
    function explicitOwnershipsOf(uint256[] memory tokenIds) external view returns (TokenOwnership[] memory);

    /**
     * @dev Returns an array of token IDs owned by `owner`,
     * in the range [`start`, `stop`)
     * (i.e. `start <= tokenId < stop`).
     *
     * This function allows for tokens to be queried if the collection
     * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}.
     *
     * Requirements:
     *
     * - `start < stop`
     */
    function tokensOfOwnerIn(
        address owner,
        uint256 start,
        uint256 stop
    ) external view returns (uint256[] memory);

    /**
     * @dev Returns an array of token IDs owned by `owner`.
     *
     * This function scans the ownership mapping and is O(`totalSupply`) in complexity.
     * It is meant to be called off-chain.
     *
     * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into
     * multiple smaller scans if the collection is large enough to cause
     * an out-of-gas error (10K collections should be fine).
     */
    function tokensOfOwner(address owner) external view returns (uint256[] memory);
}

File 17 of 17 : IERC721A.sol
// SPDX-License-Identifier: MIT
// ERC721A Contracts v4.3.0
// Creator: Chiru Labs

pragma solidity ^0.8.4;

/**
 * @dev Interface of ERC721A.
 */
interface IERC721A {
    /**
     * The caller must own the token or be an approved operator.
     */
    error ApprovalCallerNotOwnerNorApproved();

    /**
     * The token does not exist.
     */
    error ApprovalQueryForNonexistentToken();

    /**
     * Cannot query the balance for the zero address.
     */
    error BalanceQueryForZeroAddress();

    /**
     * Cannot mint to the zero address.
     */
    error MintToZeroAddress();

    /**
     * The quantity of tokens minted must be more than zero.
     */
    error MintZeroQuantity();

    /**
     * The token does not exist.
     */
    error OwnerQueryForNonexistentToken();

    /**
     * The caller must own the token or be an approved operator.
     */
    error TransferCallerNotOwnerNorApproved();

    /**
     * The token must be owned by `from`.
     */
    error TransferFromIncorrectOwner();

    /**
     * Cannot safely transfer to a contract that does not implement the
     * ERC721Receiver interface.
     */
    error TransferToNonERC721ReceiverImplementer();

    /**
     * Cannot transfer to the zero address.
     */
    error TransferToZeroAddress();

    /**
     * The token does not exist.
     */
    error URIQueryForNonexistentToken();

    /**
     * The `quantity` minted with ERC2309 exceeds the safety limit.
     */
    error MintERC2309QuantityExceedsLimit();

    /**
     * The `extraData` cannot be set on an unintialized ownership slot.
     */
    error OwnershipNotInitializedForExtraData();

    /**
     * `_sequentialUpTo()` must be greater than `_startTokenId()`.
     */
    error SequentialUpToTooSmall();

    /**
     * The `tokenId` of a sequential mint exceeds `_sequentialUpTo()`.
     */
    error SequentialMintExceedsLimit();

    /**
     * Spot minting requires a `tokenId` greater than `_sequentialUpTo()`.
     */
    error SpotMintTokenIdTooSmall();

    /**
     * Cannot mint over a token that already exists.
     */
    error TokenAlreadyExists();

    /**
     * The feature is not compatible with spot mints.
     */
    error NotCompatibleWithSpotMints();

    // =============================================================
    //                            STRUCTS
    // =============================================================

    struct TokenOwnership {
        // The address of the owner.
        address addr;
        // Stores the start time of ownership with minimal overhead for tokenomics.
        uint64 startTimestamp;
        // Whether the token has been burned.
        bool burned;
        // Arbitrary data similar to `startTimestamp` that can be set via {_extraData}.
        uint24 extraData;
    }

    // =============================================================
    //                         TOKEN COUNTERS
    // =============================================================

    /**
     * @dev Returns the total number of tokens in existence.
     * Burned tokens will reduce the count.
     * To get the total number of tokens minted, please see {_totalMinted}.
     */
    function totalSupply() external view returns (uint256);

    // =============================================================
    //                            IERC165
    // =============================================================

    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified)
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);

    // =============================================================
    //                            IERC721
    // =============================================================

    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

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

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

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

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

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

    /**
     * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external payable;

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

    /**
     * @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 payable;

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

    // =============================================================
    //                        IERC721Metadata
    // =============================================================

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

    // =============================================================
    //                           IERC2309
    // =============================================================

    /**
     * @dev Emitted when tokens in `fromTokenId` to `toTokenId`
     * (inclusive) is transferred from `from` to `to`, as defined in the
     * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309) standard.
     *
     * See {_mintERC2309} for more details.
     */
    event ConsecutiveTransfer(uint256 indexed fromTokenId, uint256 toTokenId, address indexed from, address indexed to);
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"uint256","name":"collectionSize_","type":"uint256"},{"internalType":"uint256","name":"maxPerWalletUBAllowlist_","type":"uint256"},{"internalType":"uint256","name":"maxPerWalletAllowlist_","type":"uint256"},{"internalType":"uint256","name":"maxPerWallet_","type":"uint256"},{"internalType":"uint256","name":"allowlistUBMintPrice_","type":"uint256"},{"internalType":"uint256","name":"allowlistMintPrice_","type":"uint256"},{"internalType":"uint256","name":"publicMintPrice_","type":"uint256"},{"internalType":"address","name":"devAddress_","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidDefaultRoyalty","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidDefaultRoyaltyReceiver","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"numerator","type":"uint256"},{"internalType":"uint256","name":"denominator","type":"uint256"}],"name":"ERC2981InvalidTokenRoyalty","type":"error"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC2981InvalidTokenRoyaltyReceiver","type":"error"},{"inputs":[],"name":"InvalidQueryRange","type":"error"},{"inputs":[],"name":"MintERC2309QuantityExceedsLimit","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"NotCompatibleWithSpotMints","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"OwnershipNotInitializedForExtraData","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[],"name":"SequentialMintExceedsLimit","type":"error"},{"inputs":[],"name":"SequentialUpToTooSmall","type":"error"},{"inputs":[],"name":"SpotMintTokenIdTooSmall","type":"error"},{"inputs":[],"name":"TokenAlreadyExists","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"fromTokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"toTokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"ConsecutiveTransfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"UBAllowlistMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"allowlistMint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"explicitOwnershipOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership","name":"ownership","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"explicitOwnershipsOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllowlistMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllowlistMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAllowlistUBMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCollectionSize","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getDevAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getIsAllowlistMintActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getIsMintActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getIsUBAllowlistMintActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMaxPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMaxPerWalletAllowlist","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMaxPerWalletUBAllowlist","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNumAllowlistMint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNumUBAllowlistMint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"getOwnerAllowlistMintCount","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"getOwnerAllowlistUBMintCount","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"getOwnerGiftsCount","outputs":[{"internalType":"uint16","name":"","type":"uint16"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPublicMintPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getUBAllowlistMerkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses","type":"address[]"}],"name":"gift","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"addresses","type":"address[]"},{"internalType":"uint256[]","name":"quantities","type":"uint256[]"}],"name":"giftMultiple","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"numberMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"salePrice","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":"payable","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":"payable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRootAllowlist","type":"bytes32"}],"name":"setAllowlistMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isAllowlistMintActive","type":"bool"}],"name":"setAllowlistMintActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_allowlistMintPrice","type":"uint256"}],"name":"setAllowlistMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"baseURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_collectionSize","type":"uint256"}],"name":"setCollectionSize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"feeNumerator","type":"uint96"}],"name":"setDefaultRoyalty","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_devAddress","type":"address"}],"name":"setDevAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxPerWallet","type":"uint256"}],"name":"setMaxPerWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxPerWalletAllowlist","type":"uint256"}],"name":"setMaxPerWalletAllowlist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_maxPerWalletUBAllowlist","type":"uint256"}],"name":"setMaxPerWalletUBAllowlist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isMintActive","type":"bool"}],"name":"setMintActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_publicMintPrice","type":"uint256"}],"name":"setPublicMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRootUBAllowlist","type":"bytes32"}],"name":"setUBAllowlistMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_isUBAllowlistMintActive","type":"bool"}],"name":"setUBAllowlistMintActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_allowlistUBMintPrice","type":"uint256"}],"name":"setUBAllowlistMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"tokensOfOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"stop","type":"uint256"}],"name":"tokensOfOwnerIn","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"result","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526011805462ffffff191690553480156200001d57600080fd5b5060405162003b4938038062003b49833981016040819052620000409162000253565b336040518060400160405280600f81526020016e4c6974746c65204461726c696e677360881b81525060405180604001604052806002815260200161131160f21b815250816002908162000095919062000371565b506003620000a4828262000371565b5050600080555060016009556001600160a01b038116620000e057604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b620000eb816200015a565b506012889055601387905560148690556015859055601684905560178390556018829055601980546001600160a01b0319166001600160a01b0383161790556200014c732717f3449736949c9472ff05fb46b833cf4c32ec6101f4620001ac565b50505050505050506200043d565b600a80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6127106001600160601b038216811015620001ed57604051636f483d0960e01b81526001600160601b038316600482015260248101829052604401620000d7565b6001600160a01b0383166200021957604051635b6cc80560e11b815260006004820152602401620000d7565b50604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600b55565b600080600080600080600080610100898b0312156200027157600080fd5b885197506020890151965060408901519550606089015194506080890151935060a0890151925060c0890151915060e089015160018060a01b0381168114620002b957600080fd5b809150509295985092959890939650565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620002f557607f821691505b6020821081036200031657634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200036c576000816000526020600020601f850160051c81016020861015620003475750805b601f850160051c820191505b81811015620003685782815560010162000353565b5050505b505050565b81516001600160401b038111156200038d576200038d620002ca565b620003a5816200039e8454620002e0565b846200031c565b602080601f831160018114620003dd5760008415620003c45750858301515b600019600386901b1c1916600185901b17855562000368565b600085815260208120601f198616915b828110156200040e57888601518255948401946001909101908401620003ed565b50858210156200042d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6136fc806200044d6000396000f3fe6080604052600436106103c35760003560e01c80637bc9200e116101f2578063c7b4fc7a1161010d578063e34d99bf116100a0578063f2fde38b1161006f578063f2fde38b14610b03578063f8e5e28b14610b23578063f95df41414610b38578063fc4856e914610b5857600080fd5b8063e34d99bf14610a67578063e985e9c514610a85578063eb181c6114610ace578063ee1cc94414610ae357600080fd5b8063d6843409116100dc578063d6843409146109f2578063dc33e68114610a12578063e066fb7d14610a32578063e268e4d314610a4757600080fd5b8063c7b4fc7a14610988578063c87b56dd1461099d578063d0d41fe1146109bd578063d439287c146109dd57600080fd5b8063a0712d6811610185578063b4001c1211610154578063b4001c121461091d578063b6c55aed14610935578063b88d4fde14610948578063c23dc68f1461095b57600080fd5b8063a0712d68146108ad578063a22cb465146108c0578063abad6555146108e0578063aca8ffe7146108fd57600080fd5b806389e98a1b116101c157806389e98a1b1461083a5780638da5cb5b1461085a57806395d89b411461087857806399a2557a1461088d57600080fd5b80637bc9200e146107bc5780637d686a23146107cf5780638399e681146107ef5780638462151c1461080d57600080fd5b80633ccfd60b116102e2578063694f45a11161027557806370a082311161024457806370a082311461075d578063715018a61461077d5780637155c1ea14610792578063744dab38146107a757600080fd5b8063694f45a1146106f35780636a8c195b146107085780636bbc429114610728578063700879d31461073d57600080fd5b806355f804b3116102b157806355f804b3146106665780635bbb2177146106865780635d82cf6e146106b35780636352211e146106d357600080fd5b80633ccfd60b146105fe57806342842e0e1461061357806342966c681461062657806349df728c1461064657600080fd5b80631e48db901161035a57806334ab41d61161032957806334ab41d61461058957806334b1d403146105a957806338da2f69146105c95780633b9315b4146105e957600080fd5b80631e48db90146104ef57806323b872dd1461052257806326537dd7146105355780632a55205a1461054a57600080fd5b8063095ea7b311610396578063095ea7b314610479578063163e1e611461048c57806318160ddd146104ac5780631bc03e18146104cf57600080fd5b806301ffc9a7146103c857806304634d8d146103fd57806306fdde031461041f578063081812fc14610441575b600080fd5b3480156103d457600080fd5b506103e86103e3366004612dd8565b610b78565b60405190151581526020015b60405180910390f35b34801561040957600080fd5b5061041d610418366004612e0a565b610b98565b005b34801561042b57600080fd5b50610434610bae565b6040516103f49190612ea4565b34801561044d57600080fd5b5061046161045c366004612eb7565b610c40565b6040516001600160a01b0390911681526020016103f4565b61041d610487366004612ed0565b610c7b565b34801561049857600080fd5b5061041d6104a7366004612f41565b610c87565b3480156104b857600080fd5b50600154600054035b6040519081526020016103f4565b3480156104db57600080fd5b5061041d6104ea366004612eb7565b610d94565b3480156104fb57600080fd5b5061050f61050a366004612f83565b610da1565b60405161ffff90911681526020016103f4565b61041d610530366004612fa0565b610def565b34801561054157600080fd5b506016546104c1565b34801561055657600080fd5b5061056a610565366004612fe1565b610f5e565b604080516001600160a01b0390931683526020830191909152016103f4565b34801561059557600080fd5b5061050f6105a4366004612f83565b61101b565b3480156105b557600080fd5b5061041d6105c4366004612eb7565b61104c565b3480156105d557600080fd5b5061041d6105e4366004613011565b611059565b3480156105f557600080fd5b506010546104c1565b34801561060a57600080fd5b5061041d61107b565b61041d610621366004612fa0565b6111ea565b34801561063257600080fd5b5061041d610641366004612eb7565b61120a565b34801561065257600080fd5b5061041d610661366004612f83565b611218565b34801561067257600080fd5b5061041d61068136600461302e565b611314565b34801561069257600080fd5b506106a66106a1366004612f41565b611329565b6040516103f491906130a0565b3480156106bf57600080fd5b5061041d6106ce366004612eb7565b611375565b3480156106df57600080fd5b506104616106ee366004612eb7565b611382565b3480156106ff57600080fd5b50600e546104c1565b34801561071457600080fd5b5061050f610723366004612f83565b61138d565b34801561073457600080fd5b506015546104c1565b34801561074957600080fd5b5061041d610758366004612eb7565b6113bf565b34801561076957600080fd5b506104c1610778366004612f83565b6113cc565b34801561078957600080fd5b5061041d611412565b34801561079e57600080fd5b506012546104c1565b3480156107b357600080fd5b506018546104c1565b61041d6107ca366004613129565b611424565b3480156107db57600080fd5b5061041d6107ea366004613011565b611787565b3480156107fb57600080fd5b5060115462010000900460ff166103e8565b34801561081957600080fd5b5061082d610828366004612f83565b6117a2565b6040516103f49190613175565b34801561084657600080fd5b5061041d6108553660046131ad565b6117d1565b34801561086657600080fd5b50600a546001600160a01b0316610461565b34801561088457600080fd5b506104346119b9565b34801561089957600080fd5b5061082d6108a8366004613219565b6119c8565b61041d6108bb366004612eb7565b6119d5565b3480156108cc57600080fd5b5061041d6108db36600461324e565b611c6d565b3480156108ec57600080fd5b50601154610100900460ff166103e8565b34801561090957600080fd5b5061041d610918366004612eb7565b611cd9565b34801561092957600080fd5b5060115460ff166103e8565b61041d610943366004613129565b611dda565b61041d610956366004613292565b612112565b34801561096757600080fd5b5061097b610976366004612eb7565b61214d565b6040516103f49190613372565b34801561099457600080fd5b506013546104c1565b3480156109a957600080fd5b506104346109b8366004612eb7565b6121a7565b3480156109c957600080fd5b5061041d6109d8366004612f83565b61222b565b3480156109e957600080fd5b506014546104c1565b3480156109fe57600080fd5b5061041d610a0d366004612eb7565b612262565b348015610a1e57600080fd5b506104c1610a2d366004612f83565b61226f565b348015610a3e57600080fd5b506017546104c1565b348015610a5357600080fd5b5061041d610a62366004612eb7565b61229a565b348015610a7357600080fd5b506019546001600160a01b0316610461565b348015610a9157600080fd5b506103e8610aa03660046133b7565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b348015610ada57600080fd5b50600f546104c1565b348015610aef57600080fd5b5061041d610afe366004613011565b6122a7565b348015610b0f57600080fd5b5061041d610b1e366004612f83565b6122cb565b348015610b2f57600080fd5b50600d546104c1565b348015610b4457600080fd5b5061041d610b53366004612eb7565b612306565b348015610b6457600080fd5b5061041d610b73366004612eb7565b612313565b6000610b8382612320565b80610b925750610b928261236e565b92915050565b610ba06123a3565b610baa82826123d0565b5050565b606060028054610bbd906133e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610be9906133e5565b8015610c365780601f10610c0b57610100808354040283529160200191610c36565b820191906000526020600020905b815481529060010190602001808311610c1957829003601f168201915b5050505050905090565b6000610c4b82612482565b610c5f57610c5f6333d1c03960e21b6124c5565b506000908152600660205260409020546001600160a01b031690565b610baa828260016124cf565b610c8f61257f565b610c976123a3565b601254819081610caa6001546000540390565b610cb49190613435565b1115610d115760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b60648201526084015b60405180910390fd5b8160005b81811015610d8757610d4e858583818110610d3257610d32613448565b9050602002016020810190610d479190612f83565b60016125a9565b610d7f858583818110610d6357610d63613448565b9050602002016020810190610d789190612f83565b600161265d565b600101610d15565b505050610baa6001600955565b610d9c6123a3565b600f55565b600080610de6610dc9846001600160a01b031660009081526005602052604090205460c01c90565b602081901c63ffffffff1691601082901c65ffffffffffff169190565b95945050505050565b6000610dfa82612677565b6001600160a01b039485169490915081168414610e2057610e2062a1148160e81b6124c5565b60008281526006602052604090208054610e4c8187335b6001600160a01b039081169116811491141790565b610e6e57610e5a8633610aa0565b610e6e57610e6e632ce44b5f60e11b6124c5565b8015610e7957600082555b6001600160a01b038681166000908152600560205260408082208054600019019055918716808252919020805460010190554260a01b17600160e11b17600085815260046020526040812091909155600160e11b84169003610f0b57600184016000818152600460205260408120549003610f09576000548114610f095760008181526004602052604090208490555b505b6001600160a01b0385168481887fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a480600003610f5557610f55633a954ecd60e21b6124c5565b50505050505050565b6000828152600c602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046bffffffffffffffffffffffff16928201929092528291610fdd575060408051808201909152600b546001600160a01b0381168252600160a01b90046bffffffffffffffffffffffff1660208201525b602081015160009061271090611001906bffffffffffffffffffffffff168761345e565b61100b9190613475565b91519350909150505b9250929050565b600080611043610dc9846001600160a01b031660009081526005602052604090205460c01c90565b50949350505050565b6110546123a3565b601455565b6110616123a3565b601180549115156101000261ff0019909216919091179055565b6110836123a3565b61108b61257f565b60003361271061109d47611f4061345e565b6110a79190613475565b604051600081818185875af1925050503d80600081146110e3576040519150601f19603f3d011682016040523d82523d6000602084013e6110e8565b606091505b50509050806111395760405162461bcd60e51b815260206004820152601560248201527f4f776e6572207472616e73666572206661696c656400000000000000000000006044820152606401610d08565b6019546040516000916001600160a01b03169047908381818185875af1925050503d8060008114611186576040519150601f19603f3d011682016040523d82523d6000602084013e61118b565b606091505b50509050806111dc5760405162461bcd60e51b815260206004820152601360248201527f446576207472616e73666572206661696c6564000000000000000000000000006044820152606401610d08565b50506111e86001600955565b565b61120583838360405180602001604052806000815250612112565b505050565b61121581600161270d565b50565b6112206123a3565b61122861257f565b6040516370a0823160e01b81523060048201526001600160a01b0382169063a9059cbb90339083906370a0823190602401602060405180830381865afa158015611276573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061129a9190613497565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af11580156112e5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061130991906134b0565b506112156001600955565b61131c6123a3565b601a61120582848361351d565b60408051828152600583901b8082016020019092526060915b801561136d57601f198082019186010135600061135e8261214d565b84840160200152506113429050565b509392505050565b61137d6123a3565b601855565b6000610b9282612677565b6000806113b5610dc9846001600160a01b031660009081526005602052604090205460c01c90565b5090949350505050565b6113c76123a3565b601355565b60006001600160a01b0382166113ec576113ec6323d3ad8160e21b6124c5565b506001600160a01b031660009081526005602052604090205467ffffffffffffffff1690565b61141a6123a3565b6111e8600061284e565b61142c61257f565b32331461147b5760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b601154610100900460ff166114d25760405162461bcd60e51b815260206004820152601b60248201527f416c6c6f776c697374206d696e74206973206e6f74206f70656e2e00000000006044820152606401610d08565b818160105461154a838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040516bffffffffffffffffffffffff193360601b16602082015285925060340190505b604051602081830303815290604052805190602001206128ad565b6115a85760405162461bcd60e51b815260206004820152602960248201527f4164647265737320646f6573206e6f7420657869737420696e20746869732061604482015268363637bbb634b9ba1760b91b6064820152608401610d08565b85601254816115ba6001546000540390565b6115c49190613435565b111561161c5760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b866000806000611647610dc9336001600160a01b031660009081526005602052604090205460c01c90565b92509250925060145484838561165d91906135dd565b61ffff1661166b9190613435565b11156116eb5760405162461bcd60e51b815260206004820152604360248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620616c6c6f776c69737420746f6b6560648201526237399760e91b608482015260a401610d08565b6017548b346116fa828461345e565b146117475760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b8c600e60008282546117599190613435565b909155506117699050338e6128c3565b611773338e61265d565b505050505050505050506112056001600955565b61178f6123a3565b6011805460ff1916911515919091179055565b60606000806117b060005490565b905060608183146117c9576117c685848461292d565b90505b949350505050565b6117d961257f565b6117e16123a3565b8281146118565760405162461bcd60e51b815260206004820152603960248201527f546865206e756d626572206f6620726563697069656e747320616e642071756160448201527f6e746974696573206d757374206265207468652073616d652e000000000000006064820152608401610d08565b6000805b828110156118905783838281811061187457611874613448565b90506020020135826118869190613435565b915060010161185a565b50601254816118a26001546000540390565b6118ac9190613435565b11156119045760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b60005b848110156119a75761195786868381811061192457611924613448565b90506020020160208101906119399190612f83565b85858481811061194b5761194b613448565b905060200201356125a9565b61199f86868381811061196c5761196c613448565b90506020020160208101906119819190612f83565b85858481811061199357611993613448565b9050602002013561265d565b600101611907565b50506119b36001600955565b50505050565b606060038054610bbd906133e5565b60606117c984848461292d565b6119dd61257f565b323314611a2c5760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b60115462010000900460ff16611a845760405162461bcd60e51b815260206004820152601160248201527f4d696e74206973206e6f74206f70656e2e0000000000000000000000000000006044820152606401610d08565b8060125481611a966001546000540390565b611aa09190613435565b1115611af85760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b816000806000611b23610dc9336001600160a01b031660009081526005602052604090205460c01c90565b9250925092508061ffff168261ffff168461ffff16601554611b459190613435565b611b4f9190613435565b611b599190613435565b33600090815260056020526040908190205486911c67ffffffffffffffff16611b829190613435565b1115611bf65760405162461bcd60e51b815260206004820152603960248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620746f6b656e732e000000000000006064820152608401610d08565b6018548634611c05828461345e565b14611c525760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b611c5c338961265d565b505050505050506112156001600955565b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b611ce16123a3565b601254811115611d335760405162461bcd60e51b815260206004820181905260248201527f43616e6e6f7420696e63726561736520636f6c6c656374696f6e2073697a652e6044820152606401610d08565b60015460005403811015611dd55760405162461bcd60e51b815260206004820152604c60248201527f43616e6e6f742073657420636f6c6c656374696f6e2073697a6520746f206c6560448201527f7373207468616e20746865206e756d626572206f6620746f6b656e7320616c7260648201527f65616479206d696e7465642e0000000000000000000000000000000000000000608482015260a401610d08565b601255565b611de261257f565b323314611e315760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b60115460ff16611e835760405162461bcd60e51b815260206004820152601e60248201527f554220416c6c6f776c697374206d696e74206973206e6f74206f70656e2e00006044820152606401610d08565b8181600f54611ee4838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040516bffffffffffffffffffffffff193360601b166020820152859250603401905061152f565b611f425760405162461bcd60e51b815260206004820152602960248201527f4164647265737320646f6573206e6f7420657869737420696e20746869732061604482015268363637bbb634b9ba1760b91b6064820152608401610d08565b8560125481611f546001546000540390565b611f5e9190613435565b1115611fb65760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b866000806000611fe1610dc9336001600160a01b031660009081526005602052604090205460c01c90565b925092509250601354848461ffff16611ffa9190613435565b11156120945760405162461bcd60e51b815260206004820152604660248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620554220616c6c6f776c697374207460648201527f6f6b656e732e0000000000000000000000000000000000000000000000000000608482015260a401610d08565b6016548b346120a3828461345e565b146120f05760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b8c600d60008282546121029190613435565b909155506117699050338e612a26565b61211d848484610def565b6001600160a01b0383163b156119b35761213984848484612a8b565b6119b3576119b36368d2bf6b60e11b6124c5565b604080516080810182526000808252602082018190529181018290526060810182905290548210156121a2575b600082815260046020526040902054612199576000199091019061217a565b610b9282612b6d565b919050565b60606121b282612482565b6121cf57604051630a14c4b560e41b815260040160405180910390fd5b60006121d9612bec565b905080516000036121f95760405180602001604052806000815250612224565b8061220384612bfb565b6040516020016122149291906135ff565b6040516020818303038152906040525b9392505050565b6122336123a3565b6019805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b61226a6123a3565b601755565b6001600160a01b0381166000908152600560205260408082205467ffffffffffffffff911c16610b92565b6122a26123a3565b601555565b6122af6123a3565b60118054911515620100000262ff000019909216919091179055565b6122d36123a3565b6001600160a01b0381166122fd57604051631e4fbdf760e01b815260006004820152602401610d08565b6112158161284e565b61230e6123a3565b601055565b61231b6123a3565b601655565b60006301ffc9a760e01b6001600160e01b03198316148061235157506380ac58cd60e01b6001600160e01b03198316145b80610b925750506001600160e01b031916635b5e139f60e01b1490565b60006001600160e01b0319821663152a902d60e11b1480610b9257506301ffc9a760e01b6001600160e01b0319831614610b92565b600a546001600160a01b031633146111e85760405163118cdaa760e01b8152336004820152602401610d08565b6127106bffffffffffffffffffffffff821681101561241957604051636f483d0960e01b81526bffffffffffffffffffffffff8316600482015260248101829052604401610d08565b6001600160a01b03831661244357604051635b6cc80560e11b815260006004820152602401610d08565b50604080518082019091526001600160a01b039092168083526bffffffffffffffffffffffff9091166020909201829052600160a01b90910217600b55565b600080548210156121a25760005b50600082815260046020526040812054908190036124b8576124b183613656565b9250612490565b600160e01b161592915050565b8060005260046000fd5b60006124da83611382565b90508180156124f25750336001600160a01b03821614155b15612515576125018133610aa0565b612515576125156367d9dca160e11b6124c5565b600083815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0388811691821790925591518693918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a450505050565b6002600954036125a257604051633ee5aeb560e01b815260040160405180910390fd5b6002600955565b60008060006125d3610dc9866001600160a01b031660009081526005602052604090205460c01c90565b919450925090506126568561261385856125ed89876135dd565b65ffff00000000602084901b1663ffff0000601084901b161761ffff8216179392505050565b6001600160a01b039091166000908152600560205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff1660c09290921b919091179055565b5050505050565b610baa828260405180602001604052806000815250612c3f565b600081815260046020526040902054806000036126ea5760005482106126a7576126a7636f96cda160e11b6124c5565b5b506000190160008181526004602052604090205480156126a857600160e01b81166000036126d557919050565b6126e5636f96cda160e11b6124c5565b6126a8565b600160e01b81166000036126fd57919050565b6121a2636f96cda160e11b6124c5565b600061271883612677565b90508060008061273686600090815260066020526040902080549091565b91509150841561276d5761274b818433610e37565b61276d576127598333610aa0565b61276d5761276d632ce44b5f60e11b6124c5565b801561277857600082555b6001600160a01b038316600081815260056020526040902080546fffffffffffffffffffffffffffffffff0190554260a01b17600360e01b17600087815260046020526040812091909155600160e11b85169003612806576001860160008181526004602052604081205490036128045760005481146128045760008181526004602052604090208590555b505b60405186906000906001600160a01b038616907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050600180548101905550505050565b600a80546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000826128ba8584612c9c565b14949350505050565b60008060006128ed610dc9866001600160a01b031660009081526005602052604090205460c01c90565b91945092509050612656856126138561290688876135dd565b8565ffff00000000602084901b1663ffff0000601084901b161761ffff8216179392505050565b606081831061294657612946631960ccad60e11b6124c5565b60005480808410612955578093505b6000612960876113cc565b905084861061296d575060005b8015612a1c57808686031161298157508484035b604080516001830160051b8101918290529450600061299f8861214d565b9050600081604001516129b0575080515b60005b6129bc8a612b6d565b92506040830151600081146129d457600092506129f9565b8351156129e057835192505b8b831860601b6129f9576001820191508a8260051b8a01525b5060018a01995083604052888a1480612a1157508481145b156129b35787525050505b5050509392505050565b6000806000612a50610dc9866001600160a01b031660009081526005602052604090205460c01c90565b9194509250905061265685612613612a6887876135dd565b65ffff0000000060209190911b1663ffff0000601087901b161761ffff85161790565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a0290612ac090339089908890889060040161366d565b6020604051808303816000875af1925050508015612afb575060408051601f3d908101601f19168201909252612af8918101906136a9565b60015b612b50573d808015612b29576040519150601f19603f3d011682016040523d82523d6000602084013e612b2e565b606091505b508051600003612b4857612b486368d2bf6b60e11b6124c5565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b604080516080810182526000808252602082018190529181018290526060810191909152600082815260046020526040902054610b9290604080516080810182526001600160a01b038316815260a083901c67ffffffffffffffff166020820152600160e01b831615159181019190915260e89190911c606082015290565b6060601a8054610bbd906133e5565b606060a06040510180604052602081039150506000815280825b600183039250600a81066030018353600a900480612c155750819003601f19909101908152919050565b612c498383612cd7565b6001600160a01b0383163b15611205576000548281035b612c736000868380600101945086612a8b565b612c8757612c876368d2bf6b60e11b6124c5565b818110612c6057816000541461265657600080fd5b600081815b845181101561136d57612ccd82868381518110612cc057612cc0613448565b6020026020010151612d96565b9150600101612ca1565b6000805490829003612cf357612cf363b562e8dd60e01b6124c5565b60008181526004602090815260408083206001600160a01b0387164260a01b6001881460e11b17811790915580845260059092528220805468010000000000000001860201905590819003612d5157612d51622e076360e81b6124c5565b818301825b808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4818160010191508103612d56575060005550505050565b6000818310612db2576000828152602084905260409020612224565b5060009182526020526040902090565b6001600160e01b03198116811461121557600080fd5b600060208284031215612dea57600080fd5b813561222481612dc2565b6001600160a01b038116811461121557600080fd5b60008060408385031215612e1d57600080fd5b8235612e2881612df5565b915060208301356bffffffffffffffffffffffff81168114612e4957600080fd5b809150509250929050565b60005b83811015612e6f578181015183820152602001612e57565b50506000910152565b60008151808452612e90816020860160208601612e54565b601f01601f19169290920160200192915050565b6020815260006122246020830184612e78565b600060208284031215612ec957600080fd5b5035919050565b60008060408385031215612ee357600080fd5b8235612eee81612df5565b946020939093013593505050565b60008083601f840112612f0e57600080fd5b50813567ffffffffffffffff811115612f2657600080fd5b6020830191508360208260051b850101111561101457600080fd5b60008060208385031215612f5457600080fd5b823567ffffffffffffffff811115612f6b57600080fd5b612f7785828601612efc565b90969095509350505050565b600060208284031215612f9557600080fd5b813561222481612df5565b600080600060608486031215612fb557600080fd5b8335612fc081612df5565b92506020840135612fd081612df5565b929592945050506040919091013590565b60008060408385031215612ff457600080fd5b50508035926020909101359150565b801515811461121557600080fd5b60006020828403121561302357600080fd5b813561222481613003565b6000806020838503121561304157600080fd5b823567ffffffffffffffff8082111561305957600080fd5b818501915085601f83011261306d57600080fd5b81358181111561307c57600080fd5b86602082850101111561308e57600080fd5b60209290920196919550909350505050565b6020808252825182820181905260009190848201906040850190845b8181101561311d5761310a8385516001600160a01b03815116825267ffffffffffffffff602082015116602083015260408101511515604083015262ffffff60608201511660608301525050565b92840192608092909201916001016130bc565b50909695505050505050565b60008060006040848603121561313e57600080fd5b83359250602084013567ffffffffffffffff81111561315c57600080fd5b61316886828701612efc565b9497909650939450505050565b6020808252825182820181905260009190848201906040850190845b8181101561311d57835183529284019291840191600101613191565b600080600080604085870312156131c357600080fd5b843567ffffffffffffffff808211156131db57600080fd5b6131e788838901612efc565b9096509450602087013591508082111561320057600080fd5b5061320d87828801612efc565b95989497509550505050565b60008060006060848603121561322e57600080fd5b833561323981612df5565b95602085013595506040909401359392505050565b6000806040838503121561326157600080fd5b823561326c81612df5565b91506020830135612e4981613003565b634e487b7160e01b600052604160045260246000fd5b600080600080608085870312156132a857600080fd5b84356132b381612df5565b935060208501356132c381612df5565b925060408501359150606085013567ffffffffffffffff808211156132e757600080fd5b818701915087601f8301126132fb57600080fd5b81358181111561330d5761330d61327c565b604051601f8201601f19908116603f011681019083821181831017156133355761333561327c565b816040528281528a602084870101111561334e57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b81516001600160a01b0316815260208083015167ffffffffffffffff169082015260408083015115159082015260608083015162ffffff169082015260808101610b92565b600080604083850312156133ca57600080fd5b82356133d581612df5565b91506020830135612e4981612df5565b600181811c908216806133f957607f821691505b60208210810361341957634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b80820180821115610b9257610b9261341f565b634e487b7160e01b600052603260045260246000fd5b8082028115828204841417610b9257610b9261341f565b60008261349257634e487b7160e01b600052601260045260246000fd5b500490565b6000602082840312156134a957600080fd5b5051919050565b6000602082840312156134c257600080fd5b815161222481613003565b601f821115611205576000816000526020600020601f850160051c810160208610156134f65750805b601f850160051c820191505b8181101561351557828155600101613502565b505050505050565b67ffffffffffffffff8311156135355761353561327c565b6135498361354383546133e5565b836134cd565b6000601f84116001811461357d57600085156135655750838201355b600019600387901b1c1916600186901b178355612656565b600083815260209020601f19861690835b828110156135ae578685013582556020948501946001909201910161358e565b50868210156135cb5760001960f88860031b161c19848701351681555b505060018560011b0183555050505050565b61ffff8181168382160190808211156135f8576135f861341f565b5092915050565b60008351613611818460208801612e54565b835190830190613625818360208801612e54565b7f2e6a736f6e0000000000000000000000000000000000000000000000000000009101908152600501949350505050565b6000816136655761366561341f565b506000190190565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261369f6080830184612e78565b9695505050505050565b6000602082840312156136bb57600080fd5b815161222481612dc256fea2646970667358221220d3433ecc8e436da984123245117fc59ce8f4668bca2237cff508264eb3956bd164736f6c6343000818003300000000000000000000000000000000000000000000000000000000000002ee00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000ec9c58de0a800000000000000000000000000000000000000000000000000000ec9c58de0a800000000000000000000000000000000000000000000000000001140bbd030c4000000000000000000000000000cbc94f1c3578c61137cad3dd7c49fd56fe0720a2

Deployed Bytecode

0x6080604052600436106103c35760003560e01c80637bc9200e116101f2578063c7b4fc7a1161010d578063e34d99bf116100a0578063f2fde38b1161006f578063f2fde38b14610b03578063f8e5e28b14610b23578063f95df41414610b38578063fc4856e914610b5857600080fd5b8063e34d99bf14610a67578063e985e9c514610a85578063eb181c6114610ace578063ee1cc94414610ae357600080fd5b8063d6843409116100dc578063d6843409146109f2578063dc33e68114610a12578063e066fb7d14610a32578063e268e4d314610a4757600080fd5b8063c7b4fc7a14610988578063c87b56dd1461099d578063d0d41fe1146109bd578063d439287c146109dd57600080fd5b8063a0712d6811610185578063b4001c1211610154578063b4001c121461091d578063b6c55aed14610935578063b88d4fde14610948578063c23dc68f1461095b57600080fd5b8063a0712d68146108ad578063a22cb465146108c0578063abad6555146108e0578063aca8ffe7146108fd57600080fd5b806389e98a1b116101c157806389e98a1b1461083a5780638da5cb5b1461085a57806395d89b411461087857806399a2557a1461088d57600080fd5b80637bc9200e146107bc5780637d686a23146107cf5780638399e681146107ef5780638462151c1461080d57600080fd5b80633ccfd60b116102e2578063694f45a11161027557806370a082311161024457806370a082311461075d578063715018a61461077d5780637155c1ea14610792578063744dab38146107a757600080fd5b8063694f45a1146106f35780636a8c195b146107085780636bbc429114610728578063700879d31461073d57600080fd5b806355f804b3116102b157806355f804b3146106665780635bbb2177146106865780635d82cf6e146106b35780636352211e146106d357600080fd5b80633ccfd60b146105fe57806342842e0e1461061357806342966c681461062657806349df728c1461064657600080fd5b80631e48db901161035a57806334ab41d61161032957806334ab41d61461058957806334b1d403146105a957806338da2f69146105c95780633b9315b4146105e957600080fd5b80631e48db90146104ef57806323b872dd1461052257806326537dd7146105355780632a55205a1461054a57600080fd5b8063095ea7b311610396578063095ea7b314610479578063163e1e611461048c57806318160ddd146104ac5780631bc03e18146104cf57600080fd5b806301ffc9a7146103c857806304634d8d146103fd57806306fdde031461041f578063081812fc14610441575b600080fd5b3480156103d457600080fd5b506103e86103e3366004612dd8565b610b78565b60405190151581526020015b60405180910390f35b34801561040957600080fd5b5061041d610418366004612e0a565b610b98565b005b34801561042b57600080fd5b50610434610bae565b6040516103f49190612ea4565b34801561044d57600080fd5b5061046161045c366004612eb7565b610c40565b6040516001600160a01b0390911681526020016103f4565b61041d610487366004612ed0565b610c7b565b34801561049857600080fd5b5061041d6104a7366004612f41565b610c87565b3480156104b857600080fd5b50600154600054035b6040519081526020016103f4565b3480156104db57600080fd5b5061041d6104ea366004612eb7565b610d94565b3480156104fb57600080fd5b5061050f61050a366004612f83565b610da1565b60405161ffff90911681526020016103f4565b61041d610530366004612fa0565b610def565b34801561054157600080fd5b506016546104c1565b34801561055657600080fd5b5061056a610565366004612fe1565b610f5e565b604080516001600160a01b0390931683526020830191909152016103f4565b34801561059557600080fd5b5061050f6105a4366004612f83565b61101b565b3480156105b557600080fd5b5061041d6105c4366004612eb7565b61104c565b3480156105d557600080fd5b5061041d6105e4366004613011565b611059565b3480156105f557600080fd5b506010546104c1565b34801561060a57600080fd5b5061041d61107b565b61041d610621366004612fa0565b6111ea565b34801561063257600080fd5b5061041d610641366004612eb7565b61120a565b34801561065257600080fd5b5061041d610661366004612f83565b611218565b34801561067257600080fd5b5061041d61068136600461302e565b611314565b34801561069257600080fd5b506106a66106a1366004612f41565b611329565b6040516103f491906130a0565b3480156106bf57600080fd5b5061041d6106ce366004612eb7565b611375565b3480156106df57600080fd5b506104616106ee366004612eb7565b611382565b3480156106ff57600080fd5b50600e546104c1565b34801561071457600080fd5b5061050f610723366004612f83565b61138d565b34801561073457600080fd5b506015546104c1565b34801561074957600080fd5b5061041d610758366004612eb7565b6113bf565b34801561076957600080fd5b506104c1610778366004612f83565b6113cc565b34801561078957600080fd5b5061041d611412565b34801561079e57600080fd5b506012546104c1565b3480156107b357600080fd5b506018546104c1565b61041d6107ca366004613129565b611424565b3480156107db57600080fd5b5061041d6107ea366004613011565b611787565b3480156107fb57600080fd5b5060115462010000900460ff166103e8565b34801561081957600080fd5b5061082d610828366004612f83565b6117a2565b6040516103f49190613175565b34801561084657600080fd5b5061041d6108553660046131ad565b6117d1565b34801561086657600080fd5b50600a546001600160a01b0316610461565b34801561088457600080fd5b506104346119b9565b34801561089957600080fd5b5061082d6108a8366004613219565b6119c8565b61041d6108bb366004612eb7565b6119d5565b3480156108cc57600080fd5b5061041d6108db36600461324e565b611c6d565b3480156108ec57600080fd5b50601154610100900460ff166103e8565b34801561090957600080fd5b5061041d610918366004612eb7565b611cd9565b34801561092957600080fd5b5060115460ff166103e8565b61041d610943366004613129565b611dda565b61041d610956366004613292565b612112565b34801561096757600080fd5b5061097b610976366004612eb7565b61214d565b6040516103f49190613372565b34801561099457600080fd5b506013546104c1565b3480156109a957600080fd5b506104346109b8366004612eb7565b6121a7565b3480156109c957600080fd5b5061041d6109d8366004612f83565b61222b565b3480156109e957600080fd5b506014546104c1565b3480156109fe57600080fd5b5061041d610a0d366004612eb7565b612262565b348015610a1e57600080fd5b506104c1610a2d366004612f83565b61226f565b348015610a3e57600080fd5b506017546104c1565b348015610a5357600080fd5b5061041d610a62366004612eb7565b61229a565b348015610a7357600080fd5b506019546001600160a01b0316610461565b348015610a9157600080fd5b506103e8610aa03660046133b7565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b348015610ada57600080fd5b50600f546104c1565b348015610aef57600080fd5b5061041d610afe366004613011565b6122a7565b348015610b0f57600080fd5b5061041d610b1e366004612f83565b6122cb565b348015610b2f57600080fd5b50600d546104c1565b348015610b4457600080fd5b5061041d610b53366004612eb7565b612306565b348015610b6457600080fd5b5061041d610b73366004612eb7565b612313565b6000610b8382612320565b80610b925750610b928261236e565b92915050565b610ba06123a3565b610baa82826123d0565b5050565b606060028054610bbd906133e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610be9906133e5565b8015610c365780601f10610c0b57610100808354040283529160200191610c36565b820191906000526020600020905b815481529060010190602001808311610c1957829003601f168201915b5050505050905090565b6000610c4b82612482565b610c5f57610c5f6333d1c03960e21b6124c5565b506000908152600660205260409020546001600160a01b031690565b610baa828260016124cf565b610c8f61257f565b610c976123a3565b601254819081610caa6001546000540390565b610cb49190613435565b1115610d115760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b60648201526084015b60405180910390fd5b8160005b81811015610d8757610d4e858583818110610d3257610d32613448565b9050602002016020810190610d479190612f83565b60016125a9565b610d7f858583818110610d6357610d63613448565b9050602002016020810190610d789190612f83565b600161265d565b600101610d15565b505050610baa6001600955565b610d9c6123a3565b600f55565b600080610de6610dc9846001600160a01b031660009081526005602052604090205460c01c90565b602081901c63ffffffff1691601082901c65ffffffffffff169190565b95945050505050565b6000610dfa82612677565b6001600160a01b039485169490915081168414610e2057610e2062a1148160e81b6124c5565b60008281526006602052604090208054610e4c8187335b6001600160a01b039081169116811491141790565b610e6e57610e5a8633610aa0565b610e6e57610e6e632ce44b5f60e11b6124c5565b8015610e7957600082555b6001600160a01b038681166000908152600560205260408082208054600019019055918716808252919020805460010190554260a01b17600160e11b17600085815260046020526040812091909155600160e11b84169003610f0b57600184016000818152600460205260408120549003610f09576000548114610f095760008181526004602052604090208490555b505b6001600160a01b0385168481887fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a480600003610f5557610f55633a954ecd60e21b6124c5565b50505050505050565b6000828152600c602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046bffffffffffffffffffffffff16928201929092528291610fdd575060408051808201909152600b546001600160a01b0381168252600160a01b90046bffffffffffffffffffffffff1660208201525b602081015160009061271090611001906bffffffffffffffffffffffff168761345e565b61100b9190613475565b91519350909150505b9250929050565b600080611043610dc9846001600160a01b031660009081526005602052604090205460c01c90565b50949350505050565b6110546123a3565b601455565b6110616123a3565b601180549115156101000261ff0019909216919091179055565b6110836123a3565b61108b61257f565b60003361271061109d47611f4061345e565b6110a79190613475565b604051600081818185875af1925050503d80600081146110e3576040519150601f19603f3d011682016040523d82523d6000602084013e6110e8565b606091505b50509050806111395760405162461bcd60e51b815260206004820152601560248201527f4f776e6572207472616e73666572206661696c656400000000000000000000006044820152606401610d08565b6019546040516000916001600160a01b03169047908381818185875af1925050503d8060008114611186576040519150601f19603f3d011682016040523d82523d6000602084013e61118b565b606091505b50509050806111dc5760405162461bcd60e51b815260206004820152601360248201527f446576207472616e73666572206661696c6564000000000000000000000000006044820152606401610d08565b50506111e86001600955565b565b61120583838360405180602001604052806000815250612112565b505050565b61121581600161270d565b50565b6112206123a3565b61122861257f565b6040516370a0823160e01b81523060048201526001600160a01b0382169063a9059cbb90339083906370a0823190602401602060405180830381865afa158015611276573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061129a9190613497565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af11580156112e5573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061130991906134b0565b506112156001600955565b61131c6123a3565b601a61120582848361351d565b60408051828152600583901b8082016020019092526060915b801561136d57601f198082019186010135600061135e8261214d565b84840160200152506113429050565b509392505050565b61137d6123a3565b601855565b6000610b9282612677565b6000806113b5610dc9846001600160a01b031660009081526005602052604090205460c01c90565b5090949350505050565b6113c76123a3565b601355565b60006001600160a01b0382166113ec576113ec6323d3ad8160e21b6124c5565b506001600160a01b031660009081526005602052604090205467ffffffffffffffff1690565b61141a6123a3565b6111e8600061284e565b61142c61257f565b32331461147b5760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b601154610100900460ff166114d25760405162461bcd60e51b815260206004820152601b60248201527f416c6c6f776c697374206d696e74206973206e6f74206f70656e2e00000000006044820152606401610d08565b818160105461154a838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040516bffffffffffffffffffffffff193360601b16602082015285925060340190505b604051602081830303815290604052805190602001206128ad565b6115a85760405162461bcd60e51b815260206004820152602960248201527f4164647265737320646f6573206e6f7420657869737420696e20746869732061604482015268363637bbb634b9ba1760b91b6064820152608401610d08565b85601254816115ba6001546000540390565b6115c49190613435565b111561161c5760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b866000806000611647610dc9336001600160a01b031660009081526005602052604090205460c01c90565b92509250925060145484838561165d91906135dd565b61ffff1661166b9190613435565b11156116eb5760405162461bcd60e51b815260206004820152604360248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620616c6c6f776c69737420746f6b6560648201526237399760e91b608482015260a401610d08565b6017548b346116fa828461345e565b146117475760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b8c600e60008282546117599190613435565b909155506117699050338e6128c3565b611773338e61265d565b505050505050505050506112056001600955565b61178f6123a3565b6011805460ff1916911515919091179055565b60606000806117b060005490565b905060608183146117c9576117c685848461292d565b90505b949350505050565b6117d961257f565b6117e16123a3565b8281146118565760405162461bcd60e51b815260206004820152603960248201527f546865206e756d626572206f6620726563697069656e747320616e642071756160448201527f6e746974696573206d757374206265207468652073616d652e000000000000006064820152608401610d08565b6000805b828110156118905783838281811061187457611874613448565b90506020020135826118869190613435565b915060010161185a565b50601254816118a26001546000540390565b6118ac9190613435565b11156119045760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b60005b848110156119a75761195786868381811061192457611924613448565b90506020020160208101906119399190612f83565b85858481811061194b5761194b613448565b905060200201356125a9565b61199f86868381811061196c5761196c613448565b90506020020160208101906119819190612f83565b85858481811061199357611993613448565b9050602002013561265d565b600101611907565b50506119b36001600955565b50505050565b606060038054610bbd906133e5565b60606117c984848461292d565b6119dd61257f565b323314611a2c5760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b60115462010000900460ff16611a845760405162461bcd60e51b815260206004820152601160248201527f4d696e74206973206e6f74206f70656e2e0000000000000000000000000000006044820152606401610d08565b8060125481611a966001546000540390565b611aa09190613435565b1115611af85760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b816000806000611b23610dc9336001600160a01b031660009081526005602052604090205460c01c90565b9250925092508061ffff168261ffff168461ffff16601554611b459190613435565b611b4f9190613435565b611b599190613435565b33600090815260056020526040908190205486911c67ffffffffffffffff16611b829190613435565b1115611bf65760405162461bcd60e51b815260206004820152603960248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620746f6b656e732e000000000000006064820152608401610d08565b6018548634611c05828461345e565b14611c525760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b611c5c338961265d565b505050505050506112156001600955565b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b611ce16123a3565b601254811115611d335760405162461bcd60e51b815260206004820181905260248201527f43616e6e6f7420696e63726561736520636f6c6c656374696f6e2073697a652e6044820152606401610d08565b60015460005403811015611dd55760405162461bcd60e51b815260206004820152604c60248201527f43616e6e6f742073657420636f6c6c656374696f6e2073697a6520746f206c6560448201527f7373207468616e20746865206e756d626572206f6620746f6b656e7320616c7260648201527f65616479206d696e7465642e0000000000000000000000000000000000000000608482015260a401610d08565b601255565b611de261257f565b323314611e315760405162461bcd60e51b815260206004820152601f60248201527f5468652063616c6c657220697320616e6f7468657220636f6e74726163742e006044820152606401610d08565b60115460ff16611e835760405162461bcd60e51b815260206004820152601e60248201527f554220416c6c6f776c697374206d696e74206973206e6f74206f70656e2e00006044820152606401610d08565b8181600f54611ee4838380806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506040516bffffffffffffffffffffffff193360601b166020820152859250603401905061152f565b611f425760405162461bcd60e51b815260206004820152602960248201527f4164647265737320646f6573206e6f7420657869737420696e20746869732061604482015268363637bbb634b9ba1760b91b6064820152608401610d08565b8560125481611f546001546000540390565b611f5e9190613435565b1115611fb65760405162461bcd60e51b815260206004820152602160248201527f546865726520617265206e6f20746f6b656e73206c65667420746f206d696e746044820152601760f91b6064820152608401610d08565b866000806000611fe1610dc9336001600160a01b031660009081526005602052604090205460c01c90565b925092509250601354848461ffff16611ffa9190613435565b11156120945760405162461bcd60e51b815260206004820152604660248201527f546869732077616c6c657420686173207265616368656420697473206d61786960448201527f6d756d20616c6c6f636174696f6e206f6620554220616c6c6f776c697374207460648201527f6f6b656e732e0000000000000000000000000000000000000000000000000000608482015260a401610d08565b6016548b346120a3828461345e565b146120f05760405162461bcd60e51b815260206004820152601d60248201527f496e636f727265637420616d6f756e74206f66204554482073656e742e0000006044820152606401610d08565b8c600d60008282546121029190613435565b909155506117699050338e612a26565b61211d848484610def565b6001600160a01b0383163b156119b35761213984848484612a8b565b6119b3576119b36368d2bf6b60e11b6124c5565b604080516080810182526000808252602082018190529181018290526060810182905290548210156121a2575b600082815260046020526040902054612199576000199091019061217a565b610b9282612b6d565b919050565b60606121b282612482565b6121cf57604051630a14c4b560e41b815260040160405180910390fd5b60006121d9612bec565b905080516000036121f95760405180602001604052806000815250612224565b8061220384612bfb565b6040516020016122149291906135ff565b6040516020818303038152906040525b9392505050565b6122336123a3565b6019805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b61226a6123a3565b601755565b6001600160a01b0381166000908152600560205260408082205467ffffffffffffffff911c16610b92565b6122a26123a3565b601555565b6122af6123a3565b60118054911515620100000262ff000019909216919091179055565b6122d36123a3565b6001600160a01b0381166122fd57604051631e4fbdf760e01b815260006004820152602401610d08565b6112158161284e565b61230e6123a3565b601055565b61231b6123a3565b601655565b60006301ffc9a760e01b6001600160e01b03198316148061235157506380ac58cd60e01b6001600160e01b03198316145b80610b925750506001600160e01b031916635b5e139f60e01b1490565b60006001600160e01b0319821663152a902d60e11b1480610b9257506301ffc9a760e01b6001600160e01b0319831614610b92565b600a546001600160a01b031633146111e85760405163118cdaa760e01b8152336004820152602401610d08565b6127106bffffffffffffffffffffffff821681101561241957604051636f483d0960e01b81526bffffffffffffffffffffffff8316600482015260248101829052604401610d08565b6001600160a01b03831661244357604051635b6cc80560e11b815260006004820152602401610d08565b50604080518082019091526001600160a01b039092168083526bffffffffffffffffffffffff9091166020909201829052600160a01b90910217600b55565b600080548210156121a25760005b50600082815260046020526040812054908190036124b8576124b183613656565b9250612490565b600160e01b161592915050565b8060005260046000fd5b60006124da83611382565b90508180156124f25750336001600160a01b03821614155b15612515576125018133610aa0565b612515576125156367d9dca160e11b6124c5565b600083815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0388811691821790925591518693918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a450505050565b6002600954036125a257604051633ee5aeb560e01b815260040160405180910390fd5b6002600955565b60008060006125d3610dc9866001600160a01b031660009081526005602052604090205460c01c90565b919450925090506126568561261385856125ed89876135dd565b65ffff00000000602084901b1663ffff0000601084901b161761ffff8216179392505050565b6001600160a01b039091166000908152600560205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff1660c09290921b919091179055565b5050505050565b610baa828260405180602001604052806000815250612c3f565b600081815260046020526040902054806000036126ea5760005482106126a7576126a7636f96cda160e11b6124c5565b5b506000190160008181526004602052604090205480156126a857600160e01b81166000036126d557919050565b6126e5636f96cda160e11b6124c5565b6126a8565b600160e01b81166000036126fd57919050565b6121a2636f96cda160e11b6124c5565b600061271883612677565b90508060008061273686600090815260066020526040902080549091565b91509150841561276d5761274b818433610e37565b61276d576127598333610aa0565b61276d5761276d632ce44b5f60e11b6124c5565b801561277857600082555b6001600160a01b038316600081815260056020526040902080546fffffffffffffffffffffffffffffffff0190554260a01b17600360e01b17600087815260046020526040812091909155600160e11b85169003612806576001860160008181526004602052604081205490036128045760005481146128045760008181526004602052604090208590555b505b60405186906000906001600160a01b038616907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050600180548101905550505050565b600a80546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000826128ba8584612c9c565b14949350505050565b60008060006128ed610dc9866001600160a01b031660009081526005602052604090205460c01c90565b91945092509050612656856126138561290688876135dd565b8565ffff00000000602084901b1663ffff0000601084901b161761ffff8216179392505050565b606081831061294657612946631960ccad60e11b6124c5565b60005480808410612955578093505b6000612960876113cc565b905084861061296d575060005b8015612a1c57808686031161298157508484035b604080516001830160051b8101918290529450600061299f8861214d565b9050600081604001516129b0575080515b60005b6129bc8a612b6d565b92506040830151600081146129d457600092506129f9565b8351156129e057835192505b8b831860601b6129f9576001820191508a8260051b8a01525b5060018a01995083604052888a1480612a1157508481145b156129b35787525050505b5050509392505050565b6000806000612a50610dc9866001600160a01b031660009081526005602052604090205460c01c90565b9194509250905061265685612613612a6887876135dd565b65ffff0000000060209190911b1663ffff0000601087901b161761ffff85161790565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a0290612ac090339089908890889060040161366d565b6020604051808303816000875af1925050508015612afb575060408051601f3d908101601f19168201909252612af8918101906136a9565b60015b612b50573d808015612b29576040519150601f19603f3d011682016040523d82523d6000602084013e612b2e565b606091505b508051600003612b4857612b486368d2bf6b60e11b6124c5565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b604080516080810182526000808252602082018190529181018290526060810191909152600082815260046020526040902054610b9290604080516080810182526001600160a01b038316815260a083901c67ffffffffffffffff166020820152600160e01b831615159181019190915260e89190911c606082015290565b6060601a8054610bbd906133e5565b606060a06040510180604052602081039150506000815280825b600183039250600a81066030018353600a900480612c155750819003601f19909101908152919050565b612c498383612cd7565b6001600160a01b0383163b15611205576000548281035b612c736000868380600101945086612a8b565b612c8757612c876368d2bf6b60e11b6124c5565b818110612c6057816000541461265657600080fd5b600081815b845181101561136d57612ccd82868381518110612cc057612cc0613448565b6020026020010151612d96565b9150600101612ca1565b6000805490829003612cf357612cf363b562e8dd60e01b6124c5565b60008181526004602090815260408083206001600160a01b0387164260a01b6001881460e11b17811790915580845260059092528220805468010000000000000001860201905590819003612d5157612d51622e076360e81b6124c5565b818301825b808360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef600080a4818160010191508103612d56575060005550505050565b6000818310612db2576000828152602084905260409020612224565b5060009182526020526040902090565b6001600160e01b03198116811461121557600080fd5b600060208284031215612dea57600080fd5b813561222481612dc2565b6001600160a01b038116811461121557600080fd5b60008060408385031215612e1d57600080fd5b8235612e2881612df5565b915060208301356bffffffffffffffffffffffff81168114612e4957600080fd5b809150509250929050565b60005b83811015612e6f578181015183820152602001612e57565b50506000910152565b60008151808452612e90816020860160208601612e54565b601f01601f19169290920160200192915050565b6020815260006122246020830184612e78565b600060208284031215612ec957600080fd5b5035919050565b60008060408385031215612ee357600080fd5b8235612eee81612df5565b946020939093013593505050565b60008083601f840112612f0e57600080fd5b50813567ffffffffffffffff811115612f2657600080fd5b6020830191508360208260051b850101111561101457600080fd5b60008060208385031215612f5457600080fd5b823567ffffffffffffffff811115612f6b57600080fd5b612f7785828601612efc565b90969095509350505050565b600060208284031215612f9557600080fd5b813561222481612df5565b600080600060608486031215612fb557600080fd5b8335612fc081612df5565b92506020840135612fd081612df5565b929592945050506040919091013590565b60008060408385031215612ff457600080fd5b50508035926020909101359150565b801515811461121557600080fd5b60006020828403121561302357600080fd5b813561222481613003565b6000806020838503121561304157600080fd5b823567ffffffffffffffff8082111561305957600080fd5b818501915085601f83011261306d57600080fd5b81358181111561307c57600080fd5b86602082850101111561308e57600080fd5b60209290920196919550909350505050565b6020808252825182820181905260009190848201906040850190845b8181101561311d5761310a8385516001600160a01b03815116825267ffffffffffffffff602082015116602083015260408101511515604083015262ffffff60608201511660608301525050565b92840192608092909201916001016130bc565b50909695505050505050565b60008060006040848603121561313e57600080fd5b83359250602084013567ffffffffffffffff81111561315c57600080fd5b61316886828701612efc565b9497909650939450505050565b6020808252825182820181905260009190848201906040850190845b8181101561311d57835183529284019291840191600101613191565b600080600080604085870312156131c357600080fd5b843567ffffffffffffffff808211156131db57600080fd5b6131e788838901612efc565b9096509450602087013591508082111561320057600080fd5b5061320d87828801612efc565b95989497509550505050565b60008060006060848603121561322e57600080fd5b833561323981612df5565b95602085013595506040909401359392505050565b6000806040838503121561326157600080fd5b823561326c81612df5565b91506020830135612e4981613003565b634e487b7160e01b600052604160045260246000fd5b600080600080608085870312156132a857600080fd5b84356132b381612df5565b935060208501356132c381612df5565b925060408501359150606085013567ffffffffffffffff808211156132e757600080fd5b818701915087601f8301126132fb57600080fd5b81358181111561330d5761330d61327c565b604051601f8201601f19908116603f011681019083821181831017156133355761333561327c565b816040528281528a602084870101111561334e57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b81516001600160a01b0316815260208083015167ffffffffffffffff169082015260408083015115159082015260608083015162ffffff169082015260808101610b92565b600080604083850312156133ca57600080fd5b82356133d581612df5565b91506020830135612e4981612df5565b600181811c908216806133f957607f821691505b60208210810361341957634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b80820180821115610b9257610b9261341f565b634e487b7160e01b600052603260045260246000fd5b8082028115828204841417610b9257610b9261341f565b60008261349257634e487b7160e01b600052601260045260246000fd5b500490565b6000602082840312156134a957600080fd5b5051919050565b6000602082840312156134c257600080fd5b815161222481613003565b601f821115611205576000816000526020600020601f850160051c810160208610156134f65750805b601f850160051c820191505b8181101561351557828155600101613502565b505050505050565b67ffffffffffffffff8311156135355761353561327c565b6135498361354383546133e5565b836134cd565b6000601f84116001811461357d57600085156135655750838201355b600019600387901b1c1916600186901b178355612656565b600083815260209020601f19861690835b828110156135ae578685013582556020948501946001909201910161358e565b50868210156135cb5760001960f88860031b161c19848701351681555b505060018560011b0183555050505050565b61ffff8181168382160190808211156135f8576135f861341f565b5092915050565b60008351613611818460208801612e54565b835190830190613625818360208801612e54565b7f2e6a736f6e0000000000000000000000000000000000000000000000000000009101908152600501949350505050565b6000816136655761366561341f565b506000190190565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261369f6080830184612e78565b9695505050505050565b6000602082840312156136bb57600080fd5b815161222481612dc256fea2646970667358221220d3433ecc8e436da984123245117fc59ce8f4668bca2237cff508264eb3956bd164736f6c63430008180033

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

00000000000000000000000000000000000000000000000000000000000002ee00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000ec9c58de0a800000000000000000000000000000000000000000000000000000ec9c58de0a800000000000000000000000000000000000000000000000000001140bbd030c4000000000000000000000000000cbc94f1c3578c61137cad3dd7c49fd56fe0720a2

-----Decoded View---------------
Arg [0] : collectionSize_ (uint256): 750
Arg [1] : maxPerWalletUBAllowlist_ (uint256): 2
Arg [2] : maxPerWalletAllowlist_ (uint256): 2
Arg [3] : maxPerWallet_ (uint256): 8
Arg [4] : allowlistUBMintPrice_ (uint256): 66600000000000000
Arg [5] : allowlistMintPrice_ (uint256): 66600000000000000
Arg [6] : publicMintPrice_ (uint256): 77700000000000000
Arg [7] : devAddress_ (address): 0xcBC94F1C3578C61137cAD3dd7C49fd56FE0720A2

-----Encoded View---------------
8 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000002ee
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [4] : 00000000000000000000000000000000000000000000000000ec9c58de0a8000
Arg [5] : 00000000000000000000000000000000000000000000000000ec9c58de0a8000
Arg [6] : 00000000000000000000000000000000000000000000000001140bbd030c4000
Arg [7] : 000000000000000000000000cbc94f1c3578c61137cad3dd7c49fd56fe0720a2


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.