Source Code
Overview
S Balance
More Info
ContractCreator
Loading...
Loading
Similar Match Source Code This contract matches the deployed Bytecode of the Source Code for Contract 0xBcbCA217...8a9EBA7AB The constructor portion of the code might be different and could alter the actual behaviour of the contract
Contract Name:
Staking
Compiler Version
v0.8.26+commit.8a97fa7a
Optimization Enabled:
Yes with 1000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.24; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/utils/ReentrancyGuard.sol"; import "./interfaces/IToken.sol"; import "./interfaces/IReferral.sol"; import "./interfaces/IManager.sol"; contract Staking is ReentrancyGuard { IManager private Manager; IToken private Token; IReferral private Referral; uint256 private depositFee = 0; uint256 public epochDuration = 6 hours; uint256 public fullDistributionEpochs = 28; // 28 * 6 hours = 7 days uint256 private genesisEpochTime; bool private isStarted = false; uint256 public totalFueledToken = 0; uint256 public multiplier; struct Ticket { uint256 id; uint256 baseAmount; uint256 baseRedeemed; uint256 boostAmount; uint256 boostRedeemed; uint256 creationEpoch; } struct Epoch { uint256 epoch; bool initialized; uint256 totalStaked; } mapping(address => Ticket[]) public tickets; mapping(uint256 => Epoch) public epochs; mapping(address => uint256) public pendingReferralRewards; //--------------------------------------------------// constructor(address _manager) { Manager = IManager(_manager); } //--------------------------------------------------// modifier onlyOwner() { require( msg.sender == Manager.owner(), "Only owner can call this function" ); _; } //--------------------------------------------------// function setFees(uint256 _depositFee) external onlyOwner { require(_depositFee < 100, "Fees too high"); depositFee = _depositFee; } function setEpochDuration(uint256 _epochDuration) external onlyOwner { epochDuration = _epochDuration; } function setFullDistributionEpochs( uint256 _fullDistributionEpochs ) external onlyOwner { fullDistributionEpochs = _fullDistributionEpochs; } function startEpoch() external onlyOwner { require(!isStarted, "Epoch already started"); genesisEpochTime = block.timestamp; epochs[0] = Epoch(0, true, 0); isStarted = true; } function setAll() external onlyOwner { Token = IToken(_getContract("Token")); Referral = IReferral(_getContract("Referral")); } function setManager(address _manager) external onlyOwner { Manager = IManager(_manager); } //--------------------------------------------------// function deposit(uint256 amount, uint8 rate) external nonReentrant { _deposit(msg.sender, amount, rate); } function claim(uint256 id) external nonReentrant { address sender = msg.sender; uint256 _rewards = _claim(sender, id); Token.mint(sender, _rewards); } function batchClaim(uint256[] memory ids) external nonReentrant { address sender = msg.sender; uint256 _rewards = 0; for (uint256 i = 0; i < ids.length; i++) { _rewards += _claim(sender, ids[i]); } Token.mint(sender, _rewards); } function claimAll() external nonReentrant { address sender = msg.sender; uint256 _rewards = 0; for (uint256 i = 0; i < tickets[sender].length; i++) { _rewards += _claim(sender, i); } Token.mint(sender, _rewards); } function claimReferralRewards() external nonReentrant { address sender = msg.sender; uint256 availableRewards = pendingReferralRewards[sender]; require(availableRewards > 0, "Nothing to claim"); pendingReferralRewards[sender] = 0; Token.mint(sender, availableRewards); } //--------------------------------------------------// function _redeemCalculator( address user, uint256 id ) private view returns (uint256, uint256) { uint256 currentEpoch = _getEpoch(); Ticket memory ticket = tickets[user][id]; uint256 _fullDistributionEpochs = fullDistributionEpochs; uint256 epochsPassed = currentEpoch - ticket.creationEpoch; epochsPassed = epochsPassed > _fullDistributionEpochs ? _fullDistributionEpochs : epochsPassed; uint256 amountToRedeemWithMultiplier = ((ticket.boostAmount * epochsPassed) / _fullDistributionEpochs) - ticket.boostRedeemed; uint256 amountToRedeem = ((ticket.baseAmount * epochsPassed) / _fullDistributionEpochs) - ticket.baseRedeemed; return (amountToRedeem, amountToRedeemWithMultiplier); } function nextEpochRedeemForUserCalculator( address user, uint256 id ) public view returns (uint256) { Ticket memory ticket = tickets[user][id]; uint256 amountToRedeem = ((ticket.boostAmount * 1) / fullDistributionEpochs) - ticket.boostRedeemed; return amountToRedeem; } function _getEpoch() internal view returns (uint256) { return (block.timestamp - genesisEpochTime) / epochDuration; } function getNextEpoch() public view returns (uint256) { return genesisEpochTime + (_getEpoch() + 1) * epochDuration; } //--------------------------------------------------// function _deposit(address user, uint256 amount, uint8 rate) private { require(isStarted, "Epoch not started"); require(rate == 0 || rate == 1, "Invalid rate"); uint256 currentEpoch = _getEpoch(); uint256 amountAfterFee = amount; uint256 fee; unchecked { fee = (amount * depositFee) / 100; amountAfterFee = amount - fee; } totalFueledToken += amountAfterFee; Token.burnFrom(user, amount); if (fee > 0) { Token.transfer(address(Token), fee); } tickets[user].push( Ticket( tickets[user].length, amountAfterFee, 0, (amountAfterFee * multiplier) / 1e18, 0, currentEpoch ) ); } function _claim(address user, uint256 id) private returns (uint256) { (uint256 base, uint256 boost) = _redeemCalculator(user, id); if (base == 0) { return 0; } if (Referral.getReferrer(user) != address(0)) { uint256 referralRewards = (boost * 5) / 100; pendingReferralRewards[ Referral.getReferrer(user) ] += referralRewards; } Ticket storage ticket = tickets[user][id]; ticket.boostRedeemed += boost; ticket.baseRedeemed += base; totalFueledToken -= base; return boost; } function _updateMultiplier() private { uint256 ratio = 3e18 - ((totalFueledToken * 2e18) / Token.totalSupply()); if (ratio < 1e18) { ratio = 1e18; } else if (ratio > 3e18) { ratio = 3e18; } multiplier = ratio; } function _getContract( string memory contractName ) internal view returns (address) { return Manager.getContract(contractName); } //--------------------------------------------------// function getCurrentEpoch() external view returns (uint256) { return _getEpoch(); } function getUserTotalStaked(address user) external view returns (uint256) { uint256 sumToken = 0; Ticket[] memory ticket = tickets[user]; for (uint256 i = 0; i < tickets[user].length; i++) { sumToken += ticket[i].baseAmount; } return sumToken; } function getTotalRedeemableAmountForUser( address user ) external view returns (uint256) { uint256 sum = 0; for (uint256 i = 0; i < tickets[user].length; i++) { (, uint256 pendingRedeem) = _redeemCalculator(user, i); sum += pendingRedeem; } return sum; } function getNextStakingRewardsForAllTicketsForUser( address user ) external view returns (uint256) { uint256 sum = 0; for (uint256 i = 0; i < tickets[user].length; i++) { sum += nextEpochRedeemForUserCalculator(user, i); } return sum; } function getTotalTicketsForUser( address user ) external view returns (uint256) { return tickets[user].length; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC-20 standard as defined in the ERC. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the value of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the value of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves a `value` amount of tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 value) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets a `value` amount of tokens as the allowance of `spender` over the * caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 value) external returns (bool); /** * @dev Moves a `value` amount of tokens from `from` to `to` using the * allowance mechanism. `value` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 value) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.1.0) (utils/ReentrancyGuard.sol) pragma solidity ^0.8.20; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If EIP-1153 (transient storage) is available on the chain you're deploying at, * consider using {ReentrancyGuardTransient} instead. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant NOT_ENTERED = 1; uint256 private constant ENTERED = 2; uint256 private _status; /** * @dev Unauthorized reentrant call. */ error ReentrancyGuardReentrantCall(); constructor() { _status = NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and making it call a * `private` function that does the actual work. */ modifier nonReentrant() { _nonReentrantBefore(); _; _nonReentrantAfter(); } function _nonReentrantBefore() private { // On the first call to nonReentrant, _status will be NOT_ENTERED if (_status == ENTERED) { revert ReentrancyGuardReentrantCall(); } // Any calls to nonReentrant after this point will fail _status = ENTERED; } function _nonReentrantAfter() private { // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = NOT_ENTERED; } /** * @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a * `nonReentrant` function in the call stack. */ function _reentrancyGuardEntered() internal view returns (bool) { return _status == ENTERED; } }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.20; interface IManager { function getContract(string memory name) external view returns (address); function owner() external view returns (address); }
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.20; interface IReferral { function getUserFromCode(bytes32 code) external view returns (address); function getReferrals(address user) external view returns (address[] memory); function getTimeOfReferrals(address user) external view returns (uint256[] memory); function getReferrer(address user) external view returns (address); function rewardsPerReferral() external view returns (uint256); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v5.0.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.20; /** * @dev Interface of the ERC-20 standard as defined in the ERC. */ interface IToken { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev Returns the value of tokens in existence. */ function totalSupply() external view returns (uint256); /** * @dev Returns the value of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** * @dev Moves a `value` amount of tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, uint256 value) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be * allowed to spend on behalf of `owner` through {transferFrom}. This is * zero by default. * * This value changes when {approve} or {transferFrom} are called. */ function allowance(address owner, address spender) external view returns (uint256); /** * @dev Sets a `value` amount of tokens as the allowance of `spender` over the * caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * * IMPORTANT: Beware that changing an allowance with this method brings the risk * that someone may use both the old and the new allowance by unfortunate * transaction ordering. One possible solution to mitigate this race * condition is to first reduce the spender's allowance to 0 and set the * desired value afterwards: * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * * Emits an {Approval} event. */ function approve(address spender, uint256 value) external returns (bool); /** * @dev Moves a `value` amount of tokens from `from` to `to` using the * allowance mechanism. `value` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transferFrom(address from, address to, uint256 value) external returns (bool); function mint(address to, uint256 value) external; function burnFrom(address from, uint256 value) external; }
{ "optimizer": { "enabled": true, "runs": 1000 }, "evmVersion": "paris", "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
[{"inputs":[{"internalType":"address","name":"_manager","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ReentrancyGuardReentrantCall","type":"error"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"batchClaim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"claimReferralRewards","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint8","name":"rate","type":"uint8"}],"name":"deposit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"epochDuration","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"epochs","outputs":[{"internalType":"uint256","name":"epoch","type":"uint256"},{"internalType":"bool","name":"initialized","type":"bool"},{"internalType":"uint256","name":"totalStaked","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"fullDistributionEpochs","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getNextEpoch","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNextStakingRewardsForAllTicketsForUser","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getTotalRedeemableAmountForUser","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getTotalTicketsForUser","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getUserTotalStaked","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"multiplier","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"nextEpochRedeemForUserCalculator","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"pendingReferralRewards","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"setAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_epochDuration","type":"uint256"}],"name":"setEpochDuration","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_depositFee","type":"uint256"}],"name":"setFees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_fullDistributionEpochs","type":"uint256"}],"name":"setFullDistributionEpochs","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_manager","type":"address"}],"name":"setManager","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startEpoch","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"name":"tickets","outputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"baseAmount","type":"uint256"},{"internalType":"uint256","name":"baseRedeemed","type":"uint256"},{"internalType":"uint256","name":"boostAmount","type":"uint256"},{"internalType":"uint256","name":"boostRedeemed","type":"uint256"},{"internalType":"uint256","name":"creationEpoch","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalFueledToken","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106101a35760003560e01c8063715783a1116100ee578063bc29278211610097578063d1058e5911610071578063d1058e5914610355578063dae7a13c1461035d578063e530d0f71461039d578063efe97d05146103b057600080fd5b8063bc292782146102e2578063c6b61e4c146102f5578063d0ebdbe71461034257600080fd5b806394905cc0116100c857806394905cc0146102a9578063a2c8b177146102d2578063b97dd9e2146102da57600080fd5b8063715783a11461027a57806376f6804d1461028d5780638ba1ebe21461029657600080fd5b80633d18678e116101505780634ff0876a1161012a5780634ff0876a1461024b578063654cfdff146102545780636e2f16961461026757600080fd5b80633d18678e1461021d5780633d68c1ee146102305780633e7d15c01461024357600080fd5b806330024dfe1161018157806330024dfe146101d75780633469336d146101ea578063379607f51461020a57600080fd5b806305eaab4b146101a85780630f823594146101b25780631b3ed722146101ce575b600080fd5b6101b06103b8565b005b6101bb60095481565b6040519081526020015b60405180910390f35b6101bb600a5481565b6101b06101e53660046117e7565b6104ac565b6101bb6101f8366004611815565b600d6020526000908152604090205481565b6101b06102183660046117e7565b610592565b6101b061022b3660046117e7565b61061f565b6101b061023e3660046117e7565b610755565b6101b061083b565b6101bb60055481565b6101b0610262366004611839565b6109f3565b6101bb610275366004611815565b610a14565b6101bb61028836600461186f565b610b1f565b6101bb60065481565b6101bb6102a4366004611815565b610bdd565b6101bb6102b7366004611815565b6001600160a01b03166000908152600b602052604090205490565b6101b0610c2e565b6101bb610e11565b6101b06102f03660046118b1565b610e20565b6103276103033660046117e7565b600c60205260009081526040902080546001820154600290920154909160ff169083565b604080519384529115156020840152908201526060016101c5565b6101b0610350366004611815565b610ea7565b6101b0610fb7565b61037061036b36600461186f565b61103c565b604080519687526020870195909552938501929092526060840152608083015260a082015260c0016101c5565b6101bb6103ab366004611815565b611090565b6101bb6110d3565b6103c0611102565b336000818152600d6020526040902054806104225760405162461bcd60e51b815260206004820152601060248201527f4e6f7468696e6720746f20636c61696d0000000000000000000000000000000060448201526064015b60405180910390fd5b6001600160a01b038281166000818152600d60205260408082209190915560025490516340c10f1960e01b8152600481019290925260248201849052909116906340c10f19906044015b600060405180830381600087803b15801561048657600080fd5b505af115801561049a573d6000803e3d6000fd5b5050505050506104aa6001600055565b565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610523919061197e565b6001600160a01b0316336001600160a01b03161461058d5760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b600555565b61059a611102565b3360006105a78284611145565b6002546040516340c10f1960e01b81526001600160a01b038581166004830152602482018490529293509116906340c10f19906044015b600060405180830381600087803b1580156105f857600080fd5b505af115801561060c573d6000803e3d6000fd5b50505050505061061c6001600055565b50565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610672573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610696919061197e565b6001600160a01b0316336001600160a01b0316146107005760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b606481106107505760405162461bcd60e51b815260206004820152600d60248201527f4665657320746f6f2068696768000000000000000000000000000000000000006044820152606401610419565b600455565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156107a8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107cc919061197e565b6001600160a01b0316336001600160a01b0316146108365760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b600655565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561088e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108b2919061197e565b6001600160a01b0316336001600160a01b03161461091c5760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b61095a6040518060400160405280600581526020017f546f6b656e000000000000000000000000000000000000000000000000000000815250611340565b6002805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b039290921691909117905560408051808201909152600881527f526566657272616c00000000000000000000000000000000000000000000000060208201526109c490611340565b6003805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6109fb611102565b610a063383836113cb565b610a106001600055565b5050565b6001600160a01b0381166000908152600b60209081526040808320805482518185028101850190935280835284938493929190849084015b82821015610aba57838290600052602060002090600602016040518060c0016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152505081526020019060010190610a4c565b50505050905060005b6001600160a01b0385166000908152600b6020526040902054811015610b1657818181518110610af557610af561199b565b60200260200101516020015183610b0c91906119c7565b9250600101610ac3565b50909392505050565b6001600160a01b0382166000908152600b60205260408120805482919084908110610b4c57610b4c61199b565b90600052602060002090600602016040518060c0016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152505090506000816080015160065483606001516001610bbe91906119da565b610bc89190611a07565b610bd29190611a29565b925050505b92915050565b600080805b6001600160a01b0384166000908152600b6020526040902054811015610c27576000610c0e85836116a1565b9150610c1c905081846119c7565b925050600101610be2565b5092915050565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ca5919061197e565b6001600160a01b0316336001600160a01b031614610d0f5760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b60085460ff1615610d625760405162461bcd60e51b815260206004820152601560248201527f45706f636820616c7265616479207374617274656400000000000000000000006044820152606401610419565b4260075560408051606081018252600080825260016020808401828152948401838152928052600c905291517f13649b2456f1b42fef0f0040b3aaeabcd21a76a0f3f5defd4f583839455116e85591517f13649b2456f1b42fef0f0040b3aaeabcd21a76a0f3f5defd4f583839455116e9805491151560ff1992831617905591517f13649b2456f1b42fef0f0040b3aaeabcd21a76a0f3f5defd4f583839455116ea5560088054909216179055565b6000610e1b6117ca565b905090565b610e28611102565b336000805b8351811015610e6d57610e5983858381518110610e4c57610e4c61199b565b6020026020010151611145565b610e6390836119c7565b9150600101610e2d565b506002546040516340c10f1960e01b81526001600160a01b03848116600483015260248201849052909116906340c10f19906044016105de565b600160009054906101000a90046001600160a01b03166001600160a01b0316638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610efa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1e919061197e565b6001600160a01b0316336001600160a01b031614610f885760405162461bcd60e51b815260206004820152602160248201527f4f6e6c79206f776e65722063616e2063616c6c20746869732066756e6374696f6044820152603760f91b6064820152608401610419565b6001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b610fbf611102565b336000805b6001600160a01b0383166000908152600b602052604090205481101561100257610fee8382611145565b610ff890836119c7565b9150600101610fc4565b506002546040516340c10f1960e01b81526001600160a01b03848116600483015260248201849052909116906340c10f199060440161046c565b600b602052816000526040600020818154811061105857600080fd5b600091825260209091206006909102018054600182015460028301546003840154600485015460059095015493965091945092909186565b600080805b6001600160a01b0384166000908152600b6020526040902054811015610c27576110bf8482610b1f565b6110c990836119c7565b9150600101611095565b60006005546110e06117ca565b6110eb9060016119c7565b6110f591906119da565b600754610e1b91906119c7565b60026000540361113e576040517f3ee5aeb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002600055565b600080600061115485856116a1565b915091508160000361116b57600092505050610bd7565b600354604051634a9fefc760e01b81526001600160a01b0387811660048301526000921690634a9fefc790602401602060405180830381865afa1580156111b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111da919061197e565b6001600160a01b0316146112af57600060646111f78360056119da565b6112019190611a07565b600354604051634a9fefc760e01b81526001600160a01b0389811660048301529293508392600d92600092911690634a9fefc790602401602060405180830381865afa158015611255573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611279919061197e565b6001600160a01b03166001600160a01b0316815260200190815260200160002060008282546112a891906119c7565b9091555050505b6001600160a01b0385166000908152600b602052604081208054869081106112d9576112d961199b565b90600052602060002090600602019050818160040160008282546112fd91906119c7565b925050819055508281600201600082825461131891906119c7565b9250508190555082600960008282546113319190611a29565b90915550919695505050505050565b6001546040517f358177730000000000000000000000000000000000000000000000000000000081526000916001600160a01b03169063358177739061138a908590600401611a3c565b602060405180830381865afa1580156113a7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610bd7919061197e565b60085460ff1661141d5760405162461bcd60e51b815260206004820152601160248201527f45706f6368206e6f7420737461727465640000000000000000000000000000006044820152606401610419565b60ff8116158061143057508060ff166001145b61147c5760405162461bcd60e51b815260206004820152600c60248201527f496e76616c6964207261746500000000000000000000000000000000000000006044820152606401610419565b60006114866117ca565b90506000839050600060646004548602816114a3576114a36119f1565b049050808503915081600960008282546114bd91906119c7565b90915550506002546040517f79cc67900000000000000000000000000000000000000000000000000000000081526001600160a01b03888116600483015260248201889052909116906379cc679090604401600060405180830381600087803b15801561152957600080fd5b505af115801561153d573d6000803e3d6000fd5b5050505060008111156115db576002546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081526001600160a01b0390911660048201819052602482018390529063a9059cbb906044016020604051808303816000875af11580156115b5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115d99190611a8a565b505b6001600160a01b0386166000908152600b60209081526040808320815160c0810183528154815292830186905290820192909252600a546060820190670de0b6b3a76400009061162b90876119da565b6116359190611a07565b8152600060208083018290526040928301979097528354600181810186559482529087902083516006909202019081559582015192860192909255908101516002850155606081015160038501556080810151600485015560a001516005909301929092555050505050565b60008060006116ae6117ca565b6001600160a01b0386166000908152600b6020526040812080549293509091869081106116dd576116dd61199b565b90600052602060002090600602016040518060c0016040529081600082015481526020016001820154815260200160028201548152602001600382015481526020016004820154815260200160058201548152505090506000600654905060008260a001518461174d9190611a29565b905081811161175c578061175e565b815b9050600083608001518383866060015161177891906119da565b6117829190611a07565b61178c9190611a29565b905060008460400151848487602001516117a691906119da565b6117b09190611a07565b6117ba9190611a29565b9a91995090975050505050505050565b6000600554600754426117dd9190611a29565b610e1b9190611a07565b6000602082840312156117f957600080fd5b5035919050565b6001600160a01b038116811461061c57600080fd5b60006020828403121561182757600080fd5b813561183281611800565b9392505050565b6000806040838503121561184c57600080fd5b82359150602083013560ff8116811461186457600080fd5b809150509250929050565b6000806040838503121561188257600080fd5b823561188d81611800565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b6000602082840312156118c357600080fd5b813567ffffffffffffffff8111156118da57600080fd5b8201601f810184136118eb57600080fd5b803567ffffffffffffffff8111156119055761190561189b565b8060051b604051601f19603f830116810181811067ffffffffffffffff821117156119325761193261189b565b60405291825260208184018101929081018784111561195057600080fd5b6020850194505b8385101561197357843580825260209586019590935001611957565b509695505050505050565b60006020828403121561199057600080fd5b815161183281611800565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115610bd757610bd76119b1565b8082028115828204841417610bd757610bd76119b1565b634e487b7160e01b600052601260045260246000fd5b600082611a2457634e487b7160e01b600052601260045260246000fd5b500490565b81810381811115610bd757610bd76119b1565b602081526000825180602084015260005b81811015611a6a5760208186018101516040868401015201611a4d565b506000604082850101526040601f19601f83011684010191505092915050565b600060208284031215611a9c57600080fd5b8151801515811461183257600080fdfea264697066735822122066105594c2bc8d516c71947dfa889dac4f97a514abea123ca0dd0c5c6949319e64736f6c634300081a0033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 31 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.