Contract Overview
Balance:
0 MATIC
Token:
My Name Tag:
Not Available
[ Download CSV Export ]
Contract Name:
EntropyLiquidityFarm
Compiler Version
v0.8.2+commit.661d1103
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL 3.0 pragma solidity ^0.8.2; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract EntropyLiquidityFarm is Ownable { using SafeMath for uint256; using SafeERC20 for IERC20; // Info of each user. struct UserInfo { uint256 amount; // How many lp tokens the user has provided. uint256 rewardDebt; // Reward debt. See explanation below. // // We do some fancy math here. Basically, any point in time, the amount of ENTROPYs // entitled to a user but is pending to be distributed is: // // pending reward = (user.amount * pool.accEntropyPerShare) - user.rewardDebt // // Whenever a user deposits or withdraws lp tokens to a pool. Here's what happens: // 1. The pool's `accEntropyPerShare` (and `lastRewardBlock`) gets updated. // 2. User receives the pending reward sent to his/her address. // 3. User's `amount` gets updated. // 4. User's `rewardDebt` gets updated. } // Info of each pool. struct PoolInfo { uint256 allocPoint; // How many allocation points assigned to this pool. ENTROPYs to distribute per block. uint256 lastRewardBlock; // Last block number that ENTROPYs distribution occurs. uint256 accEntropyPerShare; // Accumulated ENTROPYs per share, times 1e12. See below. } // The ENTROPY TOKEN! IERC20 public immutable entropy; // ENTROPY tokens created per block. uint256 public entropyPerBlock; // Info of each pool. PoolInfo[] public poolInfo; // Info of lp token. IERC20[] public lpToken; // check if the lp token already been added or not mapping(address => bool) public isTokenAdded; // check the pool ID from a specific sponsor token mapping(address => uint256) public getPoolID; // Info of each user that stakes lp tokens. mapping(uint256 => mapping(address => UserInfo)) public userInfo; // Total allocation poitns. Must be the sum of all allocation points in all pools. uint256 public totalAllocPoint = 0; // user actions event event Deposit(address indexed user, uint256 indexed pid, uint256 amount); event Withdraw(address indexed user, uint256 indexed pid, uint256 amount); event Claim(address indexed user, uint256 indexed pid, uint256 amount); event EmergencyWithdraw(address indexed user, uint256 indexed pid, uint256 amount); // admin actions event event LogPoolAddition(uint256 indexed pid, uint256 allocPoint, IERC20 indexed lpToken, bool withUpdate); event LogSetPool(uint256 indexed pid, uint256 allocPoint, IERC20 indexed lpToken, bool withUpdate); event LogUpdatePool(uint256 indexed pid, uint256 lastRewardBlock, IERC20 indexed lpToken, uint256 accEntropyPerShare); modifier validatePoolByPid(uint256 _pid) { require(_pid < poolInfo.length, "LPFARM: Pool does not exist"); _; } constructor(address _entropy, uint256 _entropyPerBlock) { entropy = IERC20(_entropy); entropyPerBlock = _entropyPerBlock; } function poolLength() external view returns (uint256) { return poolInfo.length; } // Add a new lp token to the pool. Can only be called by the owner. function add( uint256 _allocPoint, address _lpToken, bool _withUpdate ) external onlyOwner { require(isTokenAdded[_lpToken] == false, "LPFARM: SPONSOR TOKEN ALREADY IN POOL"); isTokenAdded[_lpToken] = true; if (_withUpdate) { massUpdatePools(); } uint256 lastRewardBlock = block.number; totalAllocPoint = totalAllocPoint.add(_allocPoint); lpToken.push(IERC20(_lpToken)); poolInfo.push(PoolInfo({ allocPoint: _allocPoint, lastRewardBlock: lastRewardBlock, accEntropyPerShare: 0 })); getPoolID[_lpToken] = poolInfo.length.sub(1); emit LogPoolAddition(poolInfo.length.sub(1), _allocPoint, IERC20(_lpToken), _withUpdate); } // Update the given pool's ENTROPY allocation point. Can only be called by the owner. function set( uint256 _pid, uint256 _allocPoint, bool _withUpdate ) external onlyOwner validatePoolByPid(_pid) { if (_withUpdate) { massUpdatePools(); } totalAllocPoint = totalAllocPoint.sub(poolInfo[_pid].allocPoint).add(_allocPoint); poolInfo[_pid].allocPoint = _allocPoint; emit LogSetPool(_pid, _allocPoint, lpToken[_pid], _withUpdate); } // View function to see pending ENTROPYs on frontend. function pendingEntropy(uint256 _pid, address _user) external view validatePoolByPid(_pid) returns (uint256) { PoolInfo memory pool = poolInfo[_pid]; UserInfo storage user = userInfo[_pid][_user]; uint256 accEntropyPerShare = pool.accEntropyPerShare; uint256 lpSupply = lpToken[_pid].balanceOf(address(this)); if (block.number > pool.lastRewardBlock && lpSupply != 0) { uint256 blocks = block.number.sub(pool.lastRewardBlock); uint256 entropyReward = blocks.mul(entropyPerBlock).mul(pool.allocPoint).div(totalAllocPoint); accEntropyPerShare = accEntropyPerShare.add(entropyReward.mul(1e12).div(lpSupply)); } return user.amount.mul(accEntropyPerShare).div(1e12).sub(user.rewardDebt); } // Update reward vairables for all pools. Be careful of gas spending! function massUpdatePools() public { uint256 length = poolInfo.length; for (uint256 pid = 0; pid < length; ++pid) { updatePool(pid); } } // Update reward variables of the given pool to be up-to-date. function updatePool(uint256 _pid) public validatePoolByPid(_pid) { PoolInfo storage pool = poolInfo[_pid]; if (block.number <= pool.lastRewardBlock) { return; } uint256 lpSupply = lpToken[_pid].balanceOf(address(this)); if (lpSupply == 0) { pool.lastRewardBlock = block.number; return; } uint256 blocks = block.number.sub(pool.lastRewardBlock); uint256 entropyReward = blocks.mul(entropyPerBlock).mul(pool.allocPoint).div(totalAllocPoint); pool.accEntropyPerShare = pool.accEntropyPerShare.add(entropyReward.mul(1e12).div(lpSupply)); pool.lastRewardBlock = block.number; emit LogUpdatePool(_pid, pool.lastRewardBlock, lpToken[_pid], pool.accEntropyPerShare); } // Deposit lp tokens to MasterChef for ENTROPY allocation. function deposit(uint256 _pid, uint256 _amount) external validatePoolByPid(_pid) { PoolInfo storage pool = poolInfo[_pid]; UserInfo storage user = userInfo[_pid][msg.sender]; updatePool(_pid); if (user.amount > 0) { uint256 pending = user.amount.mul(pool.accEntropyPerShare).div(1e12).sub(user.rewardDebt); safeEntropyTransfer(msg.sender, pending); } lpToken[_pid].safeTransferFrom(address(msg.sender), address(this), _amount); user.amount = user.amount.add(_amount); user.rewardDebt = user.amount.mul(pool.accEntropyPerShare).div(1e12); emit Deposit(msg.sender, _pid, _amount); } // Withdraw lp tokens from MasterChef. function withdraw(uint256 _pid, uint256 _amount) external validatePoolByPid(_pid) { PoolInfo storage pool = poolInfo[_pid]; UserInfo storage user = userInfo[_pid][msg.sender]; require(user.amount >= _amount, "LPFARM: INSUFFICIENT BALANCE"); updatePool(_pid); uint256 pending = user.amount.mul(pool.accEntropyPerShare).div(1e12).sub(user.rewardDebt); safeEntropyTransfer(msg.sender, pending); emit Claim(msg.sender, _pid, pending); user.amount = user.amount.sub(_amount); user.rewardDebt = user.amount.mul(pool.accEntropyPerShare).div(1e12); lpToken[_pid].safeTransfer(address(msg.sender), _amount); emit Withdraw(msg.sender, _pid, _amount); } // Claim mint entropy tokens function claim(uint256 _pid) external validatePoolByPid(_pid) { PoolInfo storage pool = poolInfo[_pid]; UserInfo storage user = userInfo[_pid][msg.sender]; updatePool(_pid); uint256 accumulatedEntropy = user.amount.mul(pool.accEntropyPerShare).div(1e12); uint256 pending = accumulatedEntropy.sub(user.rewardDebt); user.rewardDebt = accumulatedEntropy; safeEntropyTransfer(msg.sender, pending); emit Claim(msg.sender, _pid, pending); } // Withdraw without caring about rewards. EMERGENCY ONLY. function emergencyWithdraw(uint256 _pid) external validatePoolByPid(_pid) { UserInfo storage user = userInfo[_pid][msg.sender]; uint256 amount = user.amount; user.amount = 0; user.rewardDebt = 0; lpToken[_pid].safeTransfer(address(msg.sender), amount); emit EmergencyWithdraw(msg.sender, _pid, user.amount); } // Safe entropy transfer function, just in case if rounding error causes pool to not have enough ENTROPYs. function safeEntropyTransfer(address _to, uint256 _amount) private { uint256 entropyBal = entropy.balanceOf(address(this)); if (_amount > entropyBal) { entropy.transfer(_to, entropyBal); } else { entropy.transfer(_to, _amount); } } // Rescue left over ERP token function rescue(uint256 amount_) external onlyOwner { IERC20(entropy).transfer(owner(), amount_); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves `amount` tokens from the caller's account to `recipient`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address recipient, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 amount) external returns (bool); /** * @dev Moves `amount` tokens from `sender` to `recipient` using the * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom( address sender, address recipient, uint256 amount ) external returns (bool); /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC20.sol"; import "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove( IERC20 token, address spender, uint256 value ) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance( IERC20 token, address spender, uint256 value ) internal { uint256 newAllowance = token.allowance(address(this), spender) + value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance( IERC20 token, address spender, uint256 value ) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); uint256 newAllowance = oldAllowance - value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _setOwner(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"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return _verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return _verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return _verifyCallResult(success, returndata, errorMessage); } function _verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) private pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /* * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
[{"inputs":[{"internalType":"address","name":"_entropy","type":"address"},{"internalType":"uint256","name":"_entropyPerBlock","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Claim","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Deposit","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"EmergencyWithdraw","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"allocPoint","type":"uint256"},{"indexed":true,"internalType":"contract IERC20","name":"lpToken","type":"address"},{"indexed":false,"internalType":"bool","name":"withUpdate","type":"bool"}],"name":"LogPoolAddition","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"allocPoint","type":"uint256"},{"indexed":true,"internalType":"contract IERC20","name":"lpToken","type":"address"},{"indexed":false,"internalType":"bool","name":"withUpdate","type":"bool"}],"name":"LogSetPool","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"lastRewardBlock","type":"uint256"},{"indexed":true,"internalType":"contract IERC20","name":"lpToken","type":"address"},{"indexed":false,"internalType":"uint256","name":"accEntropyPerShare","type":"uint256"}],"name":"LogUpdatePool","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":"user","type":"address"},{"indexed":true,"internalType":"uint256","name":"pid","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"Withdraw","type":"event"},{"inputs":[{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"address","name":"_lpToken","type":"address"},{"internalType":"bool","name":"_withUpdate","type":"bool"}],"name":"add","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"entropy","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"entropyPerBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"getPoolID","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isTokenAdded","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"lpToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"massUpdatePools","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"address","name":"_user","type":"address"}],"name":"pendingEntropy","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"poolInfo","outputs":[{"internalType":"uint256","name":"allocPoint","type":"uint256"},{"internalType":"uint256","name":"lastRewardBlock","type":"uint256"},{"internalType":"uint256","name":"accEntropyPerShare","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"poolLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount_","type":"uint256"}],"name":"rescue","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_allocPoint","type":"uint256"},{"internalType":"bool","name":"_withUpdate","type":"bool"}],"name":"set","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"totalAllocPoint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"}],"name":"updatePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"address","name":"","type":"address"}],"name":"userInfo","outputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"rewardDebt","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_pid","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60a0604052600060075534801561001557600080fd5b5060405162001bf338038062001bf3833981016040819052610036916100aa565b61003f3361005a565b60609190911b6001600160601b0319166080526001556100e2565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600080604083850312156100bc578182fd5b82516001600160a01b03811681146100d2578283fd5b6020939093015192949293505050565b60805160601c611ad66200011d600039600081816101d501528181610d4b015281816112b401528181611366015261140e0152611ad66000f3fe608060405234801561001057600080fd5b50600436106101425760003560e01c80636ac053ad116100b85780638da5cb5b1161007c5780638da5cb5b1461029a57806393f1a40b146102ab578063a36532b2146102f2578063b6506a9714610325578063e2bbb15814610345578063f2fde38b1461035857610142565b80636ac053ad146102505780636c0106fa14610263578063715018a61461027657806378ed5d1f1461027e57806384bfdcba1461029157610142565b8063441a3e701161010a578063441a3e70146101bd57806347ce07cc146101d057806351eb05a61461020f5780635312ea8e14610222578063630b5ba11461023557806364482f791461023d57610142565b8063081e3eda146101475780631526fe271461015e57806317caf6f11461018c5780631eaaa04514610195578063379607f5146101aa575b600080fd5b6002545b6040519081526020015b60405180910390f35b61017161016c366004611824565b61036b565b60408051938452602084019290925290820152606001610155565b61014b60075481565b6101a86101a336600461187f565b61039e565b005b6101a86101b8366004611824565b6105ec565b6101a86101cb3660046118be565b6106fd565b6101f77f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b039091168152602001610155565b6101a861021d366004611824565b6108e3565b6101a8610230366004611824565b610af7565b6101a8610ba3565b6101a861024b3660046118df565b610bca565b6101a861025e366004611824565b610d1f565b61014b610271366004611854565b610e0a565b6101a8611000565b6101f761028c366004611824565b611036565b61014b60015481565b6000546001600160a01b03166101f7565b6102dd6102b9366004611854565b60066020908152600092835260408084209091529082529020805460019091015482565b60408051928352602083019190915201610155565b6103156103003660046117ee565b60046020526000908152604090205460ff1681565b6040519015158152602001610155565b61014b6103333660046117ee565b60056020526000908152604090205481565b6101a86103533660046118be565b611060565b6101a86103663660046117ee565b6111ca565b6002818154811061037b57600080fd5b600091825260209091206003909102018054600182015460029092015490925083565b6000546001600160a01b031633146103d15760405162461bcd60e51b81526004016103c890611992565b60405180910390fd5b6001600160a01b03821660009081526004602052604090205460ff16156104485760405162461bcd60e51b815260206004820152602560248201527f4c504641524d3a2053504f4e534f5220544f4b454e20414c524541445920494e604482015264081413d3d360da1b60648201526084016103c8565b6001600160a01b0382166000908152600460205260409020805460ff19166001179055801561047957610479610ba3565b60075443906104889085611265565b60075560038054600180820183557fc2575a0e9e593c00f959f8c92f12db2869c3395a3b0502d05e2516446f71f85b90910180546001600160a01b0319166001600160a01b038716179055604080516060810182528781526020810185815260009282018381526002805480870182559481905292517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace9490960293840195909555517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf83015592517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad090910155905461058191611278565b6001600160a01b0384166000818152600560205260409020919091556002546105ab906001611278565b6040805187815285151560208201527fad5b09333e221a3ab1ec48f5594f2ba9fd1c56d813d8928281574015e18c0a5b91015b60405180910390a350505050565b6002548190811061060f5760405162461bcd60e51b81526004016103c89061195b565b60006002838154811061063257634e487b7160e01b600052603260045260246000fd5b60009182526020808320868452600682526040808520338652909252922060039091029091019150610663846108e3565b600061068f64e8d4a510006106898560020154856000015461128490919063ffffffff16565b90611290565b905060006106aa83600101548361127890919063ffffffff16565b6001840183905590506106bd338261129c565b604051818152869033907f34fcbac0073d7c3d388e51312faf357774904998eeb8fca628b9e6f65ee1cbf7906020015b60405180910390a3505050505050565b600254829081106107205760405162461bcd60e51b81526004016103c89061195b565b60006002848154811061074357634e487b7160e01b600052603260045260246000fd5b6000918252602080832087845260068252604080852033865290925292208054600390920290920192508411156107bc5760405162461bcd60e51b815260206004820152601c60248201527f4c504641524d3a20494e53554646494349454e542042414c414e43450000000060448201526064016103c8565b6107c5856108e3565b60006107f982600101546107f364e8d4a510006106898760020154876000015461128490919063ffffffff16565b90611278565b9050610805338261129c565b604051818152869033907f34fcbac0073d7c3d388e51312faf357774904998eeb8fca628b9e6f65ee1cbf79060200160405180910390a381546108489086611278565b80835560028401546108659164e8d4a51000916106899190611284565b82600101819055506108af33866003898154811061089357634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b03169190611491565b604051858152869033907ff279e6a1f5e320cca91135676d9cb6e44ca8a08c0b88342bcdb1144f6511b568906020016106ed565b600254819081106109065760405162461bcd60e51b81526004016103c89061195b565b60006002838154811061092957634e487b7160e01b600052603260045260246000fd5b906000526020600020906003020190508060010154431161094a5750610af3565b60006003848154811061096d57634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546040516370a0823160e01b81523060048201526001600160a01b03909116906370a082319060240160206040518083038186803b1580156109b957600080fd5b505afa1580156109cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109f1919061183c565b905080610a05575043600190910155610af3565b6000610a1e83600101544361127890919063ffffffff16565b90506000610a4b6007546106898660000154610a456001548761128490919063ffffffff16565b90611284565b9050610a6e610a63846106898464e8d4a51000611284565b600286015490611265565b60028501554360018501556003805487908110610a9b57634e487b7160e01b600052603260045260246000fd5b600091825260209182902001546001860154600287015460408051928352938201526001600160a01b039091169188917f6249d10e9027bf710bc27387709e839bc4166063108ed277ab28a32cec45031191016106ed565b5050565b60025481908110610b1a5760405162461bcd60e51b81526004016103c89061195b565b600082815260066020908152604080832033808552925282208054838255600182019390935560038054919392610b6d92909184918890811061089357634e487b7160e01b600052603260045260246000fd5b8154604051908152849033907fbb757047c2b5f3974fe26b7c10f732e7bce710b0952a71082702781e62ae0595906020016105de565b60025460005b81811015610af357610bba816108e3565b610bc381611a61565b9050610ba9565b6000546001600160a01b03163314610bf45760405162461bcd60e51b81526004016103c890611992565b60025483908110610c175760405162461bcd60e51b81526004016103c89061195b565b8115610c2557610c25610ba3565b610c6d83610c6760028781548110610c4d57634e487b7160e01b600052603260045260246000fd5b600091825260209091206003909102015460075490611278565b90611265565b6007819055508260028581548110610c9557634e487b7160e01b600052603260045260246000fd5b90600052602060002090600302016000018190555060038481548110610ccb57634e487b7160e01b600052603260045260246000fd5b6000918252602091829020015460408051868152851515938101939093526001600160a01b039091169186917f95895a6ab1df54420d241b55243258a33e61b2194db66c1179ec521aae8e186591016105de565b6000546001600160a01b03163314610d495760405162461bcd60e51b81526004016103c890611992565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031663a9059cbb610d8a6000546001600160a01b031690565b6040516001600160e01b031960e084901b1681526001600160a01b03909116600482015260248101849052604401602060405180830381600087803b158015610dd257600080fd5b505af1158015610de6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610af39190611808565b60025460009083908110610e305760405162461bcd60e51b81526004016103c89061195b565b600060028581548110610e5357634e487b7160e01b600052603260045260246000fd5b6000918252602080832060408051606081018252600394850290920180548352600181015483850152600201548282019081528a8652600684528186206001600160a01b038b168752909352842091518354919550919391929089908110610ecb57634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546040516370a0823160e01b81523060048201526001600160a01b03909116906370a082319060240160206040518083038186803b158015610f1757600080fd5b505afa158015610f2b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f4f919061183c565b9050836020015143118015610f6357508015155b15610fcc576000610f8185602001514361127890919063ffffffff16565b90506000610fa86007546106898860000151610a456001548761128490919063ffffffff16565b9050610fc7610fc0846106898464e8d4a51000611284565b8590611265565b935050505b610ff483600101546107f364e8d4a5100061068986886000015461128490919063ffffffff16565b98975050505050505050565b6000546001600160a01b0316331461102a5760405162461bcd60e51b81526004016103c890611992565b61103460006114f4565b565b6003818154811061104657600080fd5b6000918252602090912001546001600160a01b0316905081565b600254829081106110835760405162461bcd60e51b81526004016103c89061195b565b6000600284815481106110a657634e487b7160e01b600052603260045260246000fd5b600091825260208083208784526006825260408085203386529092529220600390910290910191506110d7856108e3565b80541561111a57600061110c82600101546107f364e8d4a510006106898760020154876000015461128490919063ffffffff16565b9050611118338261129c565b505b61115e3330866003898154811061114157634e487b7160e01b600052603260045260246000fd5b6000918252602090912001546001600160a01b0316929190611544565b805461116a9085611265565b80825560028301546111879164e8d4a51000916106899190611284565b6001820155604051848152859033907f90890809c654f11d6e72a28fa60149770a0d11ec6c92319d6ceb2bb0a4ea1a159060200160405180910390a35050505050565b6000546001600160a01b031633146111f45760405162461bcd60e51b81526004016103c890611992565b6001600160a01b0381166112595760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016103c8565b611262816114f4565b50565b600061127182846119c7565b9392505050565b60006112718284611a1e565b600061127182846119ff565b600061127182846119df565b6040516370a0823160e01b81523060048201526000907f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316906370a082319060240160206040518083038186803b1580156112fe57600080fd5b505afa158015611312573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611336919061183c565b9050808211156113e85760405163a9059cbb60e01b81526001600160a01b038481166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb90604401602060405180830381600087803b1580156113aa57600080fd5b505af11580156113be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113e29190611808565b5061148c565b60405163a9059cbb60e01b81526001600160a01b038481166004830152602482018490527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb90604401602060405180830381600087803b15801561145257600080fd5b505af1158015611466573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061148a9190611808565b505b505050565b6040516001600160a01b03831660248201526044810182905261148c90849063a9059cbb60e01b906064015b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915261157c565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b6040516001600160a01b038085166024830152831660448201526064810182905261148a9085906323b872dd60e01b906084016114bd565b60006115d1826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661164e9092919063ffffffff16565b80519091501561148c57808060200190518101906115ef9190611808565b61148c5760405162461bcd60e51b815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e6044820152691bdd081cdd58d8d9595960b21b60648201526084016103c8565b606061165d8484600085611665565b949350505050565b6060824710156116c65760405162461bcd60e51b815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f6044820152651c8818d85b1b60d21b60648201526084016103c8565b6116cf85611794565b61171b5760405162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016103c8565b600080866001600160a01b03168587604051611737919061190c565b60006040518083038185875af1925050503d8060008114611774576040519150601f19603f3d011682016040523d82523d6000602084013e611779565b606091505b509150915061178982828661179e565b979650505050505050565b803b15155b919050565b606083156117ad575081611271565b8251156117bd5782518084602001fd5b8160405162461bcd60e51b81526004016103c89190611928565b80356001600160a01b038116811461179957600080fd5b6000602082840312156117ff578081fd5b611271826117d7565b600060208284031215611819578081fd5b815161127181611a92565b600060208284031215611835578081fd5b5035919050565b60006020828403121561184d578081fd5b5051919050565b60008060408385031215611866578081fd5b82359150611876602084016117d7565b90509250929050565b600080600060608486031215611893578081fd5b833592506118a3602085016117d7565b915060408401356118b381611a92565b809150509250925092565b600080604083850312156118d0578182fd5b50508035926020909101359150565b6000806000606084860312156118f3578283fd5b833592506020840135915060408401356118b381611a92565b6000825161191e818460208701611a35565b9190910192915050565b6000602082528251806020840152611947816040850160208701611a35565b601f01601f19169190910160400192915050565b6020808252601b908201527f4c504641524d3a20506f6f6c20646f6573206e6f742065786973740000000000604082015260600190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600082198211156119da576119da611a7c565b500190565b6000826119fa57634e487b7160e01b81526012600452602481fd5b500490565b6000816000190483118215151615611a1957611a19611a7c565b500290565b600082821015611a3057611a30611a7c565b500390565b60005b83811015611a50578181015183820152602001611a38565b8381111561148a5750506000910152565b6000600019821415611a7557611a75611a7c565b5060010190565b634e487b7160e01b600052601160045260246000fd5b801515811461126257600080fdfea2646970667358221220c9d15eee29f83bf45071d94847cf701f2edad2a1571c4146127ff56059c2ea1c64736f6c63430008020033000000000000000000000000775d2b13d9d80e7691cf9c223567481b2a278755000000000000000000000000000000000000000000000001158e460913d00000
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000775d2b13d9d80e7691cf9c223567481b2a278755000000000000000000000000000000000000000000000001158e460913d00000
-----Decoded View---------------
Arg [0] : _entropy (address): 0x775d2b13d9d80e7691cf9c223567481b2a278755
Arg [1] : _entropyPerBlock (uint256): 20000000000000000000
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000775d2b13d9d80e7691cf9c223567481b2a278755
Arg [1] : 000000000000000000000000000000000000000000000001158e460913d00000
Age | Block | Fee Address | BC Fee Address | Voting Power | Jailed | Incoming |
---|