ETH Price: $3,309.61 (+2.52%)

Contract

0xf1502140f2E223c0eD46A5aAAceDf82F749cB391
 

Overview

ETH Balance

0 ETH

Eth Value

$0.00

Multichain Info

No addresses found
Transaction Hash
Method
Block
From
To
Withdraw Ether195911312024-04-05 17:50:23290 days ago1712339423IN
0xf1502140...F749cB391
0 ETH0.0008150825.59366139
Withdraw Tokens195911012024-04-05 17:44:11290 days ago1712339051IN
0xf1502140...F749cB391
0 ETH0.0014052629.41605072
Set Sale Step195910652024-04-05 17:36:59290 days ago1712338619IN
0xf1502140...F749cB391
0 ETH0.0008572433.96648258
Buy Tokens195883392024-04-05 8:25:47290 days ago1712305547IN
0xf1502140...F749cB391
0.135 ETH0.0032218816.88123924
Buy Tokens195882782024-04-05 8:13:23290 days ago1712304803IN
0xf1502140...F749cB391
0.01836 ETH0.0016920915.06051195
Buy Tokens195881292024-04-05 7:43:23290 days ago1712303003IN
0xf1502140...F749cB391
0.03375 ETH0.0018860317.10939399
Buy Tokens195853092024-04-04 22:15:35290 days ago1712268935IN
0xf1502140...F749cB391
0.0135 ETH0.0018507316.78918178
Buy Tokens195850582024-04-04 21:24:47291 days ago1712265887IN
0xf1502140...F749cB391
0.135 ETH0.0043080622.57234574
Buy Tokens195849132024-04-04 20:55:47291 days ago1712264147IN
0xf1502140...F749cB391
0.135 ETH0.005417628.38584889
Withdraw Tokens195848442024-04-04 20:41:59291 days ago1712263319IN
0xf1502140...F749cB391
0 ETH0.0018519735.23538455
Buy Tokens195845202024-04-04 19:36:47291 days ago1712259407IN
0xf1502140...F749cB391
0.135 ETH0.0108470856.83388218
Buy Tokens195840762024-04-04 18:06:59291 days ago1712254019IN
0xf1502140...F749cB391
0.04725 ETH0.0034694545.63027543
Buy Tokens195840552024-04-04 18:02:47291 days ago1712253767IN
0xf1502140...F749cB391
0.007425 ETH0.0052457747.58763372
Withdraw Tokens195839952024-04-04 17:50:47291 days ago1712253047IN
0xf1502140...F749cB391
0 ETH0.0021384440.68584779
Buy Tokens195835552024-04-04 16:21:59291 days ago1712247719IN
0xf1502140...F749cB391
0.675 ETH0.0233215961.40169315
Buy Tokens195834832024-04-04 16:07:35291 days ago1712246855IN
0xf1502140...F749cB391
0.0675 ETH0.0073525294.07855439
Buy Tokens195834822024-04-04 16:07:23291 days ago1712246843IN
0xf1502140...F749cB391
0.00675 ETH0.0063639283.69845624
Buy Tokens195834592024-04-04 16:02:47291 days ago1712246567IN
0xf1502140...F749cB391
0.135 ETH0.0185322497.10067811
Buy Tokens195834562024-04-04 16:02:11291 days ago1712246531IN
0xf1502140...F749cB391
0.135 ETH0.01960035102.69708945
Set Sale Step195834402024-04-04 15:58:59291 days ago1712246339IN
0xf1502140...F749cB391
0 ETH0.001750137.11780767
Distribute Token...195823532024-04-04 12:18:47291 days ago1712233127IN
0xf1502140...F749cB391
0 ETH0.3227315523.78753671
Set Sale Step195691712024-04-02 16:03:35293 days ago1712073815IN
0xf1502140...F749cB391
0 ETH0.0021011683.25401182
Buy Tokens195685862024-04-02 14:04:35293 days ago1712066675IN
0xf1502140...F749cB391
0.22 ETH0.0126561750.474873
Buy Tokens195671982024-04-02 9:22:47293 days ago1712049767IN
0xf1502140...F749cB391
0.22 ETH0.0063787631.53184576
Buy Tokens195671702024-04-02 9:17:11293 days ago1712049431IN
0xf1502140...F749cB391
0.22 ETH0.0060812630.18462618
View all transactions

Latest 1 internal transaction

Advanced mode:
Parent Transaction Hash Block
From
To
195911312024-04-05 17:50:23290 days ago1712339423
0xf1502140...F749cB391
21.87916511 ETH
Loading...
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
Vendor

Compiler Version
v0.8.20+commit.a1b79de6

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion
File 1 of 6 : Vendor.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/ReentrancyGuard.sol";
import {MerkleProof} from "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol";

import "./SPT.sol";

contract Vendor is Ownable, ReentrancyGuard {
    SPT public token; // Use interface

    uint256 public constant PRICE = 135000000000000000;
    uint256 public constant PRICE_WL = 110000000000000000;
    uint256 public maxBuyAmountPerWallet;
    uint256 public maxBuyAmountPerWalletForWLSales;
    uint256 public maxBuyAmountForWLSalesPeriod;
    uint256 public salesStep = 0; // 0 - not active, 1 - whitelist only, 2 - public
    uint256 public totalBought = 0;
    bytes32 public merkleRoot;

    mapping(address => uint256) public tokensCountPerAddress;

    event BuyTokens(address buyer, uint256 amountOfETH, uint256 amountOfTokens);
    event WithdrawEther(address caller, uint256 amount);
    event WithdrawTokens(address caller, uint256 amount);
    event MerkleRootUpdated(address caller, bytes32 merkleRoot);
    event SalesStepUpdated(address caller, uint256 salesStep);

    constructor(
        address _tokenAddress,
        bytes32 _merkleRoot,
        uint256 _maxBuyAmountPerWallet,
        uint256 _maxBuyAmountPerWalletForWLSales,
        uint256 _maxBuyAmountForWLSalesPeriod
    ) Ownable(msg.sender) {
        token = SPT(_tokenAddress);
        merkleRoot = _merkleRoot;
        maxBuyAmountPerWallet = _maxBuyAmountPerWallet;
        maxBuyAmountPerWalletForWLSales = _maxBuyAmountPerWalletForWLSales;
        maxBuyAmountForWLSalesPeriod = _maxBuyAmountForWLSalesPeriod;
    }

    /**
     * @notice Allow users to buy token for ETH
     */
    function buyTokens(
        bytes32[] calldata merkleProof
    ) public payable nonReentrant returns (uint256 tokenAmount) {
        require(salesStep != 0, "Sales not active");

        bool isWL = isWhitelisted(msg.sender, merkleProof);
        require(salesStep != 1 || isWL, "Private sales only");

        uint256 tokenDecimalsMultiplier = 10 ** token.decimals();

        uint256 price = salesStep == 1 ? PRICE_WL : PRICE;

        uint256 maxBuyAmount = salesStep == 1
            ? maxBuyAmountPerWalletForWLSales * tokenDecimalsMultiplier
            : maxBuyAmountPerWallet * tokenDecimalsMultiplier;

        uint256 transferAmount = (msg.value * tokenDecimalsMultiplier) / price;

        require(
            tokensCountPerAddress[msg.sender] + transferAmount <= maxBuyAmount,
            "Exceeded max buy amount per wallet"
        );
        require(
            token.balanceOf(address(this)) >= transferAmount,
            "Insufficient token balance in contract"
        );
        require(
            salesStep != 1 ||
                totalBought + transferAmount <=
                maxBuyAmountForWLSalesPeriod * tokenDecimalsMultiplier,
            "Max sales amount exceeded for private sales"
        );

        tokensCountPerAddress[msg.sender] += transferAmount;
        totalBought += transferAmount;

        bool success = token.transfer(msg.sender, transferAmount);
        require(success, "Transfer failed");

        emit BuyTokens(msg.sender, msg.value, transferAmount);
        return transferAmount;
    }

    function distributeTokens(
        address[] memory recipients,
        uint256[] memory amounts
    ) public onlyOwner {
        require(
            recipients.length == amounts.length,
            "Array lengths do not match"
        );

        uint256 n = recipients.length;
        uint256 totalAmount = 0;
        for (uint256 i = 0; i < n; i++) {
            totalAmount += amounts[i];
        }

        require(
            token.balanceOf(address(this)) >= totalAmount,
            "Insufficient token balance in contract"
        );

        for (uint256 i = 0; i < n; i++) {
            token.transfer(recipients[i], amounts[i]);
        }
    }

    /**
     * @notice Allow the owner of the contract to withdraw ETH
     */
    function withdrawEther() public onlyOwner {
        uint256 ownerBalance = address(this).balance;
        require(ownerBalance > 0, "Nothing to withdraw");

        (bool success, ) = payable(owner()).call{value: ownerBalance}("");
        require(success, "Transfer failed");

        emit WithdrawEther(msg.sender, ownerBalance);
    }

    function withdrawTokens(uint256 amountInWei) public onlyOwner {
        bool success = token.transfer(msg.sender, amountInWei);
        require(success, "Token removal failed");

        emit WithdrawTokens(msg.sender, amountInWei);
    }

    function setSaleStep(uint256 newStep) public onlyOwner {
        require(newStep >= 0 && newStep <= 2, "Invalid sale step");
        require(
            newStep != salesStep,
            "New step is the same as the current step"
        );

        salesStep = newStep;
        emit SalesStepUpdated(msg.sender, salesStep);
    }

    function setMerkleRoot(bytes32 _merkleRoot) public onlyOwner {
        merkleRoot = _merkleRoot;
        emit MerkleRootUpdated(msg.sender, merkleRoot);
    }

    function ethBalance() public view returns (uint256) {
        return address(this).balance;
    }

    function isWhitelisted(
        address _address,
        bytes32[] calldata merkleProof
    ) public view returns (bool) {
        bytes32 node = keccak256(abi.encodePacked(_address));
        return MerkleProof.verify(merkleProof, merkleRoot, node);
    }
}

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

pragma solidity ^0.8.20;

import {Context} from "../utils/Context.sol";

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

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

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

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

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

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

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

    /**
     * @dev Throws if the sender is not the owner.
     */
    function _checkOwner() internal view virtual {
        if (owner() != _msgSender()) {
            revert OwnableUnauthorizedAccount(_msgSender());
        }
    }

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

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        if (newOwner == address(0)) {
            revert OwnableInvalidOwner(address(0));
        }
        _transferOwnership(newOwner);
    }

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

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

pragma solidity ^0.8.20;

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

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

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

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

pragma solidity ^0.8.20;

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

File 5 of 6 : ReentrancyGuard.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/ReentrancyGuard.sol)

pragma solidity ^0.8.20;

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

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

    uint256 private _status;

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

    constructor() {
        _status = NOT_ENTERED;
    }

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

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

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

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

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

File 6 of 6 : SPT.sol
// A public demonstration in single-contract dual-token implementations
// with zero-conflict events, and function overloading.

// Website : https://spacepoptroopers.io/
// X : https://x.com/spt_erc741
// TG : https://t.me/SPT_ERC741

// A big thank you to Serec Thunderson for your awesome code contribution.
// Your work is greatly appreciated.
// Thank you for your valuable input.

// Find his work on the following link:
// https://github.com/SJ741/sj741-token

// WARNING - Fungible NFT specs are universally new, and inherently DANGEROUS
// no systems have been built with these use-cases in mind, and there are a number of
// ways that experimental, complex contracts can lead to unforeseen consequences.
// INTERACT WITH EXPERIMENTAL SMART CONTRACTS AT YOUR OWN RISK

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

// libraries to separate ERC20 and ERC721 events, and certain signature-specific functions
// ERC20 events
library libSPT20 {
    event Transfer(address indexed from, address indexed to, uint amount);
    event Approval(
        address indexed owner,
        address indexed spender,
        uint256 value
    );

    function emitTransfer(address _from, address _to, uint _amount) internal {
        emit Transfer(_from, _to, _amount);
    }

    function emitApproval(
        address _owner,
        address _spender,
        uint _value
    ) internal {
        emit Approval(_owner, _spender, _value);
    }
}

// ERC721 events
library libSPT721 {
    event Transfer(
        address indexed _from,
        address indexed _to,
        uint indexed _tokenId
    );
    event Approval(
        address indexed _owner,
        address indexed _approved,
        uint indexed _tokenId
    );
    event ApprovalForAll(
        address indexed _owner,
        address indexed _operator,
        bool _approved
    );

    function emitTransfer(address _from, address _to, uint _tokenId) internal {
        emit Transfer(_from, _to, _tokenId);
    }

    function emitApproval(
        address _owner,
        address _approve,
        uint _tokenId
    ) internal {
        emit Approval(_owner, _approve, _tokenId);
    }

    function emitApprovalForAll(
        address _owner,
        address _operator,
        bool _approved
    ) internal {
        emit ApprovalForAll(_owner, _operator, _approved);
    }
}

// ERC165 https://eips.ethereum.org/EIPS/eip-721
interface IERC165 {
    function supportsInterface(bytes4 interfaceID) external view returns (bool);
}

// ERC20 https://eips.ethereum.org/EIPS/eip-20
interface IERC20 {
    function balanceOf(address account) external view returns (uint256);

    function totalSupply() external view returns (uint256);

    function transfer(address to, uint256 value) external returns (bool);

    function allowance(
        address owner,
        address spender
    ) external view returns (uint256);

    function approve(address spender, uint256 value) external returns (bool);

    function transferFrom(
        address from,
        address to,
        uint256 value
    ) external returns (bool);
}

// ERC721 https://eips.ethereum.org/EIPS/eip-721
interface IERC721 is IERC165 {
    function balanceOf(address account) external view returns (uint256);

    function ownerOf(uint256 _tokenId) external view returns (address);

    function safeTransferFrom(
        address _from,
        address _to,
        uint256 _tokenId,
        bytes memory data
    ) external payable;

    function safeTransferFrom(
        address _from,
        address _to,
        uint256 _tokenId
    ) external payable;

    function setApprovalForAll(address _operator, bool _approved) external;

    function getApproved(uint256 _tokenId) external view returns (address);

    function isApprovedForAll(
        address _owner,
        address _operator
    ) external view returns (bool);

    // payable removed for erc20 etherscan compatibility
    function approve(address spender, uint256 value) external returns (bool);

    function transferFrom(
        address from,
        address to,
        uint256 value
    ) external returns (bool);
}

interface ISPT741 is IERC20, IERC721 {
    // library transfers can not be included in the interface
    // incorporate them directly with library
    // libSPT20.Transfer
    // libSPT20.Approval
    // libSPT721.Transfer
    // libSPT721.Approval
    // libSPT721.ApprovalForAll
    function balanceOf(
        address account
    ) external view override(IERC20, IERC721) returns (uint256);

    function approve(
        address spender,
        uint256 value
    ) external override(IERC20, IERC721) returns (bool);

    function transferFrom(
        address from,
        address to,
        uint256 value
    ) external override(IERC20, IERC721) returns (bool);
}

// ERC721 Token Receiver https://eips.ethereum.org/EIPS/eip-721
interface IERC721TokenReceiver {
    function onERC721Received(
        address _operator,
        address _from,
        uint256 _tokenId,
        bytes memory _data
    ) external returns (bytes4);
}

contract SPT is ISPT741 {
    string public baseURI =
        "ipfs://bafybeidskgytes3zn4ge2yoejahnl7gmlsuwirg2czsujhxbzcwrthuuti/";
    string internal constant _name = "Space Pop Troopers";
    string internal constant _symbol = "SPT";

    uint internal constant _decimals = 8;
    uint internal constant _totalIds = 1741;
    uint internal constant _totalSupply = _totalIds * 10 ** _decimals;
    uint internal constant ONE = 10 ** _decimals; // 1.0 token(s)
    uint internal constant MAXID = ONE + _totalIds; // 1.00000001 : 1.00007777 is the range for NFT IDs

    uint32 public minted; // number of unique ID mints
    uint32[] private broken; // broken NFTs stored in limbo list

    address public dev;
    bool public supportsNFTinterface;
    bool public skipMintingGlobal = false;

    mapping(address => mapping(address => bool)) private _operatorApprovals;
    mapping(address => mapping(address => uint)) internal _allowance;
    mapping(uint256 => address) public ownerOf;
    mapping(uint256 => address) private _nftApprovals;
    mapping(address => uint) internal _balanceOf;
    mapping(address => uint32[]) public ownedNFTs;
    mapping(uint32 => uint256) private idToIndex;
    mapping(address => bool) internal skipMintingUser;

    function setSkipMintingGlobal(bool newSkipMintingGlobal) public onlyDev {
        skipMintingGlobal = newSkipMintingGlobal;
    }

    function setSkipMinting(bool newSkipMinting) public {
        skipMintingUser[msg.sender] = newSkipMinting;
    }

    error UnsupportedReceiver();

    modifier onlyDev() {
        require(msg.sender == dev, "Not the developer");
        _;
    }

    constructor() {
        //set minted at ONE to ensure correct operation within range of IDs
        minted = uint32(ONE);

        //the message sender receives the entire supply
        _balanceOf[msg.sender] = _totalSupply;

        //the message sender is set as "dev" role
        dev = msg.sender;
    }

    function name() public view virtual returns (string memory) {
        return _name;
    }

    function symbol() public view virtual returns (string memory) {
        return _symbol;
    }

    function decimals() public view virtual returns (uint) {
        return _decimals;
    }

    function totalSupply() public pure override returns (uint) {
        return _totalSupply;
    }

    function balanceOf(address account) public view override returns (uint) {
        return _balanceOf[account];
    }

    function allowance(
        address owner,
        address spender
    ) public view override returns (uint) {
        return _allowance[owner][spender];
    }

    function setBaseURI(string memory newBaseURI) public onlyDev {
        baseURI = newBaseURI;
    }

    function changeDev(address newDev) public onlyDev {
        dev = newDev;
    } //simple function to change developer address, or revoke ownership (with address(0))

    // @DEV toggleNFTinterface is for the small possibility of frontend system changes leading the contract to favor enabling the disabled supportsNFTinterface flag
    // don't waste it, as frontends don't typically change classification of contracts
    // probably never to be used.
    function toggelNFTinterface() public onlyDev {
        supportsNFTinterface = !supportsNFTinterface;
    }

    function approve(
        address spender,
        uint amount
    ) public override returns (bool) {
        // if the amount is greater than one token, and within range of IDs for NFTs
        // then set NFT approval for the given ID
        if (amount > ONE && amount <= MAXID) {
            address owner = ownerOf[amount]; // getting the owner of token ID via the `amount` input
            if (msg.sender != owner && !isApprovedForAll(owner, msg.sender))
                revert("SPT741: You are not approved");
            _nftApprovals[amount] = spender; // calling nft approval for the token and spender
            libSPT721.emitApproval(owner, spender, amount);
            return true;
        }

        // else set the ERC20 allowance
        // the NFT ID range being set within a limited subset of ONE token(s)
        // allows for non-clashing interactions
        _allowance[msg.sender][spender] = amount;
        libSPT20.emitApproval(msg.sender, spender, amount);
        return true;
    }

    function _transfer741(
        address from,
        address to,
        uint amount
    ) internal virtual {
        require(
            _balanceOf[from] >= amount,
            "SPT741: transfer amount exceeds balance"
        );

        // checking the decimal amount of tokens owned before transaction for both participants
        uint256 fromDecimalsPre = _balanceOf[from] % ONE;
        uint256 toDecimalsPre = _balanceOf[to] % ONE;

        // simple erc20 balance operations
        _transfer20(from, to, amount);

        // checking the decimal amount of tokens after transaction for both partcipants
        uint256 fromDecimalsPost = _balanceOf[from] % ONE;
        uint256 toDecimalsPost = _balanceOf[to] % ONE;

        // stores the NFT IDs owned by `from`, enabling NFT management for that address.
        uint32[] storage ownedNFTsArray = ownedNFTs[from];

        // references NFTs marked as "broken", tracking these special state NFTs.
        uint32[] storage brokenIDsArray = broken;

        // if sender has higher decimal count after transaction, then they "roll under" and break an NFT
        if (fromDecimalsPre < fromDecimalsPost) {
            if (ownedNFTsArray.length > 0) {
                // if the sender has an nft to send

                uint32 tokenId = ownedNFTsArray[0]; //selects the user's first NFT from the list

                brokenIDsArray.push(tokenId); //pushes the nft into the "broken list" for limbo NFTs
                _transfer721(from, address(0), tokenId); //transfers the NFT ID ownership to (0) address for stewardship
            }
        }

        // if receiver has lower decimal count after transaction then they "roll over" and will "remake" an nft
        if (toDecimalsPre > toDecimalsPost) {
            if (brokenIDsArray.length > 0) {
                // recover an id from broken list

                _transfer721(
                    address(0),
                    to,
                    brokenIDsArray[brokenIDsArray.length - 1]
                );
                brokenIDsArray.pop();
            } else {
                // mint new id
                _mint(to);
            }
        }

        // amount of tokens - amount of whole tokens being processed in int
        uint amountInTokens = amount / ONE;

        // ignore minting nfts from dev when they call -- this allows for gas-efficient team operations
        // @DEV if dev gathers NFTs, use the ERC721 transferFrom method to extract
        // @DEV be careful, don't let the wallet fall to some convoluted transferFrom scam to do something unexpected
        if (
            from == dev ||
            skipMintingGlobal ||
            skipMintingUser[to] ||
            skipMintingUser[from]
        ) return;

        if (amountInTokens > 0) {
            uint len = ownedNFTsArray.length; //len is the length, or number of NFTs in the addresses's owned array
            len = amountInTokens < len ? amountInTokens : len;
            // transfers owned NFTs from `from` to `to` until either all are transferred or the desired amount is reached
            // Subtracts transferred NFT count from `amountInTokens` to update remaining transfers
            for (uint i = 0; i < len; i++) {
                _transfer721(from, to, ownedNFTsArray[0]);
            }
            amountInTokens -= len;
            len = brokenIDsArray.length;
            len = amountInTokens < len ? amountInTokens : len;

            // recovers NFTs from the broken state to `to`, or mints new ones if not enough broken NFTs are available
            // if any tokens remain to be allocated, it mints new NFTs to `to` for the remaining balance
            for (uint i = 0; i < len; i++) {
                _transfer721(
                    address(0),
                    to,
                    brokenIDsArray[brokenIDsArray.length - 1]
                );
                brokenIDsArray.pop();
            }

            _mintBatch(to, amountInTokens - len);
        }
    }

    function _mintBatch(address to, uint256 amount) internal {
        if (amount == 0) return; // Exit if no NFTs to mint

        if (amount == 1) {
            // Optimize single mint process
            _mint(to);
            return;
        }
        uint32 id = minted; // Start ID from last minted value
        uint256 ownedLen = ownedNFTs[to].length; // Current number of NFTs owned by 'to'
        for (uint i = 0; i < amount; ) {
            unchecked {
                id++; // Increment ID for each new NFT
            }
            ownerOf[id] = to; // Assign new NFT to owner.
            idToIndex[id] = ownedLen; // Map NFT ID to its index in owner's array
            ownedNFTs[to].push(id); // Add new NFT ID to owner's list

            libSPT721.emitTransfer(address(0), to, id); // Emit NFT transfer event

            unchecked {
                ownedLen++; // Increment count of owned NFTs
                i++; // Move to next NFT
            }
        }
        unchecked {
            minted += uint32(amount); // Update total minted count
        }
    }

    function _mint(address to) internal returns (uint32 tokenId) {
        unchecked {
            minted++; // Increment the total number of minted tokens
        }
        tokenId = minted; // Assign the newly minted token ID

        ownerOf[tokenId] = to; // Set ownership of the new token to 'to'
        idToIndex[tokenId] = ownedNFTs[to].length; // Map the new token ID to its index in the owner's list
        ownedNFTs[to].push(tokenId); // Add the new token ID to the owner's list of owned tokens

        libSPT721.emitTransfer(address(0), to, tokenId); // Emit an event for the token transfer
    }

    // Updates the mappings and arrays managing ownership and index of NFTs after a transfer
    function _updateOwnedNFTs(
        address from,
        address to,
        uint32 tokenId
    ) internal {
        uint256 index = idToIndex[tokenId]; // Get current index of the token in the owner's list
        uint32[] storage nftArray = ownedNFTs[from]; // Reference to the list of NFTs owned by 'from'
        uint256 len = nftArray.length; // Current number of NFTs owned by 'from'
        uint32 lastTokenId = nftArray[len - 1]; // Last token in the 'from' array to swap with transferred token

        nftArray[index] = lastTokenId; // Replace the transferred token with the last token in the array
        nftArray.pop(); // Remove the last element, effectively deleting the transferred token from 'from'

        if (len - 1 != 0) {
            idToIndex[lastTokenId] = index; // Update the index of the swapped token
        }

        ownedNFTs[to].push(tokenId); // Add the transferred token to the 'to' array
        idToIndex[tokenId] = ownedNFTs[to].length - 1; // Update the index mapping for the transferred token
    }

    // Executes a simple ERC20 token transfer.
    function _transfer20(address from, address to, uint256 amount) internal {
        _balanceOf[from] -= amount; // Deduct the amount from the sender's balance
        unchecked {
            _balanceOf[to] += amount; // Add the amount to the recipient's balance
        }
        libSPT20.emitTransfer(from, to, amount); // Emit an ERC20 transfer event
    }

    // Handles the transfer of an ERC721 token, ensuring proper ownership and event emission
    function _transfer721(
        address from,
        address to,
        uint32 tokenId
    ) internal virtual {
        require(from == ownerOf[tokenId], "SPT741: Incorrect owner"); // Ensure 'from' is the current owner

        delete _nftApprovals[tokenId]; // Clear any approvals for this token
        ownerOf[tokenId] = to; // Transfer ownership of the token to 'to'
        _updateOwnedNFTs(from, to, tokenId); // Update ownership tracking structures
        libSPT721.emitTransfer(from, to, tokenId); // Emit an ERC721 transfer event
    }

    // only erc20 calls this
    // if amount is a token id owned by the caller send as an NFT
    // else transfer741
    function transfer(address to, uint amount) public override returns (bool) {
        if (ownerOf[amount] == msg.sender) {
            _transfer721(msg.sender, to, uint32(amount));
            _transfer20(msg.sender, to, ONE);
            return true;
        }
        _transfer741(msg.sender, to, amount);
        return true;
    }

    // erc20 and erc721 call this
    function transferFrom(
        address from,
        address to,
        uint amount
    ) public override returns (bool) {
        //if amount is within the NFT id range, then a simple NFT transfer + token amount (ONE)
        if (amount > ONE && amount <= MAXID) {
            require(
                //require from is the msg caller, or that caller is approved for that specific NFT, or all NFTs
                msg.sender == from ||
                    msg.sender == getApproved(amount) ||
                    isApprovedForAll(from, msg.sender),
                "SPT741: You don't have the right"
            );

            _transfer721(from, to, uint32(amount));
            _transfer20(from, to, ONE);
            return true;
        }

        _spendAllowance(from, msg.sender, amount);
        _transfer741(from, to, amount);
        return true;
    }

    // erc721
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) public payable override {
        require(
            msg.sender == from ||
                msg.sender == getApproved(tokenId) ||
                isApprovedForAll(from, msg.sender),
            "SPT741: You don't have the right"
        );
        _transfer721(from, to, uint32(tokenId));
        _transfer20(from, to, ONE);

        if (
            to.code.length != 0 &&
            IERC721TokenReceiver(to).onERC721Received(
                msg.sender,
                from,
                tokenId,
                ""
            ) !=
            IERC721TokenReceiver.onERC721Received.selector
        ) {
            revert UnsupportedReceiver();
        }
    }

    // erc721
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes memory data
    ) public payable override {
        require(
            msg.sender == from ||
                msg.sender == getApproved(tokenId) ||
                isApprovedForAll(from, msg.sender),
            "SPT741: You don't have the right"
        );
        _transfer721(from, to, uint32(tokenId));
        _transfer20(from, to, ONE);

        if (
            to.code.length != 0 &&
            IERC721TokenReceiver(to).onERC721Received(
                msg.sender,
                from,
                tokenId,
                data
            ) !=
            IERC721TokenReceiver.onERC721Received.selector
        ) {
            revert UnsupportedReceiver();
        }
    }

    function _spendAllowance(
        address owner,
        address spender,
        uint amount
    ) internal virtual {
        require(
            _allowance[owner][spender] >= amount,
            "SPT741: insufficient allowance"
        );
        _allowance[owner][spender] -= amount;
    }

    function getApproved(
        uint256 tokenId
    ) public view override returns (address) {
        if (ownerOf[tokenId] == address(0)) revert();
        return _nftApprovals[tokenId];
    }

    function setApprovalForAll(
        address operator,
        bool approved
    ) public override {
        _operatorApprovals[msg.sender][operator] = approved;
        libSPT721.emitApprovalForAll(msg.sender, operator, approved);
    }

    function isApprovedForAll(
        address owner,
        address operator
    ) public view override returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    function tokenURI(
        uint256 tokenId
    ) public view virtual returns (string memory) {
        require(tokenId <= MAXID, "SPT741: invalid id");
        if (bytes(baseURI).length == 0) {
            return "";
        }
        return
            string(abi.encodePacked(baseURI, toString(tokenId - ONE), ".json"));
    }

    function toString(uint256 value) internal pure returns (string memory) {
        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(value % 10) + 48);
            value /= 10;
        }
        return string(buffer);
    }

    function withdraw() external onlyDev {
        payable(dev).transfer(address(this).balance);
    }

    function supportsInterface(
        bytes4 interfaceId
    ) public view override returns (bool) {
        return
            // Even though we support ERC721 and should return true, etherscan wants to treat us as ERC721 instead of ERC20
            // @DEV ERC165 for ERC721 can be toggled on for reasons of frontend/dapp/script implementations, but is very specific
            (supportsNFTinterface && interfaceId == 0x80ac58cd) || // ERC165 interface ID for ERC721
            interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165
            interfaceId == 0x36372b07; // ERC165 interface ID for ERC20
    }

    function getOwnedNFTs(
        address _owner
    ) external view returns (uint32[] memory) {
        return ownedNFTs[_owner];
    }
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"_tokenAddress","type":"address"},{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"},{"internalType":"uint256","name":"_maxBuyAmountPerWallet","type":"uint256"},{"internalType":"uint256","name":"_maxBuyAmountPerWalletForWLSales","type":"uint256"},{"internalType":"uint256","name":"_maxBuyAmountForWLSalesPeriod","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"buyer","type":"address"},{"indexed":false,"internalType":"uint256","name":"amountOfETH","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amountOfTokens","type":"uint256"}],"name":"BuyTokens","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"caller","type":"address"},{"indexed":false,"internalType":"bytes32","name":"merkleRoot","type":"bytes32"}],"name":"MerkleRootUpdated","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":"caller","type":"address"},{"indexed":false,"internalType":"uint256","name":"salesStep","type":"uint256"}],"name":"SalesStepUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"caller","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"WithdrawEther","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"caller","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"WithdrawTokens","type":"event"},{"inputs":[],"name":"PRICE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"PRICE_WL","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"buyTokens","outputs":[{"internalType":"uint256","name":"tokenAmount","type":"uint256"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address[]","name":"recipients","type":"address[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"}],"name":"distributeTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"ethBalance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_address","type":"address"},{"internalType":"bytes32[]","name":"merkleProof","type":"bytes32[]"}],"name":"isWhitelisted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxBuyAmountForWLSalesPeriod","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxBuyAmountPerWallet","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxBuyAmountPerWalletForWLSales","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"salesStep","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_merkleRoot","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"newStep","type":"uint256"}],"name":"setSaleStep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract SPT","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"tokensCountPerAddress","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBought","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":"withdrawEther","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amountInWei","type":"uint256"}],"name":"withdrawTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526000600655600060075534801561001a57600080fd5b506040516115d73803806115d7833981016040819052610039916100f2565b338061005f57604051631e4fbdf760e01b81526000600482015260240160405180910390fd5b610068816100a2565b5060018055600280546001600160a01b0319166001600160a01b039690961695909517909455600892909255600355600455600555610147565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600080600080600060a0868803121561010a57600080fd5b85516001600160a01b038116811461012157600080fd5b602087015160408801516060890151608090990151929a91995097965090945092505050565b611481806101566000396000f3fe60806040526004361061012a5760003560e01c806364ec130c116100ab578063894c1d401161006f578063894c1d40146102e85780638d859f3e146102fe5780638da5cb5b1461031a578063ab98089f1461034c578063f2fde38b1461035f578063fc0c546a1461037f57600080fd5b806364ec130c14610255578063715018a6146102825780637362377b146102975780637cb64759146102ac57806380161359146102cc57600080fd5b80634bd09c2a116100f25780634bd09c2a146101bc5780634e6630b0146101dc57806353e90cbd146101ef5780635a23dd991461020f5780635a7b094e1461023f57600080fd5b80632eb4a7ab1461012f578063315a095d1461015857806339ca27e51461017a5780634a2aac30146101905780634a91f195146101a6575b600080fd5b34801561013b57600080fd5b5061014560085481565b6040519081526020015b60405180910390f35b34801561016457600080fd5b50610178610173366004610f82565b61039f565b005b34801561018657600080fd5b5061014560055481565b34801561019c57600080fd5b5061014560065481565b3480156101b257600080fd5b5061014560075481565b3480156101c857600080fd5b506101786101d736600461108d565b6104a6565b3480156101e857600080fd5b5047610145565b3480156101fb57600080fd5b5061017861020a366004610f82565b6106b5565b34801561021b57600080fd5b5061022f61022a366004611199565b6107a6565b604051901515815260200161014f565b34801561024b57600080fd5b5061014560045481565b34801561026157600080fd5b506101456102703660046111ec565b60096020526000908152604090205481565b34801561028e57600080fd5b5061017861082c565b3480156102a357600080fd5b50610178610840565b3480156102b857600080fd5b506101786102c7366004610f82565b610957565b3480156102d857600080fd5b50610145670186cc6acd4b000081565b3480156102f457600080fd5b5061014560035481565b34801561030a57600080fd5b506101456701df9dc8e4ad800081565b34801561032657600080fd5b506000546001600160a01b03165b6040516001600160a01b03909116815260200161014f565b61014561035a366004611207565b61099a565b34801561036b57600080fd5b5061017861037a3660046111ec565b610e08565b34801561038b57600080fd5b50600254610334906001600160a01b031681565b6103a7610e46565b60025460405163a9059cbb60e01b8152336004820152602481018390526000916001600160a01b03169063a9059cbb906044016020604051808303816000875af11580156103f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041d9190611249565b9050806104685760405162461bcd60e51b8152602060048201526014602482015273151bdad95b881c995b5bdd985b0819985a5b195960621b60448201526064015b60405180910390fd5b60408051338152602081018490527f680f2e4f4032ebf1774e8cdbaddcb1b617a5a606411c8ca96257ada338d3833c91015b60405180910390a15050565b6104ae610e46565b80518251146104ff5760405162461bcd60e51b815260206004820152601a60248201527f4172726179206c656e6774687320646f206e6f74206d61746368000000000000604482015260640161045f565b81516000805b828110156105465783818151811061051f5761051f61126b565b6020026020010151826105329190611297565b91508061053e816112aa565b915050610505565b506002546040516370a0823160e01b815230600482015282916001600160a01b0316906370a0823190602401602060405180830381865afa15801561058f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105b391906112c3565b10156105d15760405162461bcd60e51b815260040161045f906112dc565b60005b828110156106ae5760025485516001600160a01b039091169063a9059cbb908790849081106106055761060561126b565b602002602001015186848151811061061f5761061f61126b565b60200260200101516040518363ffffffff1660e01b81526004016106589291906001600160a01b03929092168252602082015260400190565b6020604051808303816000875af1158015610677573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061069b9190611249565b50806106a6816112aa565b9150506105d4565b5050505050565b6106bd610e46565b60028111156107025760405162461bcd60e51b81526020600482015260116024820152700496e76616c69642073616c65207374657607c1b604482015260640161045f565b60065481036107645760405162461bcd60e51b815260206004820152602860248201527f4e65772073746570206973207468652073616d652061732074686520637572726044820152670656e7420737465760c41b606482015260840161045f565b600681905560408051338152602081018390527fb82a32d8800e63db99c3d179cfbc6dd13b7551923fd2633218231715ee694ab891015b60405180910390a150565b6040516bffffffffffffffffffffffff19606085901b1660208201526000908190603401604051602081830303815290604052805190602001209050610823848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506008549150849050610e73565b95945050505050565b610834610e46565b61083e6000610e89565b565b610848610e46565b478061088c5760405162461bcd60e51b81526020600482015260136024820152724e6f7468696e6720746f20776974686472617760681b604482015260640161045f565b600080546040516001600160a01b039091169083908381818185875af1925050503d80600081146108d9576040519150601f19603f3d011682016040523d82523d6000602084013e6108de565b606091505b50509050806109215760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b604482015260640161045f565b60408051338152602081018490527fdb35132c111efe920cede025e819975671cfd1b8fcc1174762c8670c4e94c211910161049a565b61095f610e46565b600881905560408051338152602081018390527f2d3b238aa223af835b06f5ddeb56c45951f7cf4a29ab728434765ef33cb7598f910161079b565b60006109a4610ed9565b6006546000036109e95760405162461bcd60e51b815260206004820152601060248201526f53616c6573206e6f742061637469766560801b604482015260640161045f565b60006109f63385856107a6565b90506006546001141580610a075750805b610a485760405162461bcd60e51b8152602060048201526012602482015271507269766174652073616c6573206f6e6c7960701b604482015260640161045f565b6002546040805163313ce56760e01b815290516000926001600160a01b03169163313ce5679160048083019260209291908290030181865afa158015610a92573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ab691906112c3565b610ac190600a611406565b90506000600654600114610add576701df9dc8e4ad8000610ae7565b670186cc6acd4b00005b90506000600654600114610b085782600354610b039190611412565b610b16565b82600454610b169190611412565b9050600082610b258534611412565b610b2f9190611429565b336000908152600960205260409020549091508290610b4f908390611297565b1115610ba85760405162461bcd60e51b815260206004820152602260248201527f4578636565646564206d61782062757920616d6f756e74207065722077616c6c604482015261195d60f21b606482015260840161045f565b6002546040516370a0823160e01b815230600482015282916001600160a01b0316906370a0823190602401602060405180830381865afa158015610bf0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c1491906112c3565b1015610c325760405162461bcd60e51b815260040161045f906112dc565b6006546001141580610c5e575083600554610c4d9190611412565b81600754610c5b9190611297565b11155b610cbe5760405162461bcd60e51b815260206004820152602b60248201527f4d61782073616c657320616d6f756e7420657863656564656420666f7220707260448201526a69766174652073616c657360a81b606482015260840161045f565b3360009081526009602052604081208054839290610cdd908490611297565b925050819055508060076000828254610cf69190611297565b909155505060025460405163a9059cbb60e01b8152336004820152602481018390526000916001600160a01b03169063a9059cbb906044016020604051808303816000875af1158015610d4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d719190611249565b905080610db25760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b604482015260640161045f565b604080513381523460208201529081018390527f0a37b72bb67eee30e09084cf386f8a17817c57f620c3ab95fb25d6a20356ec779060600160405180910390a150945050505050610e0260018055565b92915050565b610e10610e46565b6001600160a01b038116610e3a57604051631e4fbdf760e01b81526000600482015260240161045f565b610e4381610e89565b50565b6000546001600160a01b0316331461083e5760405163118cdaa760e01b815233600482015260240161045f565b600082610e808584610f03565b14949350505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600260015403610efc57604051633ee5aeb560e01b815260040160405180910390fd5b6002600155565b600081815b8451811015610f4857610f3482868381518110610f2757610f2761126b565b6020026020010151610f50565b915080610f40816112aa565b915050610f08565b509392505050565b6000818310610f6c576000828152602084905260409020610f7b565b60008381526020839052604090205b9392505050565b600060208284031215610f9457600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715610fda57610fda610f9b565b604052919050565b600067ffffffffffffffff821115610ffc57610ffc610f9b565b5060051b60200190565b80356001600160a01b038116811461101d57600080fd5b919050565b600082601f83011261103357600080fd5b8135602061104861104383610fe2565b610fb1565b82815260059290921b8401810191818101908684111561106757600080fd5b8286015b84811015611082578035835291830191830161106b565b509695505050505050565b600080604083850312156110a057600080fd5b823567ffffffffffffffff808211156110b857600080fd5b818501915085601f8301126110cc57600080fd5b813560206110dc61104383610fe2565b82815260059290921b840181019181810190898411156110fb57600080fd5b948201945b838610156111205761111186611006565b82529482019490820190611100565b9650508601359250508082111561113657600080fd5b5061114385828601611022565b9150509250929050565b60008083601f84011261115f57600080fd5b50813567ffffffffffffffff81111561117757600080fd5b6020830191508360208260051b850101111561119257600080fd5b9250929050565b6000806000604084860312156111ae57600080fd5b6111b784611006565b9250602084013567ffffffffffffffff8111156111d357600080fd5b6111df8682870161114d565b9497909650939450505050565b6000602082840312156111fe57600080fd5b610f7b82611006565b6000806020838503121561121a57600080fd5b823567ffffffffffffffff81111561123157600080fd5b61123d8582860161114d565b90969095509350505050565b60006020828403121561125b57600080fd5b81518015158114610f7b57600080fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115610e0257610e02611281565b6000600182016112bc576112bc611281565b5060010190565b6000602082840312156112d557600080fd5b5051919050565b60208082526026908201527f496e73756666696369656e7420746f6b656e2062616c616e636520696e20636f6040820152651b9d1c9858dd60d21b606082015260800190565b600181815b8085111561135d57816000190482111561134357611343611281565b8085161561135057918102915b93841c9390800290611327565b509250929050565b60008261137457506001610e02565b8161138157506000610e02565b816001811461139757600281146113a1576113bd565b6001915050610e02565b60ff8411156113b2576113b2611281565b50506001821b610e02565b5060208310610133831016604e8410600b84101617156113e0575081810a610e02565b6113ea8383611322565b80600019048211156113fe576113fe611281565b029392505050565b6000610f7b8383611365565b8082028115828204841417610e0257610e02611281565b60008261144657634e487b7160e01b600052601260045260246000fd5b50049056fea2646970667358221220bbb5381b4a5cb22b381caaf249eb327676462fab5285a1d4f813d8cb71bbca3a64736f6c63430008140033000000000000000000000000ecdb004045981602c19efa99759346ab06957aeacd2487ec9c686362ca6e35832d849c3d7cd2d57d04599a26f2ce48cea306245d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000190

Deployed Bytecode

0x60806040526004361061012a5760003560e01c806364ec130c116100ab578063894c1d401161006f578063894c1d40146102e85780638d859f3e146102fe5780638da5cb5b1461031a578063ab98089f1461034c578063f2fde38b1461035f578063fc0c546a1461037f57600080fd5b806364ec130c14610255578063715018a6146102825780637362377b146102975780637cb64759146102ac57806380161359146102cc57600080fd5b80634bd09c2a116100f25780634bd09c2a146101bc5780634e6630b0146101dc57806353e90cbd146101ef5780635a23dd991461020f5780635a7b094e1461023f57600080fd5b80632eb4a7ab1461012f578063315a095d1461015857806339ca27e51461017a5780634a2aac30146101905780634a91f195146101a6575b600080fd5b34801561013b57600080fd5b5061014560085481565b6040519081526020015b60405180910390f35b34801561016457600080fd5b50610178610173366004610f82565b61039f565b005b34801561018657600080fd5b5061014560055481565b34801561019c57600080fd5b5061014560065481565b3480156101b257600080fd5b5061014560075481565b3480156101c857600080fd5b506101786101d736600461108d565b6104a6565b3480156101e857600080fd5b5047610145565b3480156101fb57600080fd5b5061017861020a366004610f82565b6106b5565b34801561021b57600080fd5b5061022f61022a366004611199565b6107a6565b604051901515815260200161014f565b34801561024b57600080fd5b5061014560045481565b34801561026157600080fd5b506101456102703660046111ec565b60096020526000908152604090205481565b34801561028e57600080fd5b5061017861082c565b3480156102a357600080fd5b50610178610840565b3480156102b857600080fd5b506101786102c7366004610f82565b610957565b3480156102d857600080fd5b50610145670186cc6acd4b000081565b3480156102f457600080fd5b5061014560035481565b34801561030a57600080fd5b506101456701df9dc8e4ad800081565b34801561032657600080fd5b506000546001600160a01b03165b6040516001600160a01b03909116815260200161014f565b61014561035a366004611207565b61099a565b34801561036b57600080fd5b5061017861037a3660046111ec565b610e08565b34801561038b57600080fd5b50600254610334906001600160a01b031681565b6103a7610e46565b60025460405163a9059cbb60e01b8152336004820152602481018390526000916001600160a01b03169063a9059cbb906044016020604051808303816000875af11580156103f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061041d9190611249565b9050806104685760405162461bcd60e51b8152602060048201526014602482015273151bdad95b881c995b5bdd985b0819985a5b195960621b60448201526064015b60405180910390fd5b60408051338152602081018490527f680f2e4f4032ebf1774e8cdbaddcb1b617a5a606411c8ca96257ada338d3833c91015b60405180910390a15050565b6104ae610e46565b80518251146104ff5760405162461bcd60e51b815260206004820152601a60248201527f4172726179206c656e6774687320646f206e6f74206d61746368000000000000604482015260640161045f565b81516000805b828110156105465783818151811061051f5761051f61126b565b6020026020010151826105329190611297565b91508061053e816112aa565b915050610505565b506002546040516370a0823160e01b815230600482015282916001600160a01b0316906370a0823190602401602060405180830381865afa15801561058f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105b391906112c3565b10156105d15760405162461bcd60e51b815260040161045f906112dc565b60005b828110156106ae5760025485516001600160a01b039091169063a9059cbb908790849081106106055761060561126b565b602002602001015186848151811061061f5761061f61126b565b60200260200101516040518363ffffffff1660e01b81526004016106589291906001600160a01b03929092168252602082015260400190565b6020604051808303816000875af1158015610677573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061069b9190611249565b50806106a6816112aa565b9150506105d4565b5050505050565b6106bd610e46565b60028111156107025760405162461bcd60e51b81526020600482015260116024820152700496e76616c69642073616c65207374657607c1b604482015260640161045f565b60065481036107645760405162461bcd60e51b815260206004820152602860248201527f4e65772073746570206973207468652073616d652061732074686520637572726044820152670656e7420737465760c41b606482015260840161045f565b600681905560408051338152602081018390527fb82a32d8800e63db99c3d179cfbc6dd13b7551923fd2633218231715ee694ab891015b60405180910390a150565b6040516bffffffffffffffffffffffff19606085901b1660208201526000908190603401604051602081830303815290604052805190602001209050610823848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506008549150849050610e73565b95945050505050565b610834610e46565b61083e6000610e89565b565b610848610e46565b478061088c5760405162461bcd60e51b81526020600482015260136024820152724e6f7468696e6720746f20776974686472617760681b604482015260640161045f565b600080546040516001600160a01b039091169083908381818185875af1925050503d80600081146108d9576040519150601f19603f3d011682016040523d82523d6000602084013e6108de565b606091505b50509050806109215760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b604482015260640161045f565b60408051338152602081018490527fdb35132c111efe920cede025e819975671cfd1b8fcc1174762c8670c4e94c211910161049a565b61095f610e46565b600881905560408051338152602081018390527f2d3b238aa223af835b06f5ddeb56c45951f7cf4a29ab728434765ef33cb7598f910161079b565b60006109a4610ed9565b6006546000036109e95760405162461bcd60e51b815260206004820152601060248201526f53616c6573206e6f742061637469766560801b604482015260640161045f565b60006109f63385856107a6565b90506006546001141580610a075750805b610a485760405162461bcd60e51b8152602060048201526012602482015271507269766174652073616c6573206f6e6c7960701b604482015260640161045f565b6002546040805163313ce56760e01b815290516000926001600160a01b03169163313ce5679160048083019260209291908290030181865afa158015610a92573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ab691906112c3565b610ac190600a611406565b90506000600654600114610add576701df9dc8e4ad8000610ae7565b670186cc6acd4b00005b90506000600654600114610b085782600354610b039190611412565b610b16565b82600454610b169190611412565b9050600082610b258534611412565b610b2f9190611429565b336000908152600960205260409020549091508290610b4f908390611297565b1115610ba85760405162461bcd60e51b815260206004820152602260248201527f4578636565646564206d61782062757920616d6f756e74207065722077616c6c604482015261195d60f21b606482015260840161045f565b6002546040516370a0823160e01b815230600482015282916001600160a01b0316906370a0823190602401602060405180830381865afa158015610bf0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c1491906112c3565b1015610c325760405162461bcd60e51b815260040161045f906112dc565b6006546001141580610c5e575083600554610c4d9190611412565b81600754610c5b9190611297565b11155b610cbe5760405162461bcd60e51b815260206004820152602b60248201527f4d61782073616c657320616d6f756e7420657863656564656420666f7220707260448201526a69766174652073616c657360a81b606482015260840161045f565b3360009081526009602052604081208054839290610cdd908490611297565b925050819055508060076000828254610cf69190611297565b909155505060025460405163a9059cbb60e01b8152336004820152602481018390526000916001600160a01b03169063a9059cbb906044016020604051808303816000875af1158015610d4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d719190611249565b905080610db25760405162461bcd60e51b815260206004820152600f60248201526e151c985b9cd9995c8819985a5b1959608a1b604482015260640161045f565b604080513381523460208201529081018390527f0a37b72bb67eee30e09084cf386f8a17817c57f620c3ab95fb25d6a20356ec779060600160405180910390a150945050505050610e0260018055565b92915050565b610e10610e46565b6001600160a01b038116610e3a57604051631e4fbdf760e01b81526000600482015260240161045f565b610e4381610e89565b50565b6000546001600160a01b0316331461083e5760405163118cdaa760e01b815233600482015260240161045f565b600082610e808584610f03565b14949350505050565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600260015403610efc57604051633ee5aeb560e01b815260040160405180910390fd5b6002600155565b600081815b8451811015610f4857610f3482868381518110610f2757610f2761126b565b6020026020010151610f50565b915080610f40816112aa565b915050610f08565b509392505050565b6000818310610f6c576000828152602084905260409020610f7b565b60008381526020839052604090205b9392505050565b600060208284031215610f9457600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f1916810167ffffffffffffffff81118282101715610fda57610fda610f9b565b604052919050565b600067ffffffffffffffff821115610ffc57610ffc610f9b565b5060051b60200190565b80356001600160a01b038116811461101d57600080fd5b919050565b600082601f83011261103357600080fd5b8135602061104861104383610fe2565b610fb1565b82815260059290921b8401810191818101908684111561106757600080fd5b8286015b84811015611082578035835291830191830161106b565b509695505050505050565b600080604083850312156110a057600080fd5b823567ffffffffffffffff808211156110b857600080fd5b818501915085601f8301126110cc57600080fd5b813560206110dc61104383610fe2565b82815260059290921b840181019181810190898411156110fb57600080fd5b948201945b838610156111205761111186611006565b82529482019490820190611100565b9650508601359250508082111561113657600080fd5b5061114385828601611022565b9150509250929050565b60008083601f84011261115f57600080fd5b50813567ffffffffffffffff81111561117757600080fd5b6020830191508360208260051b850101111561119257600080fd5b9250929050565b6000806000604084860312156111ae57600080fd5b6111b784611006565b9250602084013567ffffffffffffffff8111156111d357600080fd5b6111df8682870161114d565b9497909650939450505050565b6000602082840312156111fe57600080fd5b610f7b82611006565b6000806020838503121561121a57600080fd5b823567ffffffffffffffff81111561123157600080fd5b61123d8582860161114d565b90969095509350505050565b60006020828403121561125b57600080fd5b81518015158114610f7b57600080fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115610e0257610e02611281565b6000600182016112bc576112bc611281565b5060010190565b6000602082840312156112d557600080fd5b5051919050565b60208082526026908201527f496e73756666696369656e7420746f6b656e2062616c616e636520696e20636f6040820152651b9d1c9858dd60d21b606082015260800190565b600181815b8085111561135d57816000190482111561134357611343611281565b8085161561135057918102915b93841c9390800290611327565b509250929050565b60008261137457506001610e02565b8161138157506000610e02565b816001811461139757600281146113a1576113bd565b6001915050610e02565b60ff8411156113b2576113b2611281565b50506001821b610e02565b5060208310610133831016604e8410600b84101617156113e0575081810a610e02565b6113ea8383611322565b80600019048211156113fe576113fe611281565b029392505050565b6000610f7b8383611365565b8082028115828204841417610e0257610e02611281565b60008261144657634e487b7160e01b600052601260045260246000fd5b50049056fea2646970667358221220bbb5381b4a5cb22b381caaf249eb327676462fab5285a1d4f813d8cb71bbca3a64736f6c63430008140033

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

000000000000000000000000ecdb004045981602c19efa99759346ab06957aeacd2487ec9c686362ca6e35832d849c3d7cd2d57d04599a26f2ce48cea306245d000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000190

-----Decoded View---------------
Arg [0] : _tokenAddress (address): 0xEcdb004045981602c19EFA99759346aB06957AEa
Arg [1] : _merkleRoot (bytes32): 0xcd2487ec9c686362ca6e35832d849c3d7cd2d57d04599a26f2ce48cea306245d
Arg [2] : _maxBuyAmountPerWallet (uint256): 10
Arg [3] : _maxBuyAmountPerWalletForWLSales (uint256): 5
Arg [4] : _maxBuyAmountForWLSalesPeriod (uint256): 400

-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 000000000000000000000000ecdb004045981602c19efa99759346ab06957aea
Arg [1] : cd2487ec9c686362ca6e35832d849c3d7cd2d57d04599a26f2ce48cea306245d
Arg [2] : 000000000000000000000000000000000000000000000000000000000000000a
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000190


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.