Source Code
Overview
S Balance
0 S
More Info
ContractCreator
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
LauncherPlugin
Compiler Version
v0.8.28+commit.7893614a
Optimization Enabled:
Yes with 100 runs
Other Settings:
cancun EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.24; import {ILauncherPlugin} from "./interfaces/ILauncherPlugin.sol"; import {IVoter} from "./interfaces/IVoter.sol"; /// @author ShadowDEX on Sonic /// @title LauncherPlugins contract for modular plug-n-play with Sonic memes /** @dev There are two trusted roles in the LauncherPlugin system * Authority: Whitelisted external launchers, e.g. DegenExpress * Operator: Shadow operational multisig, or other timelocked/secure system * AccessHub: central authority management contract * These roles are to be managed securely, and with diligence to prevent abuse * However, the system already has checks in place to mitigate any possible abuse situations ahead of time */ contract LauncherPlugin is ILauncherPlugin { /// @inheritdoc ILauncherPlugin address public accessHub; /// @inheritdoc ILauncherPlugin address public operator; /// @notice the voter contract IVoter public immutable voter; /// @inheritdoc ILauncherPlugin mapping(address pool => bool isEnabled) public launcherPluginEnabled; /// @inheritdoc ILauncherPlugin mapping(address pool => LauncherConfigs) public poolConfigs; /// @inheritdoc ILauncherPlugin mapping(address pool => address feeDist) public feeDistToPool; /// @inheritdoc ILauncherPlugin mapping(address who => bool authority) public authorityMap; /// @inheritdoc ILauncherPlugin mapping(address authority => string name) public nameOfAuthority; /// @inheritdoc ILauncherPlugin uint256 public constant DENOM = 10_000; modifier onlyAuthority() { /// @dev authority check of either the operator of authority in the mapping require( authorityMap[msg.sender] || msg.sender == accessHub, NOT_AUTHORITY() ); _; } modifier onlyOperator() { /// @dev redundant `operator` address put here as a safeguard for input errors on transferring roles require( msg.sender == accessHub || msg.sender == operator, NOT_OPERATOR() ); _; } constructor(address _voter, address _accessHub, address _operator) { /// @dev initialize the voter voter = IVoter(_voter); /// @dev operator and team initially are the same accessHub = _accessHub; operator = _operator; } /// @inheritdoc ILauncherPlugin /// @dev should be called by another contract with proper batching of function calls function setConfigs( address _pool, uint256 _take, address _recipient ) external onlyAuthority { /// @dev ensure launcherPlugins are enabled require(launcherPluginEnabled[_pool], NOT_ENABLED()); /// @dev ensure the fee is <= 100% require(_take <= DENOM, INVALID_TAKE()); /// @dev store launcher configs in pool to struct mapping LauncherConfigs memory lc = LauncherConfigs(_take, _recipient); /// @dev store the pool configs in the mapping poolConfigs[_pool] = lc; /// @dev emit an event for configuration emit Configured(_pool, _take, _recipient); } /// @inheritdoc ILauncherPlugin /// @dev should be called by another contract with proper batching of function calls function enablePool(address _pool) external onlyAuthority { /// @dev require that the plugin is enabled require(!launcherPluginEnabled[_pool], ENABLED()); /// @dev fetch the feeDistributor address address _feeDist = voter.feeDistributorForGauge( voter.gaugeForPool(_pool) ); /// @dev set the feeDist for the pool feeDistToPool[_feeDist] = _pool; launcherPluginEnabled[_pool] = true; /// @dev emit with the name of the authority emit EnabledPool(_pool, nameOfAuthority[msg.sender]); } /// @inheritdoc ILauncherPlugin function migratePool(address _oldPool, address _newPool) external { require( msg.sender == address(voter) || msg.sender == operator, IVoter.NOT_AUTHORIZED(msg.sender) ); require(launcherPluginEnabled[_oldPool], NOT_ENABLED()); launcherPluginEnabled[_newPool] = true; /// @dev fetch the feedists for each pool (address _feeDist, address _newFeeDist) = ( voter.feeDistributorForGauge(voter.gaugeForPool(_oldPool)), voter.feeDistributorForGauge(voter.gaugeForPool(_newPool)) ); /// @dev set the new pool's feedist feeDistToPool[_newFeeDist] = _newPool; /// @dev copy over the values poolConfigs[_newPool] = poolConfigs[_oldPool]; /// @dev delete old values delete poolConfigs[_oldPool]; /// @dev set to disabled launcherPluginEnabled[_oldPool] = false; /// @dev set the old fee dist to the new one as a safety measure feeDistToPool[_feeDist] = feeDistToPool[_newFeeDist]; emit MigratedPool(_oldPool, _newPool); } /// @inheritdoc ILauncherPlugin function disablePool(address _pool) external onlyOperator { /// @dev require the plugin is already enabled require(launcherPluginEnabled[_pool], NOT_ENABLED()); /// @dev wipe struct delete poolConfigs[_pool]; /// @dev wipe the mapping for feeDist to the pool, incase the feeDist is overwritten delete feeDistToPool[ voter.feeDistributorForGauge(voter.gaugeForPool(_pool)) ]; /// @dev set to disabled launcherPluginEnabled[_pool] = false; /// @dev emit an event emit DisabledPool(_pool); } /// @inheritdoc ILauncherPlugin function setOperator(address _newOperator) external onlyOperator { /// @dev ensure the new operator is not already the operator require(operator != _newOperator, ALREADY_OPERATOR()); /// @dev store the oldOperator to use in the event, for info purposes address oldOperator = operator; /// @dev set operator as the new operator operator = _newOperator; /// @dev emit operator change event emit NewOperator(oldOperator, operator); } /// @inheritdoc ILauncherPlugin function grantAuthority( address _newAuthority, string calldata _name ) external onlyOperator { /// @dev ensure the proposed _newAuthority is not already one require(!authorityMap[_newAuthority], ALREADY_AUTHORITY()); /// @dev set the mapping to true authorityMap[_newAuthority] = true; /// @dev emit the new authority event emit NewAuthority(_newAuthority); /// @dev label the authority _labelAuthority(_newAuthority, _name); } /// @inheritdoc ILauncherPlugin function revokeAuthority(address _oldAuthority) external onlyOperator { /// @dev ensure _oldAuthority is already an authority require(authorityMap[_oldAuthority], NOT_AUTHORITY()); /// @dev set the mapping to false authorityMap[_oldAuthority] = false; /// @dev emit the remove authority event emit RemovedAuthority(_oldAuthority); } /// @inheritdoc ILauncherPlugin function label( address _authority, string calldata _label ) external onlyOperator { _labelAuthority(_authority, _label); } /// @inheritdoc ILauncherPlugin function values( address _feeDist ) external view returns (uint256 _take, address _recipient) { /// @dev fetch the poolConfigs from the mapping LauncherConfigs memory _tmp = poolConfigs[feeDistToPool[_feeDist]]; /// @dev return the existing values return (_tmp.launcherTake, _tmp.takeRecipient); } /// @dev internal function called on creation and manually function _labelAuthority( address _authority, string calldata _label ) internal { /// @dev ensure they are an authority require(authorityMap[_authority]); /// @dev label the authority nameOfAuthority[_authority] = _label; /// @dev emit on label emit Labeled(_authority, _label); } }
// SPDX-License-Identifier: GPL-2.0-or-later pragma solidity ^0.8.24; interface ILauncherPlugin { error NOT_AUTHORITY(); error ALREADY_AUTHORITY(); error NOT_OPERATOR(); error ALREADY_OPERATOR(); error NOT_ENABLED(); error ENABLED(); error INVALID_TAKE(); /// @dev struct that holds the configurations of each specific pool struct LauncherConfigs { uint256 launcherTake; address takeRecipient; } event NewOperator(address indexed _old, address indexed _new); event NewAuthority(address indexed _newAuthority); event RemovedAuthority(address indexed _previousAuthority); event EnabledPool(address indexed pool, string indexed _name); event DisabledPool(address indexed pool); event MigratedPool(address indexed oldPool, address indexed newPool); event Configured( address indexed pool, uint256 take, address indexed recipient ); event Labeled(address indexed authority, string indexed label); /// @notice address of the accessHub function accessHub() external view returns (address _accessHub); /// @notice protocol operator address function operator() external view returns (address _operator); /// @notice the denominator constant function DENOM() external view returns (uint256 _denominator); /// @notice whether configs are enabled for a pool /// @param _pool address of the pool /// @return bool function launcherPluginEnabled(address _pool) external view returns (bool); /// @notice maps whether an address is an authority or not /// @param _who the address to check /// @return _is true or false function authorityMap(address _who) external view returns (bool _is); /// @notice allows migrating the parameters from one pool to the other /// @param _oldPool the current address of the pair /// @param _newPool the new pool's address function migratePool(address _oldPool, address _newPool) external; /// @notice fetch the launcher configs if any /// @param _pool address of the pool /// @return LauncherConfigs the configs function poolConfigs( address _pool ) external view returns (uint256, address); /// @notice view functionality to see who is an authority function nameOfAuthority(address) external view returns (string memory); /// @notice returns the pool address for a feeDist /// @param _feeDist address of the feeDist /// @return _pool the pool address from the mapping function feeDistToPool( address _feeDist ) external view returns (address _pool); /// @notice set launcher configurations for a pool /// @param _pool address of the pool /// @param _take the fee that goes to the designated recipient /// @param _recipient the address that receives the fees function setConfigs( address _pool, uint256 _take, address _recipient ) external; /// @notice enables the pool for LauncherConfigs /// @param _pool address of the pool function enablePool(address _pool) external; /// @notice disables the pool for LauncherConfigs /// @dev clears mappings /// @param _pool address of the pool function disablePool(address _pool) external; /// @notice sets a new operator address /// @param _newOperator new operator address function setOperator(address _newOperator) external; /// @notice gives authority to a new contract/address /// @param _newAuthority the suggested new authority function grantAuthority(address _newAuthority, string calldata) external; /// @notice removes authority from a contract/address /// @param _oldAuthority the to-be-removed authority function revokeAuthority(address _oldAuthority) external; /// @notice labels an authority function label(address, string calldata) external; /// @notice returns the values for the launcherConfig of the specific feeDist /// @param _feeDist the address of the feeDist /// @return _launcherTake fee amount taken /// @return _recipient address that receives the fees function values( address _feeDist ) external view returns (uint256 _launcherTake, address _recipient); }
// SPDX-License-Identifier: BUSL-1.1 pragma solidity ^0.8.26; pragma abicoder v2; interface IVoter { error ACTIVE_GAUGE(address gauge); error GAUGE_INACTIVE(address gauge); error ALREADY_WHITELISTED(); error NOT_AUTHORIZED(address caller); error NOT_WHITELISTED(); error NOT_POOL(); error FORBIDDEN(); error NOT_INIT(); error LENGTH_MISMATCH(); error NO_GAUGE(); error ALREADY_DISTRIBUTED(address gauge, uint256 period); error ZERO_VOTE(address pool); error RATIO_TOO_HIGH(); error NOT_GT_ZERO(); error VOTE_UNSUCCESSFUL(); error UNAUTHORIZED(); event GaugeCreated( address indexed gauge, address creator, address feeDistributor, address indexed pool ); event GaugeKilled(address indexed gauge); event GaugeRevived(address indexed gauge); event Voted(address indexed owner, uint256 weight, address indexed pool); event Abstained(address indexed owner, uint256 weight); event Deposit( address indexed lp, address indexed gauge, address indexed owner, uint256 amount ); event Withdraw( address indexed lp, address indexed gauge, address indexed owner, uint256 amount ); event NotifyReward( address indexed sender, address indexed reward, uint256 amount ); event DistributeReward( address indexed sender, address indexed gauge, uint256 amount ); event EmissionsRatio( address indexed caller, uint256 oldRatio, uint256 newRatio ); event NewGovernor(address indexed sender, address indexed governor); event Whitelisted(address indexed whitelister, address indexed token); event WhitelistRevoked( address indexed forbidder, address indexed token, bool status ); event CustomGaugeCreated( address indexed gauge, address creator, address indexed token ); event MainTickSpacingChanged( address indexed token0, address indexed token1, int24 indexed newMainTickSpacing ); /// @notice returns the address of the current governor /// @return _governor address of the governor function governor() external view returns (address _governor); /// @notice the address of the vote module /// @return _voteModule the vote module contract address function voteModule() external view returns (address _voteModule); /// @notice the address of the shadow launcher plugin to enable third party launchers /// @return _launcherPlugin the address of the plugin function launcherPlugin() external view returns (address _launcherPlugin); /// @notice distributes emissions from the minter to the voter /// @param amount the amount of tokens to notify function notifyRewardAmount(uint256 amount) external; /// @notice distributes the emissions for a specific gauge /// @param _gauge the gauge address function distribute(address _gauge) external; /// @notice returns the address of the gauge factory /// @param _gaugeFactory gauge factory address function gaugeFactory() external view returns (address _gaugeFactory); /// @notice returns the address of the feeDistributor factory /// @return _feeDistributorFactory feeDist factory address function feeDistributorFactory() external view returns (address _feeDistributorFactory); /// @notice returns the address of the minter contract /// @return _minter address of the minter function minter() external view returns (address _minter); /// @notice check if the gauge is active for governance use /// @param _gauge address of the gauge /// @return _trueOrFalse if the gauge is alive function isAlive(address _gauge) external view returns (bool _trueOrFalse); /// @notice allows the token to be paired with other whitelisted assets to participate in governance /// @param _token the address of the token function whitelist(address _token) external; /// @notice effectively disqualifies a token from governance /// @param _token the address of the token function revokeWhitelist(address _token) external; /// @notice returns if the address is a gauge /// @param gauge address of the gauge /// @return _trueOrFalse boolean if the address is a gauge function isGauge(address gauge) external view returns (bool _trueOrFalse); /// @notice disable a gauge from governance /// @param _gauge address of the gauge function killGauge(address _gauge) external; /// @notice re-activate a dead gauge /// @param _gauge address of the gauge function reviveGauge(address _gauge) external; /// @notice re-cast a tokenID's votes /// @param owner address of the owner function poke(address owner) external; /// @notice sets the main tickspacing of a token pairing /// @param tokenA address of tokenA /// @param tokenB address of tokenB /// @param tickSpacing the main tickspacing to set to function setMainTickSpacing( address tokenA, address tokenB, int24 tickSpacing ) external; /// @notice create a legacy-type gauge for an arbitrary token /// @param _token 'token' to be used /// @return _arbitraryGauge the address of the new custom gauge function createArbitraryGauge( address _token ) external returns (address _arbitraryGauge); /// @notice returns if the address is a fee distributor /// @param _feeDistributor address of the feeDist /// @return _trueOrFalse if the address is a fee distributor function isFeeDistributor( address _feeDistributor ) external view returns (bool _trueOrFalse); /// @notice returns the address of the emission's token /// @return _emissionsToken emissions token contract address function emissionsToken() external view returns (address _emissionsToken); /// @notice returns the address of the pool's gauge, if any /// @param _pool pool address /// @return _gauge gauge address function gaugeForPool(address _pool) external view returns (address _gauge); /// @notice returns the address of the pool's feeDistributor, if any /// @param _gauge address of the gauge /// @return _feeDistributor address of the pool's feedist function feeDistributorForGauge( address _gauge ) external view returns (address _feeDistributor); /// @notice returns the new toPool that was redirected fromPool /// @param fromPool address of the original pool /// @return toPool the address of the redirected pool function poolRedirect( address fromPool ) external view returns (address toPool); /// @notice returns the gauge address of a CL pool /// @param tokenA address of token A in the pair /// @param tokenB address of token B in the pair /// @param tickSpacing tickspacing of the pool /// @return gauge address of the gauge function gaugeForClPool( address tokenA, address tokenB, int24 tickSpacing ) external view returns (address gauge); /// @notice returns the array of all tickspacings for the tokenA/tokenB combination /// @param tokenA address of token A in the pair /// @param tokenB address of token B in the pair /// @return _ts array of all the tickspacings function tickSpacingsForPair( address tokenA, address tokenB ) external view returns (int24[] memory _ts); /// @notice returns the main tickspacing used in the gauge/governance process /// @param tokenA address of token A in the pair /// @param tokenB address of token B in the pair /// @return _ts the main tickspacing function mainTickSpacingForPair( address tokenA, address tokenB ) external view returns (int24 _ts); /// @notice returns the block.timestamp divided by 1 week in seconds /// @return period the period used for gauges function getPeriod() external view returns (uint256 period); /// @notice cast a vote to direct emissions to gauges and earn incentives /// @param owner address of the owner /// @param _pools the list of pools to vote on /// @param _weights an arbitrary weight per pool which will be normalized to 100% regardless of numerical inputs function vote( address owner, address[] calldata _pools, uint256[] calldata _weights ) external; /// @notice reset the vote of an address /// @param owner address of the owner function reset(address owner) external; /// @notice set the governor address /// @param _governor the new governor address function setGovernor(address _governor) external; /// @notice recover stuck emissions /// @param _gauge the gauge address /// @param _period the period function stuckEmissionsRecovery(address _gauge, uint256 _period) external; /// @notice whitelists extra rewards for a gauge /// @param _gauge the gauge to whitelist rewards to /// @param _reward the reward to whitelist function whitelistGaugeRewards(address _gauge, address _reward) external; /// @notice removes a reward from the gauge whitelist /// @param _gauge the gauge to remove the whitelist from /// @param _reward the reward to remove from the whitelist function removeGaugeRewardWhitelist( address _gauge, address _reward ) external; /// @notice creates a legacy gauge for the pool /// @param _pool pool's address /// @return _gauge address of the new gauge function createGauge(address _pool) external returns (address _gauge); /// @notice create a concentrated liquidity gauge /// @param tokenA the address of tokenA /// @param tokenB the address of tokenB /// @param tickSpacing the tickspacing of the pool /// @return _clGauge address of the new gauge function createCLGauge( address tokenA, address tokenB, int24 tickSpacing ) external returns (address _clGauge); /// @notice claim concentrated liquidity gauge rewards for specific NFP token ids /// @param _gauges array of gauges /// @param _tokens two dimensional array for the tokens to claim /// @param _nfpTokenIds two dimensional array for the NFPs function claimClGaugeRewards( address[] calldata _gauges, address[][] calldata _tokens, uint256[][] calldata _nfpTokenIds ) external; /// @notice claim arbitrary rewards from specific feeDists /// @param owner address of the owner /// @param _feeDistributors address of the feeDists /// @param _tokens two dimensional array for the tokens to claim function claimIncentives( address owner, address[] calldata _feeDistributors, address[][] calldata _tokens ) external; /// @notice claim arbitrary rewards from specific gauges /// @param _gauges address of the gauges /// @param _tokens two dimensional array for the tokens to claim function claimRewards( address[] calldata _gauges, address[][] calldata _tokens ) external; /// @notice distribute emissions to a gauge for a specific period /// @param _gauge address of the gauge /// @param _period value of the period function distributeForPeriod(address _gauge, uint256 _period) external; /// @notice attempt distribution of emissions to all gauges function distributeAll() external; /// @notice distribute emissions to gauges by index /// @param startIndex start of the loop /// @param endIndex end of the loop function batchDistributeByIndex( uint256 startIndex, uint256 endIndex ) external; /// @notice returns the votes cast for a tokenID /// @param owner address of the owner /// @return votes an array of votes casted /// @return weights an array of the weights casted per pool function getVotes( address owner, uint256 period ) external view returns (address[] memory votes, uint256[] memory weights); /// @notice returns an array of all the gauges /// @return _gauges the array of gauges function getAllGauges() external view returns (address[] memory _gauges); /// @notice returns an array of all the feeDists /// @return _feeDistributors the array of feeDists function getAllFeeDistributors() external view returns (address[] memory _feeDistributors); /// @notice sets the xShadowRatio default function setGlobalRatio(uint256 _xRatio) external; /// @notice returns the array of all custom/arbitrary pools function getAllCustomPools() external view returns (address[] memory _customPools); /// @notice whether the token is whitelisted in governance function isWhitelisted(address _token) external view returns (bool _tf); /// @notice function for removing malicious or stuffed tokens function removeFeeDistributorReward( address _feeDist, address _token ) external; }
{ "remappings": [ "@openzeppelin-contracts-upgradeable-5.1.0/=dependencies/@openzeppelin-contracts-upgradeable-5.1.0/", "@openzeppelin/contracts/=dependencies/@openzeppelin-contracts-5.1.0/", "forge-std/=dependencies/forge-std-1.9.4/src/", "permit2/=lib/permit2/", "@openzeppelin-3.4.2/=node_modules/@openzeppelin-3.4.2/", "@openzeppelin-contracts-5.1.0/=dependencies/@openzeppelin-contracts-5.1.0/", "@uniswap/=node_modules/@uniswap/", "base64-sol/=node_modules/base64-sol/", "eth-gas-reporter/=node_modules/eth-gas-reporter/", "forge-std-1.9.4/=dependencies/forge-std-1.9.4/src/", "hardhat/=node_modules/hardhat/", "solmate/=node_modules/solmate/" ], "optimizer": { "enabled": true, "runs": 100 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "cancun", "viaIR": true, "libraries": {} }
[{"inputs":[{"internalType":"address","name":"_voter","type":"address"},{"internalType":"address","name":"_accessHub","type":"address"},{"internalType":"address","name":"_operator","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ALREADY_AUTHORITY","type":"error"},{"inputs":[],"name":"ALREADY_OPERATOR","type":"error"},{"inputs":[],"name":"ENABLED","type":"error"},{"inputs":[],"name":"INVALID_TAKE","type":"error"},{"inputs":[],"name":"NOT_AUTHORITY","type":"error"},{"inputs":[{"internalType":"address","name":"caller","type":"address"}],"name":"NOT_AUTHORIZED","type":"error"},{"inputs":[],"name":"NOT_ENABLED","type":"error"},{"inputs":[],"name":"NOT_OPERATOR","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"},{"indexed":false,"internalType":"uint256","name":"take","type":"uint256"},{"indexed":true,"internalType":"address","name":"recipient","type":"address"}],"name":"Configured","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"}],"name":"DisabledPool","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"pool","type":"address"},{"indexed":true,"internalType":"string","name":"_name","type":"string"}],"name":"EnabledPool","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"authority","type":"address"},{"indexed":true,"internalType":"string","name":"label","type":"string"}],"name":"Labeled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"oldPool","type":"address"},{"indexed":true,"internalType":"address","name":"newPool","type":"address"}],"name":"MigratedPool","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_newAuthority","type":"address"}],"name":"NewAuthority","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_old","type":"address"},{"indexed":true,"internalType":"address","name":"_new","type":"address"}],"name":"NewOperator","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_previousAuthority","type":"address"}],"name":"RemovedAuthority","type":"event"},{"inputs":[],"name":"DENOM","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"accessHub","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"who","type":"address"}],"name":"authorityMap","outputs":[{"internalType":"bool","name":"authority","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_pool","type":"address"}],"name":"disablePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_pool","type":"address"}],"name":"enablePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"feeDistToPool","outputs":[{"internalType":"address","name":"feeDist","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_newAuthority","type":"address"},{"internalType":"string","name":"_name","type":"string"}],"name":"grantAuthority","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_authority","type":"address"},{"internalType":"string","name":"_label","type":"string"}],"name":"label","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"launcherPluginEnabled","outputs":[{"internalType":"bool","name":"isEnabled","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_oldPool","type":"address"},{"internalType":"address","name":"_newPool","type":"address"}],"name":"migratePool","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"authority","type":"address"}],"name":"nameOfAuthority","outputs":[{"internalType":"string","name":"name","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"operator","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"pool","type":"address"}],"name":"poolConfigs","outputs":[{"internalType":"uint256","name":"launcherTake","type":"uint256"},{"internalType":"address","name":"takeRecipient","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_oldAuthority","type":"address"}],"name":"revokeAuthority","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_pool","type":"address"},{"internalType":"uint256","name":"_take","type":"uint256"},{"internalType":"address","name":"_recipient","type":"address"}],"name":"setConfigs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_newOperator","type":"address"}],"name":"setOperator","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_feeDist","type":"address"}],"name":"values","outputs":[{"internalType":"uint256","name":"_take","type":"uint256"},{"internalType":"address","name":"_recipient","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"voter","outputs":[{"internalType":"contract IVoter","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a0346100bd57601f61121038819003918201601f19168301916001600160401b038311848410176100c1578084926060946040528339810103126100bd57610047816100d5565b906100606040610059602084016100d5565b92016100d5565b6001600160a01b039283166080525f80549284166001600160a01b03199384161790556001805491909316911617905560405161112690816100ea823960805181818161017b015281816105600152818161098c0152610c030152f35b5f80fd5b634e487b7160e01b5f52604160045260245ffd5b51906001600160a01b03821682036100bd5756fe6080806040526004361015610012575f80fd5b5f3560e01c9081630792d51314610e1a5750806316343da414610dfe5780631e8d2e4d14610dbe57806322d65c3b14610d815780632aeb8f2214610ce25780632cd21e0014610c3257806346c96aac14610bee57806354fe9fd714610b75578063570ca73514610b4d578063595aeb50146109235780635dbb6eb414610830578063772b7e971461052f5780638668a494146104f2578063b3ab15fb1461044f578063c657c71814610409578063d309dbc6146102e6578063dcaaa61b1461010d5763e7589b39146100e2575f80fd5b34610109575f366003190112610109575f546040516001600160a01b039091168152602090f35b5f80fd5b3461010957602036600319011261010957610126610e68565b5f546001600160a01b0316331480156102d2575b156102c3576001600160a01b03165f8181526002602052604090205460ff16156102b457805f5260036020525f600160408220828155015560018060a01b037f0000000000000000000000000000000000000000000000000000000000000000166040516302045be960e41b8152826004820152602081602481855afa801561028c576020915f91610297575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f9161025d575b506001600160a01b03165f90815260046020908152604080832080546001600160a01b031916905583835260029091528120805460ff191690557fa41ee6d9177c663f26b51d8cc24e94c7331ffe79e49f760a14f15da1494ad1ca9080a2005b61027f915060203d602011610285575b6102778183610f4a565b810190610f6c565b826101fd565b503d61026d565b6040513d5f823e3d90fd5b6102ae9150823d8411610285576102778183610f4a565b846101c7565b638efa146960e01b5f5260045ffd5b630ce525af60e11b5f5260045ffd5b506001546001600160a01b0316331461013a565b34610109576060366003190112610109576102ff610e68565b6044356001600160a01b038116916024359183900361010957335f52600560205260ff60405f20541680156103f6575b156103e7576001600160a01b03165f8181526002602052604090205490919060ff16156102b45761271081116103d85760207fef6b9552a5aee5bbfb0c617440309047e908953f5258b53d1078ffc0d6c884ab9160405161038f81610f1a565b8181528281018681525f8681526003855260409081902092518355905160019290920180546001600160a01b0319166001600160a01b03939093169290921790915551908152a3005b63c65df89d60e01b5f5260045ffd5b63c18fdad560e01b5f5260045ffd5b505f546001600160a01b0316331461032f565b346101095761041736610e7e565b9060018060a01b035f54163314801561043b575b156102c35761043992610f8b565b005b506001546001600160a01b0316331461042b565b3461010957602036600319011261010957610468610e68565b5f546001600160a01b0316331480156104de575b156102c3576001546001600160a01b03918216918116908282146104cf576001600160a01b03191682176001557ff1e04d73c4304b5ff164f9d10c7473e2a1593b740674a6107975e2a7001c1e5c5f80a3005b63f6bb643960e01b5f5260045ffd5b506001546001600160a01b0316331461047c565b34610109576020366003190112610109576001600160a01b03610513610e68565b165f526002602052602060ff60405f2054166040519015158152f35b3461010957604036600319011261010957610548610e68565b6024356001600160a01b0381169190829003610109577f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031690338214801561081c575b15610809576001600160a01b03165f8181526002602052604090205490919060ff16156102b457825f52600260205260405f20600160ff19825416179055604051906302045be960e41b8252826004830152602082602481845afa91821561028c575f926107e8575b50604051630f55858b60e41b81526001600160a01b039092166004830152602082602481845afa91821561028c575f926107c7575b506040516302045be960e41b815260048101859052602081602481855afa801561028c576020915f916107aa575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f9161078b575b506001600160a01b03165f81815260046020908152604080832080546001600160a01b03191688179055858352600390915280822086835291209080820361075a575b50505f83815260036020908152604080832083815560010183905560028252808320805460ff1916905592825260049052818120546001600160a01b03938416825291812080546001600160a01b03191692909316919091179091557fa929e32c44fd4ebbb29a358c16e6cfb9b08d721f2a5e71126734a73a390e945c9080a3005b80548255600190810154910180546001600160a01b0319166001600160a01b039290921691909117905584806106d8565b6107a4915060203d602011610285576102778183610f4a565b84610695565b6107c19150823d8411610285576102778183610f4a565b8661065f565b6107e191925060203d602011610285576102778183610f4a565b9084610631565b61080291925060203d602011610285576102778183610f4a565b90846105fc565b632bc10c3360e01b5f523360045260245ffd5b506001546001600160a01b03163314610593565b34610109576020366003190112610109576001600160a01b03610851610e68565b165f52600660205260405f206040515f82549261086d84610ee2565b9081845260208401946001811690815f1461090657506001146108c6575b8460408561089b81870382610f4a565b8151928391602083525180918160208501528484015e5f828201840152601f01601f19168101030190f35b5f90815260208120939250905b8082106108ec5750909150810160200161089b8261088b565b9192600181602092548385880101520191019092916108d3565b60ff191686525050151560051b8201602001905061089b8261088b565b346101095760203660031901126101095761093c610e68565b335f52600560205260ff60405f2054168015610b3a575b156103e7576001600160a01b03165f8181526002602052604090205460ff16610b2b576040516302045be960e41b8152600481018290527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b031690602081602481855afa801561028c576020915f91610b0e575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f91610aef575b506001600160a01b03165f90815260046020908152604080832080546001600160a01b0319168517905583835260028252808320805460ff1916600117905533835260069091528082209051815490928392909190610a6282610ee2565b9160018116908115610ad85750600114610aa3575b5050039020907fec779a851842f582d1e28aca39c7057da0596cf816d0535bec1df1c0b59fdaf45f80a3005b9091505f5260205f205f905b828210610ac157505081018480610a77565b805482860152849350602090910190600101610aaf565b60ff19168552505080151502820190508480610a77565b610b08915060203d602011610285576102778183610f4a565b82610a04565b610b259150823d8411610285576102778183610f4a565b846109ce565b6352f878d960e11b5f5260045ffd5b505f546001600160a01b03163314610953565b34610109575f366003190112610109576001546040516001600160a01b039091168152602090f35b34610109576020366003190112610109576001600160a01b03610b96610e68565b165f52600460205260018060a01b0360405f2054165f526003602052602060405f20604051610bc481610f1a565b81548082526001909201546001600160a01b03169201829052604080519182526020820192909252f35b34610109575f366003190112610109576040517f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03168152602090f35b3461010957610c4036610e7e565b9060018060a01b035f541633148015610cce575b156102c3576001600160a01b0383165f8181526005602052604090205490939060ff16610cbf5783610439945f52600560205260405f20600160ff198254161790557f1a21cdb01b4a24f9795ddbd009ccbfea49adcea2f28c2606be806502192379e65f80a2610f8b565b63bc626b6f60e01b5f5260045ffd5b506001546001600160a01b03163314610c54565b3461010957602036600319011261010957610cfb610e68565b5f546001600160a01b031633148015610d6d575b156102c3576001600160a01b03165f8181526005602052604090205460ff16156103e757805f52600560205260405f2060ff1981541690557fc59f9761f66797faf208a417f9fbf142783bcffcd831283a2ded97f1a676abb05f80a2005b506001546001600160a01b03163314610d0f565b34610109576020366003190112610109576001600160a01b03610da2610e68565b165f526005602052602060ff60405f2054166040519015158152f35b34610109576020366003190112610109576001600160a01b03610ddf610e68565b165f526004602052602060018060a01b0360405f205416604051908152f35b34610109575f3660031901126101095760206040516127108152f35b34610109576020366003190112610109576001600160a01b03610e3b610e68565b165f9081526003602090815260409182902080546001909101549084526001600160a01b03169083015290f35b600435906001600160a01b038216820361010957565b6040600319820112610109576004356001600160a01b0381168103610109579160243567ffffffffffffffff811161010957826023820112156101095780600401359267ffffffffffffffff84116101095760248483010111610109576024019190565b90600182811c92168015610f10575b6020831014610efc57565b634e487b7160e01b5f52602260045260245ffd5b91607f1691610ef1565b6040810190811067ffffffffffffffff821117610f3657604052565b634e487b7160e01b5f52604160045260245ffd5b90601f8019910116810190811067ffffffffffffffff821117610f3657604052565b9081602091031261010957516001600160a01b03811681036101095790565b6001600160a01b03165f818152600560205260409020549092919060ff161561010957825f52600660205260405f2067ffffffffffffffff8311610f3657610fd38154610ee2565b601f81116110ab575b50825f601f8211600114611047575f9161103c575b508360011b905f198560031b1c19161790555b81604051928392833781015f8152039020907f28849b480f55b807e483bef9ba16565e53abaef052ab27c5f964a320aabb93975f80a3565b90508201355f610ff1565b5f8381526020812092508590601f198216905b818110611090575010611077575b5050600183811b019055611004565b8301355f19600386901b60f8161c191690555f80611068565b8684013585556001909401936020938401938893500161105a565b815f5260205f20601f850160051c810191602086106110e6575b601f0160051c01905b8181106110db5750610fdc565b5f81556001016110ce565b90915081906110c556fea2646970667358221220d2f9017532d4a646d6e6a81e1713cb1edc042e5ee7f575d7892f3946541b793664736f6c634300081c00330000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d55104000000000000000000000000c07317aff4f9cd4f4cf7785898902a31a46d4536000000000000000000000000e4878b1870518f5988572658000e7b905690d2ab
Deployed Bytecode
0x6080806040526004361015610012575f80fd5b5f3560e01c9081630792d51314610e1a5750806316343da414610dfe5780631e8d2e4d14610dbe57806322d65c3b14610d815780632aeb8f2214610ce25780632cd21e0014610c3257806346c96aac14610bee57806354fe9fd714610b75578063570ca73514610b4d578063595aeb50146109235780635dbb6eb414610830578063772b7e971461052f5780638668a494146104f2578063b3ab15fb1461044f578063c657c71814610409578063d309dbc6146102e6578063dcaaa61b1461010d5763e7589b39146100e2575f80fd5b34610109575f366003190112610109575f546040516001600160a01b039091168152602090f35b5f80fd5b3461010957602036600319011261010957610126610e68565b5f546001600160a01b0316331480156102d2575b156102c3576001600160a01b03165f8181526002602052604090205460ff16156102b457805f5260036020525f600160408220828155015560018060a01b037f0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d55104166040516302045be960e41b8152826004820152602081602481855afa801561028c576020915f91610297575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f9161025d575b506001600160a01b03165f90815260046020908152604080832080546001600160a01b031916905583835260029091528120805460ff191690557fa41ee6d9177c663f26b51d8cc24e94c7331ffe79e49f760a14f15da1494ad1ca9080a2005b61027f915060203d602011610285575b6102778183610f4a565b810190610f6c565b826101fd565b503d61026d565b6040513d5f823e3d90fd5b6102ae9150823d8411610285576102778183610f4a565b846101c7565b638efa146960e01b5f5260045ffd5b630ce525af60e11b5f5260045ffd5b506001546001600160a01b0316331461013a565b34610109576060366003190112610109576102ff610e68565b6044356001600160a01b038116916024359183900361010957335f52600560205260ff60405f20541680156103f6575b156103e7576001600160a01b03165f8181526002602052604090205490919060ff16156102b45761271081116103d85760207fef6b9552a5aee5bbfb0c617440309047e908953f5258b53d1078ffc0d6c884ab9160405161038f81610f1a565b8181528281018681525f8681526003855260409081902092518355905160019290920180546001600160a01b0319166001600160a01b03939093169290921790915551908152a3005b63c65df89d60e01b5f5260045ffd5b63c18fdad560e01b5f5260045ffd5b505f546001600160a01b0316331461032f565b346101095761041736610e7e565b9060018060a01b035f54163314801561043b575b156102c35761043992610f8b565b005b506001546001600160a01b0316331461042b565b3461010957602036600319011261010957610468610e68565b5f546001600160a01b0316331480156104de575b156102c3576001546001600160a01b03918216918116908282146104cf576001600160a01b03191682176001557ff1e04d73c4304b5ff164f9d10c7473e2a1593b740674a6107975e2a7001c1e5c5f80a3005b63f6bb643960e01b5f5260045ffd5b506001546001600160a01b0316331461047c565b34610109576020366003190112610109576001600160a01b03610513610e68565b165f526002602052602060ff60405f2054166040519015158152f35b3461010957604036600319011261010957610548610e68565b6024356001600160a01b0381169190829003610109577f0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d551046001600160a01b031690338214801561081c575b15610809576001600160a01b03165f8181526002602052604090205490919060ff16156102b457825f52600260205260405f20600160ff19825416179055604051906302045be960e41b8252826004830152602082602481845afa91821561028c575f926107e8575b50604051630f55858b60e41b81526001600160a01b039092166004830152602082602481845afa91821561028c575f926107c7575b506040516302045be960e41b815260048101859052602081602481855afa801561028c576020915f916107aa575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f9161078b575b506001600160a01b03165f81815260046020908152604080832080546001600160a01b03191688179055858352600390915280822086835291209080820361075a575b50505f83815260036020908152604080832083815560010183905560028252808320805460ff1916905592825260049052818120546001600160a01b03938416825291812080546001600160a01b03191692909316919091179091557fa929e32c44fd4ebbb29a358c16e6cfb9b08d721f2a5e71126734a73a390e945c9080a3005b80548255600190810154910180546001600160a01b0319166001600160a01b039290921691909117905584806106d8565b6107a4915060203d602011610285576102778183610f4a565b84610695565b6107c19150823d8411610285576102778183610f4a565b8661065f565b6107e191925060203d602011610285576102778183610f4a565b9084610631565b61080291925060203d602011610285576102778183610f4a565b90846105fc565b632bc10c3360e01b5f523360045260245ffd5b506001546001600160a01b03163314610593565b34610109576020366003190112610109576001600160a01b03610851610e68565b165f52600660205260405f206040515f82549261086d84610ee2565b9081845260208401946001811690815f1461090657506001146108c6575b8460408561089b81870382610f4a565b8151928391602083525180918160208501528484015e5f828201840152601f01601f19168101030190f35b5f90815260208120939250905b8082106108ec5750909150810160200161089b8261088b565b9192600181602092548385880101520191019092916108d3565b60ff191686525050151560051b8201602001905061089b8261088b565b346101095760203660031901126101095761093c610e68565b335f52600560205260ff60405f2054168015610b3a575b156103e7576001600160a01b03165f8181526002602052604090205460ff16610b2b576040516302045be960e41b8152600481018290527f0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d551046001600160a01b031690602081602481855afa801561028c576020915f91610b0e575b50604051630f55858b60e41b81526001600160a01b03909116600482015291829060249082905afa90811561028c575f91610aef575b506001600160a01b03165f90815260046020908152604080832080546001600160a01b0319168517905583835260028252808320805460ff1916600117905533835260069091528082209051815490928392909190610a6282610ee2565b9160018116908115610ad85750600114610aa3575b5050039020907fec779a851842f582d1e28aca39c7057da0596cf816d0535bec1df1c0b59fdaf45f80a3005b9091505f5260205f205f905b828210610ac157505081018480610a77565b805482860152849350602090910190600101610aaf565b60ff19168552505080151502820190508480610a77565b610b08915060203d602011610285576102778183610f4a565b82610a04565b610b259150823d8411610285576102778183610f4a565b846109ce565b6352f878d960e11b5f5260045ffd5b505f546001600160a01b03163314610953565b34610109575f366003190112610109576001546040516001600160a01b039091168152602090f35b34610109576020366003190112610109576001600160a01b03610b96610e68565b165f52600460205260018060a01b0360405f2054165f526003602052602060405f20604051610bc481610f1a565b81548082526001909201546001600160a01b03169201829052604080519182526020820192909252f35b34610109575f366003190112610109576040517f0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d551046001600160a01b03168152602090f35b3461010957610c4036610e7e565b9060018060a01b035f541633148015610cce575b156102c3576001600160a01b0383165f8181526005602052604090205490939060ff16610cbf5783610439945f52600560205260405f20600160ff198254161790557f1a21cdb01b4a24f9795ddbd009ccbfea49adcea2f28c2606be806502192379e65f80a2610f8b565b63bc626b6f60e01b5f5260045ffd5b506001546001600160a01b03163314610c54565b3461010957602036600319011261010957610cfb610e68565b5f546001600160a01b031633148015610d6d575b156102c3576001600160a01b03165f8181526005602052604090205460ff16156103e757805f52600560205260405f2060ff1981541690557fc59f9761f66797faf208a417f9fbf142783bcffcd831283a2ded97f1a676abb05f80a2005b506001546001600160a01b03163314610d0f565b34610109576020366003190112610109576001600160a01b03610da2610e68565b165f526005602052602060ff60405f2054166040519015158152f35b34610109576020366003190112610109576001600160a01b03610ddf610e68565b165f526004602052602060018060a01b0360405f205416604051908152f35b34610109575f3660031901126101095760206040516127108152f35b34610109576020366003190112610109576001600160a01b03610e3b610e68565b165f9081526003602090815260409182902080546001909101549084526001600160a01b03169083015290f35b600435906001600160a01b038216820361010957565b6040600319820112610109576004356001600160a01b0381168103610109579160243567ffffffffffffffff811161010957826023820112156101095780600401359267ffffffffffffffff84116101095760248483010111610109576024019190565b90600182811c92168015610f10575b6020831014610efc57565b634e487b7160e01b5f52602260045260245ffd5b91607f1691610ef1565b6040810190811067ffffffffffffffff821117610f3657604052565b634e487b7160e01b5f52604160045260245ffd5b90601f8019910116810190811067ffffffffffffffff821117610f3657604052565b9081602091031261010957516001600160a01b03811681036101095790565b6001600160a01b03165f818152600560205260409020549092919060ff161561010957825f52600660205260405f2067ffffffffffffffff8311610f3657610fd38154610ee2565b601f81116110ab575b50825f601f8211600114611047575f9161103c575b508360011b905f198560031b1c19161790555b81604051928392833781015f8152039020907f28849b480f55b807e483bef9ba16565e53abaef052ab27c5f964a320aabb93975f80a3565b90508201355f610ff1565b5f8381526020812092508590601f198216905b818110611090575010611077575b5050600183811b019055611004565b8301355f19600386901b60f8161c191690555f80611068565b8684013585556001909401936020938401938893500161105a565b815f5260205f20601f850160051c810191602086106110e6575b601f0160051c01905b8181106110db5750610fdc565b5f81556001016110ce565b90915081906110c556fea2646970667358221220d2f9017532d4a646d6e6a81e1713cb1edc042e5ee7f575d7892f3946541b793664736f6c634300081c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d55104000000000000000000000000c07317aff4f9cd4f4cf7785898902a31a46d4536000000000000000000000000e4878b1870518f5988572658000e7b905690d2ab
-----Decoded View---------------
Arg [0] : _voter (address): 0x4Ada7f1F305B3b5FCf0225933De7539557D55104
Arg [1] : _accessHub (address): 0xc07317aFf4f9cd4f4Cf7785898902a31A46D4536
Arg [2] : _operator (address): 0xe4878b1870518F5988572658000E7B905690D2aB
-----Encoded View---------------
3 Constructor Arguments found :
Arg [0] : 0000000000000000000000004ada7f1f305b3b5fcf0225933de7539557d55104
Arg [1] : 000000000000000000000000c07317aff4f9cd4f4cf7785898902a31a46d4536
Arg [2] : 000000000000000000000000e4878b1870518f5988572658000e7b905690d2ab
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.