false
true
0

Contract Address Details

0x04BBbd84A0c12E73bdC369DdC1cEd8528092390F

Contract Name
PulsepotParticipationPool
Creator
0xa30f2b–d6edb4 at 0x3b4e08–76c06b
Balance
0 PLS ( )
Tokens
Fetching tokens...
Transactions
Fetching transactions...
Transfers
Fetching transfers...
Gas Used
Fetching gas used...
Last Balance Update
25866390
Warning! Contract bytecode has been changed and doesn't match the verified one. Therefore, interaction with this smart contract may be risky.
Contract name:
PulsepotParticipationPool




Optimization enabled
true
Compiler version
v0.8.19+commit.7dd6d404




Optimization runs
200
EVM Version
default




Verified at
2024-01-10T18:40:06.823894Z

contracts/Pulsepot/ParticipationPool.sol

// SPDX-License-Identifier: MIT
pragma solidity >=0.8.7;

import '@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol';
import '../interfaces/Pulsepot/IPLSPStaking.sol';
import '../interfaces/Pulsepot/IWPLSP.sol';
import '../interfaces/IPRC20.sol';

contract PulsepotParticipationPool is OwnableUpgradeable {
    IPRC20 public PLSP;
    IWPLSP public WPLSP;
    IPLSPStaking public PLSPStaking;
    uint256 public maxPayout;

    mapping(address => bool) isAuthorizedGameContract;

    function initialize(address PLSPAddress, address WPLSPAddress, address _stakingAddress) public initializer {
        PLSP = IPRC20(PLSPAddress);
        WPLSP = IWPLSP(WPLSPAddress);
        PLSPStaking = IPLSPStaking(_stakingAddress);
        maxPayout = 5000 * 10 ** 18; // max 5000 wPLSP per round
        __Ownable_init();
    }

    // Should be updated
    function calculatePPBonus(uint256 usdValue, address receiver) public view returns(uint256) {
        IPLSPStaking.StakingInfo memory stakingInfo = PLSPStaking.getUserStakingInfo(receiver);
        uint256 wPLSPPerUSD;
        uint256 stakingAmount = stakingInfo.totalAmount;
        uint256 bonusMultiplier = 0;
        
        if (stakingAmount >= 76200 * 10 ** 18) {
            bonusMultiplier = 140; wPLSPPerUSD = 24;
        } else if (stakingAmount >= 62000 * 10 ** 18) {
            bonusMultiplier = 130; wPLSPPerUSD = 23;
        } else if (stakingAmount >= 50000 * 10 ** 18) {
            bonusMultiplier = 120; wPLSPPerUSD = 22;
        } else if (stakingAmount >= 32000 * 10 ** 18) {
            bonusMultiplier = 110; wPLSPPerUSD = 21;
        } else if (stakingAmount >= 16000 * 10 ** 18) {
            bonusMultiplier = 100; wPLSPPerUSD = 20;
        } else if (stakingAmount >= 8000 * 10 ** 18) {
            bonusMultiplier = 90; wPLSPPerUSD = 19;
        } else if (stakingAmount >= 4000 * 10 ** 18) {
            bonusMultiplier = 80; wPLSPPerUSD = 18;
        } else if (stakingAmount >= 3500 * 10 ** 18) {
            bonusMultiplier = 70; wPLSPPerUSD = 17;
        } else if (stakingAmount >= 3000 * 10 ** 18) {
            bonusMultiplier = 60; wPLSPPerUSD = 16;
        } else if (stakingAmount >= 2500 * 10 ** 18) {
            bonusMultiplier = 50; wPLSPPerUSD = 15;
        } else if (stakingAmount >= 2000 * 10 ** 18) {
            bonusMultiplier = 40; wPLSPPerUSD = 14;
        } else if (stakingAmount >= 1500 * 10 ** 18) {
            bonusMultiplier = 30; wPLSPPerUSD = 13;
        } else if (stakingAmount >= 1000 * 10 ** 18) {
            bonusMultiplier = 20; wPLSPPerUSD = 12;
        } else if (stakingAmount >= 500 * 10 ** 18) {
            bonusMultiplier = 10; wPLSPPerUSD = 11;
        } else {
            bonusMultiplier = 0; wPLSPPerUSD = 10;
        }

        uint256 baseAmount = usdValue * wPLSPPerUSD / 1000;
        uint256 amount = baseAmount * (100 + bonusMultiplier) / 100;
        if (maxPayout != 0 && amount > maxPayout) {
            amount = maxPayout;
        }
        return amount;
    }

    function requestPPBonus(address receiver, uint256 usdValue) external returns(uint256) {
        require(isAuthorizedGameContract[msg.sender], 'not authorized');
        
        uint256 balance = PLSP.balanceOf(address(this));
        if (balance == 0) return 0;

        uint256 amount = calculatePPBonus(usdValue, receiver);

        if (amount > balance) amount = balance;
        
        PLSP.approve(address(WPLSP), amount);
        WPLSP.wrapPLSP(receiver, amount);

        return amount;
    }

    function setAuthorizedGameContract(address addr, bool value) external onlyOwner {
        isAuthorizedGameContract[addr] = value;
    }

    function updateMaxPPPayout(uint256 value) external onlyOwner {
        maxPayout = value;
    }
}
        

@openzeppelin/contracts-upgradeable/access/OwnableUpgradeable.sol

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

pragma solidity ^0.8.7;

import "../utils/ContextUpgradeable.sol";
import "../proxy/utils/Initializable.sol";

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

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

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    function __Ownable_init() internal onlyInitializing {
        __Ownable_init_unchained();
    }

    function __Ownable_init_unchained() internal onlyInitializing {
        _transferOwnership(_msgSender());
    }

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

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

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

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

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

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

    /**
     * @dev This empty reserved space is put in place to allow future versions to add new
     * variables without shifting down storage in the inheritance chain.
     * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps
     */
    uint256[49] private __gap;
}
          

@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol

// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.7.0) (proxy/utils/Initializable.sol)

pragma solidity ^0.8.2;

import "../../utils/AddressUpgradeable.sol";

/**
 * @dev This is a base contract to aid in writing upgradeable contracts, or any kind of contract that will be deployed
 * behind a proxy. Since proxied contracts do not make use of a constructor, it's common to move constructor logic to an
 * external initializer function, usually called `initialize`. It then becomes necessary to protect this initializer
 * function so it can only be called once. The {initializer} modifier provided by this contract will have this effect.
 *
 * The initialization functions use a version number. Once a version number is used, it is consumed and cannot be
 * reused. This mechanism prevents re-execution of each "step" but allows the creation of new initialization steps in
 * case an upgrade adds a module that needs to be initialized.
 *
 * For example:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * contract MyToken is ERC20Upgradeable {
 *     function initialize() initializer public {
 *         __ERC20_init("MyToken", "MTK");
 *     }
 * }
 * contract MyTokenV2 is MyToken, ERC20PermitUpgradeable {
 *     function initializeV2() reinitializer(2) public {
 *         __ERC20Permit_init("MyToken");
 *     }
 * }
 * ```
 *
 * TIP: To avoid leaving the proxy in an uninitialized state, the initializer function should be called as early as
 * possible by providing the encoded function call as the `_data` argument to {ERC1967Proxy-constructor}.
 *
 * CAUTION: When used with inheritance, manual care must be taken to not invoke a parent initializer twice, or to ensure
 * that all initializers are idempotent. This is not verified automatically as constructors are by Solidity.
 *
 * [CAUTION]
 * ====
 * Avoid leaving a contract uninitialized.
 *
 * An uninitialized contract can be taken over by an attacker. This applies to both a proxy and its implementation
 * contract, which may impact the proxy. To prevent the implementation contract from being used, you should invoke
 * the {_disableInitializers} function in the constructor to automatically lock it when it is deployed:
 *
 * [.hljs-theme-light.nopadding]
 * ```
 * /// @custom:oz-upgrades-unsafe-allow constructor
 * constructor() {
 *     _disableInitializers();
 * }
 * ```
 * ====
 */
abstract contract Initializable {
    /**
     * @dev Indicates that the contract has been initialized.
     * @custom:oz-retyped-from bool
     */
    uint8 private _initialized;

    /**
     * @dev Indicates that the contract is in the process of being initialized.
     */
    bool private _initializing;

    /**
     * @dev Triggered when the contract has been initialized or reinitialized.
     */
    event Initialized(uint8 version);

    /**
     * @dev A modifier that defines a protected initializer function that can be invoked at most once. In its scope,
     * `onlyInitializing` functions can be used to initialize parent contracts. Equivalent to `reinitializer(1)`.
     */
    modifier initializer() {
        bool isTopLevelCall = !_initializing;
        require(
            (isTopLevelCall && _initialized < 1) || (!AddressUpgradeable.isContract(address(this)) && _initialized == 1),
            "Initializable: contract is already initialized"
        );
        _initialized = 1;
        if (isTopLevelCall) {
            _initializing = true;
        }
        _;
        if (isTopLevelCall) {
            _initializing = false;
            emit Initialized(1);
        }
    }

    /**
     * @dev A modifier that defines a protected reinitializer function that can be invoked at most once, and only if the
     * contract hasn't been initialized to a greater version before. In its scope, `onlyInitializing` functions can be
     * used to initialize parent contracts.
     *
     * `initializer` is equivalent to `reinitializer(1)`, so a reinitializer may be used after the original
     * initialization step. This is essential to configure modules that are added through upgrades and that require
     * initialization.
     *
     * Note that versions can jump in increments greater than 1; this implies that if multiple reinitializers coexist in
     * a contract, executing them in the right order is up to the developer or operator.
     */
    modifier reinitializer(uint8 version) {
        require(!_initializing && _initialized < version, "Initializable: contract is already initialized");
        _initialized = version;
        _initializing = true;
        _;
        _initializing = false;
        emit Initialized(version);
    }

    /**
     * @dev Modifier to protect an initialization function so that it can only be invoked by functions with the
     * {initializer} and {reinitializer} modifiers, directly or indirectly.
     */
    modifier onlyInitializing() {
        require(_initializing, "Initializable: contract is not initializing");
        _;
    }

    /**
     * @dev Locks the contract, preventing any future reinitialization. This cannot be part of an initializer call.
     * Calling this in the constructor of a contract will prevent that contract from being initialized or reinitialized
     * to any version. It is recommended to use this to lock implementation contracts that are designed to be called
     * through proxies.
     */
    function _disableInitializers() internal virtual {
        require(!_initializing, "Initializable: contract is initializing");
        if (_initialized < type(uint8).max) {
            _initialized = type(uint8).max;
            emit Initialized(type(uint8).max);
        }
    }
}
          

@openzeppelin/contracts-upgradeable/utils/AddressUpgradeable.sol

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

pragma solidity ^0.8.1;

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

        return account.code.length > 0;
    }

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

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

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

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

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

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

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

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

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

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

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

@openzeppelin/contracts-upgradeable/utils/ContextUpgradeable.sol

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

pragma solidity ^0.8.0;
import "../proxy/utils/Initializable.sol";

/**
 * @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 ContextUpgradeable is Initializable {
    function __Context_init() internal onlyInitializing {
    }

    function __Context_init_unchained() internal onlyInitializing {
    }
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

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

    /**
     * @dev This empty reserved space is put in place to allow future versions to add new
     * variables without shifting down storage in the inheritance chain.
     * See https://docs.openzeppelin.com/contracts/4.x/upgradeable#storage_gaps
     */
    uint256[50] private __gap;
}
          

contracts/interfaces/IPRC20.sol

// SPDX-License-Identifier: MIT
pragma solidity >=0.8.7;

interface IPRC20 {
    function totalSupply() external view returns (uint256);

    function balanceOf(address account) external view returns (uint256);

    function transfer(address recipient, uint256 amount) external returns (bool);

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

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

    function transferFrom(
        address sender,
        address recipient,
        uint256 amount
    ) external returns (bool);

    function decimals() external view returns (uint8);

    event Transfer(address indexed from, address indexed to, uint256 value);
    event Approval(address indexed owner, address indexed spender, uint256 value);
}
          

contracts/interfaces/Pulsepot/IPLSPStaking.sol

// SPDX-License-Identifier: MIT
pragma solidity >=0.8.7;

interface IPLSPStaking {
    struct Stake {
        uint256 id;
        address user;
        uint256 amount;
        uint256 timestamp;
        uint256 startedUnstakingAt;
        uint256 status; // 0: staking, 1: started unstaking, 2: finished unstaking
    }

    struct StakingInfo {
        uint256 totalAmount;
        uint256 stakeCount;
        uint256[] stakeIds;
    }

    function stakeList(uint256) external view returns (Stake memory);

    function userStakingInfo(address) external view returns (StakingInfo memory);

    function totalAmount() external view returns (uint256);

    function lockTime() external view returns (uint256);

    event UserStakingAmountChanged(address user, uint256 stakingId, uint256 totalAmount, bool isFinished);
    event StartedUnstaking(uint256 id);

    function getUserStakingList(address user) external view returns (Stake[] memory);

    function getUserStakingListByPages(
        address user,
        uint256 start,
        uint256 length
    ) external view returns (Stake[] memory);

    function getUserStakingInfo(address user) external view returns(StakingInfo memory);
}
          

contracts/interfaces/Pulsepot/IWPLSP.sol

// SPDX-License-Identifier: GPL-3.0

pragma solidity ^0.8.7;

interface IWPLSP {
    struct UnWrapping {
        uint256 id;
        address user;
        uint256 amount;
        uint256 timestamp;
        uint256 lockTime;
        bool isFinished;
    }
    struct UserInfo {
        uint256[] ids;
        uint256 unWrappingCount;
        uint256 totalAmount;
    }

    function unWrappingList(uint256) external view returns (UnWrapping memory);

    function userInfos(address) external view returns (UserInfo memory);

    function minDay() external view returns (uint256);

    function maxDay() external view returns (uint256);

    /* Events */
    event UnWrappingStart(uint256 id);
    event UnWrappingEnded(uint256 id);

    function wrapPLSP(address receiver, uint256 amount) external;

    function getUserUnWrappingList(address user) external view returns (UnWrapping[] memory list);

    function getUserUnWrappingListByPages(
        address user,
        uint256 start,
        uint256 length
    ) external view returns (UnWrapping[] memory list);
}
          

Compiler Settings

{"viaIR":true,"outputSelection":{"*":{"*":["*"],"":["*"]}},"optimizer":{"runs":200,"enabled":true},"libraries":{}}
              

Contract ABI

[{"type":"event","name":"Initialized","inputs":[{"type":"uint8","name":"version","internalType":"uint8","indexed":false}],"anonymous":false},{"type":"event","name":"OwnershipTransferred","inputs":[{"type":"address","name":"previousOwner","internalType":"address","indexed":true},{"type":"address","name":"newOwner","internalType":"address","indexed":true}],"anonymous":false},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"contract IPRC20"}],"name":"PLSP","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"contract IPLSPStaking"}],"name":"PLSPStaking","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"contract IWPLSP"}],"name":"WPLSP","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"calculatePPBonus","inputs":[{"type":"uint256","name":"usdValue","internalType":"uint256"},{"type":"address","name":"receiver","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"initialize","inputs":[{"type":"address","name":"PLSPAddress","internalType":"address"},{"type":"address","name":"WPLSPAddress","internalType":"address"},{"type":"address","name":"_stakingAddress","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"maxPayout","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"renounceOwnership","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"requestPPBonus","inputs":[{"type":"address","name":"receiver","internalType":"address"},{"type":"uint256","name":"usdValue","internalType":"uint256"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"setAuthorizedGameContract","inputs":[{"type":"address","name":"addr","internalType":"address"},{"type":"bool","name":"value","internalType":"bool"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"transferOwnership","inputs":[{"type":"address","name":"newOwner","internalType":"address"}]},{"type":"function","stateMutability":"nonpayable","outputs":[],"name":"updateMaxPPPayout","inputs":[{"type":"uint256","name":"value","internalType":"uint256"}]}]
              

Contract Creation Code

0x6080806040523461001657610c16908161001c8239f35b600080fdfe604060808152600436101561001357600080fd5b600090813560e01c806314a7cc0e1461049b5780631987ba6f146104735780632436ec231461041e5780633cf50c7a146103f657806367252143146103ce578063715018a61461036e57806385f6b18f146103465780638da5cb5b1461031e578063c0c53b8b14610183578063d47a8d9014610155578063e0176de8146101375763f2fde38b146100a357600080fd5b34610133576020366003190112610133576100bc6104be565b906100c56104ef565b6001600160a01b038216156100e157506100de90610547565b80f35b5162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608490fd5b5080fd5b50346101335781600319360112610133576020906068549051908152f35b503461013357806003193601126101335760209061017c6101746104d9565b600435610651565b9051908152f35b50346101335760603660031901126101335761019d6104be565b6101a56104d9565b906044356001600160a01b03818116929183900361031a5785549360ff8560081c16159485809661030d575b80156102f6575b1561029b5760ff19811660011788558561028a575b50816bffffffffffffffffffffffff60a01b931683606554161760655516816066541617606655606754161760675569010f0cf064dd5920000060685561024360ff845460081c1661023e81610590565b610590565b61024c33610547565b610254575080f35b60207f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989161ff001984541684555160018152a180f35b61ffff1916610101178755386101ed565b865162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608490fd5b50303b1580156101d85750600160ff8216146101d8565b50600160ff8216106101d1565b8580fd5b503461013357816003193601126101335760335490516001600160a01b039091168152602090f35b503461013357816003193601126101335760675490516001600160a01b039091168152602090f35b82346103cb57806003193601126103cb576103876104ef565b603380546001600160a01b0319811690915581906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b503461013357816003193601126101335760665490516001600160a01b039091168152602090f35b503461013357806003193601126101335760209061017c6104156104be565b602435906109e1565b50346101335780600319360112610133576104376104be565b906024359182151580930361046f5761044e6104ef565b60018060a01b03168352606960205282209060ff8019835416911617905580f35b8380fd5b503461013357816003193601126101335760655490516001600160a01b039091168152602090f35b82346103cb5760203660031901126103cb576104b56104ef565b60043560685580f35b600435906001600160a01b03821682036104d457565b600080fd5b602435906001600160a01b03821682036104d457565b6033546001600160a01b0316330361050357565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b603380546001600160a01b039283166001600160a01b0319821681179092559091167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3565b1561059757565b60405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608490fd5b90601f8019910116810190811067ffffffffffffffff82111761061257604052565b634e487b7160e01b600052604160045260246000fd5b8181029291811591840414171561063b57565b634e487b7160e01b600052601160045260246000fd5b6067546040805163101266c160e31b81526001600160a01b0394851660048201526000949092859184916024918391165afa9182156109d75784926108d6575b505051691022cf6e5318dda00000811061070957506103e86106b7608c92601890610628565b049060640191826064116106f557506064916106d291610628565b04606854801515806106ec575b6106e7575090565b905090565b508082116106df565b634e487b7160e01b81526011600452602490fd5b690d2106d815ebeac00000811061072c57506103e86106b7608292601790610628565b690a968163f0a57b400000811061074f57506103e86106b7607892601690610628565b6906c6b935b8bbd4000000811061077257506103e86106b7606e92601590610628565b6903635c9adc5dea000000811061079557506103e86106b7606492601490610628565b6901b1ae4d6e2ef500000081106107b857506103e86106b7605a92601390610628565b68d8d726b7177a80000081106107da57506103e86106b7605092601290610628565b68bdbc41e0348b30000081106107fc57506103e86106b7604692601190610628565b68a2a15d09519be00000811061081e57506103e86106b7603c92601090610628565b68878678326eac900000811061084057506103e86106b7603292600f90610628565b686c6b935b8bbd400000811061086257506103e86106b7602892600e90610628565b685150ae84a8cdf00000811061088457506103e86106b7601e92600d90610628565b683635c9adc5dea0000081106108a657506103e86106b7601492600c90610628565b681b1ae4d6e2ef500000116108c6576103e86106b7600a92600b90610628565b6103e86106b78392600a90610628565b9091503d8085833e6108e881836105f0565b8101916020808385031261031a57825167ffffffffffffffff938482116109bb5701936060858203126109d35782519460608601868110868211176109bf57845280518652828101518387015283810151908582116109a3570181601f820112156109bb5780519485116109a7578460051b9084519561096a858401886105f0565b865283808701928201019283116109a3578301905b82821061099457505050508201523880610691565b8151815290830190830161097f565b8880fd5b634e487b7160e01b88526041600452602488fd5b8780fd5b634e487b7160e01b89526041600452602489fd5b8680fd5b81513d86823e3d90fd5b60003381526020916069835260409260ff848420541615610bac5760655484516370a0823160e01b8152306004820152956001600160a01b0392918316908288602481855afa978815610ba2578698610b73575b508715610b685784610a4691610651565b96808811610b60575b50606654865163095ea7b360e01b81529084166001600160a01b03166004820152602481018890529190819083908188816044810103925af18015610b5657610b23575b50506066541690813b15610b1f5783516377b30c2360e11b81526001600160a01b039190911660048201526024810185905292919081908490604490829084905af18015610b1357610ae6575b50505090565b67ffffffffffffffff8311610aff575052388080610ae0565b634e487b7160e01b81526041600452602490fd5b509051903d90823e3d90fd5b8280fd5b81813d8311610b4f575b610b3781836105f0565b8101031261046f575180151503610b1f573880610a93565b503d610b2d565b86513d87823e3d90fd5b965081610a4f565b505050505091505090565b9097508281813d8311610b9b575b610b8b81836105f0565b8101031261031a57519638610a35565b503d610b81565b87513d88823e3d90fd5b60649084519062461bcd60e51b82526004820152600e60248201526d1b9bdd08185d5d1a1bdc9a5e995960921b6044820152fdfea2646970667358221220b4ed53d32262645a5696bd2dd97b38323c1a0f960a3a9e760f86d02a9916df7e64736f6c63430008130033

Deployed ByteCode

0x604060808152600436101561001357600080fd5b600090813560e01c806314a7cc0e1461049b5780631987ba6f146104735780632436ec231461041e5780633cf50c7a146103f657806367252143146103ce578063715018a61461036e57806385f6b18f146103465780638da5cb5b1461031e578063c0c53b8b14610183578063d47a8d9014610155578063e0176de8146101375763f2fde38b146100a357600080fd5b34610133576020366003190112610133576100bc6104be565b906100c56104ef565b6001600160a01b038216156100e157506100de90610547565b80f35b5162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608490fd5b5080fd5b50346101335781600319360112610133576020906068549051908152f35b503461013357806003193601126101335760209061017c6101746104d9565b600435610651565b9051908152f35b50346101335760603660031901126101335761019d6104be565b6101a56104d9565b906044356001600160a01b03818116929183900361031a5785549360ff8560081c16159485809661030d575b80156102f6575b1561029b5760ff19811660011788558561028a575b50816bffffffffffffffffffffffff60a01b931683606554161760655516816066541617606655606754161760675569010f0cf064dd5920000060685561024360ff845460081c1661023e81610590565b610590565b61024c33610547565b610254575080f35b60207f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989161ff001984541684555160018152a180f35b61ffff1916610101178755386101ed565b865162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608490fd5b50303b1580156101d85750600160ff8216146101d8565b50600160ff8216106101d1565b8580fd5b503461013357816003193601126101335760335490516001600160a01b039091168152602090f35b503461013357816003193601126101335760675490516001600160a01b039091168152602090f35b82346103cb57806003193601126103cb576103876104ef565b603380546001600160a01b0319811690915581906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b80fd5b503461013357816003193601126101335760665490516001600160a01b039091168152602090f35b503461013357806003193601126101335760209061017c6104156104be565b602435906109e1565b50346101335780600319360112610133576104376104be565b906024359182151580930361046f5761044e6104ef565b60018060a01b03168352606960205282209060ff8019835416911617905580f35b8380fd5b503461013357816003193601126101335760655490516001600160a01b039091168152602090f35b82346103cb5760203660031901126103cb576104b56104ef565b60043560685580f35b600435906001600160a01b03821682036104d457565b600080fd5b602435906001600160a01b03821682036104d457565b6033546001600160a01b0316330361050357565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b603380546001600160a01b039283166001600160a01b0319821681179092559091167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0600080a3565b1561059757565b60405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608490fd5b90601f8019910116810190811067ffffffffffffffff82111761061257604052565b634e487b7160e01b600052604160045260246000fd5b8181029291811591840414171561063b57565b634e487b7160e01b600052601160045260246000fd5b6067546040805163101266c160e31b81526001600160a01b0394851660048201526000949092859184916024918391165afa9182156109d75784926108d6575b505051691022cf6e5318dda00000811061070957506103e86106b7608c92601890610628565b049060640191826064116106f557506064916106d291610628565b04606854801515806106ec575b6106e7575090565b905090565b508082116106df565b634e487b7160e01b81526011600452602490fd5b690d2106d815ebeac00000811061072c57506103e86106b7608292601790610628565b690a968163f0a57b400000811061074f57506103e86106b7607892601690610628565b6906c6b935b8bbd4000000811061077257506103e86106b7606e92601590610628565b6903635c9adc5dea000000811061079557506103e86106b7606492601490610628565b6901b1ae4d6e2ef500000081106107b857506103e86106b7605a92601390610628565b68d8d726b7177a80000081106107da57506103e86106b7605092601290610628565b68bdbc41e0348b30000081106107fc57506103e86106b7604692601190610628565b68a2a15d09519be00000811061081e57506103e86106b7603c92601090610628565b68878678326eac900000811061084057506103e86106b7603292600f90610628565b686c6b935b8bbd400000811061086257506103e86106b7602892600e90610628565b685150ae84a8cdf00000811061088457506103e86106b7601e92600d90610628565b683635c9adc5dea0000081106108a657506103e86106b7601492600c90610628565b681b1ae4d6e2ef500000116108c6576103e86106b7600a92600b90610628565b6103e86106b78392600a90610628565b9091503d8085833e6108e881836105f0565b8101916020808385031261031a57825167ffffffffffffffff938482116109bb5701936060858203126109d35782519460608601868110868211176109bf57845280518652828101518387015283810151908582116109a3570181601f820112156109bb5780519485116109a7578460051b9084519561096a858401886105f0565b865283808701928201019283116109a3578301905b82821061099457505050508201523880610691565b8151815290830190830161097f565b8880fd5b634e487b7160e01b88526041600452602488fd5b8780fd5b634e487b7160e01b89526041600452602489fd5b8680fd5b81513d86823e3d90fd5b60003381526020916069835260409260ff848420541615610bac5760655484516370a0823160e01b8152306004820152956001600160a01b0392918316908288602481855afa978815610ba2578698610b73575b508715610b685784610a4691610651565b96808811610b60575b50606654865163095ea7b360e01b81529084166001600160a01b03166004820152602481018890529190819083908188816044810103925af18015610b5657610b23575b50506066541690813b15610b1f5783516377b30c2360e11b81526001600160a01b039190911660048201526024810185905292919081908490604490829084905af18015610b1357610ae6575b50505090565b67ffffffffffffffff8311610aff575052388080610ae0565b634e487b7160e01b81526041600452602490fd5b509051903d90823e3d90fd5b8280fd5b81813d8311610b4f575b610b3781836105f0565b8101031261046f575180151503610b1f573880610a93565b503d610b2d565b86513d87823e3d90fd5b965081610a4f565b505050505091505090565b9097508281813d8311610b9b575b610b8b81836105f0565b8101031261031a57519638610a35565b503d610b81565b87513d88823e3d90fd5b60649084519062461bcd60e51b82526004820152600e60248201526d1b9bdd08185d5d1a1bdc9a5e995960921b6044820152fdfea2646970667358221220b4ed53d32262645a5696bd2dd97b38323c1a0f960a3a9e760f86d02a9916df7e64736f6c63430008130033