ETH Price: $2,085.87 (+1.88%)
 

Overview

Max Total Supply

10,000,000,000 MAOMAO

Holders

7,350 (0.00%)

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 18 Decimals)

Filtered by Token Holder
FixedFloat 1
Balance
5,000 MAOMAO

Value
$0.00
0x4e5b2e1dc63f6b91cb6cd759936495434c7e972f
Loading...
Loading
Loading...
Loading
Loading...
Loading

OVERVIEW

MAOMAO is a meme-fueled economy where every trade rewards holders and every NFT boosts your yield.

# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
MaoMao

Compiler Version
v0.8.25+commit.b61c2a91

Optimization Enabled:
Yes with 200 runs

Other Settings:
paris EvmVersion
// SPDX-License-Identifier: MIT
pragma solidity 0.8.25;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/access/Ownable.sol";

//     /\/\/\                          /\/\/\
//    /      \                        /      \
//   /  /\    \         MAOMAO       /    /\  \
//  /  /  \    \                    /    /  \  \
// /__/    \____\                  /____/    \__\

interface INFT {
    function mint(address to, uint256 quantity, uint8 level) external;
}

contract MaoMao is ERC20, Ownable {
    uint256 public constant INITIAL_SUPPLY = 10_000_000_000 * 10 ** 18;

    uint256 private constant FEE_PERCENT = 25; 
    uint256 private constant DIVIDEND_PERCENT = 25; 
    uint256 private constant PERCENT_DIVISOR = 1000;
    uint256 private constant apeThreshold = 0.1 ether;
    uint256 private apeRewardRate = 300000 * 10 ** uint256(decimals());
    uint256[] private milestoneThresholds = [
        5 ether,
        10 ether,
        15 ether,
        30 ether
    ];
    uint256[] private milestoneRewardAmounts = [
        750000, 
        1500000,
        2250000,
        4500000
    ];
    uint256 private presaleTxCount;

    bool public isApingTime = true;
    address public dividendContract;
    address public mainPair;

    mapping(address => uint256) private claimedMilestoneReward;
    mapping(address => uint256) private userContributions;
    mapping(address => bool) public liquidityProviders;
    mapping(address => mapping(uint8 => bool)) private rewardMinted;
    INFT public NFTContract;

    event UserApedIn(
        uint256 indexed eventId,
        address indexed sender,
        uint256 indexed value
    );


    constructor() ERC20("MAOMAO", "MAOMAO") Ownable(msg.sender) {
        _mint(address(this), INITIAL_SUPPLY);
    }

    function apeIn() external payable {
        require(isApingTime, "Too late fren, the degen gate is shut!");
        require(owner() != address(0), "No degen overlord assigned yet");
        require(msg.value >= apeThreshold, "Not enough ETH to ape in");

        uint256 tokensToReceive = (msg.value * apeRewardRate) / apeThreshold;
        require(
            balanceOf(address(this)) >= tokensToReceive,
            "Not enough tokens left in the vault"
        );
        super._transfer(address(this), msg.sender, tokensToReceive);
        userContributions[msg.sender] =
            userContributions[msg.sender] +
            msg.value;

        distributeMilestoneReward(msg.sender);
        presaleTxCount++;
        emit UserApedIn(presaleTxCount, msg.sender, msg.value);
    }

    function distributeMilestoneReward(address user) internal {
        uint256 totalReward = 0; // Total token rewards currently due
        uint256 userDeposit = userContributions[user]; // Accumulated deposits of users
        // Traverse reward levels
        for (uint8 level = 1; level <= 4; level++) {
            uint256 threshold = milestoneThresholds[level - 1];
            uint256 reward = milestoneRewardAmounts[level - 1] *
                (10 ** decimals());
            // Check if the reward level is reached
            if (userDeposit >= threshold) {
                // Update token rewards
                totalReward = reward;
                // Check if mint method needs to be called
                if (address(NFTContract) != address(0)) {
                    if (!rewardMinted[user][level]) {
                        rewardMinted[user][level] = true; // Mark the reward for this level as received
                        NFTContract.mint(user, 1, level); // Call NFT mint method
                    }
                }
            } else {
                break; // User deposit is not enough to reach the next level
            }
        }

        // Check the total amount of token rewards claimed
        uint256 claimedReward = claimedMilestoneReward[user];

        // If the total token reward is greater than the received reward, the difference will be reissued
        if (totalReward > claimedReward) {
            uint256 rewardToSend = totalReward - claimedReward; // Calculate the difference
            require(
                balanceOf(address(this)) >= rewardToSend,
                "Owner does not have enough tokens for rewards"
            );
            claimedMilestoneReward[user] = totalReward; // Update the total amount of rewards claimed
            super._transfer(address(this), user, rewardToSend); // Issue token rewards
        }
    }

    function setNftContract(address _contract) external onlyOwner {
        NFTContract = INFT(_contract);
    }

    function endApingTime() external onlyOwner {
        require(isApingTime, "Aping already ended");
        isApingTime = false;
    }

    function batchDistributeTokens(
        address[] memory recipients,
        uint256 amount
    ) external onlyOwner {
        require(
            owner() != address(0),
            "Owner address is zero, operation not allowed"
        );
        for (uint i = 0; i < recipients.length; i++) {
            super._transfer(address(this), recipients[i], amount);
        }
    }

    function isAddressContract(address account) internal view returns (bool) {
        return account.code.length > 0;
    }

    function addLiquidityProvider(address _addr) external onlyOwner {
        liquidityProviders[_addr] = true;
    }

    function removeLiquidityProvider(address _addr) external onlyOwner {
        liquidityProviders[_addr] = false;
    }

    function isUnauthorizedLiquidityAddition(
        address to
    ) internal view returns (bool) {
        return
            isAddressContract(to) && (!liquidityProviders[to] && isApingTime);
    }

    function _update(
        address from,
        address to,
        uint256 amount
    ) internal override {
        if (isUnauthorizedLiquidityAddition(to)) {
            revert("Only chosen degens can summon liquidity rn.");
        }

        bool takeFee = false;
        if (mainPair != address(0) && (from == mainPair || to == mainPair)) {
            if (dividendContract == address(0)) {
                takeFee = false;
            } else {
                takeFee = true;
            }
        }

        if (takeFee) {
            uint256 fee = (amount * FEE_PERCENT) / PERCENT_DIVISOR;
            uint256 dividend = (amount * DIVIDEND_PERCENT) / PERCENT_DIVISOR;

            super._update(from, dividendContract, dividend);

            uint256 remaining = amount - fee;
            super._update(from, to, remaining);
        } else {
            super._update(from, to, amount);
        }
    }

    function setMainPair(address pair) external onlyOwner {
        require(pair != address(0), "Invalid address");
        mainPair = pair;
    }

    function setDividendContract(address _contract) external onlyOwner {
        require(_contract != address(0), "Invalid address");
        dividendContract = _contract;
    }

    function rescueAssets(
        address tokenAddress,
        uint256 amount,
        address to
    ) external onlyOwner {
        require(to != address(0), "Invalid recipient address");

        if (tokenAddress == address(0)) {
            require(
                amount <= address(this).balance,
                "Insufficient contract balance"
            );
            (bool success, ) = payable(to).call{value: amount}("");
            require(success, "ETH transfer failed");
            return;
        }

        IERC20 token = IERC20(tokenAddress);
        uint256 contractBalance = token.balanceOf(address(this));

        require(amount <= contractBalance, "Insufficient balance in contract");

        bool tokenSuccess = token.transfer(to, amount);
        require(tokenSuccess, "Token transfer failed");
    }
}

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

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (interfaces/draft-IERC6093.sol)
pragma solidity ^0.8.20;

/**
 * @dev Standard ERC-20 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-20 tokens.
 */
interface IERC20Errors {
    /**
     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param balance Current balance for the interacting account.
     * @param needed Minimum amount required to perform a transfer.
     */
    error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC20InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC20InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers.
     * @param spender Address that may be allowed to operate on tokens without being their owner.
     * @param allowance Amount of tokens a `spender` is allowed to operate with.
     * @param needed Minimum amount required to perform a transfer.
     */
    error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC20InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `spender` to be approved. Used in approvals.
     * @param spender Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC20InvalidSpender(address spender);
}

/**
 * @dev Standard ERC-721 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-721 tokens.
 */
interface IERC721Errors {
    /**
     * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in ERC-20.
     * Used in balance queries.
     * @param owner Address of the current owner of a token.
     */
    error ERC721InvalidOwner(address owner);

    /**
     * @dev Indicates a `tokenId` whose `owner` is the zero address.
     * @param tokenId Identifier number of a token.
     */
    error ERC721NonexistentToken(uint256 tokenId);

    /**
     * @dev Indicates an error related to the ownership over a particular token. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param tokenId Identifier number of a token.
     * @param owner Address of the current owner of a token.
     */
    error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC721InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC721InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     * @param tokenId Identifier number of a token.
     */
    error ERC721InsufficientApproval(address operator, uint256 tokenId);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC721InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC721InvalidOperator(address operator);
}

/**
 * @dev Standard ERC-1155 Errors
 * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC-1155 tokens.
 */
interface IERC1155Errors {
    /**
     * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     * @param balance Current balance for the interacting account.
     * @param needed Minimum amount required to perform a transfer.
     * @param tokenId Identifier number of a token.
     */
    error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId);

    /**
     * @dev Indicates a failure with the token `sender`. Used in transfers.
     * @param sender Address whose tokens are being transferred.
     */
    error ERC1155InvalidSender(address sender);

    /**
     * @dev Indicates a failure with the token `receiver`. Used in transfers.
     * @param receiver Address to which tokens are being transferred.
     */
    error ERC1155InvalidReceiver(address receiver);

    /**
     * @dev Indicates a failure with the `operator`’s approval. Used in transfers.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     * @param owner Address of the current owner of a token.
     */
    error ERC1155MissingApprovalForAll(address operator, address owner);

    /**
     * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals.
     * @param approver Address initiating an approval operation.
     */
    error ERC1155InvalidApprover(address approver);

    /**
     * @dev Indicates a failure with the `operator` to be approved. Used in approvals.
     * @param operator Address that may be allowed to operate on tokens without being their owner.
     */
    error ERC1155InvalidOperator(address operator);

    /**
     * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation.
     * Used in batch transfers.
     * @param idsLength Length of the array of token identifiers
     * @param valuesLength Length of the array of token amounts
     */
    error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.3.0) (token/ERC20/ERC20.sol)

pragma solidity ^0.8.20;

import {IERC20} from "./IERC20.sol";
import {IERC20Metadata} from "./extensions/IERC20Metadata.sol";
import {Context} from "../../utils/Context.sol";
import {IERC20Errors} from "../../interfaces/draft-IERC6093.sol";

/**
 * @dev Implementation of the {IERC20} interface.
 *
 * This implementation is agnostic to the way tokens are created. This means
 * that a supply mechanism has to be added in a derived contract using {_mint}.
 *
 * TIP: For a detailed writeup see our guide
 * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How
 * to implement supply mechanisms].
 *
 * The default value of {decimals} is 18. To change this, you should override
 * this function so it returns a different value.
 *
 * We have followed general OpenZeppelin Contracts guidelines: functions revert
 * instead returning `false` on failure. This behavior is nonetheless
 * conventional and does not conflict with the expectations of ERC-20
 * applications.
 */
abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors {
    mapping(address account => uint256) private _balances;

    mapping(address account => mapping(address spender => uint256)) private _allowances;

    uint256 private _totalSupply;

    string private _name;
    string private _symbol;

    /**
     * @dev Sets the values for {name} and {symbol}.
     *
     * Both values are immutable: they can only be set once during construction.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

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

    /**
     * @dev Returns the symbol of the token, usually a shorter version of the
     * name.
     */
    function symbol() public view virtual returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns the number of decimals used to get its user representation.
     * For example, if `decimals` equals `2`, a balance of `505` tokens should
     * be displayed to a user as `5.05` (`505 / 10 ** 2`).
     *
     * Tokens usually opt for a value of 18, imitating the relationship between
     * Ether and Wei. This is the default value returned by this function, unless
     * it's overridden.
     *
     * NOTE: This information is only used for _display_ purposes: it in
     * no way affects any of the arithmetic of the contract, including
     * {IERC20-balanceOf} and {IERC20-transfer}.
     */
    function decimals() public view virtual returns (uint8) {
        return 18;
    }

    /**
     * @dev See {IERC20-totalSupply}.
     */
    function totalSupply() public view virtual returns (uint256) {
        return _totalSupply;
    }

    /**
     * @dev See {IERC20-balanceOf}.
     */
    function balanceOf(address account) public view virtual returns (uint256) {
        return _balances[account];
    }

    /**
     * @dev See {IERC20-transfer}.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - the caller must have a balance of at least `value`.
     */
    function transfer(address to, uint256 value) public virtual returns (bool) {
        address owner = _msgSender();
        _transfer(owner, to, value);
        return true;
    }

    /**
     * @dev See {IERC20-allowance}.
     */
    function allowance(address owner, address spender) public view virtual returns (uint256) {
        return _allowances[owner][spender];
    }

    /**
     * @dev See {IERC20-approve}.
     *
     * NOTE: If `value` is the maximum `uint256`, the allowance is not updated on
     * `transferFrom`. This is semantically equivalent to an infinite approval.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function approve(address spender, uint256 value) public virtual returns (bool) {
        address owner = _msgSender();
        _approve(owner, spender, value);
        return true;
    }

    /**
     * @dev See {IERC20-transferFrom}.
     *
     * Skips emitting an {Approval} event indicating an allowance update. This is not
     * required by the ERC. See {xref-ERC20-_approve-address-address-uint256-bool-}[_approve].
     *
     * NOTE: Does not update the allowance if the current allowance
     * is the maximum `uint256`.
     *
     * Requirements:
     *
     * - `from` and `to` cannot be the zero address.
     * - `from` must have a balance of at least `value`.
     * - the caller must have allowance for ``from``'s tokens of at least
     * `value`.
     */
    function transferFrom(address from, address to, uint256 value) public virtual returns (bool) {
        address spender = _msgSender();
        _spendAllowance(from, spender, value);
        _transfer(from, to, value);
        return true;
    }

    /**
     * @dev Moves a `value` amount of tokens from `from` to `to`.
     *
     * This internal function is equivalent to {transfer}, and can be used to
     * e.g. implement automatic token fees, slashing mechanisms, etc.
     *
     * Emits a {Transfer} event.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead.
     */
    function _transfer(address from, address to, uint256 value) internal {
        if (from == address(0)) {
            revert ERC20InvalidSender(address(0));
        }
        if (to == address(0)) {
            revert ERC20InvalidReceiver(address(0));
        }
        _update(from, to, value);
    }

    /**
     * @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from`
     * (or `to`) is the zero address. All customizations to transfers, mints, and burns should be done by overriding
     * this function.
     *
     * Emits a {Transfer} event.
     */
    function _update(address from, address to, uint256 value) internal virtual {
        if (from == address(0)) {
            // Overflow check required: The rest of the code assumes that totalSupply never overflows
            _totalSupply += value;
        } else {
            uint256 fromBalance = _balances[from];
            if (fromBalance < value) {
                revert ERC20InsufficientBalance(from, fromBalance, value);
            }
            unchecked {
                // Overflow not possible: value <= fromBalance <= totalSupply.
                _balances[from] = fromBalance - value;
            }
        }

        if (to == address(0)) {
            unchecked {
                // Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply.
                _totalSupply -= value;
            }
        } else {
            unchecked {
                // Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256.
                _balances[to] += value;
            }
        }

        emit Transfer(from, to, value);
    }

    /**
     * @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0).
     * Relies on the `_update` mechanism
     *
     * Emits a {Transfer} event with `from` set to the zero address.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead.
     */
    function _mint(address account, uint256 value) internal {
        if (account == address(0)) {
            revert ERC20InvalidReceiver(address(0));
        }
        _update(address(0), account, value);
    }

    /**
     * @dev Destroys a `value` amount of tokens from `account`, lowering the total supply.
     * Relies on the `_update` mechanism.
     *
     * Emits a {Transfer} event with `to` set to the zero address.
     *
     * NOTE: This function is not virtual, {_update} should be overridden instead
     */
    function _burn(address account, uint256 value) internal {
        if (account == address(0)) {
            revert ERC20InvalidSender(address(0));
        }
        _update(account, address(0), value);
    }

    /**
     * @dev Sets `value` as the allowance of `spender` over the `owner`'s tokens.
     *
     * This internal function is equivalent to `approve`, and can be used to
     * e.g. set automatic allowances for certain subsystems, etc.
     *
     * Emits an {Approval} event.
     *
     * Requirements:
     *
     * - `owner` cannot be the zero address.
     * - `spender` cannot be the zero address.
     *
     * Overrides to this logic should be done to the variant with an additional `bool emitEvent` argument.
     */
    function _approve(address owner, address spender, uint256 value) internal {
        _approve(owner, spender, value, true);
    }

    /**
     * @dev Variant of {_approve} with an optional flag to enable or disable the {Approval} event.
     *
     * By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by
     * `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any
     * `Approval` event during `transferFrom` operations.
     *
     * Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to
     * true using the following override:
     *
     * ```solidity
     * function _approve(address owner, address spender, uint256 value, bool) internal virtual override {
     *     super._approve(owner, spender, value, true);
     * }
     * ```
     *
     * Requirements are the same as {_approve}.
     */
    function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual {
        if (owner == address(0)) {
            revert ERC20InvalidApprover(address(0));
        }
        if (spender == address(0)) {
            revert ERC20InvalidSpender(address(0));
        }
        _allowances[owner][spender] = value;
        if (emitEvent) {
            emit Approval(owner, spender, value);
        }
    }

    /**
     * @dev Updates `owner`'s allowance for `spender` based on spent `value`.
     *
     * Does not update the allowance value in case of infinite allowance.
     * Revert if not enough allowance is available.
     *
     * Does not emit an {Approval} event.
     */
    function _spendAllowance(address owner, address spender, uint256 value) internal virtual {
        uint256 currentAllowance = allowance(owner, spender);
        if (currentAllowance < type(uint256).max) {
            if (currentAllowance < value) {
                revert ERC20InsufficientAllowance(spender, currentAllowance, value);
            }
            unchecked {
                _approve(owner, spender, currentAllowance - value, false);
            }
        }
    }
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC20/extensions/IERC20Metadata.sol)

pragma solidity ^0.8.20;

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

/**
 * @dev Interface for the optional metadata functions from the ERC-20 standard.
 */
interface IERC20Metadata is IERC20 {
    /**
     * @dev Returns the name of the token.
     */
    function name() external view returns (string memory);

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

    /**
     * @dev Returns the decimals places of the token.
     */
    function decimals() external view returns (uint8);
}

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.1.0) (token/ERC20/IERC20.sol)

pragma solidity ^0.8.20;

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

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

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

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

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

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

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

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

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

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

Contract Security Audit

Contract ABI

API
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"allowance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientAllowance","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"balance","type":"uint256"},{"internalType":"uint256","name":"needed","type":"uint256"}],"name":"ERC20InsufficientBalance","type":"error"},{"inputs":[{"internalType":"address","name":"approver","type":"address"}],"name":"ERC20InvalidApprover","type":"error"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"}],"name":"ERC20InvalidReceiver","type":"error"},{"inputs":[{"internalType":"address","name":"sender","type":"address"}],"name":"ERC20InvalidSender","type":"error"},{"inputs":[{"internalType":"address","name":"spender","type":"address"}],"name":"ERC20InvalidSpender","type":"error"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"eventId","type":"uint256"},{"indexed":true,"internalType":"address","name":"sender","type":"address"},{"indexed":true,"internalType":"uint256","name":"value","type":"uint256"}],"name":"UserApedIn","type":"event"},{"inputs":[],"name":"INITIAL_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"NFTContract","outputs":[{"internalType":"contract INFT","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"addLiquidityProvider","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"apeIn","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"recipients","type":"address[]"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"batchDistributeTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"dividendContract","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"endApingTime","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"isApingTime","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"liquidityProviders","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mainPair","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_addr","type":"address"}],"name":"removeLiquidityProvider","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"tokenAddress","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"rescueAssets","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_contract","type":"address"}],"name":"setDividendContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"pair","type":"address"}],"name":"setMainPair","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_contract","type":"address"}],"name":"setNftContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"value","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]

60806040526100106012600a61066b565b61001d90620493e061067e565b60065560408051608081018252674563918244f400008152678ac7230489e80000602082015267d02ab486cedc0000918101919091526801a055690d9db8000060608201526100709060079060046104c4565b5060408051608081018252620b71b081526216e360602082015262225510918101919091526244aa2060608201526100ac90600890600461051a565b50600a805460ff191660011790553480156100c657600080fd5b506040805180820182526006808252654d414f4d414f60d01b6020808401829052845180860190955291845290830152339160036101048382610736565b5060046101118282610736565b5050506001600160a01b03811661014357604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b61014c81610168565b50610163306b204fce5e3e250261100000006101ba565b61083d565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0382166101e45760405163ec442f0560e01b81526000600482015260240161013a565b6101f0600083836101f4565b5050565b6101fd82610353565b1561025e5760405162461bcd60e51b815260206004820152602b60248201527f4f6e6c792063686f73656e20646567656e732063616e2073756d6d6f6e206c6960448201526a38bab4b234ba3c9039371760a91b606482015260840161013a565b600b546000906001600160a01b03161580159061029f5750600b546001600160a01b038581169116148061029f5750600b546001600160a01b038481169116145b156102c557600a5461010090046001600160a01b03166102c1575060006102c5565b5060015b80156103425760006103e86102db60198561067e565b6102e591906107f5565b905060006103e86102f760198661067e565b61030191906107f5565b600a5490915061032190879061010090046001600160a01b03168361039a565b600061032d8386610817565b905061033a87878361039a565b50505061034d565b61034d84848461039a565b50505050565b60006001600160a01b0382163b1515801561039457506001600160a01b0382166000908152600e602052604090205460ff161580156103945750600a5460ff165b92915050565b6001600160a01b0383166103c55780600260008282546103ba919061082a565b909155506104379050565b6001600160a01b038316600090815260208190526040902054818110156104185760405163391434e360e21b81526001600160a01b0385166004820152602481018290526044810183905260640161013a565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661045357600280548290039055610472565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516104b791815260200190565b60405180910390a3505050565b82805482825590600052602060002090810192821561050a579160200282015b8281111561050a57825182906001600160481b03169055916020019190600101906104e4565b5061051692915061055c565b5090565b82805482825590600052602060002090810192821561050a579160200282015b8281111561050a578251829062ffffff1690559160200191906001019061053a565b5b80821115610516576000815560010161055d565b634e487b7160e01b600052601160045260246000fd5b600181815b808511156105c25781600019048211156105a8576105a8610571565b808516156105b557918102915b93841c939080029061058c565b509250929050565b6000826105d957506001610394565b816105e657506000610394565b81600181146105fc576002811461060657610622565b6001915050610394565b60ff84111561061757610617610571565b50506001821b610394565b5060208310610133831016604e8410600b8410161715610645575081810a610394565b61064f8383610587565b806000190482111561066357610663610571565b029392505050565b600061067783836105ca565b9392505050565b808202811582820484141761039457610394610571565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806106bf57607f821691505b6020821081036106df57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115610731576000816000526020600020601f850160051c8101602086101561070e5750805b601f850160051c820191505b8181101561072d5782815560010161071a565b5050505b505050565b81516001600160401b0381111561074f5761074f610695565b6107638161075d84546106ab565b846106e5565b602080601f83116001811461079857600084156107805750858301515b600019600386901b1c1916600185901b17855561072d565b600085815260208120601f198616915b828110156107c7578886015182559484019460019091019084016107a8565b50858210156107e55787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60008261081257634e487b7160e01b600052601260045260246000fd5b500490565b8181038181111561039457610394610571565b8082018082111561039457610394610571565b611a588061084c6000396000f3fe60806040526004361061019c5760003560e01c806385af30c5116100ec578063dd62ed3e1161008a578063f2fde38b11610064578063f2fde38b146104cc578063f30e85bc146104ec578063f5e0a3741461050c578063f73782971461052c57600080fd5b8063dd62ed3e14610446578063e5b394aa1461048c578063ed83b802146104ac57600080fd5b8063a9059cbb116100c6578063a9059cbb146103b6578063bd6af9e4146103d6578063c1809db1146103f6578063dbd942671461041657600080fd5b806385af30c5146103635780638da5cb5b1461038357806395d89b41146103a157600080fd5b8063313ce567116101595780636124e4e7116101335780636124e4e7146102eb57806370a0823114610310578063715018a6146103465780637d5d6edb1461035b57600080fd5b8063313ce5671461027557806331c2273b1461029157806352f5ad77146102c957600080fd5b806306fdde03146101a1578063095ea7b3146101cc57806318160ddd146101fc5780631f7562da1461021b57806323b872dd146102355780632ff2e9dc14610255575b600080fd5b3480156101ad57600080fd5b506101b6610541565b6040516101c3919061159b565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611606565b6105d3565b60405190151581526020016101c3565b34801561020857600080fd5b506002545b6040519081526020016101c3565b34801561022757600080fd5b50600a546101ec9060ff1681565b34801561024157600080fd5b506101ec610250366004611630565b6105ed565b34801561026157600080fd5b5061020d6b204fce5e3e2502611000000081565b34801561028157600080fd5b50604051601281526020016101c3565b34801561029d57600080fd5b506010546102b1906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b3480156102d557600080fd5b506102e96102e436600461166c565b610611565b005b3480156102f757600080fd5b50600a546102b19061010090046001600160a01b031681565b34801561031c57600080fd5b5061020d61032b36600461166c565b6001600160a01b031660009081526020819052604090205490565b34801561035257600080fd5b506102e961063b565b6102e961064f565b34801561036f57600080fd5b50600b546102b1906001600160a01b031681565b34801561038f57600080fd5b506005546001600160a01b03166102b1565b3480156103ad57600080fd5b506101b6610892565b3480156103c257600080fd5b506101ec6103d1366004611606565b6108a1565b3480156103e257600080fd5b506102e96103f136600461166c565b6108af565b34801561040257600080fd5b506102e961041136600461166c565b6108d8565b34801561042257600080fd5b506101ec61043136600461166c565b600e6020526000908152604090205460ff1681565b34801561045257600080fd5b5061020d61046136600461168e565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b34801561049857600080fd5b506102e96104a736600461166c565b610904565b3480156104b857600080fd5b506102e96104c73660046116c1565b61097c565b3480156104d857600080fd5b506102e96104e736600461166c565b610c5d565b3480156104f857600080fd5b506102e961050736600461166c565b610c9b565b34801561051857600080fd5b506102e9610527366004611713565b610d0d565b34801561053857600080fd5b506102e9610dcc565b606060038054610550906117de565b80601f016020809104026020016040519081016040528092919081815260200182805461057c906117de565b80156105c95780601f1061059e576101008083540402835291602001916105c9565b820191906000526020600020905b8154815290600101906020018083116105ac57829003601f168201915b5050505050905090565b6000336105e1818585610e28565b60019150505b92915050565b6000336105fb858285610e35565b610606858585610eae565b506001949350505050565b610619610f0d565b601080546001600160a01b0319166001600160a01b0392909216919091179055565b610643610f0d565b61064d6000610f3a565b565b600a5460ff166106b55760405162461bcd60e51b815260206004820152602660248201527f546f6f206c617465206672656e2c2074686520646567656e206761746520697360448201526520736875742160d01b60648201526084015b60405180910390fd5b60006106c96005546001600160a01b031690565b6001600160a01b03160361071f5760405162461bcd60e51b815260206004820152601e60248201527f4e6f20646567656e206f7665726c6f72642061737369676e656420796574000060448201526064016106ac565b67016345785d8a00003410156107775760405162461bcd60e51b815260206004820152601860248201527f4e6f7420656e6f7567682045544820746f2061706520696e000000000000000060448201526064016106ac565b600067016345785d8a000060065434610790919061182e565b61079a9190611845565b306000908152602081905260409020549091508111156108085760405162461bcd60e51b815260206004820152602360248201527f4e6f7420656e6f75676820746f6b656e73206c65667420696e207468652076616044820152621d5b1d60ea1b60648201526084016106ac565b610813303383610eae565b336000908152600d602052604090205461082e903490611867565b336000818152600d602052604090209190915561084a90610f8c565b6009805490600061085a8361187a565b9091555050600954604051349133917f4b7758381053a8732ac43469947b0ebe647778adb6b49e7bf730f3517499680590600090a450565b606060048054610550906117de565b6000336105e1818585610eae565b6108b7610f0d565b6001600160a01b03166000908152600e60205260409020805460ff19169055565b6108e0610f0d565b6001600160a01b03166000908152600e60205260409020805460ff19166001179055565b61090c610f0d565b6001600160a01b0381166109545760405162461bcd60e51b815260206004820152600f60248201526e496e76616c6964206164647265737360881b60448201526064016106ac565b600a80546001600160a01b0390921661010002610100600160a81b0319909216919091179055565b610984610f0d565b6001600160a01b0381166109da5760405162461bcd60e51b815260206004820152601960248201527f496e76616c696420726563697069656e7420616464726573730000000000000060448201526064016106ac565b6001600160a01b038316610ad75747821115610a385760405162461bcd60e51b815260206004820152601d60248201527f496e73756666696369656e7420636f6e74726163742062616c616e636500000060448201526064016106ac565b6000816001600160a01b03168360405160006040518083038185875af1925050503d8060008114610a85576040519150601f19603f3d011682016040523d82523d6000602084013e610a8a565b606091505b5050905080610ad15760405162461bcd60e51b8152602060048201526013602482015272115512081d1c985b9cd9995c8819985a5b1959606a1b60448201526064016106ac565b50505050565b6040516370a0823160e01b815230600482015283906000906001600160a01b038316906370a0823190602401602060405180830381865afa158015610b20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b449190611893565b905080841115610b965760405162461bcd60e51b815260206004820181905260248201527f496e73756666696369656e742062616c616e636520696e20636f6e747261637460448201526064016106ac565b60405163a9059cbb60e01b81526001600160a01b038481166004830152602482018690526000919084169063a9059cbb906044016020604051808303816000875af1158015610be9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c0d91906118ac565b905080610c545760405162461bcd60e51b8152602060048201526015602482015274151bdad95b881d1c985b9cd9995c8819985a5b1959605a1b60448201526064016106ac565b5050505b505050565b610c65610f0d565b6001600160a01b038116610c8f57604051631e4fbdf760e01b8152600060048201526024016106ac565b610c9881610f3a565b50565b610ca3610f0d565b6001600160a01b038116610ceb5760405162461bcd60e51b815260206004820152600f60248201526e496e76616c6964206164647265737360881b60448201526064016106ac565b600b80546001600160a01b0319166001600160a01b0392909216919091179055565b610d15610f0d565b6000610d296005546001600160a01b031690565b6001600160a01b031603610d945760405162461bcd60e51b815260206004820152602c60248201527f4f776e65722061646472657373206973207a65726f2c206f7065726174696f6e60448201526b081b9bdd08185b1b1bddd95960a21b60648201526084016106ac565b60005b8251811015610c5857610dc430848381518110610db657610db66118ce565b602002602001015184610eae565b600101610d97565b610dd4610f0d565b600a5460ff16610e1c5760405162461bcd60e51b8152602060048201526013602482015272105c1a5b99c8185b1c9958591e48195b991959606a1b60448201526064016106ac565b600a805460ff19169055565b610c5883838360016111fb565b6001600160a01b03838116600090815260016020908152604080832093861683529290522054600019811015610ad15781811015610e9f57604051637dc7a0d960e11b81526001600160a01b038416600482015260248101829052604481018390526064016106ac565b610ad1848484840360006111fb565b6001600160a01b038316610ed857604051634b637e8f60e11b8152600060048201526024016106ac565b6001600160a01b038216610f025760405163ec442f0560e01b8152600060048201526024016106ac565b610c588383836112d0565b6005546001600160a01b0316331461064d5760405163118cdaa760e01b81523360048201526024016106ac565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0381166000908152600d602052604081205460015b60048160ff16116111285760006007610fc26001846118e4565b60ff1681548110610fd557610fd56118ce565b60009182526020822001549150610fee6012600a6119e1565b6008610ffb6001866118e4565b60ff168154811061100e5761100e6118ce565b9060005260206000200154611023919061182e565b905081841061110c5760105490945084906001600160a01b031615611107576001600160a01b0386166000908152600f6020908152604080832060ff808816855292529091205416611107576001600160a01b038681166000818152600f6020908152604080832060ff8916808552925291829020805460ff191660019081179091556010549251631844ba2b60e21b815260048101949094526024840152604483015290911690636112e8ac90606401600060405180830381600087803b1580156110ee57600080fd5b505af1158015611102573d6000803e3d6000fd5b505050505b611113565b5050611128565b50508080611120906119f0565b915050610fa8565b506001600160a01b0383166000908152600c602052604090205480831115610ad15760006111568285611a0f565b306000908152602081905260409020549091508111156111ce5760405162461bcd60e51b815260206004820152602d60248201527f4f776e657220646f6573206e6f74206861766520656e6f75676820746f6b656e60448201526c7320666f72207265776172647360981b60648201526084016106ac565b6001600160a01b0385166000908152600c602052604090208490556111f4308683610eae565b5050505050565b6001600160a01b0384166112255760405163e602df0560e01b8152600060048201526024016106ac565b6001600160a01b03831661124f57604051634a1406b160e11b8152600060048201526024016106ac565b6001600160a01b0380851660009081526001602090815260408083209387168352929052208290558015610ad157826001600160a01b0316846001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040516112c291815260200190565b60405180910390a350505050565b6112d98261142b565b1561133a5760405162461bcd60e51b815260206004820152602b60248201527f4f6e6c792063686f73656e20646567656e732063616e2073756d6d6f6e206c6960448201526a38bab4b234ba3c9039371760a91b60648201526084016106ac565b600b546000906001600160a01b03161580159061137b5750600b546001600160a01b038581169116148061137b5750600b546001600160a01b038481169116145b156113a157600a5461010090046001600160a01b031661139d575060006113a1565b5060015b80156114205760006103e86113b760198561182e565b6113c19190611845565b905060006103e86113d360198661182e565b6113dd9190611845565b90506113ff86600a60019054906101000a90046001600160a01b031683611471565b600061140b8386611a0f565b9050611418878783611471565b505050610ad1565b610ad1848484611471565b60006001600160a01b0382163b151580156105e757506001600160a01b0382166000908152600e602052604090205460ff161580156105e75750600a5460ff1692915050565b6001600160a01b03831661149c5780600260008282546114919190611867565b9091555061150e9050565b6001600160a01b038316600090815260208190526040902054818110156114ef5760405163391434e360e21b81526001600160a01b038516600482015260248101829052604481018390526064016106ac565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661152a57600280548290039055611549565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8360405161158e91815260200190565b60405180910390a3505050565b60006020808352835180602085015260005b818110156115c9578581018301518582016040015282016115ad565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b038116811461160157600080fd5b919050565b6000806040838503121561161957600080fd5b611622836115ea565b946020939093013593505050565b60008060006060848603121561164557600080fd5b61164e846115ea565b925061165c602085016115ea565b9150604084013590509250925092565b60006020828403121561167e57600080fd5b611687826115ea565b9392505050565b600080604083850312156116a157600080fd5b6116aa836115ea565b91506116b8602084016115ea565b90509250929050565b6000806000606084860312156116d657600080fd5b6116df846115ea565b9250602084013591506116f4604085016115ea565b90509250925092565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561172657600080fd5b823567ffffffffffffffff8082111561173e57600080fd5b818501915085601f83011261175257600080fd5b8135602082821115611766576117666116fd565b8160051b604051601f19603f8301168101818110868211171561178b5761178b6116fd565b6040529283528183019350848101820192898411156117a957600080fd5b948201945b838610156117ce576117bf866115ea565b855294820194938201936117ae565b9997909101359750505050505050565b600181811c908216806117f257607f821691505b60208210810361181257634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176105e7576105e7611818565b60008261186257634e487b7160e01b600052601260045260246000fd5b500490565b808201808211156105e7576105e7611818565b60006001820161188c5761188c611818565b5060010190565b6000602082840312156118a557600080fd5b5051919050565b6000602082840312156118be57600080fd5b8151801515811461168757600080fd5b634e487b7160e01b600052603260045260246000fd5b60ff82811682821603908111156105e7576105e7611818565b600181815b8085111561193857816000190482111561191e5761191e611818565b8085161561192b57918102915b93841c9390800290611902565b509250929050565b60008261194f575060016105e7565b8161195c575060006105e7565b8160018114611972576002811461197c57611998565b60019150506105e7565b60ff84111561198d5761198d611818565b50506001821b6105e7565b5060208310610133831016604e8410600b84101617156119bb575081810a6105e7565b6119c583836118fd565b80600019048211156119d9576119d9611818565b029392505050565b600061168760ff841683611940565b600060ff821660ff8103611a0657611a06611818565b60010192915050565b818103818111156105e7576105e761181856fea2646970667358221220a3709cdc351433c09216b5c5136546f87caa2850e7e941b85f0d3a47245b278c64736f6c63430008190033

Deployed Bytecode

0x60806040526004361061019c5760003560e01c806385af30c5116100ec578063dd62ed3e1161008a578063f2fde38b11610064578063f2fde38b146104cc578063f30e85bc146104ec578063f5e0a3741461050c578063f73782971461052c57600080fd5b8063dd62ed3e14610446578063e5b394aa1461048c578063ed83b802146104ac57600080fd5b8063a9059cbb116100c6578063a9059cbb146103b6578063bd6af9e4146103d6578063c1809db1146103f6578063dbd942671461041657600080fd5b806385af30c5146103635780638da5cb5b1461038357806395d89b41146103a157600080fd5b8063313ce567116101595780636124e4e7116101335780636124e4e7146102eb57806370a0823114610310578063715018a6146103465780637d5d6edb1461035b57600080fd5b8063313ce5671461027557806331c2273b1461029157806352f5ad77146102c957600080fd5b806306fdde03146101a1578063095ea7b3146101cc57806318160ddd146101fc5780631f7562da1461021b57806323b872dd146102355780632ff2e9dc14610255575b600080fd5b3480156101ad57600080fd5b506101b6610541565b6040516101c3919061159b565b60405180910390f35b3480156101d857600080fd5b506101ec6101e7366004611606565b6105d3565b60405190151581526020016101c3565b34801561020857600080fd5b506002545b6040519081526020016101c3565b34801561022757600080fd5b50600a546101ec9060ff1681565b34801561024157600080fd5b506101ec610250366004611630565b6105ed565b34801561026157600080fd5b5061020d6b204fce5e3e2502611000000081565b34801561028157600080fd5b50604051601281526020016101c3565b34801561029d57600080fd5b506010546102b1906001600160a01b031681565b6040516001600160a01b0390911681526020016101c3565b3480156102d557600080fd5b506102e96102e436600461166c565b610611565b005b3480156102f757600080fd5b50600a546102b19061010090046001600160a01b031681565b34801561031c57600080fd5b5061020d61032b36600461166c565b6001600160a01b031660009081526020819052604090205490565b34801561035257600080fd5b506102e961063b565b6102e961064f565b34801561036f57600080fd5b50600b546102b1906001600160a01b031681565b34801561038f57600080fd5b506005546001600160a01b03166102b1565b3480156103ad57600080fd5b506101b6610892565b3480156103c257600080fd5b506101ec6103d1366004611606565b6108a1565b3480156103e257600080fd5b506102e96103f136600461166c565b6108af565b34801561040257600080fd5b506102e961041136600461166c565b6108d8565b34801561042257600080fd5b506101ec61043136600461166c565b600e6020526000908152604090205460ff1681565b34801561045257600080fd5b5061020d61046136600461168e565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b34801561049857600080fd5b506102e96104a736600461166c565b610904565b3480156104b857600080fd5b506102e96104c73660046116c1565b61097c565b3480156104d857600080fd5b506102e96104e736600461166c565b610c5d565b3480156104f857600080fd5b506102e961050736600461166c565b610c9b565b34801561051857600080fd5b506102e9610527366004611713565b610d0d565b34801561053857600080fd5b506102e9610dcc565b606060038054610550906117de565b80601f016020809104026020016040519081016040528092919081815260200182805461057c906117de565b80156105c95780601f1061059e576101008083540402835291602001916105c9565b820191906000526020600020905b8154815290600101906020018083116105ac57829003601f168201915b5050505050905090565b6000336105e1818585610e28565b60019150505b92915050565b6000336105fb858285610e35565b610606858585610eae565b506001949350505050565b610619610f0d565b601080546001600160a01b0319166001600160a01b0392909216919091179055565b610643610f0d565b61064d6000610f3a565b565b600a5460ff166106b55760405162461bcd60e51b815260206004820152602660248201527f546f6f206c617465206672656e2c2074686520646567656e206761746520697360448201526520736875742160d01b60648201526084015b60405180910390fd5b60006106c96005546001600160a01b031690565b6001600160a01b03160361071f5760405162461bcd60e51b815260206004820152601e60248201527f4e6f20646567656e206f7665726c6f72642061737369676e656420796574000060448201526064016106ac565b67016345785d8a00003410156107775760405162461bcd60e51b815260206004820152601860248201527f4e6f7420656e6f7567682045544820746f2061706520696e000000000000000060448201526064016106ac565b600067016345785d8a000060065434610790919061182e565b61079a9190611845565b306000908152602081905260409020549091508111156108085760405162461bcd60e51b815260206004820152602360248201527f4e6f7420656e6f75676820746f6b656e73206c65667420696e207468652076616044820152621d5b1d60ea1b60648201526084016106ac565b610813303383610eae565b336000908152600d602052604090205461082e903490611867565b336000818152600d602052604090209190915561084a90610f8c565b6009805490600061085a8361187a565b9091555050600954604051349133917f4b7758381053a8732ac43469947b0ebe647778adb6b49e7bf730f3517499680590600090a450565b606060048054610550906117de565b6000336105e1818585610eae565b6108b7610f0d565b6001600160a01b03166000908152600e60205260409020805460ff19169055565b6108e0610f0d565b6001600160a01b03166000908152600e60205260409020805460ff19166001179055565b61090c610f0d565b6001600160a01b0381166109545760405162461bcd60e51b815260206004820152600f60248201526e496e76616c6964206164647265737360881b60448201526064016106ac565b600a80546001600160a01b0390921661010002610100600160a81b0319909216919091179055565b610984610f0d565b6001600160a01b0381166109da5760405162461bcd60e51b815260206004820152601960248201527f496e76616c696420726563697069656e7420616464726573730000000000000060448201526064016106ac565b6001600160a01b038316610ad75747821115610a385760405162461bcd60e51b815260206004820152601d60248201527f496e73756666696369656e7420636f6e74726163742062616c616e636500000060448201526064016106ac565b6000816001600160a01b03168360405160006040518083038185875af1925050503d8060008114610a85576040519150601f19603f3d011682016040523d82523d6000602084013e610a8a565b606091505b5050905080610ad15760405162461bcd60e51b8152602060048201526013602482015272115512081d1c985b9cd9995c8819985a5b1959606a1b60448201526064016106ac565b50505050565b6040516370a0823160e01b815230600482015283906000906001600160a01b038316906370a0823190602401602060405180830381865afa158015610b20573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b449190611893565b905080841115610b965760405162461bcd60e51b815260206004820181905260248201527f496e73756666696369656e742062616c616e636520696e20636f6e747261637460448201526064016106ac565b60405163a9059cbb60e01b81526001600160a01b038481166004830152602482018690526000919084169063a9059cbb906044016020604051808303816000875af1158015610be9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c0d91906118ac565b905080610c545760405162461bcd60e51b8152602060048201526015602482015274151bdad95b881d1c985b9cd9995c8819985a5b1959605a1b60448201526064016106ac565b5050505b505050565b610c65610f0d565b6001600160a01b038116610c8f57604051631e4fbdf760e01b8152600060048201526024016106ac565b610c9881610f3a565b50565b610ca3610f0d565b6001600160a01b038116610ceb5760405162461bcd60e51b815260206004820152600f60248201526e496e76616c6964206164647265737360881b60448201526064016106ac565b600b80546001600160a01b0319166001600160a01b0392909216919091179055565b610d15610f0d565b6000610d296005546001600160a01b031690565b6001600160a01b031603610d945760405162461bcd60e51b815260206004820152602c60248201527f4f776e65722061646472657373206973207a65726f2c206f7065726174696f6e60448201526b081b9bdd08185b1b1bddd95960a21b60648201526084016106ac565b60005b8251811015610c5857610dc430848381518110610db657610db66118ce565b602002602001015184610eae565b600101610d97565b610dd4610f0d565b600a5460ff16610e1c5760405162461bcd60e51b8152602060048201526013602482015272105c1a5b99c8185b1c9958591e48195b991959606a1b60448201526064016106ac565b600a805460ff19169055565b610c5883838360016111fb565b6001600160a01b03838116600090815260016020908152604080832093861683529290522054600019811015610ad15781811015610e9f57604051637dc7a0d960e11b81526001600160a01b038416600482015260248101829052604481018390526064016106ac565b610ad1848484840360006111fb565b6001600160a01b038316610ed857604051634b637e8f60e11b8152600060048201526024016106ac565b6001600160a01b038216610f025760405163ec442f0560e01b8152600060048201526024016106ac565b610c588383836112d0565b6005546001600160a01b0316331461064d5760405163118cdaa760e01b81523360048201526024016106ac565b600580546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6001600160a01b0381166000908152600d602052604081205460015b60048160ff16116111285760006007610fc26001846118e4565b60ff1681548110610fd557610fd56118ce565b60009182526020822001549150610fee6012600a6119e1565b6008610ffb6001866118e4565b60ff168154811061100e5761100e6118ce565b9060005260206000200154611023919061182e565b905081841061110c5760105490945084906001600160a01b031615611107576001600160a01b0386166000908152600f6020908152604080832060ff808816855292529091205416611107576001600160a01b038681166000818152600f6020908152604080832060ff8916808552925291829020805460ff191660019081179091556010549251631844ba2b60e21b815260048101949094526024840152604483015290911690636112e8ac90606401600060405180830381600087803b1580156110ee57600080fd5b505af1158015611102573d6000803e3d6000fd5b505050505b611113565b5050611128565b50508080611120906119f0565b915050610fa8565b506001600160a01b0383166000908152600c602052604090205480831115610ad15760006111568285611a0f565b306000908152602081905260409020549091508111156111ce5760405162461bcd60e51b815260206004820152602d60248201527f4f776e657220646f6573206e6f74206861766520656e6f75676820746f6b656e60448201526c7320666f72207265776172647360981b60648201526084016106ac565b6001600160a01b0385166000908152600c602052604090208490556111f4308683610eae565b5050505050565b6001600160a01b0384166112255760405163e602df0560e01b8152600060048201526024016106ac565b6001600160a01b03831661124f57604051634a1406b160e11b8152600060048201526024016106ac565b6001600160a01b0380851660009081526001602090815260408083209387168352929052208290558015610ad157826001600160a01b0316846001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925846040516112c291815260200190565b60405180910390a350505050565b6112d98261142b565b1561133a5760405162461bcd60e51b815260206004820152602b60248201527f4f6e6c792063686f73656e20646567656e732063616e2073756d6d6f6e206c6960448201526a38bab4b234ba3c9039371760a91b60648201526084016106ac565b600b546000906001600160a01b03161580159061137b5750600b546001600160a01b038581169116148061137b5750600b546001600160a01b038481169116145b156113a157600a5461010090046001600160a01b031661139d575060006113a1565b5060015b80156114205760006103e86113b760198561182e565b6113c19190611845565b905060006103e86113d360198661182e565b6113dd9190611845565b90506113ff86600a60019054906101000a90046001600160a01b031683611471565b600061140b8386611a0f565b9050611418878783611471565b505050610ad1565b610ad1848484611471565b60006001600160a01b0382163b151580156105e757506001600160a01b0382166000908152600e602052604090205460ff161580156105e75750600a5460ff1692915050565b6001600160a01b03831661149c5780600260008282546114919190611867565b9091555061150e9050565b6001600160a01b038316600090815260208190526040902054818110156114ef5760405163391434e360e21b81526001600160a01b038516600482015260248101829052604481018390526064016106ac565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661152a57600280548290039055611549565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8360405161158e91815260200190565b60405180910390a3505050565b60006020808352835180602085015260005b818110156115c9578581018301518582016040015282016115ad565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b038116811461160157600080fd5b919050565b6000806040838503121561161957600080fd5b611622836115ea565b946020939093013593505050565b60008060006060848603121561164557600080fd5b61164e846115ea565b925061165c602085016115ea565b9150604084013590509250925092565b60006020828403121561167e57600080fd5b611687826115ea565b9392505050565b600080604083850312156116a157600080fd5b6116aa836115ea565b91506116b8602084016115ea565b90509250929050565b6000806000606084860312156116d657600080fd5b6116df846115ea565b9250602084013591506116f4604085016115ea565b90509250925092565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561172657600080fd5b823567ffffffffffffffff8082111561173e57600080fd5b818501915085601f83011261175257600080fd5b8135602082821115611766576117666116fd565b8160051b604051601f19603f8301168101818110868211171561178b5761178b6116fd565b6040529283528183019350848101820192898411156117a957600080fd5b948201945b838610156117ce576117bf866115ea565b855294820194938201936117ae565b9997909101359750505050505050565b600181811c908216806117f257607f821691505b60208210810361181257634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b80820281158282048414176105e7576105e7611818565b60008261186257634e487b7160e01b600052601260045260246000fd5b500490565b808201808211156105e7576105e7611818565b60006001820161188c5761188c611818565b5060010190565b6000602082840312156118a557600080fd5b5051919050565b6000602082840312156118be57600080fd5b8151801515811461168757600080fd5b634e487b7160e01b600052603260045260246000fd5b60ff82811682821603908111156105e7576105e7611818565b600181815b8085111561193857816000190482111561191e5761191e611818565b8085161561192b57918102915b93841c9390800290611902565b509250929050565b60008261194f575060016105e7565b8161195c575060006105e7565b8160018114611972576002811461197c57611998565b60019150506105e7565b60ff84111561198d5761198d611818565b50506001821b6105e7565b5060208310610133831016604e8410600b84101617156119bb575081810a6105e7565b6119c583836118fd565b80600019048211156119d9576119d9611818565b029392505050565b600061168760ff841683611940565b600060ff821660ff8103611a0657611a06611818565b60010192915050565b818103818111156105e7576105e761181856fea2646970667358221220a3709cdc351433c09216b5c5136546f87caa2850e7e941b85f0d3a47245b278c64736f6c63430008190033

Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.