ETH Price: $2,724.06 (-1.49%)

Contract

0xA298D5abFf9Ed6C32c9794E64eD14394c39AB6cc
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Token Holdings

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Pause153967632022-08-23 13:11:33733 days ago1661260293IN
0xA298D5ab...4c39AB6cc
0 ETH0.000229328.26260979
Set Sale Start D...148989032022-06-03 19:20:42814 days ago1654284042IN
0xA298D5ab...4c39AB6cc
0 ETH0.0018818865.4114163
Set Sale Start D...148986272022-06-03 18:25:02814 days ago1654280702IN
0xA298D5ab...4c39AB6cc
0 ETH0.0014119549.07727702
0x60e06040148983162022-06-03 17:11:35814 days ago1654276295IN
 Create: MirandusExchange
0 ETH0.0641042450.28091189

Latest 1 internal transaction

Advanced mode:
Parent Transaction Hash Block From To
161192952022-12-05 14:47:11629 days ago1670251631
0xA298D5ab...4c39AB6cc
0.07623285 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
MirandusExchange

Compiler Version
v0.8.11+commit.d7f03943

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 16 : MirandusExchange.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/token/ERC1155/IERC1155.sol";
import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol";
import "@openzeppelin/contracts/security/Pausable.sol";
import "@chainlink/contracts/src/v0.8/VRFConsumerBaseV2.sol";
import "@chainlink/contracts/src/v0.8/interfaces/VRFCoordinatorV2Interface.sol";
import "./interfaces/IRandomRewardTable.sol";

contract MirandusExchange is
    Ownable,
    ERC1155Holder,
    Pausable,
    VRFConsumerBaseV2
{  
    event onERC1155ReceivedExecuted(
        uint256 requestId,
        address from,
        uint256 value
    );

    using SafeERC20 for IERC20;

    struct ExchangeRequest {
        address beneficiary;
        uint256 amount;
    }

    VRFCoordinatorV2Interface COORDINATOR;

    uint64 public saleStartTimestamp;

    bytes32 public vrfKeyHash;
    uint64 vrfSubscriptionId;

    address public immutable erc1155Contract;
    uint256 public immutable boxTokenId;
    address public randomRewardAddress;    

    mapping(uint256 => ExchangeRequest) public exchangeRequests;
    mapping(address => uint32) public pendingRequests;

    uint256 public constant maxSupply = 37500;
    uint256 public totalSupply = 0;
    uint256 public MAX_PURCHASE = 1;

    constructor(
        uint64 _saleStartTimestamp,
        address _vrfCoordinator,
        bytes32 _vrfKeyhash,
        uint64 _vrfSubscriptionId,
        address _erc1155Contract,        
        uint256 _boxTokenId,
        address  _randomRewardAddress        
    ) VRFConsumerBaseV2(_vrfCoordinator) {
        vrfKeyHash = _vrfKeyhash;
        vrfSubscriptionId = _vrfSubscriptionId;
        saleStartTimestamp = _saleStartTimestamp;
        erc1155Contract = _erc1155Contract;
        boxTokenId = _boxTokenId;
        randomRewardAddress = _randomRewardAddress;
        COORDINATOR = VRFCoordinatorV2Interface(_vrfCoordinator);
    }

    function onERC1155Received(
        address,
        address from,
        uint256 id,
        uint256 value,
        bytes calldata
    ) public override returns (bytes4) {
        require(block.timestamp >= saleStartTimestamp, "Mirandus Exchange: not started");
        require(
            msg.sender == erc1155Contract,
            "Mirandus Exchange: not Mirandus Exchange contract"
        );
        require(id == boxTokenId, "Mirandus Exchange: not Mirandus Exchange token");
        require(value > 0, "Mirandus Exchange: amount is zero");
        require(from != address(0), "Mirandus Exchange: from is address(0)");
        require(!paused(), "Mirandus Exchange: paused");

        uint256 requestId = COORDINATOR.requestRandomWords(
            vrfKeyHash,
            vrfSubscriptionId,
            3,
            2500000,
            uint32(value)
        );

        exchangeRequests[requestId] = ExchangeRequest(from, value);
        pendingRequests[from] += uint32(value);

        emit onERC1155ReceivedExecuted(requestId, from, value);
        return this.onERC1155Received.selector;
        
    }

    function onERC1155BatchReceived(
        address,
        address,
        uint256[] calldata,
        uint256[] calldata,
        bytes calldata
    ) public pure override returns (bytes4) {
        revert("Mirandus Exchange: Batch Transfer is not allowed");
    }

    function fulfillRandomWords(uint256 requestId, uint256[] memory randomWords)
        internal
        override
    {        
        ExchangeRequest memory request = exchangeRequests[requestId];
        require(request.beneficiary != address(0), "Mirandus Exchange: Invalid request");       

        for (uint256 i = 0; i < request.amount; i++) {
            uint256 randomNumber = randomWords[i];    
            IRandomRewardTable(randomRewardAddress).rewardRandomOne(
                request.beneficiary,
                randomNumber
            );                 
        }                    

        delete exchangeRequests[requestId];
        pendingRequests[request.beneficiary] -= uint32(request.amount);
        totalSupply += request.amount;        
    }

    function pause() external onlyOwner {
        _pause();
    }

    function unpause() external onlyOwner {
        _unpause();
    }

    function setTotalSupply(uint256 _totalSupply) external onlyOwner {
        totalSupply = _totalSupply;
    }

    function updateVrfKeyHash(bytes32 _vrfKeyHash) external onlyOwner {
        vrfKeyHash = _vrfKeyHash;
    }

    function updateVrfSubscriptionId(uint64 _vrfSubscriptionId)
        external
        onlyOwner
    {
        vrfSubscriptionId = _vrfSubscriptionId;
    }

    function getPendingRequests(address addr) public view returns (uint32) {
        return pendingRequests[addr];
    }    

     function setSaleStartDateTime(uint64 _saleStartTimestamp) public onlyOwner {
        saleStartTimestamp = _saleStartTimestamp;
    }

    function setMaxPurchase(uint256 _MAX_PURCHASE) public onlyOwner {
        MAX_PURCHASE = _MAX_PURCHASE;
    }
}

File 2 of 16 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

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

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

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

File 3 of 16 : IERC1155.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/IERC1155.sol)

pragma solidity ^0.8.0;

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

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

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

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

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

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

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

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

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

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

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

File 4 of 16 : IERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/IERC20.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC20 standard as defined in the EIP.
 */
interface IERC20 {
    /**
     * @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 `recipient`.
     *
     * Returns a boolean value indicating whether the operation succeeded.
     *
     * Emits a {Transfer} event.
     */
    function transfer(address recipient, 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 `sender` to `recipient` 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 sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

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

File 5 of 16 : SafeERC20.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol)

pragma solidity ^0.8.0;

import "../IERC20.sol";
import "../../../utils/Address.sol";

/**
 * @title SafeERC20
 * @dev Wrappers around ERC20 operations that throw on failure (when the token
 * contract returns false). Tokens that return no value (and instead revert or
 * throw on failure) are also supported, non-reverting calls are assumed to be
 * successful.
 * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract,
 * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
 */
library SafeERC20 {
    using Address for address;

    function safeTransfer(
        IERC20 token,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
    }

    function safeTransferFrom(
        IERC20 token,
        address from,
        address to,
        uint256 value
    ) internal {
        _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
    }

    /**
     * @dev Deprecated. This function has issues similar to the ones found in
     * {IERC20-approve}, and its usage is discouraged.
     *
     * Whenever possible, use {safeIncreaseAllowance} and
     * {safeDecreaseAllowance} instead.
     */
    function safeApprove(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        // safeApprove should only be called when setting an initial allowance,
        // or when resetting it to zero. To increase and decrease it, use
        // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
        require(
            (value == 0) || (token.allowance(address(this), spender) == 0),
            "SafeERC20: approve from non-zero to non-zero allowance"
        );
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
    }

    function safeIncreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        uint256 newAllowance = token.allowance(address(this), spender) + value;
        _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
    }

    function safeDecreaseAllowance(
        IERC20 token,
        address spender,
        uint256 value
    ) internal {
        unchecked {
            uint256 oldAllowance = token.allowance(address(this), spender);
            require(oldAllowance >= value, "SafeERC20: decreased allowance below zero");
            uint256 newAllowance = oldAllowance - value;
            _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
        }
    }

    /**
     * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
     * on the return value: the return value is optional (but if data is returned, it must not be false).
     * @param token The token targeted by the call.
     * @param data The call data (encoded using abi.encode or one of its variants).
     */
    function _callOptionalReturn(IERC20 token, bytes memory data) private {
        // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
        // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that
        // the target address contains contract code and also asserts for success in the low-level call.

        bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed");
        if (returndata.length > 0) {
            // Return data is optional
            require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed");
        }
    }
}

File 6 of 16 : ERC1155Holder.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/utils/ERC1155Holder.sol)

pragma solidity ^0.8.0;

import "./ERC1155Receiver.sol";

/**
 * @dev _Available since v3.1._
 */
contract ERC1155Holder is ERC1155Receiver {
    function onERC1155Received(
        address,
        address,
        uint256,
        uint256,
        bytes memory
    ) public virtual override returns (bytes4) {
        return this.onERC1155Received.selector;
    }

    function onERC1155BatchReceived(
        address,
        address,
        uint256[] memory,
        uint256[] memory,
        bytes memory
    ) public virtual override returns (bytes4) {
        return this.onERC1155BatchReceived.selector;
    }
}

File 7 of 16 : Pausable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (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 Returns true if the contract is paused, and false otherwise.
     */
    function paused() public view virtual returns (bool) {
        return _paused;
    }

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

    /**
     * @dev Modifier to make a function callable only when the contract is paused.
     *
     * Requirements:
     *
     * - The contract must be paused.
     */
    modifier whenPaused() {
        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 8 of 16 : 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 9 of 16 : 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;
}

File 10 of 16 : IRandomRewardTable.sol
// SPDX-License-Identifier: MIT
pragma solidity 0.8.11;

interface IRandomRewardTable {
    function rewardRandomOne(address _to, uint256 _rand) external;
}

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

pragma solidity ^0.8.0;

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

File 13 of 16 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Address.sol)

pragma solidity ^0.8.0;

/**
 * @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
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize, which returns 0 for contracts in
        // construction, since the code is only stored at the end of the
        // constructor execution.

        uint256 size;
        assembly {
            size := extcodesize(account)
        }
        return size > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 14 of 16 : ERC1155Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC1155/utils/ERC1155Receiver.sol)

pragma solidity ^0.8.0;

import "../IERC1155Receiver.sol";
import "../../../utils/introspection/ERC165.sol";

/**
 * @dev _Available since v3.1._
 */
abstract contract ERC1155Receiver is ERC165, IERC1155Receiver {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return interfaceId == type(IERC1155Receiver).interfaceId || super.supportsInterface(interfaceId);
    }
}

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

pragma solidity ^0.8.0;

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

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

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

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

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"uint64","name":"_saleStartTimestamp","type":"uint64"},{"internalType":"address","name":"_vrfCoordinator","type":"address"},{"internalType":"bytes32","name":"_vrfKeyhash","type":"bytes32"},{"internalType":"uint64","name":"_vrfSubscriptionId","type":"uint64"},{"internalType":"address","name":"_erc1155Contract","type":"address"},{"internalType":"uint256","name":"_boxTokenId","type":"uint256"},{"internalType":"address","name":"_randomRewardAddress","type":"address"}],"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":"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":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"requestId","type":"uint256"},{"indexed":false,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"onERC1155ReceivedExecuted","type":"event"},{"inputs":[],"name":"MAX_PURCHASE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"boxTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"erc1155Contract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"exchangeRequests","outputs":[{"internalType":"address","name":"beneficiary","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getPendingRequests","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155BatchReceived","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"from","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"","type":"bytes"}],"name":"onERC1155Received","outputs":[{"internalType":"bytes4","name":"","type":"bytes4"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"pendingRequests","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"randomRewardAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"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":[],"name":"saleStartTimestamp","outputs":[{"internalType":"uint64","name":"","type":"uint64"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_MAX_PURCHASE","type":"uint256"}],"name":"setMaxPurchase","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_saleStartTimestamp","type":"uint64"}],"name":"setSaleStartDateTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_totalSupply","type":"uint256"}],"name":"setTotalSupply","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_vrfKeyHash","type":"bytes32"}],"name":"updateVrfKeyHash","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_vrfSubscriptionId","type":"uint64"}],"name":"updateVrfSubscriptionId","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"vrfKeyHash","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"}]

60e0604052600060065560016007553480156200001b57600080fd5b5060405162001600380380620016008339810160408190526200003e9162000159565b856200004a33620000d4565b6000805460ff60a01b191690556001600160a01b03908116608052600295909555600380546001805495881660a05260c0949094526001600160401b039586166001600160e01b0319918216176801000000000000000093881693909302929092179055909116600160a01b95909216949094026001600160a01b031916179116179055620001dc565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b80516001600160401b03811681146200013c57600080fd5b919050565b80516001600160a01b03811681146200013c57600080fd5b600080600080600080600060e0888a0312156200017557600080fd5b620001808862000124565b9650620001906020890162000141565b955060408801519450620001a76060890162000124565b9350620001b76080890162000141565b925060a08801519150620001ce60c0890162000141565b905092959891949750929550565b60805160a05160c0516113df620002216000396000818161033e015261081e0152600081816102b901526107950152600081816104a001526104e201526113df6000f3fe608060405234801561001057600080fd5b506004361061018e5760003560e01c80638da5cb5b116100de578063d5abeb0111610097578063f23a6e6111610071578063f23a6e61146103ff578063f2fde38b14610412578063f7ea7a3d14610425578063fb22e6511461043857600080fd5b8063d5abeb011461039f578063ea9d36cc146103a8578063f05bfa7b146103bb57600080fd5b80638da5cb5b146102fb57806398264fa61461030c578063a293eff81461031f578063a7dd255214610339578063bc197c8114610360578063c3fde3db1461038c57600080fd5b80633f4ba83a1161014b5780637146bd08116101255780637146bd08146102a3578063715018a6146102ac5780637a564970146102b45780638456cb59146102f357600080fd5b80633f4ba83a146102765780635c975abb1461027e578063711897421461029057600080fd5b806301ffc9a714610193578063041d443e146101bb57806318160ddd146101d25780631fe543e3146101db5780633bf13b44146101f05780633c276d8614610242575b600080fd5b6101a66101a1366004610f63565b61045e565b60405190151581526020015b60405180910390f35b6101c460025481565b6040519081526020016101b2565b6101c460065481565b6101ee6101e9366004610faa565b610495565b005b6102236101fe366004611074565b600460205260009081526040902080546001909101546001600160a01b039091169082565b604080516001600160a01b0390931683526020830191909152016101b2565b60015461025d90600160a01b900467ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101b2565b6101ee610522565b600054600160a01b900460ff166101a6565b6101ee61029e366004611074565b610556565b6101c460075481565b6101ee610585565b6102db7f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016101b2565b6101ee6105b9565b6000546001600160a01b03166102db565b6101ee61031a366004611074565b6105eb565b6003546102db90600160401b90046001600160a01b031681565b6101c47f000000000000000000000000000000000000000000000000000000000000000081565b61037361036e366004611137565b61061a565b6040516001600160e01b031990911681526020016101b2565b6101ee61039a3660046111f2565b61067e565b6101c461927c81565b6101ee6103b63660046111f2565b6106cc565b6103ea6103c936600461121c565b6001600160a01b031660009081526005602052604090205463ffffffff1690565b60405163ffffffff90911681526020016101b2565b61037361040d366004611237565b610724565b6101ee61042036600461121c565b610b52565b6101ee610433366004611074565b610bed565b6103ea61044636600461121c565b60056020526000908152604090205463ffffffff1681565b60006001600160e01b03198216630271189760e51b148061048f57506301ffc9a760e01b6001600160e01b03198316145b92915050565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146105145760405163073e64fd60e21b81523360048201526001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b61051e8282610c1c565b5050565b6000546001600160a01b0316331461054c5760405162461bcd60e51b815260040161050b906112af565b610554610dee565b565b6000546001600160a01b031633146105805760405162461bcd60e51b815260040161050b906112af565b600755565b6000546001600160a01b031633146105af5760405162461bcd60e51b815260040161050b906112af565b6105546000610e8b565b6000546001600160a01b031633146105e35760405162461bcd60e51b815260040161050b906112af565b610554610edb565b6000546001600160a01b031633146106155760405162461bcd60e51b815260040161050b906112af565b600255565b60405162461bcd60e51b815260206004820152603060248201527f4d6972616e6475732045786368616e67653a204261746368205472616e73666560448201526f1c881a5cc81b9bdd08185b1b1bddd95960821b606482015260009060840161050b565b6000546001600160a01b031633146106a85760405162461bcd60e51b815260040161050b906112af565b6003805467ffffffffffffffff191667ffffffffffffffff92909216919091179055565b6000546001600160a01b031633146106f65760405162461bcd60e51b815260040161050b906112af565b6001805467ffffffffffffffff909216600160a01b0267ffffffffffffffff60a01b19909216919091179055565b600154600090600160a01b900467ffffffffffffffff1642101561078a5760405162461bcd60e51b815260206004820152601e60248201527f4d6972616e6475732045786368616e67653a206e6f7420737461727465640000604482015260640161050b565b336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461081c5760405162461bcd60e51b815260206004820152603160248201527f4d6972616e6475732045786368616e67653a206e6f74204d6972616e64757320604482015270115e18da185b99d94818dbdb9d1c9858dd607a1b606482015260840161050b565b7f000000000000000000000000000000000000000000000000000000000000000085146108a25760405162461bcd60e51b815260206004820152602e60248201527f4d6972616e6475732045786368616e67653a206e6f74204d6972616e6475732060448201526d22bc31b430b733b2903a37b5b2b760911b606482015260840161050b565b600084116108fc5760405162461bcd60e51b815260206004820152602160248201527f4d6972616e6475732045786368616e67653a20616d6f756e74206973207a65726044820152606f60f81b606482015260840161050b565b6001600160a01b0386166109605760405162461bcd60e51b815260206004820152602560248201527f4d6972616e6475732045786368616e67653a2066726f6d206973206164647265604482015264737328302960d81b606482015260840161050b565b600054600160a01b900460ff16156109ba5760405162461bcd60e51b815260206004820152601960248201527f4d6972616e6475732045786368616e67653a2070617573656400000000000000604482015260640161050b565b600154600254600380546040516305d3b1d360e41b8152600481019390935267ffffffffffffffff1660248301526044820152622625a0606482015263ffffffff861660848201526000916001600160a01b031690635d3b1d309060a4016020604051808303816000875af1158015610a37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5b91906112e4565b6040805180820182526001600160a01b038a811680835260208084018b8152600087815260048352868120955186546001600160a01b0319169516949094178555516001909401939093558152600590915290812080549293508792909190610acb90849063ffffffff16611313565b92506101000a81548163ffffffff021916908363ffffffff1602179055507f6e67d52a6deec37ea0760af8c17d9a6c94f902dc418444a34b4ceaef124449e3818887604051610b36939291909283526001600160a01b03919091166020830152604082015260600190565b60405180910390a15063f23a6e6160e01b979650505050505050565b6000546001600160a01b03163314610b7c5760405162461bcd60e51b815260040161050b906112af565b6001600160a01b038116610be15760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161050b565b610bea81610e8b565b50565b6000546001600160a01b03163314610c175760405162461bcd60e51b815260040161050b906112af565b600655565b600082815260046020908152604091829020825180840190935280546001600160a01b031680845260019091015491830191909152610ca85760405162461bcd60e51b815260206004820152602260248201527f4d6972616e6475732045786368616e67653a20496e76616c69642072657175656044820152611cdd60f21b606482015260840161050b565b60005b8160200151811015610d5b576000838281518110610ccb57610ccb61133b565b60209081029190910101516003548451604051636d603f2160e11b81526001600160a01b03918216600482015260248101849052929350600160401b909104169063dac07e4290604401600060405180830381600087803b158015610d2f57600080fd5b505af1158015610d43573d6000803e3d6000fd5b50505050508080610d5390611351565b915050610cab565b50600083815260046020908152604080832080546001600160a01b03191681556001018390558382015184516001600160a01b0316845260059092528220805491929091610db090849063ffffffff1661136c565b92506101000a81548163ffffffff021916908363ffffffff160217905550806020015160066000828254610de49190611391565b9091555050505050565b600054600160a01b900460ff16610e3e5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604482015260640161050b565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff1615610f285760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015260640161050b565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610e6e3390565b600060208284031215610f7557600080fd5b81356001600160e01b031981168114610f8d57600080fd5b9392505050565b634e487b7160e01b600052604160045260246000fd5b60008060408385031215610fbd57600080fd5b8235915060208084013567ffffffffffffffff80821115610fdd57600080fd5b818601915086601f830112610ff157600080fd5b81358181111561100357611003610f94565b8060051b604051601f19603f8301168101818110858211171561102857611028610f94565b60405291825284820192508381018501918983111561104657600080fd5b938501935b828510156110645784358452938501939285019261104b565b8096505050505050509250929050565b60006020828403121561108657600080fd5b5035919050565b80356001600160a01b03811681146110a457600080fd5b919050565b60008083601f8401126110bb57600080fd5b50813567ffffffffffffffff8111156110d357600080fd5b6020830191508360208260051b85010111156110ee57600080fd5b9250929050565b60008083601f84011261110757600080fd5b50813567ffffffffffffffff81111561111f57600080fd5b6020830191508360208285010111156110ee57600080fd5b60008060008060008060008060a0898b03121561115357600080fd5b61115c8961108d565b975061116a60208a0161108d565b9650604089013567ffffffffffffffff8082111561118757600080fd5b6111938c838d016110a9565b909850965060608b01359150808211156111ac57600080fd5b6111b88c838d016110a9565b909650945060808b01359150808211156111d157600080fd5b506111de8b828c016110f5565b999c989b5096995094979396929594505050565b60006020828403121561120457600080fd5b813567ffffffffffffffff81168114610f8d57600080fd5b60006020828403121561122e57600080fd5b610f8d8261108d565b60008060008060008060a0878903121561125057600080fd5b6112598761108d565b95506112676020880161108d565b94506040870135935060608701359250608087013567ffffffffffffffff81111561129157600080fd5b61129d89828a016110f5565b979a9699509497509295939492505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6000602082840312156112f657600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b600063ffffffff808316818516808303821115611332576113326112fd565b01949350505050565b634e487b7160e01b600052603260045260246000fd5b6000600019821415611365576113656112fd565b5060010190565b600063ffffffff83811690831681811015611389576113896112fd565b039392505050565b600082198211156113a4576113a46112fd565b50019056fea2646970667358221220388833adfe6cc7c1f7f0ed93b79a59841732bf86cdf2eb7f4f38e5a658d7d81764736f6c634300080b003300000000000000000000000000000000000000000000000000000000629a8460000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699099fe0eebf5e446e3c998ec9bb19951541aee00bb90ea201ae456421a2ded86805000000000000000000000000000000000000000000000000000000000000001d000000000000000000000000c36cf0cfcb5d905b8b513860db0cfe63f6cf9f5c000000000000000000000000000003310000000000000000000000000000000000000000000000000000000089c885614abcedaf012330e652a764e1289cda81

Deployed Bytecode

0x608060405234801561001057600080fd5b506004361061018e5760003560e01c80638da5cb5b116100de578063d5abeb0111610097578063f23a6e6111610071578063f23a6e61146103ff578063f2fde38b14610412578063f7ea7a3d14610425578063fb22e6511461043857600080fd5b8063d5abeb011461039f578063ea9d36cc146103a8578063f05bfa7b146103bb57600080fd5b80638da5cb5b146102fb57806398264fa61461030c578063a293eff81461031f578063a7dd255214610339578063bc197c8114610360578063c3fde3db1461038c57600080fd5b80633f4ba83a1161014b5780637146bd08116101255780637146bd08146102a3578063715018a6146102ac5780637a564970146102b45780638456cb59146102f357600080fd5b80633f4ba83a146102765780635c975abb1461027e578063711897421461029057600080fd5b806301ffc9a714610193578063041d443e146101bb57806318160ddd146101d25780631fe543e3146101db5780633bf13b44146101f05780633c276d8614610242575b600080fd5b6101a66101a1366004610f63565b61045e565b60405190151581526020015b60405180910390f35b6101c460025481565b6040519081526020016101b2565b6101c460065481565b6101ee6101e9366004610faa565b610495565b005b6102236101fe366004611074565b600460205260009081526040902080546001909101546001600160a01b039091169082565b604080516001600160a01b0390931683526020830191909152016101b2565b60015461025d90600160a01b900467ffffffffffffffff1681565b60405167ffffffffffffffff90911681526020016101b2565b6101ee610522565b600054600160a01b900460ff166101a6565b6101ee61029e366004611074565b610556565b6101c460075481565b6101ee610585565b6102db7f000000000000000000000000c36cf0cfcb5d905b8b513860db0cfe63f6cf9f5c81565b6040516001600160a01b0390911681526020016101b2565b6101ee6105b9565b6000546001600160a01b03166102db565b6101ee61031a366004611074565b6105eb565b6003546102db90600160401b90046001600160a01b031681565b6101c47f000000000000000000000000000003310000000000000000000000000000000081565b61037361036e366004611137565b61061a565b6040516001600160e01b031990911681526020016101b2565b6101ee61039a3660046111f2565b61067e565b6101c461927c81565b6101ee6103b63660046111f2565b6106cc565b6103ea6103c936600461121c565b6001600160a01b031660009081526005602052604090205463ffffffff1690565b60405163ffffffff90911681526020016101b2565b61037361040d366004611237565b610724565b6101ee61042036600461121c565b610b52565b6101ee610433366004611074565b610bed565b6103ea61044636600461121c565b60056020526000908152604090205463ffffffff1681565b60006001600160e01b03198216630271189760e51b148061048f57506301ffc9a760e01b6001600160e01b03198316145b92915050565b336001600160a01b037f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e6990916146105145760405163073e64fd60e21b81523360048201526001600160a01b037f000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699091660248201526044015b60405180910390fd5b61051e8282610c1c565b5050565b6000546001600160a01b0316331461054c5760405162461bcd60e51b815260040161050b906112af565b610554610dee565b565b6000546001600160a01b031633146105805760405162461bcd60e51b815260040161050b906112af565b600755565b6000546001600160a01b031633146105af5760405162461bcd60e51b815260040161050b906112af565b6105546000610e8b565b6000546001600160a01b031633146105e35760405162461bcd60e51b815260040161050b906112af565b610554610edb565b6000546001600160a01b031633146106155760405162461bcd60e51b815260040161050b906112af565b600255565b60405162461bcd60e51b815260206004820152603060248201527f4d6972616e6475732045786368616e67653a204261746368205472616e73666560448201526f1c881a5cc81b9bdd08185b1b1bddd95960821b606482015260009060840161050b565b6000546001600160a01b031633146106a85760405162461bcd60e51b815260040161050b906112af565b6003805467ffffffffffffffff191667ffffffffffffffff92909216919091179055565b6000546001600160a01b031633146106f65760405162461bcd60e51b815260040161050b906112af565b6001805467ffffffffffffffff909216600160a01b0267ffffffffffffffff60a01b19909216919091179055565b600154600090600160a01b900467ffffffffffffffff1642101561078a5760405162461bcd60e51b815260206004820152601e60248201527f4d6972616e6475732045786368616e67653a206e6f7420737461727465640000604482015260640161050b565b336001600160a01b037f000000000000000000000000c36cf0cfcb5d905b8b513860db0cfe63f6cf9f5c161461081c5760405162461bcd60e51b815260206004820152603160248201527f4d6972616e6475732045786368616e67653a206e6f74204d6972616e64757320604482015270115e18da185b99d94818dbdb9d1c9858dd607a1b606482015260840161050b565b7f000000000000000000000000000003310000000000000000000000000000000085146108a25760405162461bcd60e51b815260206004820152602e60248201527f4d6972616e6475732045786368616e67653a206e6f74204d6972616e6475732060448201526d22bc31b430b733b2903a37b5b2b760911b606482015260840161050b565b600084116108fc5760405162461bcd60e51b815260206004820152602160248201527f4d6972616e6475732045786368616e67653a20616d6f756e74206973207a65726044820152606f60f81b606482015260840161050b565b6001600160a01b0386166109605760405162461bcd60e51b815260206004820152602560248201527f4d6972616e6475732045786368616e67653a2066726f6d206973206164647265604482015264737328302960d81b606482015260840161050b565b600054600160a01b900460ff16156109ba5760405162461bcd60e51b815260206004820152601960248201527f4d6972616e6475732045786368616e67653a2070617573656400000000000000604482015260640161050b565b600154600254600380546040516305d3b1d360e41b8152600481019390935267ffffffffffffffff1660248301526044820152622625a0606482015263ffffffff861660848201526000916001600160a01b031690635d3b1d309060a4016020604051808303816000875af1158015610a37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5b91906112e4565b6040805180820182526001600160a01b038a811680835260208084018b8152600087815260048352868120955186546001600160a01b0319169516949094178555516001909401939093558152600590915290812080549293508792909190610acb90849063ffffffff16611313565b92506101000a81548163ffffffff021916908363ffffffff1602179055507f6e67d52a6deec37ea0760af8c17d9a6c94f902dc418444a34b4ceaef124449e3818887604051610b36939291909283526001600160a01b03919091166020830152604082015260600190565b60405180910390a15063f23a6e6160e01b979650505050505050565b6000546001600160a01b03163314610b7c5760405162461bcd60e51b815260040161050b906112af565b6001600160a01b038116610be15760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b606482015260840161050b565b610bea81610e8b565b50565b6000546001600160a01b03163314610c175760405162461bcd60e51b815260040161050b906112af565b600655565b600082815260046020908152604091829020825180840190935280546001600160a01b031680845260019091015491830191909152610ca85760405162461bcd60e51b815260206004820152602260248201527f4d6972616e6475732045786368616e67653a20496e76616c69642072657175656044820152611cdd60f21b606482015260840161050b565b60005b8160200151811015610d5b576000838281518110610ccb57610ccb61133b565b60209081029190910101516003548451604051636d603f2160e11b81526001600160a01b03918216600482015260248101849052929350600160401b909104169063dac07e4290604401600060405180830381600087803b158015610d2f57600080fd5b505af1158015610d43573d6000803e3d6000fd5b50505050508080610d5390611351565b915050610cab565b50600083815260046020908152604080832080546001600160a01b03191681556001018390558382015184516001600160a01b0316845260059092528220805491929091610db090849063ffffffff1661136c565b92506101000a81548163ffffffff021916908363ffffffff160217905550806020015160066000828254610de49190611391565b9091555050505050565b600054600160a01b900460ff16610e3e5760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b604482015260640161050b565b6000805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600054600160a01b900460ff1615610f285760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015260640161050b565b6000805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258610e6e3390565b600060208284031215610f7557600080fd5b81356001600160e01b031981168114610f8d57600080fd5b9392505050565b634e487b7160e01b600052604160045260246000fd5b60008060408385031215610fbd57600080fd5b8235915060208084013567ffffffffffffffff80821115610fdd57600080fd5b818601915086601f830112610ff157600080fd5b81358181111561100357611003610f94565b8060051b604051601f19603f8301168101818110858211171561102857611028610f94565b60405291825284820192508381018501918983111561104657600080fd5b938501935b828510156110645784358452938501939285019261104b565b8096505050505050509250929050565b60006020828403121561108657600080fd5b5035919050565b80356001600160a01b03811681146110a457600080fd5b919050565b60008083601f8401126110bb57600080fd5b50813567ffffffffffffffff8111156110d357600080fd5b6020830191508360208260051b85010111156110ee57600080fd5b9250929050565b60008083601f84011261110757600080fd5b50813567ffffffffffffffff81111561111f57600080fd5b6020830191508360208285010111156110ee57600080fd5b60008060008060008060008060a0898b03121561115357600080fd5b61115c8961108d565b975061116a60208a0161108d565b9650604089013567ffffffffffffffff8082111561118757600080fd5b6111938c838d016110a9565b909850965060608b01359150808211156111ac57600080fd5b6111b88c838d016110a9565b909650945060808b01359150808211156111d157600080fd5b506111de8b828c016110f5565b999c989b5096995094979396929594505050565b60006020828403121561120457600080fd5b813567ffffffffffffffff81168114610f8d57600080fd5b60006020828403121561122e57600080fd5b610f8d8261108d565b60008060008060008060a0878903121561125057600080fd5b6112598761108d565b95506112676020880161108d565b94506040870135935060608701359250608087013567ffffffffffffffff81111561129157600080fd5b61129d89828a016110f5565b979a9699509497509295939492505050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6000602082840312156112f657600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b600063ffffffff808316818516808303821115611332576113326112fd565b01949350505050565b634e487b7160e01b600052603260045260246000fd5b6000600019821415611365576113656112fd565b5060010190565b600063ffffffff83811690831681811015611389576113896112fd565b039392505050565b600082198211156113a4576113a46112fd565b50019056fea2646970667358221220388833adfe6cc7c1f7f0ed93b79a59841732bf86cdf2eb7f4f38e5a658d7d81764736f6c634300080b0033

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

00000000000000000000000000000000000000000000000000000000629a8460000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e699099fe0eebf5e446e3c998ec9bb19951541aee00bb90ea201ae456421a2ded86805000000000000000000000000000000000000000000000000000000000000001d000000000000000000000000c36cf0cfcb5d905b8b513860db0cfe63f6cf9f5c000000000000000000000000000003310000000000000000000000000000000000000000000000000000000089c885614abcedaf012330e652a764e1289cda81

-----Decoded View---------------
Arg [0] : _saleStartTimestamp (uint64): 1654293600
Arg [1] : _vrfCoordinator (address): 0x271682DEB8C4E0901D1a1550aD2e64D568E69909
Arg [2] : _vrfKeyhash (bytes32): 0x9fe0eebf5e446e3c998ec9bb19951541aee00bb90ea201ae456421a2ded86805
Arg [3] : _vrfSubscriptionId (uint64): 29
Arg [4] : _erc1155Contract (address): 0xc36cF0cFcb5d905B8B513860dB0CFE63F6Cf9F5c
Arg [5] : _boxTokenId (uint256): 278010693774406724649577054271754628759552
Arg [6] : _randomRewardAddress (address): 0x89C885614abCEDaF012330e652A764E1289Cda81

-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000629a8460
Arg [1] : 000000000000000000000000271682deb8c4e0901d1a1550ad2e64d568e69909
Arg [2] : 9fe0eebf5e446e3c998ec9bb19951541aee00bb90ea201ae456421a2ded86805
Arg [3] : 000000000000000000000000000000000000000000000000000000000000001d
Arg [4] : 000000000000000000000000c36cf0cfcb5d905b8b513860db0cfe63f6cf9f5c
Arg [5] : 0000000000000000000000000000033100000000000000000000000000000000
Arg [6] : 00000000000000000000000089c885614abcedaf012330e652a764e1289cda81


Block Transaction Difficulty Gas Used Reward
View All Blocks Produced

Block Uncle Number Difficulty Gas Used Reward
View All Uncles
Loading...
Loading
Loading...
Loading

Validator Index Block Amount
View All Withdrawals

Transaction Hash Block Value Eth2 PubKey Valid
View All Deposits
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.