ETH Price: $2,819.10 (+7.62%)
 

Overview

Max Total Supply

748 ASTRO

Holders

204

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A
Balance
3 ASTRO
0xf792f9a01a6Bd1D08301Defc2B0dee9AB2459EB4
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:
DSLAMetaverseAstromancers

Compiler Version
v0.8.16+commit.07a7930e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 18 : DSLAMetaverseAstromancers.sol
// SPDX-License-Identifier: BUSL-1.1
pragma solidity 0.8.16;

import '@openzeppelin/contracts/access/Ownable.sol';
import '@openzeppelin/contracts/utils/Counters.sol';
import '@openzeppelin/contracts/utils/Strings.sol';
import '@openzeppelin/contracts/security/Pausable.sol';
import '@openzeppelin/contracts/token/ERC20/IERC20.sol';
import '@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol';
import '@chainlink/contracts/src/v0.8/VRFConsumerBaseV2.sol';
import '@chainlink/contracts/src/v0.8/interfaces/VRFCoordinatorV2Interface.sol';

contract DSLAMetaverseAstromancers is
    Ownable,
    ERC721Enumerable,
    VRFConsumerBaseV2,
    Pausable
{
    using Counters for Counters.Counter;

    address public DSLA;
    address[] public dTokens;

    uint256 public tokenHoldThreshold;
    uint256 public walletThreshold;
    uint256 public whitelistSlots = 1000;
    uint256 public whitelistMintPeriod = 4 weeks;
    uint256 public maxSupply = 10000;

    string private _baseTokenURI;

    // Chainlink VRF States
    VRFCoordinatorV2Interface public immutable coordinator;
    uint64 public subscriptionId;
    bytes32 public keyHash;

    uint256 totalRequests;
    mapping(uint256 => address) vrfRequests;
    mapping(address => uint256) requestsPerWallet;
    mapping(address => bool) public whitelisted;

    event RequestedRandomness(uint256 requestId);
    event Minted(uint256 tokenId, address account);

    bool public initialized;
    uint256 public startTimestamp;
    uint256[] tokenIdsLeft;

    modifier whenNotStarted() {
        require(!initialized, 'Minting started.');
        _;
    }

    modifier whenStarted() {
        require(initialized, 'Minting not started.');
        _;
    }

    constructor(
        address dsla_,
        address[] memory dTokens_,
        string memory name,
        string memory symbol,
        string memory baseTokenURI,
        uint256 walletThreshold_,
        uint256 tokenHoldThreshold_,
        address vrfCoordinator_,
        bytes32 keyHash_,
        uint64 subscriptionId_
    ) VRFConsumerBaseV2(vrfCoordinator_) ERC721(name, symbol) {
        _baseTokenURI = baseTokenURI;
        walletThreshold = walletThreshold_;

        tokenHoldThreshold = tokenHoldThreshold_;
        DSLA = dsla_;
        dTokens = dTokens_;

        subscriptionId = subscriptionId_;
        keyHash = keyHash_;
        coordinator = VRFCoordinatorV2Interface(vrfCoordinator_);
    }

    function setMaxSupply(uint256 newMaxSupply, uint256 newSlots)
        external
        onlyOwner
        whenNotStarted
    {
        require(newSlots < newMaxSupply, 'Slot allocation exceeds max supply.');
        maxSupply = newMaxSupply;
        whitelistSlots = newSlots;
    }

    function setWhitelistMintPeriod(uint256 newPeriod)
        external
        onlyOwner
        whenNotStarted
    {
        whitelistMintPeriod = newPeriod;
    }

    function whitelistUsers(address[] memory users, bool whitelist)
        external
        onlyOwner
        whenNotStarted
    {
        for (uint256 i = 0; i < users.length; i++) {
            whitelisted[users[i]] = whitelist;
        }
    }

    function initTokenIdIndex(uint256 num)
        external
        onlyOwner
        whenNotStarted
        whenNotPaused
    {
        // Gas fee optimized
        unchecked {
            uint256 index = tokenIdsLeft.length;
            uint256 max = index + num;
            require(
                max <= maxSupply,
                'Token id allocation exceeds max supply.'
            );

            for (uint256 i = index; i < max; i++) {
                tokenIdsLeft.push(i);
            }
        }
    }

    function startMinting() external onlyOwner whenNotStarted {
        require(tokenIdsLeft.length == maxSupply, 'Token ids not initialized.');
        initialized = true;
        startTimestamp = block.timestamp;
    }

    function setBaseURI(string memory baseURI) external onlyOwner {
        _baseTokenURI = baseURI;
    }

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

    function tokenURI(uint256 tokenId)
        public
        view
        virtual
        override
        returns (string memory)
    {
        return string(abi.encodePacked(_baseURI(), Strings.toString(tokenId)));
    }

    function getRemainingSlots() external view returns (uint256) {
        return tokenIdsLeft.length;
    }

    function _checkTokenHolding(address user) internal view returns (bool) {
        // Check DSLA token holding
        if (IERC20(DSLA).balanceOf(user) >= tokenHoldThreshold) return true;

        // Check StakingSLA LP/SP tokens
        for (uint256 i = 0; i < dTokens.length; i++) {
            if (IERC20(dTokens[i]).balanceOf(user) >= tokenHoldThreshold)
                return true;
        }

        return false;
    }

    function mint() external whenStarted {
        require(msg.sender != address(0), 'Invalid user account.');
        require(
            ++requestsPerWallet[msg.sender] <= walletThreshold,
            'exceed limit'
        );
        require(_checkTokenHolding(msg.sender), 'Insufficient token holdings.');
        require(++totalRequests <= maxSupply, 'No available slots to mint.');

        if (whitelisted[msg.sender]) {
            // Should be in guaranteed minting period
            require(
                block.timestamp <= startTimestamp + whitelistMintPeriod,
                'Whitelist has expired.'
            );
            whitelistSlots--;
        } else {
            // Should leave guaranteed slots until guaranteed period expires
            if (block.timestamp <= startTimestamp + whitelistMintPeriod) {
                require(
                    totalRequests <= maxSupply - whitelistSlots,
                    'Remaining minting slots are for whitelisted users.'
                );
            }
        }

        uint256 requestId = coordinator.requestRandomWords(
            keyHash,
            subscriptionId,
            3, // minimumRequestConfirmations
            200000, // callbackGasLimit
            uint32(1) // numWords
        );

        vrfRequests[requestId] = msg.sender;

        emit RequestedRandomness(requestId);
    }

    function fulfillRandomWords(uint256 requestId, uint256[] memory randomWords)
        internal
        override
    {
        address account = vrfRequests[requestId];
        require(account != address(0), 'Invalid user account.');
        uint256 numberOfLeft = tokenIdsLeft.length;
        uint256 indexToMint = randomWords[0] % numberOfLeft;

        // Swap remaining token ids
        uint256 tokenIdToMint = tokenIdsLeft[indexToMint];
        tokenIdsLeft[indexToMint] = tokenIdsLeft[numberOfLeft - 1];
        tokenIdsLeft.pop();

        _safeMint(account, tokenIdToMint);
        vrfRequests[requestId] = address(0);

        emit Minted(tokenIdToMint, account);
    }
}

File 2 of 18 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        _checkOwner();
        _;
    }

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

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

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

File 3 of 18 : Pausable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which allows children to implement an emergency stop
 * mechanism that can be triggered by an authorized account.
 *
 * This module is used through inheritance. It will make available the
 * modifiers `whenNotPaused` and `whenPaused`, which can be applied to
 * the functions of your contract. Note that they will not be pausable by
 * simply including this module, only once the modifiers are put in place.
 */
abstract contract Pausable is Context {
    /**
     * @dev Emitted when the pause is triggered by `account`.
     */
    event Paused(address account);

    /**
     * @dev Emitted when the pause is lifted by `account`.
     */
    event Unpaused(address account);

    bool private _paused;

    /**
     * @dev Initializes the contract in unpaused state.
     */
    constructor() {
        _paused = false;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is not paused.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    modifier whenNotPaused() {
        _requireNotPaused();
        _;
    }

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        _requirePaused();
        _;
    }

    /**
     * @dev Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view virtual returns (bool) {
        return _paused;
    }

    /**
     * @dev Throws if the contract is paused.
     */
    function _requireNotPaused() internal view virtual {
        require(!paused(), "Pausable: paused");
    }

    /**
     * @dev Throws if the contract is not paused.
     */
    function _requirePaused() internal view virtual {
        require(paused(), "Pausable: not paused");
    }

    /**
     * @dev Triggers stopped state.
     *
     * Requirements:
     *
     * - The contract must not be paused.
     */
    function _pause() internal virtual whenNotPaused {
        _paused = true;
        emit Paused(_msgSender());
    }

    /**
     * @dev Returns to normal state.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    function _unpause() internal virtual whenPaused {
        _paused = false;
        emit Unpaused(_msgSender());
    }
}

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

pragma solidity ^0.8.0;

/**
 * @title Counters
 * @author Matt Condon (@shrugs)
 * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number
 * of elements in a mapping, issuing ERC721 ids, or counting request ids.
 *
 * Include with `using Counters for Counters.Counter;`
 */
library Counters {
    struct Counter {
        // This variable should never be directly accessed by users of the library: interactions must be restricted to
        // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
        // this feature: see https://github.com/ethereum/solidity/issues/4637
        uint256 _value; // default: 0
    }

    function current(Counter storage counter) internal view returns (uint256) {
        return counter._value;
    }

    function increment(Counter storage counter) internal {
        unchecked {
            counter._value += 1;
        }
    }

    function decrement(Counter storage counter) internal {
        uint256 value = counter._value;
        require(value > 0, "Counter: decrement overflow");
        unchecked {
            counter._value = value - 1;
        }
    }

    function reset(Counter storage counter) internal {
        counter._value = 0;
    }
}

File 5 of 18 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

File 7 of 18 : VRFConsumerBaseV2.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;

/** ****************************************************************************
 * @notice Interface for contracts using VRF randomness
 * *****************************************************************************
 * @dev PURPOSE
 *
 * @dev Reggie the Random Oracle (not his real job) wants to provide randomness
 * @dev to Vera the verifier in such a way that Vera can be sure he's not
 * @dev making his output up to suit himself. Reggie provides Vera a public key
 * @dev to which he knows the secret key. Each time Vera provides a seed to
 * @dev Reggie, he gives back a value which is computed completely
 * @dev deterministically from the seed and the secret key.
 *
 * @dev Reggie provides a proof by which Vera can verify that the output was
 * @dev correctly computed once Reggie tells it to her, but without that proof,
 * @dev the output is indistinguishable to her from a uniform random sample
 * @dev from the output space.
 *
 * @dev The purpose of this contract is to make it easy for unrelated contracts
 * @dev to talk to Vera the verifier about the work Reggie is doing, to provide
 * @dev simple access to a verifiable source of randomness. It ensures 2 things:
 * @dev 1. The fulfillment came from the VRFCoordinator
 * @dev 2. The consumer contract implements fulfillRandomWords.
 * *****************************************************************************
 * @dev USAGE
 *
 * @dev Calling contracts must inherit from VRFConsumerBase, and can
 * @dev initialize VRFConsumerBase's attributes in their constructor as
 * @dev shown:
 *
 * @dev   contract VRFConsumer {
 * @dev     constructor(<other arguments>, address _vrfCoordinator, address _link)
 * @dev       VRFConsumerBase(_vrfCoordinator) public {
 * @dev         <initialization with other arguments goes here>
 * @dev       }
 * @dev   }
 *
 * @dev The oracle will have given you an ID for the VRF keypair they have
 * @dev committed to (let's call it keyHash). Create subscription, fund it
 * @dev and your consumer contract as a consumer of it (see VRFCoordinatorInterface
 * @dev subscription management functions).
 * @dev Call requestRandomWords(keyHash, subId, minimumRequestConfirmations,
 * @dev callbackGasLimit, numWords),
 * @dev see (VRFCoordinatorInterface for a description of the arguments).
 *
 * @dev Once the VRFCoordinator has received and validated the oracle's response
 * @dev to your request, it will call your contract's fulfillRandomWords method.
 *
 * @dev The randomness argument to fulfillRandomWords is a set of random words
 * @dev generated from your requestId and the blockHash of the request.
 *
 * @dev If your contract could have concurrent requests open, you can use the
 * @dev requestId returned from requestRandomWords to track which response is associated
 * @dev with which randomness request.
 * @dev See "SECURITY CONSIDERATIONS" for principles to keep in mind,
 * @dev if your contract could have multiple requests in flight simultaneously.
 *
 * @dev Colliding `requestId`s are cryptographically impossible as long as seeds
 * @dev differ.
 *
 * *****************************************************************************
 * @dev SECURITY CONSIDERATIONS
 *
 * @dev A method with the ability to call your fulfillRandomness method directly
 * @dev could spoof a VRF response with any random value, so it's critical that
 * @dev it cannot be directly called by anything other than this base contract
 * @dev (specifically, by the VRFConsumerBase.rawFulfillRandomness method).
 *
 * @dev For your users to trust that your contract's random behavior is free
 * @dev from malicious interference, it's best if you can write it so that all
 * @dev behaviors implied by a VRF response are executed *during* your
 * @dev fulfillRandomness method. If your contract must store the response (or
 * @dev anything derived from it) and use it later, you must ensure that any
 * @dev user-significant behavior which depends on that stored value cannot be
 * @dev manipulated by a subsequent VRF request.
 *
 * @dev Similarly, both miners and the VRF oracle itself have some influence
 * @dev over the order in which VRF responses appear on the blockchain, so if
 * @dev your contract could have multiple VRF requests in flight simultaneously,
 * @dev you must ensure that the order in which the VRF responses arrive cannot
 * @dev be used to manipulate your contract's user-significant behavior.
 *
 * @dev Since the block hash of the block which contains the requestRandomness
 * @dev call is mixed into the input to the VRF *last*, a sufficiently powerful
 * @dev miner could, in principle, fork the blockchain to evict the block
 * @dev containing the request, forcing the request to be included in a
 * @dev different block with a different hash, and therefore a different input
 * @dev to the VRF. However, such an attack would incur a substantial economic
 * @dev cost. This cost scales with the number of blocks the VRF oracle waits
 * @dev until it calls responds to a request. It is for this reason that
 * @dev that you can signal to an oracle you'd like them to wait longer before
 * @dev responding to the request (however this is not enforced in the contract
 * @dev and so remains effective only in the case of unmodified oracle software).
 */
abstract contract VRFConsumerBaseV2 {
  error OnlyCoordinatorCanFulfill(address have, address want);
  address private immutable vrfCoordinator;

  /**
   * @param _vrfCoordinator address of VRFCoordinator contract
   */
  constructor(address _vrfCoordinator) {
    vrfCoordinator = _vrfCoordinator;
  }

  /**
   * @notice fulfillRandomness handles the VRF response. Your contract must
   * @notice implement it. See "SECURITY CONSIDERATIONS" above for important
   * @notice principles to keep in mind when implementing your fulfillRandomness
   * @notice method.
   *
   * @dev VRFConsumerBaseV2 expects its subcontracts to have a method with this
   * @dev signature, and will call it once it has verified the proof
   * @dev associated with the randomness. (It is triggered via a call to
   * @dev rawFulfillRandomness, below.)
   *
   * @param requestId The Id initially returned by requestRandomness
   * @param randomWords the VRF output expanded to the requested number of words
   */
  function fulfillRandomWords(uint256 requestId, uint256[] memory randomWords) internal virtual;

  // rawFulfillRandomness is called by VRFCoordinator when it receives a valid VRF
  // proof. rawFulfillRandomness then calls fulfillRandomness, after validating
  // the origin of the call
  function rawFulfillRandomWords(uint256 requestId, uint256[] memory randomWords) external {
    if (msg.sender != vrfCoordinator) {
      revert OnlyCoordinatorCanFulfill(msg.sender, vrfCoordinator);
    }
    fulfillRandomWords(requestId, randomWords);
  }
}

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

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 9 of 18 : VRFCoordinatorV2Interface.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;

interface VRFCoordinatorV2Interface {
  /**
   * @notice Get configuration relevant for making requests
   * @return minimumRequestConfirmations global min for request confirmations
   * @return maxGasLimit global max for request gas limit
   * @return s_provingKeyHashes list of registered key hashes
   */
  function getRequestConfig()
    external
    view
    returns (
      uint16,
      uint32,
      bytes32[] memory
    );

  /**
   * @notice Request a set of random words.
   * @param keyHash - Corresponds to a particular oracle job which uses
   * that key for generating the VRF proof. Different keyHash's have different gas price
   * ceilings, so you can select a specific one to bound your maximum per request cost.
   * @param subId  - The ID of the VRF subscription. Must be funded
   * with the minimum subscription balance required for the selected keyHash.
   * @param minimumRequestConfirmations - How many blocks you'd like the
   * oracle to wait before responding to the request. See SECURITY CONSIDERATIONS
   * for why you may want to request more. The acceptable range is
   * [minimumRequestBlockConfirmations, 200].
   * @param callbackGasLimit - How much gas you'd like to receive in your
   * fulfillRandomWords callback. Note that gasleft() inside fulfillRandomWords
   * may be slightly less than this amount because of gas used calling the function
   * (argument decoding etc.), so you may need to request slightly more than you expect
   * to have inside fulfillRandomWords. The acceptable range is
   * [0, maxGasLimit]
   * @param numWords - The number of uint256 random values you'd like to receive
   * in your fulfillRandomWords callback. Note these numbers are expanded in a
   * secure way by the VRFCoordinator from a single random value supplied by the oracle.
   * @return requestId - A unique identifier of the request. Can be used to match
   * a request to a response in fulfillRandomWords.
   */
  function requestRandomWords(
    bytes32 keyHash,
    uint64 subId,
    uint16 minimumRequestConfirmations,
    uint32 callbackGasLimit,
    uint32 numWords
  ) external returns (uint256 requestId);

  /**
   * @notice Create a VRF subscription.
   * @return subId - A unique subscription id.
   * @dev You can manage the consumer set dynamically with addConsumer/removeConsumer.
   * @dev Note to fund the subscription, use transferAndCall. For example
   * @dev  LINKTOKEN.transferAndCall(
   * @dev    address(COORDINATOR),
   * @dev    amount,
   * @dev    abi.encode(subId));
   */
  function createSubscription() external returns (uint64 subId);

  /**
   * @notice Get a VRF subscription.
   * @param subId - ID of the subscription
   * @return balance - LINK balance of the subscription in juels.
   * @return reqCount - number of requests for this subscription, determines fee tier.
   * @return owner - owner of the subscription.
   * @return consumers - list of consumer address which are able to use this subscription.
   */
  function getSubscription(uint64 subId)
    external
    view
    returns (
      uint96 balance,
      uint64 reqCount,
      address owner,
      address[] memory consumers
    );

  /**
   * @notice Request subscription owner transfer.
   * @param subId - ID of the subscription
   * @param newOwner - proposed new owner of the subscription
   */
  function requestSubscriptionOwnerTransfer(uint64 subId, address newOwner) external;

  /**
   * @notice Request subscription owner transfer.
   * @param subId - ID of the subscription
   * @dev will revert if original owner of subId has
   * not requested that msg.sender become the new owner.
   */
  function acceptSubscriptionOwnerTransfer(uint64 subId) external;

  /**
   * @notice Add a consumer to a VRF subscription.
   * @param subId - ID of the subscription
   * @param consumer - New consumer which can use the subscription
   */
  function addConsumer(uint64 subId, address consumer) external;

  /**
   * @notice Remove a consumer from a VRF subscription.
   * @param subId - ID of the subscription
   * @param consumer - Consumer to remove from the subscription
   */
  function removeConsumer(uint64 subId, address consumer) external;

  /**
   * @notice Cancel a subscription
   * @param subId - ID of the subscription
   * @param to - Where to send the remaining LINK to
   */
  function cancelSubscription(uint64 subId, address to) external;

  /*
   * @notice Check to see if there exists a request commitment consumers
   * for all consumers and keyhashes for a given sub.
   * @param subId - ID of the subscription
   * @return true if there exists at least one unfulfilled request for the subscription, false
   * otherwise.
   */
  function pendingRequestExists(uint64 subId) external view returns (bool);
}

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

pragma solidity ^0.8.0;

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

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

File 11 of 18 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

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

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

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

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

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

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

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

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

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

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

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

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

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

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        _requireMinted(tokenId);

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

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

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

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

        _approve(to, tokenId);
    }

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

        return _tokenApprovals[tokenId];
    }

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

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

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

        _transfer(from, to, tokenId);
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        _beforeTokenTransfer(from, to, tokenId);

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

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

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

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

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

    /**
     * @dev Reverts if the `tokenId` has not been minted yet.
     */
    function _requireMinted(uint256 tokenId) internal view virtual {
        require(_exists(tokenId), "ERC721: invalid token ID");
    }

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

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

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

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

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

File 13 of 18 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (utils/Address.sol)

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 14 of 18 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

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

File 15 of 18 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

pragma solidity ^0.8.0;

import "../IERC721.sol";

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

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

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

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

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

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

pragma solidity ^0.8.0;

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

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"dsla_","type":"address"},{"internalType":"address[]","name":"dTokens_","type":"address[]"},{"internalType":"string","name":"name","type":"string"},{"internalType":"string","name":"symbol","type":"string"},{"internalType":"string","name":"baseTokenURI","type":"string"},{"internalType":"uint256","name":"walletThreshold_","type":"uint256"},{"internalType":"uint256","name":"tokenHoldThreshold_","type":"uint256"},{"internalType":"address","name":"vrfCoordinator_","type":"address"},{"internalType":"bytes32","name":"keyHash_","type":"bytes32"},{"internalType":"uint64","name":"subscriptionId_","type":"uint64"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"have","type":"address"},{"internalType":"address","name":"want","type":"address"}],"name":"OnlyCoordinatorCanFulfill","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":false,"internalType":"uint256","name":"tokenId","type":"uint256"},{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Minted","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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"requestId","type":"uint256"}],"name":"RequestedRandomness","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"DSLA","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"coordinator","outputs":[{"internalType":"contract VRFCoordinatorV2Interface","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"dTokens","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getRemainingSlots","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"num","type":"uint256"}],"name":"initTokenIdIndex","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"initialized","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"keyHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"requestId","type":"uint256"},{"internalType":"uint256[]","name":"randomWords","type":"uint256[]"}],"name":"rawFulfillRandomWords","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"baseURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newMaxSupply","type":"uint256"},{"internalType":"uint256","name":"newSlots","type":"uint256"}],"name":"setMaxSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newPeriod","type":"uint256"}],"name":"setWhitelistMintPeriod","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startMinting","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"subscriptionId","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tokenHoldThreshold","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"walletThreshold","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistMintPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistSlots","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"users","type":"address[]"},{"internalType":"bool","name":"whitelist","type":"bool"}],"name":"whitelistUsers","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelisted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]

60c06040526103e8600f556224ea006010556127106011553480156200002457600080fd5b5060405162002f0e38038062002f0e833981016040819052620000479162000384565b828888620000553362000117565b600162000063838262000524565b50600262000072828262000524565b5050506001600160a01b0316608052600b805460ff19169055601262000099878262000524565b50600e859055600d849055600b8054610100600160a81b0319166101006001600160a01b038d16021790558851620000d990600c9060208c019062000167565b50601380546001600160401b0319166001600160401b03929092169190911790556014556001600160a01b031660a05250620005f095505050505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b828054828255906000526020600020908101928215620001bf579160200282015b82811115620001bf57825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019062000188565b50620001cd929150620001d1565b5090565b5b80821115620001cd5760008155600101620001d2565b80516001600160a01b03811681146200020057600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000246576200024662000205565b604052919050565b600082601f8301126200026057600080fd5b815160206001600160401b038211156200027e576200027e62000205565b8160051b6200028f8282016200021b565b9283528481018201928281019087851115620002aa57600080fd5b83870192505b84831015620002d457620002c483620001e8565b82529183019190830190620002b0565b979650505050505050565b600082601f830112620002f157600080fd5b81516001600160401b038111156200030d576200030d62000205565b602062000323601f8301601f191682016200021b565b82815285828487010111156200033857600080fd5b60005b83811015620003585785810183015182820184015282016200033b565b506000928101909101919091529392505050565b80516001600160401b03811681146200020057600080fd5b6000806000806000806000806000806101408b8d031215620003a557600080fd5b620003b08b620001e8565b60208c0151909a506001600160401b0380821115620003ce57600080fd5b620003dc8e838f016200024e565b9a5060408d0151915080821115620003f357600080fd5b620004018e838f01620002df565b995060608d01519150808211156200041857600080fd5b620004268e838f01620002df565b985060808d01519150808211156200043d57600080fd5b506200044c8d828e01620002df565b96505060a08b0151945060c08b015193506200046b60e08c01620001e8565b92506101008b01519150620004846101208c016200036c565b90509295989b9194979a5092959850565b600181811c90821680620004aa57607f821691505b602082108103620004cb57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200051f57600081815260208120601f850160051c81016020861015620004fa5750805b601f850160051c820191505b818110156200051b5782815560010162000506565b5050505b505050565b81516001600160401b0381111562000540576200054062000205565b620005588162000551845462000495565b84620004d1565b602080601f831160018114620005905760008415620005775750858301515b600019600386901b1c1916600185901b1785556200051b565b600085815260208120601f198616915b82811015620005c157888601518255948401946001909101908401620005a0565b5085821015620005e05787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a0516128ea62000624600039600081816103120152610a9a015260008181610b780152610bba01526128ea6000f3fe608060405234801561001057600080fd5b506004361061025e5760003560e01c80635c975abb116101465780639a65ea26116100c3578063c87b56dd11610087578063c87b56dd146104f9578063d5abeb011461050c578063d936547e14610515578063e6fd48bc14610538578063e985e9c514610541578063f2fde38b1461057d57600080fd5b80639a65ea26146104b0578063a22cb465146104b8578063aab71bcf146104cb578063b88d4fde146104d3578063bb210fc0146104e657600080fd5b8063715018a61161010a578063715018a6146104735780638046e8301461047b57806382d1059b1461048e5780638da5cb5b1461049757806395d89b41146104a857600080fd5b80635c975abb1461042657806361728f39146104315780636352211e1461043a5780636a0d50111461044d57806370a082311461046057600080fd5b80631fe543e3116101df57806337da577c116101a357806337da577c146103be57806342842e0e146103d15780634f6ccce7146103e457806350f13709146103f757806355f804b31461040a57806356b224f21461041d57600080fd5b80631fe543e31461037357806323b872dd1461038657806323f68d87146103995780632f745c59146103a2578063347c51e6146103b557600080fd5b80630a009097116102265780630a0090971461030d5780631249c58b14610334578063158ef93e1461033c57806318160ddd146103495780631eb062e41461035b57600080fd5b806301ffc9a71461026357806306fdde031461028b578063081812fc146102a0578063095ea7b3146102cb57806309c1ba2e146102e0575b600080fd5b61027661027136600461208a565b610590565b60405190151581526020015b60405180910390f35b6102936105bb565b60405161028291906120fe565b6102b36102ae366004612111565b61064d565b6040516001600160a01b039091168152602001610282565b6102de6102d9366004612146565b610674565b005b6013546102f49067ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610282565b6102b37f000000000000000000000000000000000000000000000000000000000000000081565b6102de61078e565b6019546102769060ff1681565b6009545b604051908152602001610282565b600b546102b39061010090046001600160a01b031681565b6102de6103813660046121db565b610b6d565b6102de61039436600461227d565b610bf5565b61034d600e5481565b61034d6103b0366004612146565b610c26565b61034d600f5481565b6102de6103cc3660046122b9565b610cbc565b6102de6103df36600461227d565b610d4d565b61034d6103f2366004612111565b610d68565b6102de6104053660046122eb565b610dfb565b6102de6104183660046123ed565b610e8d565b61034d60105481565b600b5460ff16610276565b61034d60145481565b6102b3610448366004612111565b610ea1565b6102de61045b366004612111565b610f01565b61034d61046e366004612436565b610fe9565b6102de61106f565b6102b3610489366004612111565b611083565b61034d600d5481565b6000546001600160a01b03166102b3565b6102936110ad565b6102de6110bc565b6102de6104c6366004612451565b61114d565b601b5461034d565b6102de6104e1366004612484565b611158565b6102de6104f4366004612111565b61118a565b610293610507366004612111565b6111ba565b61034d60115481565b610276610523366004612436565b60186020526000908152604090205460ff1681565b61034d601a5481565b61027661054f366004612500565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b6102de61058b366004612436565b6111f4565b60006001600160e01b0319821663780e9d6360e01b14806105b557506105b58261126d565b92915050565b6060600180546105ca9061252a565b80601f01602080910402602001604051908101604052809291908181526020018280546105f69061252a565b80156106435780601f1061061857610100808354040283529160200191610643565b820191906000526020600020905b81548152906001019060200180831161062657829003601f168201915b5050505050905090565b6000610658826112bd565b506000908152600560205260409020546001600160a01b031690565b600061067f82610ea1565b9050806001600160a01b0316836001600160a01b0316036106f15760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b038216148061070d575061070d813361054f565b61077f5760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c000060648201526084016106e8565b610789838361131c565b505050565b60195460ff166107d75760405162461bcd60e51b815260206004820152601460248201527326b4b73a34b733903737ba1039ba30b93a32b21760611b60448201526064016106e8565b3361081c5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103ab9b2b91030b1b1b7bab73a1760591b60448201526064016106e8565b600e54336000908152601760205260408120805490919061083c9061257a565b9182905550111561087e5760405162461bcd60e51b815260206004820152600c60248201526b195e18d95959081b1a5b5a5d60a21b60448201526064016106e8565b6108873361138a565b6108d35760405162461bcd60e51b815260206004820152601c60248201527f496e73756666696369656e7420746f6b656e20686f6c64696e67732e0000000060448201526064016106e8565b6011546015600081546108e59061257a565b918290555011156109385760405162461bcd60e51b815260206004820152601b60248201527f4e6f20617661696c61626c6520736c6f747320746f206d696e742e000000000060448201526064016106e8565b3360009081526018602052604090205460ff16156109c257601054601a546109609190612593565b4211156109a85760405162461bcd60e51b81526020600482015260166024820152752bb434ba32b634b9ba103430b99032bc3834b932b21760511b60448201526064016106e8565b600f80549060006109b8836125a6565b9190505550610a54565b601054601a546109d29190612593565b4211610a5457600f546011546109e891906125bd565b6015541115610a545760405162461bcd60e51b815260206004820152603260248201527f52656d61696e696e67206d696e74696e6720736c6f74732061726520666f72206044820152713bb434ba32b634b9ba32b2103ab9b2b9399760711b60648201526084016106e8565b6014546013546040516305d3b1d360e41b8152600481019290925267ffffffffffffffff1660248201526003604482015262030d406064820152600160848201526000907f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031690635d3b1d309060a4016020604051808303816000875af1158015610aeb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b0f91906125d0565b6000818152601660205260409081902080546001600160a01b03191633179055519091507f5d7d0431c4991fcc9f63f03ad0ead4128b866a8ed115a818b6d87a3afedb726490610b629083815260200190565b60405180910390a150565b336001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001614610be75760405163073e64fd60e21b81523360048201526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001660248201526044016106e8565b610bf182826114d2565b5050565b610bff3382611669565b610c1b5760405162461bcd60e51b81526004016106e8906125e9565b6107898383836116e8565b6000610c3183610fe9565b8210610c935760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b60648201526084016106e8565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b610cc461188f565b60195460ff1615610ce75760405162461bcd60e51b81526004016106e890612637565b818110610d425760405162461bcd60e51b815260206004820152602360248201527f536c6f7420616c6c6f636174696f6e2065786365656473206d61782073757070604482015262363c9760e91b60648201526084016106e8565b601191909155600f55565b61078983838360405180602001604052806000815250611158565b6000610d7360095490565b8210610dd65760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b60648201526084016106e8565b60098281548110610de957610de9612661565b90600052602060002001549050919050565b610e0361188f565b60195460ff1615610e265760405162461bcd60e51b81526004016106e890612637565b60005b8251811015610789578160186000858481518110610e4957610e49612661565b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff191691151591909117905580610e858161257a565b915050610e29565b610e9561188f565b6012610bf182826126c5565b6000818152600360205260408120546001600160a01b0316806105b55760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016106e8565b610f0961188f565b60195460ff1615610f2c5760405162461bcd60e51b81526004016106e890612637565b610f346118e9565b601b5460115482820190811115610f9d5760405162461bcd60e51b815260206004820152602760248201527f546f6b656e20696420616c6c6f636174696f6e2065786365656473206d61782060448201526639bab838363c9760c91b60648201526084016106e8565b815b81811015610fe357601b8054600181810183556000929092527f3ad8aa4f87544323a9d1e5dd902f40c356527a7955687113db5f9a85ad579dc10182905501610f9f565b50505050565b60006001600160a01b0382166110535760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016106e8565b506001600160a01b031660009081526004602052604090205490565b61107761188f565b611081600061192f565b565b600c818154811061109357600080fd5b6000918252602090912001546001600160a01b0316905081565b6060600280546105ca9061252a565b6110c461188f565b60195460ff16156110e75760405162461bcd60e51b81526004016106e890612637565b601154601b541461113a5760405162461bcd60e51b815260206004820152601a60248201527f546f6b656e20696473206e6f7420696e697469616c697a65642e00000000000060448201526064016106e8565b6019805460ff1916600117905542601a55565b610bf133838361197f565b6111623383611669565b61117e5760405162461bcd60e51b81526004016106e8906125e9565b610fe384848484611a4d565b61119261188f565b60195460ff16156111b55760405162461bcd60e51b81526004016106e890612637565b601055565b60606111c4611a80565b6111cd83611a8f565b6040516020016111de929190612785565b6040516020818303038152906040529050919050565b6111fc61188f565b6001600160a01b0381166112615760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016106e8565b61126a8161192f565b50565b60006001600160e01b031982166380ac58cd60e01b148061129e57506001600160e01b03198216635b5e139f60e01b145b806105b557506301ffc9a760e01b6001600160e01b03198316146105b5565b6000818152600360205260409020546001600160a01b031661126a5760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016106e8565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061135182610ea1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600d54600b546040516370a0823160e01b81526001600160a01b03848116600483015260009392610100900416906370a0823190602401602060405180830381865afa1580156113de573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061140291906125d0565b1061140f57506001919050565b60005b600c548110156114c957600d54600c828154811061143257611432612661565b6000918252602090912001546040516370a0823160e01b81526001600160a01b038681166004830152909116906370a0823190602401602060405180830381865afa158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a991906125d0565b106114b75750600192915050565b806114c18161257a565b915050611412565b50600092915050565b6000828152601660205260409020546001600160a01b03168061152f5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103ab9b2b91030b1b1b7bab73a1760591b60448201526064016106e8565b601b54825160009082908590839061154957611549612661565b602002602001015161155b91906127ca565b90506000601b828154811061157257611572612661565b90600052602060002001549050601b60018461158e91906125bd565b8154811061159e5761159e612661565b9060005260206000200154601b83815481106115bc576115bc612661565b600091825260209091200155601b8054806115d9576115d96127de565b600190038181906000526020600020016000905590556115f98482611b90565b6000868152601660205260409081902080546001600160a01b0319169055517fb9203d657e9c0ec8274c818292ab0f58b04e1970050716891770eb1bab5d655e9061165990839087909182526001600160a01b0316602082015260400190565b60405180910390a1505050505050565b60008061167583610ea1565b9050806001600160a01b0316846001600160a01b031614806116bc57506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff165b806116e05750836001600160a01b03166116d58461064d565b6001600160a01b0316145b949350505050565b826001600160a01b03166116fb82610ea1565b6001600160a01b03161461175f5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b60648201526084016106e8565b6001600160a01b0382166117c15760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016106e8565b6117cc838383611baa565b6117d760008261131c565b6001600160a01b03831660009081526004602052604081208054600192906118009084906125bd565b90915550506001600160a01b038216600090815260046020526040812080546001929061182e908490612593565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000546001600160a01b031633146110815760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016106e8565b600b5460ff16156110815760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016106e8565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b816001600160a01b0316836001600160a01b0316036119e05760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016106e8565b6001600160a01b03838116600081815260066020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b611a588484846116e8565b611a6484848484611c62565b610fe35760405162461bcd60e51b81526004016106e8906127f4565b6060601280546105ca9061252a565b606081600003611ab65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611ae05780611aca8161257a565b9150611ad99050600a83612846565b9150611aba565b60008167ffffffffffffffff811115611afb57611afb612170565b6040519080825280601f01601f191660200182016040528015611b25576020820181803683370190505b5090505b84156116e057611b3a6001836125bd565b9150611b47600a866127ca565b611b52906030612593565b60f81b818381518110611b6757611b67612661565b60200101906001600160f81b031916908160001a905350611b89600a86612846565b9450611b29565b610bf1828260405180602001604052806000815250611d63565b6001600160a01b038316611c0557611c0081600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b611c28565b816001600160a01b0316836001600160a01b031614611c2857611c288382611d96565b6001600160a01b038216611c3f5761078981611e33565b826001600160a01b0316826001600160a01b031614610789576107898282611ee2565b60006001600160a01b0384163b15611d5857604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ca690339089908890889060040161285a565b6020604051808303816000875af1925050508015611ce1575060408051601f3d908101601f19168201909252611cde91810190612897565b60015b611d3e573d808015611d0f576040519150601f19603f3d011682016040523d82523d6000602084013e611d14565b606091505b508051600003611d365760405162461bcd60e51b81526004016106e8906127f4565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506116e0565b506001949350505050565b611d6d8383611f26565b611d7a6000848484611c62565b6107895760405162461bcd60e51b81526004016106e8906127f4565b60006001611da384610fe9565b611dad91906125bd565b600083815260086020526040902054909150808214611e00576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090611e45906001906125bd565b6000838152600a602052604081205460098054939450909284908110611e6d57611e6d612661565b906000526020600020015490508060098381548110611e8e57611e8e612661565b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480611ec657611ec66127de565b6001900381819060005260206000200160009055905550505050565b6000611eed83610fe9565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b6001600160a01b038216611f7c5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016106e8565b6000818152600360205260409020546001600160a01b031615611fe15760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016106e8565b611fed60008383611baa565b6001600160a01b0382166000908152600460205260408120805460019290612016908490612593565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b03198116811461126a57600080fd5b60006020828403121561209c57600080fd5b81356120a781612074565b9392505050565b60005b838110156120c95781810151838201526020016120b1565b50506000910152565b600081518084526120ea8160208601602086016120ae565b601f01601f19169290920160200192915050565b6020815260006120a760208301846120d2565b60006020828403121561212357600080fd5b5035919050565b80356001600160a01b038116811461214157600080fd5b919050565b6000806040838503121561215957600080fd5b6121628361212a565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156121af576121af612170565b604052919050565b600067ffffffffffffffff8211156121d1576121d1612170565b5060051b60200190565b600080604083850312156121ee57600080fd5b8235915060208084013567ffffffffffffffff81111561220d57600080fd5b8401601f8101861361221e57600080fd5b803561223161222c826121b7565b612186565b81815260059190911b8201830190838101908883111561225057600080fd5b928401925b8284101561226e57833582529284019290840190612255565b80955050505050509250929050565b60008060006060848603121561229257600080fd5b61229b8461212a565b92506122a96020850161212a565b9150604084013590509250925092565b600080604083850312156122cc57600080fd5b50508035926020909101359150565b8035801515811461214157600080fd5b600080604083850312156122fe57600080fd5b823567ffffffffffffffff81111561231557600080fd5b8301601f8101851361232657600080fd5b8035602061233661222c836121b7565b82815260059290921b8301810191818101908884111561235557600080fd5b938201935b8385101561237a5761236b8561212a565b8252938201939082019061235a565b955061238990508682016122db565b93505050509250929050565b600067ffffffffffffffff8311156123af576123af612170565b6123c2601f8401601f1916602001612186565b90508281528383830111156123d657600080fd5b828260208301376000602084830101529392505050565b6000602082840312156123ff57600080fd5b813567ffffffffffffffff81111561241657600080fd5b8201601f8101841361242757600080fd5b6116e084823560208401612395565b60006020828403121561244857600080fd5b6120a78261212a565b6000806040838503121561246457600080fd5b61246d8361212a565b915061247b602084016122db565b90509250929050565b6000806000806080858703121561249a57600080fd5b6124a38561212a565b93506124b16020860161212a565b925060408501359150606085013567ffffffffffffffff8111156124d457600080fd5b8501601f810187136124e557600080fd5b6124f487823560208401612395565b91505092959194509250565b6000806040838503121561251357600080fd5b61251c8361212a565b915061247b6020840161212a565b600181811c9082168061253e57607f821691505b60208210810361255e57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b60006001820161258c5761258c612564565b5060010190565b808201808211156105b5576105b5612564565b6000816125b5576125b5612564565b506000190190565b818103818111156105b5576105b5612564565b6000602082840312156125e257600080fd5b5051919050565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b60208082526010908201526f26b4b73a34b7339039ba30b93a32b21760811b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b601f82111561078957600081815260208120601f850160051c8101602086101561269e5750805b601f850160051c820191505b818110156126bd578281556001016126aa565b505050505050565b815167ffffffffffffffff8111156126df576126df612170565b6126f3816126ed845461252a565b84612677565b602080601f83116001811461272857600084156127105750858301515b600019600386901b1c1916600185901b1785556126bd565b600085815260208120601f198616915b8281101561275757888601518255948401946001909101908401612738565b50858210156127755787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b600083516127978184602088016120ae565b8351908301906127ab8183602088016120ae565b01949350505050565b634e487b7160e01b600052601260045260246000fd5b6000826127d9576127d96127b4565b500690565b634e487b7160e01b600052603160045260246000fd5b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b600082612855576128556127b4565b500490565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061288d908301846120d2565b9695505050505050565b6000602082840312156128a957600080fd5b81516120a78161207456fea2646970667358221220167f84f7385d00f05e2381e9c1d801f2b07ac604ba4db97fdb7de754e93c07fa64736f6c634300081000330000000000000000000000003affcca64c2a6f4e3b6bd9c64cd2c969efd1ecbe000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000034f086f3b33b68400000000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699098af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef00000000000000000000000000000000000000000000000000000000000002110000000000000000000000000000000000000000000000000000000000000002000000000000000000000000ac104c0438a7bb15c714503537c6fa271fdb284e000000000000000000000000cf4ea46eba95fe3643b6c954d29516d7376913dc000000000000000000000000000000000000000000000000000000000000001144534c4120417374726f6d616e636572730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005415354524f000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005168747470733a2f2f676174657761792e70696e6174612e636c6f75642f697066732f516d6541796d67593257544d59507739503343384145734a734564594c77754b45686d4d376647355478575361732f000000000000000000000000000000

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061025e5760003560e01c80635c975abb116101465780639a65ea26116100c3578063c87b56dd11610087578063c87b56dd146104f9578063d5abeb011461050c578063d936547e14610515578063e6fd48bc14610538578063e985e9c514610541578063f2fde38b1461057d57600080fd5b80639a65ea26146104b0578063a22cb465146104b8578063aab71bcf146104cb578063b88d4fde146104d3578063bb210fc0146104e657600080fd5b8063715018a61161010a578063715018a6146104735780638046e8301461047b57806382d1059b1461048e5780638da5cb5b1461049757806395d89b41146104a857600080fd5b80635c975abb1461042657806361728f39146104315780636352211e1461043a5780636a0d50111461044d57806370a082311461046057600080fd5b80631fe543e3116101df57806337da577c116101a357806337da577c146103be57806342842e0e146103d15780634f6ccce7146103e457806350f13709146103f757806355f804b31461040a57806356b224f21461041d57600080fd5b80631fe543e31461037357806323b872dd1461038657806323f68d87146103995780632f745c59146103a2578063347c51e6146103b557600080fd5b80630a009097116102265780630a0090971461030d5780631249c58b14610334578063158ef93e1461033c57806318160ddd146103495780631eb062e41461035b57600080fd5b806301ffc9a71461026357806306fdde031461028b578063081812fc146102a0578063095ea7b3146102cb57806309c1ba2e146102e0575b600080fd5b61027661027136600461208a565b610590565b60405190151581526020015b60405180910390f35b6102936105bb565b60405161028291906120fe565b6102b36102ae366004612111565b61064d565b6040516001600160a01b039091168152602001610282565b6102de6102d9366004612146565b610674565b005b6013546102f49067ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610282565b6102b37f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e6990981565b6102de61078e565b6019546102769060ff1681565b6009545b604051908152602001610282565b600b546102b39061010090046001600160a01b031681565b6102de6103813660046121db565b610b6d565b6102de61039436600461227d565b610bf5565b61034d600e5481565b61034d6103b0366004612146565b610c26565b61034d600f5481565b6102de6103cc3660046122b9565b610cbc565b6102de6103df36600461227d565b610d4d565b61034d6103f2366004612111565b610d68565b6102de6104053660046122eb565b610dfb565b6102de6104183660046123ed565b610e8d565b61034d60105481565b600b5460ff16610276565b61034d60145481565b6102b3610448366004612111565b610ea1565b6102de61045b366004612111565b610f01565b61034d61046e366004612436565b610fe9565b6102de61106f565b6102b3610489366004612111565b611083565b61034d600d5481565b6000546001600160a01b03166102b3565b6102936110ad565b6102de6110bc565b6102de6104c6366004612451565b61114d565b601b5461034d565b6102de6104e1366004612484565b611158565b6102de6104f4366004612111565b61118a565b610293610507366004612111565b6111ba565b61034d60115481565b610276610523366004612436565b60186020526000908152604090205460ff1681565b61034d601a5481565b61027661054f366004612500565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b6102de61058b366004612436565b6111f4565b60006001600160e01b0319821663780e9d6360e01b14806105b557506105b58261126d565b92915050565b6060600180546105ca9061252a565b80601f01602080910402602001604051908101604052809291908181526020018280546105f69061252a565b80156106435780601f1061061857610100808354040283529160200191610643565b820191906000526020600020905b81548152906001019060200180831161062657829003601f168201915b5050505050905090565b6000610658826112bd565b506000908152600560205260409020546001600160a01b031690565b600061067f82610ea1565b9050806001600160a01b0316836001600160a01b0316036106f15760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b60648201526084015b60405180910390fd5b336001600160a01b038216148061070d575061070d813361054f565b61077f5760405162461bcd60e51b815260206004820152603e60248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f7420746f60448201527f6b656e206f776e6572206e6f7220617070726f76656420666f7220616c6c000060648201526084016106e8565b610789838361131c565b505050565b60195460ff166107d75760405162461bcd60e51b815260206004820152601460248201527326b4b73a34b733903737ba1039ba30b93a32b21760611b60448201526064016106e8565b3361081c5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103ab9b2b91030b1b1b7bab73a1760591b60448201526064016106e8565b600e54336000908152601760205260408120805490919061083c9061257a565b9182905550111561087e5760405162461bcd60e51b815260206004820152600c60248201526b195e18d95959081b1a5b5a5d60a21b60448201526064016106e8565b6108873361138a565b6108d35760405162461bcd60e51b815260206004820152601c60248201527f496e73756666696369656e7420746f6b656e20686f6c64696e67732e0000000060448201526064016106e8565b6011546015600081546108e59061257a565b918290555011156109385760405162461bcd60e51b815260206004820152601b60248201527f4e6f20617661696c61626c6520736c6f747320746f206d696e742e000000000060448201526064016106e8565b3360009081526018602052604090205460ff16156109c257601054601a546109609190612593565b4211156109a85760405162461bcd60e51b81526020600482015260166024820152752bb434ba32b634b9ba103430b99032bc3834b932b21760511b60448201526064016106e8565b600f80549060006109b8836125a6565b9190505550610a54565b601054601a546109d29190612593565b4211610a5457600f546011546109e891906125bd565b6015541115610a545760405162461bcd60e51b815260206004820152603260248201527f52656d61696e696e67206d696e74696e6720736c6f74732061726520666f72206044820152713bb434ba32b634b9ba32b2103ab9b2b9399760711b60648201526084016106e8565b6014546013546040516305d3b1d360e41b8152600481019290925267ffffffffffffffff1660248201526003604482015262030d406064820152600160848201526000907f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699096001600160a01b031690635d3b1d309060a4016020604051808303816000875af1158015610aeb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b0f91906125d0565b6000818152601660205260409081902080546001600160a01b03191633179055519091507f5d7d0431c4991fcc9f63f03ad0ead4128b866a8ed115a818b6d87a3afedb726490610b629083815260200190565b60405180910390a150565b336001600160a01b037f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699091614610be75760405163073e64fd60e21b81523360048201526001600160a01b037f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699091660248201526044016106e8565b610bf182826114d2565b5050565b610bff3382611669565b610c1b5760405162461bcd60e51b81526004016106e8906125e9565b6107898383836116e8565b6000610c3183610fe9565b8210610c935760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b60648201526084016106e8565b506001600160a01b03919091166000908152600760209081526040808320938352929052205490565b610cc461188f565b60195460ff1615610ce75760405162461bcd60e51b81526004016106e890612637565b818110610d425760405162461bcd60e51b815260206004820152602360248201527f536c6f7420616c6c6f636174696f6e2065786365656473206d61782073757070604482015262363c9760e91b60648201526084016106e8565b601191909155600f55565b61078983838360405180602001604052806000815250611158565b6000610d7360095490565b8210610dd65760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b60648201526084016106e8565b60098281548110610de957610de9612661565b90600052602060002001549050919050565b610e0361188f565b60195460ff1615610e265760405162461bcd60e51b81526004016106e890612637565b60005b8251811015610789578160186000858481518110610e4957610e49612661565b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff191691151591909117905580610e858161257a565b915050610e29565b610e9561188f565b6012610bf182826126c5565b6000818152600360205260408120546001600160a01b0316806105b55760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016106e8565b610f0961188f565b60195460ff1615610f2c5760405162461bcd60e51b81526004016106e890612637565b610f346118e9565b601b5460115482820190811115610f9d5760405162461bcd60e51b815260206004820152602760248201527f546f6b656e20696420616c6c6f636174696f6e2065786365656473206d61782060448201526639bab838363c9760c91b60648201526084016106e8565b815b81811015610fe357601b8054600181810183556000929092527f3ad8aa4f87544323a9d1e5dd902f40c356527a7955687113db5f9a85ad579dc10182905501610f9f565b50505050565b60006001600160a01b0382166110535760405162461bcd60e51b815260206004820152602960248201527f4552433732313a2061646472657373207a65726f206973206e6f7420612076616044820152683634b21037bbb732b960b91b60648201526084016106e8565b506001600160a01b031660009081526004602052604090205490565b61107761188f565b611081600061192f565b565b600c818154811061109357600080fd5b6000918252602090912001546001600160a01b0316905081565b6060600280546105ca9061252a565b6110c461188f565b60195460ff16156110e75760405162461bcd60e51b81526004016106e890612637565b601154601b541461113a5760405162461bcd60e51b815260206004820152601a60248201527f546f6b656e20696473206e6f7420696e697469616c697a65642e00000000000060448201526064016106e8565b6019805460ff1916600117905542601a55565b610bf133838361197f565b6111623383611669565b61117e5760405162461bcd60e51b81526004016106e8906125e9565b610fe384848484611a4d565b61119261188f565b60195460ff16156111b55760405162461bcd60e51b81526004016106e890612637565b601055565b60606111c4611a80565b6111cd83611a8f565b6040516020016111de929190612785565b6040516020818303038152906040529050919050565b6111fc61188f565b6001600160a01b0381166112615760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016106e8565b61126a8161192f565b50565b60006001600160e01b031982166380ac58cd60e01b148061129e57506001600160e01b03198216635b5e139f60e01b145b806105b557506301ffc9a760e01b6001600160e01b03198316146105b5565b6000818152600360205260409020546001600160a01b031661126a5760405162461bcd60e51b8152602060048201526018602482015277115490cdcc8c4e881a5b9d985b1a59081d1bdad95b88125160421b60448201526064016106e8565b600081815260056020526040902080546001600160a01b0319166001600160a01b038416908117909155819061135182610ea1565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b600d54600b546040516370a0823160e01b81526001600160a01b03848116600483015260009392610100900416906370a0823190602401602060405180830381865afa1580156113de573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061140291906125d0565b1061140f57506001919050565b60005b600c548110156114c957600d54600c828154811061143257611432612661565b6000918252602090912001546040516370a0823160e01b81526001600160a01b038681166004830152909116906370a0823190602401602060405180830381865afa158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a991906125d0565b106114b75750600192915050565b806114c18161257a565b915050611412565b50600092915050565b6000828152601660205260409020546001600160a01b03168061152f5760405162461bcd60e51b815260206004820152601560248201527424b73b30b634b2103ab9b2b91030b1b1b7bab73a1760591b60448201526064016106e8565b601b54825160009082908590839061154957611549612661565b602002602001015161155b91906127ca565b90506000601b828154811061157257611572612661565b90600052602060002001549050601b60018461158e91906125bd565b8154811061159e5761159e612661565b9060005260206000200154601b83815481106115bc576115bc612661565b600091825260209091200155601b8054806115d9576115d96127de565b600190038181906000526020600020016000905590556115f98482611b90565b6000868152601660205260409081902080546001600160a01b0319169055517fb9203d657e9c0ec8274c818292ab0f58b04e1970050716891770eb1bab5d655e9061165990839087909182526001600160a01b0316602082015260400190565b60405180910390a1505050505050565b60008061167583610ea1565b9050806001600160a01b0316846001600160a01b031614806116bc57506001600160a01b0380821660009081526006602090815260408083209388168352929052205460ff165b806116e05750836001600160a01b03166116d58461064d565b6001600160a01b0316145b949350505050565b826001600160a01b03166116fb82610ea1565b6001600160a01b03161461175f5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b60648201526084016106e8565b6001600160a01b0382166117c15760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b60648201526084016106e8565b6117cc838383611baa565b6117d760008261131c565b6001600160a01b03831660009081526004602052604081208054600192906118009084906125bd565b90915550506001600160a01b038216600090815260046020526040812080546001929061182e908490612593565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6000546001600160a01b031633146110815760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016106e8565b600b5460ff16156110815760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b60448201526064016106e8565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b816001600160a01b0316836001600160a01b0316036119e05760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c65720000000000000060448201526064016106e8565b6001600160a01b03838116600081815260066020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b611a588484846116e8565b611a6484848484611c62565b610fe35760405162461bcd60e51b81526004016106e8906127f4565b6060601280546105ca9061252a565b606081600003611ab65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611ae05780611aca8161257a565b9150611ad99050600a83612846565b9150611aba565b60008167ffffffffffffffff811115611afb57611afb612170565b6040519080825280601f01601f191660200182016040528015611b25576020820181803683370190505b5090505b84156116e057611b3a6001836125bd565b9150611b47600a866127ca565b611b52906030612593565b60f81b818381518110611b6757611b67612661565b60200101906001600160f81b031916908160001a905350611b89600a86612846565b9450611b29565b610bf1828260405180602001604052806000815250611d63565b6001600160a01b038316611c0557611c0081600980546000838152600a60205260408120829055600182018355919091527f6e1540171b6c0c960b71a7020d9f60077f6af931a8bbf590da0223dacf75c7af0155565b611c28565b816001600160a01b0316836001600160a01b031614611c2857611c288382611d96565b6001600160a01b038216611c3f5761078981611e33565b826001600160a01b0316826001600160a01b031614610789576107898282611ee2565b60006001600160a01b0384163b15611d5857604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290611ca690339089908890889060040161285a565b6020604051808303816000875af1925050508015611ce1575060408051601f3d908101601f19168201909252611cde91810190612897565b60015b611d3e573d808015611d0f576040519150601f19603f3d011682016040523d82523d6000602084013e611d14565b606091505b508051600003611d365760405162461bcd60e51b81526004016106e8906127f4565b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490506116e0565b506001949350505050565b611d6d8383611f26565b611d7a6000848484611c62565b6107895760405162461bcd60e51b81526004016106e8906127f4565b60006001611da384610fe9565b611dad91906125bd565b600083815260086020526040902054909150808214611e00576001600160a01b03841660009081526007602090815260408083208584528252808320548484528184208190558352600890915290208190555b5060009182526008602090815260408084208490556001600160a01b039094168352600781528383209183525290812055565b600954600090611e45906001906125bd565b6000838152600a602052604081205460098054939450909284908110611e6d57611e6d612661565b906000526020600020015490508060098381548110611e8e57611e8e612661565b6000918252602080832090910192909255828152600a90915260408082208490558582528120556009805480611ec657611ec66127de565b6001900381819060005260206000200160009055905550505050565b6000611eed83610fe9565b6001600160a01b039093166000908152600760209081526040808320868452825280832085905593825260089052919091209190915550565b6001600160a01b038216611f7c5760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f206164647265737360448201526064016106e8565b6000818152600360205260409020546001600160a01b031615611fe15760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e7465640000000060448201526064016106e8565b611fed60008383611baa565b6001600160a01b0382166000908152600460205260408120805460019290612016908490612593565b909155505060008181526003602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b6001600160e01b03198116811461126a57600080fd5b60006020828403121561209c57600080fd5b81356120a781612074565b9392505050565b60005b838110156120c95781810151838201526020016120b1565b50506000910152565b600081518084526120ea8160208601602086016120ae565b601f01601f19169290920160200192915050565b6020815260006120a760208301846120d2565b60006020828403121561212357600080fd5b5035919050565b80356001600160a01b038116811461214157600080fd5b919050565b6000806040838503121561215957600080fd5b6121628361212a565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff811182821017156121af576121af612170565b604052919050565b600067ffffffffffffffff8211156121d1576121d1612170565b5060051b60200190565b600080604083850312156121ee57600080fd5b8235915060208084013567ffffffffffffffff81111561220d57600080fd5b8401601f8101861361221e57600080fd5b803561223161222c826121b7565b612186565b81815260059190911b8201830190838101908883111561225057600080fd5b928401925b8284101561226e57833582529284019290840190612255565b80955050505050509250929050565b60008060006060848603121561229257600080fd5b61229b8461212a565b92506122a96020850161212a565b9150604084013590509250925092565b600080604083850312156122cc57600080fd5b50508035926020909101359150565b8035801515811461214157600080fd5b600080604083850312156122fe57600080fd5b823567ffffffffffffffff81111561231557600080fd5b8301601f8101851361232657600080fd5b8035602061233661222c836121b7565b82815260059290921b8301810191818101908884111561235557600080fd5b938201935b8385101561237a5761236b8561212a565b8252938201939082019061235a565b955061238990508682016122db565b93505050509250929050565b600067ffffffffffffffff8311156123af576123af612170565b6123c2601f8401601f1916602001612186565b90508281528383830111156123d657600080fd5b828260208301376000602084830101529392505050565b6000602082840312156123ff57600080fd5b813567ffffffffffffffff81111561241657600080fd5b8201601f8101841361242757600080fd5b6116e084823560208401612395565b60006020828403121561244857600080fd5b6120a78261212a565b6000806040838503121561246457600080fd5b61246d8361212a565b915061247b602084016122db565b90509250929050565b6000806000806080858703121561249a57600080fd5b6124a38561212a565b93506124b16020860161212a565b925060408501359150606085013567ffffffffffffffff8111156124d457600080fd5b8501601f810187136124e557600080fd5b6124f487823560208401612395565b91505092959194509250565b6000806040838503121561251357600080fd5b61251c8361212a565b915061247b6020840161212a565b600181811c9082168061253e57607f821691505b60208210810361255e57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b60006001820161258c5761258c612564565b5060010190565b808201808211156105b5576105b5612564565b6000816125b5576125b5612564565b506000190190565b818103818111156105b5576105b5612564565b6000602082840312156125e257600080fd5b5051919050565b6020808252602e908201527f4552433732313a2063616c6c6572206973206e6f7420746f6b656e206f776e6560408201526d1c881b9bdc88185c1c1c9bdd995960921b606082015260800190565b60208082526010908201526f26b4b73a34b7339039ba30b93a32b21760811b604082015260600190565b634e487b7160e01b600052603260045260246000fd5b601f82111561078957600081815260208120601f850160051c8101602086101561269e5750805b601f850160051c820191505b818110156126bd578281556001016126aa565b505050505050565b815167ffffffffffffffff8111156126df576126df612170565b6126f3816126ed845461252a565b84612677565b602080601f83116001811461272857600084156127105750858301515b600019600386901b1c1916600185901b1785556126bd565b600085815260208120601f198616915b8281101561275757888601518255948401946001909101908401612738565b50858210156127755787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b600083516127978184602088016120ae565b8351908301906127ab8183602088016120ae565b01949350505050565b634e487b7160e01b600052601260045260246000fd5b6000826127d9576127d96127b4565b500690565b634e487b7160e01b600052603160045260246000fd5b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b600082612855576128556127b4565b500490565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061288d908301846120d2565b9695505050505050565b6000602082840312156128a957600080fd5b81516120a78161207456fea2646970667358221220167f84f7385d00f05e2381e9c1d801f2b07ac604ba4db97fdb7de754e93c07fa64736f6c63430008100033

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

0000000000000000000000003affcca64c2a6f4e3b6bd9c64cd2c969efd1ecbe000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000034f086f3b33b68400000000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699098af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef00000000000000000000000000000000000000000000000000000000000002110000000000000000000000000000000000000000000000000000000000000002000000000000000000000000ac104c0438a7bb15c714503537c6fa271fdb284e000000000000000000000000cf4ea46eba95fe3643b6c954d29516d7376913dc000000000000000000000000000000000000000000000000000000000000001144534c4120417374726f6d616e636572730000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005415354524f000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000005168747470733a2f2f676174657761792e70696e6174612e636c6f75642f697066732f516d6541796d67593257544d59507739503343384145734a734564594c77754b45686d4d376647355478575361732f000000000000000000000000000000

-----Decoded View---------------
Arg [0] : dsla_ (address): 0x3aFfCCa64c2A6f4e3B6Bd9c64CD2C969EFd1ECBe
Arg [1] : dTokens_ (address[]): 0xAC104C0438A7bb15C714503537c6FA271FDB284E,0xCF4eA46EbA95fe3643b6C954D29516d7376913dC
Arg [2] : name (string): DSLA Astromancers
Arg [3] : symbol (string): ASTRO
Arg [4] : baseTokenURI (string): https://gateway.pinata.cloud/ipfs/QmeAymgY2WTMYPw9P3C8AEsJsEdYLwuKEhmM7fG5TxWSas/
Arg [5] : walletThreshold_ (uint256): 3
Arg [6] : tokenHoldThreshold_ (uint256): 250000000000000000000000
Arg [7] : vrfCoordinator_ (address): 0x271682DEB8C4E0901D1a1550aD2e64D568E69909
Arg [8] : keyHash_ (bytes32): 0x8af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef
Arg [9] : subscriptionId_ (uint64): 529

-----Encoded View---------------
21 Constructor Arguments found :
Arg [0] : 0000000000000000000000003affcca64c2a6f4e3b6bd9c64cd2c969efd1ecbe
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [2] : 00000000000000000000000000000000000000000000000000000000000001a0
Arg [3] : 00000000000000000000000000000000000000000000000000000000000001e0
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000220
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000003
Arg [6] : 0000000000000000000000000000000000000000000034f086f3b33b68400000
Arg [7] : 000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e69909
Arg [8] : 8af398995b04c28e9951adb9721ef74c74f93e6a478f39e7e0777be13527e7ef
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000211
Arg [10] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [11] : 000000000000000000000000ac104c0438a7bb15c714503537c6fa271fdb284e
Arg [12] : 000000000000000000000000cf4ea46eba95fe3643b6c954d29516d7376913dc
Arg [13] : 0000000000000000000000000000000000000000000000000000000000000011
Arg [14] : 44534c4120417374726f6d616e63657273000000000000000000000000000000
Arg [15] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [16] : 415354524f000000000000000000000000000000000000000000000000000000
Arg [17] : 0000000000000000000000000000000000000000000000000000000000000051
Arg [18] : 68747470733a2f2f676174657761792e70696e6174612e636c6f75642f697066
Arg [19] : 732f516d6541796d67593257544d59507739503343384145734a734564594c77
Arg [20] : 754b45686d4d376647355478575361732f000000000000000000000000000000


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.