Source Code
Overview
S Balance
0 S
More Info
ContractCreator
Loading...
Loading
Contract Name:
FrogsSale
Compiler Version
v0.8.20+commit.a1b79de6
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.20; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract FrogsSale is Ownable { IERC20 public saleToken; // Token to be distributed struct ReferralData { uint256 totalContribution; uint256 totalReferrals; } uint256 public constant MAX_POOL = 500000 ether; // 500,000 CRO uint256 public constant INDIVIDUAL_CAP = 5000 ether; // 5,000 CRO uint256 public constant SALE_TOKEN_SUPPLY = 1000000000 * 10**18; // 1,000,000,000 FROGS with 18 decimals mapping(address => uint256) public contributions; // Tracks contributions per user mapping(address => address) public referrals; // Tracks user referrals mapping(address => uint256) public totalReferralEarned; // Tracks total referral rewards earned per user mapping(address => ReferralData) public referralData; // Tracks total contributions made by referrals uint256 public totalContributed; // Total CRO contributed bool public isSaleActive = true; uint256 public startTime; // Sale start time uint256 public endTime; // Sale end time uint256 public referralPercentage = 2; // Default 2% referral reward event Contribution(address indexed user, uint256 amount, address indexed referral); event TokensClaimed(address indexed user, uint256 tokenAmount, uint256 croRefunded, uint256 referralReward); event SaleClosed(); event SaleTimesUpdated(uint256 startTime, uint256 endTime); event ReferralPercentageUpdated(uint256 newPercentage); constructor(IERC20 _saleToken) { saleToken = _saleToken; } /** * @dev Allows users to claim tokens, refunds excess CRO, and allocates referral rewards. */ function claimTokens() external { require(!isSaleActive, "Sale is still active"); require(block.timestamp > endTime, "Sale has not ended yet"); require(contributions[msg.sender] > 0, "No contributions to claim tokens"); uint256 userContribution = contributions[msg.sender]; uint256 totalTokens = SALE_TOKEN_SUPPLY; uint256 tokenAmount = (userContribution * totalTokens) / totalContributed; uint256 excessCRO = userContribution > (userContribution * MAX_POOL / totalContributed) ? userContribution - (userContribution * MAX_POOL / totalContributed) : 0; // Calculate referral reward for the user uint256 referralReward = (referralData[msg.sender].totalContribution * totalTokens / totalContributed) * referralPercentage / 100; totalReferralEarned[msg.sender] += referralReward; // Reset user contribution contributions[msg.sender] = 0; // Transfer tokens (main + referral rewards) to the user saleToken.transfer(msg.sender, tokenAmount + referralReward); // Refund excess CRO if (excessCRO > 0) { payable(msg.sender).transfer(excessCRO); } emit TokensClaimed(msg.sender, tokenAmount, excessCRO, referralReward); } /** * @dev Allows users to estimate their token allocation, excess CRO, and referral rewards. */ function estimateClaim(address user) external view returns (uint256 tokenAmount, uint256 excessCRO, uint256 referralReward) { if (totalContributed == 0 || contributions[user] == 0) { return (0, 0, 0); } uint256 userContribution = contributions[user]; uint256 totalTokens = SALE_TOKEN_SUPPLY; tokenAmount = (userContribution * totalTokens) / totalContributed; excessCRO = userContribution > (userContribution * MAX_POOL / totalContributed) ? userContribution - (userContribution * MAX_POOL / totalContributed) : 0; referralReward = (referralData[user].totalContribution * totalTokens / totalContributed) * referralPercentage / 100; } /** * @dev Withdraw collected CRO up to the MAX_POOL limit. */ function withdrawCRO() external onlyOwner { uint256 amount = address(this).balance > MAX_POOL ? MAX_POOL : address(this).balance; payable(owner()).transfer(amount); } /** * @dev Withdraw unsold tokens proportional to the uncollected CRO. */ function withdrawUnsoldTokens() external onlyOwner { uint256 soldTokens = (totalContributed * SALE_TOKEN_SUPPLY) / MAX_POOL; uint256 unsoldTokens = SALE_TOKEN_SUPPLY - soldTokens; require(unsoldTokens > 0, "No unsold tokens available"); saleToken.transfer(owner(), unsoldTokens); } /** * @dev Allows users to contribute CRO to the sale with an optional referral. */ function contribute(address referral) external payable { require(isSaleActive, "Sale is not active"); require(block.timestamp >= startTime, "Sale has not started yet"); require(block.timestamp <= endTime, "Sale has ended"); require(msg.value > 0, "Contribution must be > 0"); require(contributions[msg.sender] + msg.value <= INDIVIDUAL_CAP, "Exceeds individual cap"); uint256 contribution = msg.value; contributions[msg.sender] += contribution; totalContributed += contribution; // Record referral if (referral != address(0) && referral != msg.sender && referrals[msg.sender] == address(0)) { referrals[msg.sender] = referral; referralData[referral].totalReferrals += 1; referralData[referral].totalContribution += contribution; } else if (referrals[msg.sender] != address(0)) { referralData[referrals[msg.sender]].totalContribution += contribution; } emit Contribution(msg.sender, contribution, referral); } /** * @dev Allows the owner to close the sale. */ function closeSale() external onlyOwner { require(isSaleActive, "Sale already closed"); isSaleActive = false; emit SaleClosed(); } /** * @dev Sets the start and end time for the sale. */ function setSaleTimes(uint256 _startTime, uint256 _endTime) external onlyOwner { require(_startTime < _endTime, "Start time must be before end time"); startTime = _startTime; endTime = _endTime; emit SaleTimesUpdated(startTime, endTime); } /** * @dev Allows the owner to set the referral reward percentage. */ function setReferralPercentage(uint256 _percentage) external onlyOwner { require(_percentage <= 10, "Referral percentage too high"); referralPercentage = _percentage; emit ReferralPercentageUpdated(_percentage); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (access/Ownable.sol) 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() { _transferOwnership(_msgSender()); } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ 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 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 `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, 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 `from` to `to` 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 from, address to, uint256 amount) external returns (bool); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) 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; } }
{ "evmVersion": "shanghai", "libraries": {}, "metadata": { "bytecodeHash": "ipfs", "useLiteralContent": true }, "optimizer": { "enabled": true, "runs": 200 }, "remappings": [], "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } } }
[{"inputs":[{"internalType":"contract IERC20","name":"_saleToken","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"referral","type":"address"}],"name":"Contribution","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":false,"internalType":"uint256","name":"newPercentage","type":"uint256"}],"name":"ReferralPercentageUpdated","type":"event"},{"anonymous":false,"inputs":[],"name":"SaleClosed","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"startTime","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"endTime","type":"uint256"}],"name":"SaleTimesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"user","type":"address"},{"indexed":false,"internalType":"uint256","name":"tokenAmount","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"croRefunded","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"referralReward","type":"uint256"}],"name":"TokensClaimed","type":"event"},{"inputs":[],"name":"INDIVIDUAL_CAP","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MAX_POOL","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"SALE_TOKEN_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claimTokens","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"closeSale","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"referral","type":"address"}],"name":"contribute","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"contributions","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"endTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"estimateClaim","outputs":[{"internalType":"uint256","name":"tokenAmount","type":"uint256"},{"internalType":"uint256","name":"excessCRO","type":"uint256"},{"internalType":"uint256","name":"referralReward","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isSaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"referralData","outputs":[{"internalType":"uint256","name":"totalContribution","type":"uint256"},{"internalType":"uint256","name":"totalReferrals","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"referralPercentage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"referrals","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"saleToken","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_percentage","type":"uint256"}],"name":"setReferralPercentage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_startTime","type":"uint256"},{"internalType":"uint256","name":"_endTime","type":"uint256"}],"name":"setSaleTimes","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startTime","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalContributed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"totalReferralEarned","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":[],"name":"withdrawCRO","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawUnsoldTokens","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040526007805460ff191660011790556002600a55348015610021575f80fd5b5060405161129e38038061129e833981016040819052610040916100bd565b6100493361006e565b600180546001600160a01b0319166001600160a01b03929092169190911790556100ea565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f602082840312156100cd575f80fd5b81516001600160a01b03811681146100e3575f80fd5b9392505050565b6111a7806100f75f395ff3fe608060405260043610610147575f3560e01c80638da5cb5b116100b3578063c8bdbfb61161006d578063c8bdbfb614610398578063c9c6b556146103ac578063cbaaf1dc146103f3578063e985e36714610412578063ee55efee14610431578063f2fde38b14610445575f80fd5b80638da5cb5b146102c457806396ea8b9c146102f45780639ca423b314610309578063a0311bd41461033d578063a7f3e70f1461035c578063a8d294051461037b575f80fd5b80634e5e0134116101045780634e5e013414610211578063564566a81461024b578063715018a61461027457806373e888fd1461028857806378e979251461029b57806379ac20b1146102b0575f80fd5b8063023f41471461014b5780630f3cf72c146101735780632c3c91c91461019e5780633197cbb6146101bb57806342e94c90146101d057806348c54b9d146101fb575b5f80fd5b348015610156575f80fd5b5061016060065481565b6040519081526020015b60405180910390f35b34801561017e575f80fd5b5061016061018d366004611078565b60046020525f908152604090205481565b3480156101a9575f80fd5b506101606969e10de76676d080000081565b3480156101c6575f80fd5b5061016060095481565b3480156101db575f80fd5b506101606101ea366004611078565b60026020525f908152604090205481565b348015610206575f80fd5b5061020f610464565b005b34801561021c575f80fd5b5061023061022b366004611078565b61076f565b6040805193845260208401929092529082015260600161016a565b348015610256575f80fd5b506007546102649060ff1681565b604051901515815260200161016a565b34801561027f575f80fd5b5061020f61089a565b61020f610296366004611078565b6108ad565b3480156102a6575f80fd5b5061016060085481565b3480156102bb575f80fd5b5061020f610be7565b3480156102cf575f80fd5b505f546001600160a01b03165b6040516001600160a01b03909116815260200161016a565b3480156102ff575f80fd5b50610160600a5481565b348015610314575f80fd5b506102dc610323366004611078565b60036020525f90815260409020546001600160a01b031681565b348015610348575f80fd5b5061020f6103573660046110a5565b610c5f565b348015610367575f80fd5b5061020f6103763660046110bc565b610cf3565b348015610386575f80fd5b5061016069010f0cf064dd5920000081565b3480156103a3575f80fd5b5061020f610d9c565b3480156103b7575f80fd5b506103de6103c6366004611078565b60056020525f90815260409020805460019091015482565b6040805192835260208301919091520161016a565b3480156103fe575f80fd5b506101606b033b2e3c9fd0803ce800000081565b34801561041d575f80fd5b506001546102dc906001600160a01b031681565b34801561043c575f80fd5b5061020f610ed3565b348015610450575f80fd5b5061020f61045f366004611078565b610f57565b60075460ff16156104b35760405162461bcd60e51b815260206004820152601460248201527353616c65206973207374696c6c2061637469766560601b60448201526064015b60405180910390fd5b60095442116104fd5760405162461bcd60e51b815260206004820152601660248201527514d85b19481a185cc81b9bdd08195b991959081e595d60521b60448201526064016104aa565b335f908152600260205260409020546105585760405162461bcd60e51b815260206004820181905260248201527f4e6f20636f6e747269627574696f6e7320746f20636c61696d20746f6b656e7360448201526064016104aa565b335f9081526002602052604081205460065490916b033b2e3c9fd0803ce80000009161058483856110f0565b61058e919061110d565b90505f6006546969e10de76676d0800000856105aa91906110f0565b6105b4919061110d565b84116105c0575f6105eb565b6006546105d76969e10de76676d0800000866110f0565b6105e1919061110d565b6105eb908561112c565b600a54600654335f908152600560205260408120549394509260649291906106149088906110f0565b61061e919061110d565b61062891906110f0565b610632919061110d565b335f9081526004602052604081208054929350839290919061065590849061113f565b9091555050335f818152600260205260408120556001546001600160a01b03169063a9059cbb90610686848761113f565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303815f875af11580156106ce573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106f29190611152565b50811561072557604051339083156108fc029084905f818181858888f19350505050158015610723573d5f803e3d5ffd5b505b604080518481526020810184905290810182905233907fe49649ad7d04a14b0d2a43dae89f207c0822143ff6f88a6480e88907e4e5c5489060600160405180910390a25050505050565b5f805f6006545f148061079757506001600160a01b0384165f90815260026020526040902054155b156107a957505f915081905080610893565b6001600160a01b0384165f908152600260205260409020546006546b033b2e3c9fd0803ce8000000906107dc82846110f0565b6107e6919061110d565b6006549095506108006969e10de76676d0800000846110f0565b61080a919061110d565b8211610816575f610841565b60065461082d6969e10de76676d0800000846110f0565b610837919061110d565b610841908361112c565b600a546006546001600160a01b0389165f908152600560205260409020549296506064926108709085906110f0565b61087a919061110d565b61088491906110f0565b61088e919061110d565b925050505b9193909250565b6108a2610fd0565b6108ab5f611029565b565b60075460ff166108f45760405162461bcd60e51b815260206004820152601260248201527153616c65206973206e6f742061637469766560701b60448201526064016104aa565b6008544210156109465760405162461bcd60e51b815260206004820152601860248201527f53616c6520686173206e6f74207374617274656420796574000000000000000060448201526064016104aa565b6009544211156109895760405162461bcd60e51b815260206004820152600e60248201526d14d85b19481a185cc8195b99195960921b60448201526064016104aa565b5f34116109d85760405162461bcd60e51b815260206004820152601860248201527f436f6e747269627574696f6e206d757374206265203e2030000000000000000060448201526064016104aa565b335f9081526002602052604090205469010f0cf064dd59200000906109fe90349061113f565b1115610a455760405162461bcd60e51b815260206004820152601660248201527504578636565647320696e646976696475616c206361760541b60448201526064016104aa565b335f90815260026020526040812080543492839291610a6590849061113f565b925050819055508060065f828254610a7d919061113f565b90915550506001600160a01b03821615801590610aa357506001600160a01b0382163314155b8015610ac45750335f908152600360205260409020546001600160a01b0316155b15610b4c57335f90815260036020908152604080832080546001600160a01b0319166001600160a01b0387169081179091558352600590915281206001908101805491929091610b1590849061113f565b90915550506001600160a01b0382165f9081526005602052604081208054839290610b4190849061113f565b90915550610ba39050565b335f908152600360205260409020546001600160a01b031615610ba357335f908152600360209081526040808320546001600160a01b03168352600590915281208054839290610b9d90849061113f565b90915550505b6040518181526001600160a01b0383169033907fd782c85a6e36ccad8c0a0438cbd8ac1deb2d934d5d7f0931dce0c787ef1096e79060200160405180910390a35050565b610bef610fd0565b5f6969e10de76676d08000004711610c075747610c13565b6969e10de76676d08000005b9050610c265f546001600160a01b031690565b6001600160a01b03166108fc8290811502906040515f60405180830381858888f19350505050158015610c5b573d5f803e3d5ffd5b5050565b610c67610fd0565b600a811115610cb85760405162461bcd60e51b815260206004820152601c60248201527f526566657272616c2070657263656e7461676520746f6f20686967680000000060448201526064016104aa565b600a8190556040518181527f19442b8628d48f50974606261c2be961f20e88dd787145ea2e83b5e2ca82cd889060200160405180910390a150565b610cfb610fd0565b808210610d555760405162461bcd60e51b815260206004820152602260248201527f53746172742074696d65206d757374206265206265666f726520656e642074696044820152616d6560f01b60648201526084016104aa565b6008829055600981905560408051838152602081018390527f289f199a6826eaa50db99d09a0c24ca53a167821078e605c8d0aa7d43c0166fd910160405180910390a15050565b610da4610fd0565b5f6969e10de76676d08000006b033b2e3c9fd0803ce8000000600654610dca91906110f0565b610dd4919061110d565b90505f610ded826b033b2e3c9fd0803ce800000061112c565b90505f8111610e3e5760405162461bcd60e51b815260206004820152601a60248201527f4e6f20756e736f6c6420746f6b656e7320617661696c61626c6500000000000060448201526064016104aa565b6001546001600160a01b031663a9059cbb610e605f546001600160a01b031690565b6040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303815f875af1158015610eaa573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610ece9190611152565b505050565b610edb610fd0565b60075460ff16610f235760405162461bcd60e51b815260206004820152601360248201527214d85b1948185b1c9958591e4818db1bdcd959606a1b60448201526064016104aa565b6007805460ff191690556040517f4c013bd73202fde3c7cfe26ca486d0882f2c5b2fc9c761b15212f759bd2347dd905f90a1565b610f5f610fd0565b6001600160a01b038116610fc45760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104aa565b610fcd81611029565b50565b5f546001600160a01b031633146108ab5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104aa565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f60208284031215611088575f80fd5b81356001600160a01b038116811461109e575f80fd5b9392505050565b5f602082840312156110b5575f80fd5b5035919050565b5f80604083850312156110cd575f80fd5b50508035926020909101359150565b634e487b7160e01b5f52601160045260245ffd5b8082028115828204841417611107576111076110dc565b92915050565b5f8261112757634e487b7160e01b5f52601260045260245ffd5b500490565b81810381811115611107576111076110dc565b80820180821115611107576111076110dc565b5f60208284031215611162575f80fd5b8151801515811461109e575f80fdfea2646970667358221220f07bc5ddc48c80961025d36d9ae0589a3b6490d8c1dd23fd03e605f1d85ea67f64736f6c63430008140033000000000000000000000000fc08df83c9702e731d3b976c520ac7b14fee3b60
Deployed Bytecode
0x608060405260043610610147575f3560e01c80638da5cb5b116100b3578063c8bdbfb61161006d578063c8bdbfb614610398578063c9c6b556146103ac578063cbaaf1dc146103f3578063e985e36714610412578063ee55efee14610431578063f2fde38b14610445575f80fd5b80638da5cb5b146102c457806396ea8b9c146102f45780639ca423b314610309578063a0311bd41461033d578063a7f3e70f1461035c578063a8d294051461037b575f80fd5b80634e5e0134116101045780634e5e013414610211578063564566a81461024b578063715018a61461027457806373e888fd1461028857806378e979251461029b57806379ac20b1146102b0575f80fd5b8063023f41471461014b5780630f3cf72c146101735780632c3c91c91461019e5780633197cbb6146101bb57806342e94c90146101d057806348c54b9d146101fb575b5f80fd5b348015610156575f80fd5b5061016060065481565b6040519081526020015b60405180910390f35b34801561017e575f80fd5b5061016061018d366004611078565b60046020525f908152604090205481565b3480156101a9575f80fd5b506101606969e10de76676d080000081565b3480156101c6575f80fd5b5061016060095481565b3480156101db575f80fd5b506101606101ea366004611078565b60026020525f908152604090205481565b348015610206575f80fd5b5061020f610464565b005b34801561021c575f80fd5b5061023061022b366004611078565b61076f565b6040805193845260208401929092529082015260600161016a565b348015610256575f80fd5b506007546102649060ff1681565b604051901515815260200161016a565b34801561027f575f80fd5b5061020f61089a565b61020f610296366004611078565b6108ad565b3480156102a6575f80fd5b5061016060085481565b3480156102bb575f80fd5b5061020f610be7565b3480156102cf575f80fd5b505f546001600160a01b03165b6040516001600160a01b03909116815260200161016a565b3480156102ff575f80fd5b50610160600a5481565b348015610314575f80fd5b506102dc610323366004611078565b60036020525f90815260409020546001600160a01b031681565b348015610348575f80fd5b5061020f6103573660046110a5565b610c5f565b348015610367575f80fd5b5061020f6103763660046110bc565b610cf3565b348015610386575f80fd5b5061016069010f0cf064dd5920000081565b3480156103a3575f80fd5b5061020f610d9c565b3480156103b7575f80fd5b506103de6103c6366004611078565b60056020525f90815260409020805460019091015482565b6040805192835260208301919091520161016a565b3480156103fe575f80fd5b506101606b033b2e3c9fd0803ce800000081565b34801561041d575f80fd5b506001546102dc906001600160a01b031681565b34801561043c575f80fd5b5061020f610ed3565b348015610450575f80fd5b5061020f61045f366004611078565b610f57565b60075460ff16156104b35760405162461bcd60e51b815260206004820152601460248201527353616c65206973207374696c6c2061637469766560601b60448201526064015b60405180910390fd5b60095442116104fd5760405162461bcd60e51b815260206004820152601660248201527514d85b19481a185cc81b9bdd08195b991959081e595d60521b60448201526064016104aa565b335f908152600260205260409020546105585760405162461bcd60e51b815260206004820181905260248201527f4e6f20636f6e747269627574696f6e7320746f20636c61696d20746f6b656e7360448201526064016104aa565b335f9081526002602052604081205460065490916b033b2e3c9fd0803ce80000009161058483856110f0565b61058e919061110d565b90505f6006546969e10de76676d0800000856105aa91906110f0565b6105b4919061110d565b84116105c0575f6105eb565b6006546105d76969e10de76676d0800000866110f0565b6105e1919061110d565b6105eb908561112c565b600a54600654335f908152600560205260408120549394509260649291906106149088906110f0565b61061e919061110d565b61062891906110f0565b610632919061110d565b335f9081526004602052604081208054929350839290919061065590849061113f565b9091555050335f818152600260205260408120556001546001600160a01b03169063a9059cbb90610686848761113f565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303815f875af11580156106ce573d5f803e3d5ffd5b505050506040513d601f19601f820116820180604052508101906106f29190611152565b50811561072557604051339083156108fc029084905f818181858888f19350505050158015610723573d5f803e3d5ffd5b505b604080518481526020810184905290810182905233907fe49649ad7d04a14b0d2a43dae89f207c0822143ff6f88a6480e88907e4e5c5489060600160405180910390a25050505050565b5f805f6006545f148061079757506001600160a01b0384165f90815260026020526040902054155b156107a957505f915081905080610893565b6001600160a01b0384165f908152600260205260409020546006546b033b2e3c9fd0803ce8000000906107dc82846110f0565b6107e6919061110d565b6006549095506108006969e10de76676d0800000846110f0565b61080a919061110d565b8211610816575f610841565b60065461082d6969e10de76676d0800000846110f0565b610837919061110d565b610841908361112c565b600a546006546001600160a01b0389165f908152600560205260409020549296506064926108709085906110f0565b61087a919061110d565b61088491906110f0565b61088e919061110d565b925050505b9193909250565b6108a2610fd0565b6108ab5f611029565b565b60075460ff166108f45760405162461bcd60e51b815260206004820152601260248201527153616c65206973206e6f742061637469766560701b60448201526064016104aa565b6008544210156109465760405162461bcd60e51b815260206004820152601860248201527f53616c6520686173206e6f74207374617274656420796574000000000000000060448201526064016104aa565b6009544211156109895760405162461bcd60e51b815260206004820152600e60248201526d14d85b19481a185cc8195b99195960921b60448201526064016104aa565b5f34116109d85760405162461bcd60e51b815260206004820152601860248201527f436f6e747269627574696f6e206d757374206265203e2030000000000000000060448201526064016104aa565b335f9081526002602052604090205469010f0cf064dd59200000906109fe90349061113f565b1115610a455760405162461bcd60e51b815260206004820152601660248201527504578636565647320696e646976696475616c206361760541b60448201526064016104aa565b335f90815260026020526040812080543492839291610a6590849061113f565b925050819055508060065f828254610a7d919061113f565b90915550506001600160a01b03821615801590610aa357506001600160a01b0382163314155b8015610ac45750335f908152600360205260409020546001600160a01b0316155b15610b4c57335f90815260036020908152604080832080546001600160a01b0319166001600160a01b0387169081179091558352600590915281206001908101805491929091610b1590849061113f565b90915550506001600160a01b0382165f9081526005602052604081208054839290610b4190849061113f565b90915550610ba39050565b335f908152600360205260409020546001600160a01b031615610ba357335f908152600360209081526040808320546001600160a01b03168352600590915281208054839290610b9d90849061113f565b90915550505b6040518181526001600160a01b0383169033907fd782c85a6e36ccad8c0a0438cbd8ac1deb2d934d5d7f0931dce0c787ef1096e79060200160405180910390a35050565b610bef610fd0565b5f6969e10de76676d08000004711610c075747610c13565b6969e10de76676d08000005b9050610c265f546001600160a01b031690565b6001600160a01b03166108fc8290811502906040515f60405180830381858888f19350505050158015610c5b573d5f803e3d5ffd5b5050565b610c67610fd0565b600a811115610cb85760405162461bcd60e51b815260206004820152601c60248201527f526566657272616c2070657263656e7461676520746f6f20686967680000000060448201526064016104aa565b600a8190556040518181527f19442b8628d48f50974606261c2be961f20e88dd787145ea2e83b5e2ca82cd889060200160405180910390a150565b610cfb610fd0565b808210610d555760405162461bcd60e51b815260206004820152602260248201527f53746172742074696d65206d757374206265206265666f726520656e642074696044820152616d6560f01b60648201526084016104aa565b6008829055600981905560408051838152602081018390527f289f199a6826eaa50db99d09a0c24ca53a167821078e605c8d0aa7d43c0166fd910160405180910390a15050565b610da4610fd0565b5f6969e10de76676d08000006b033b2e3c9fd0803ce8000000600654610dca91906110f0565b610dd4919061110d565b90505f610ded826b033b2e3c9fd0803ce800000061112c565b90505f8111610e3e5760405162461bcd60e51b815260206004820152601a60248201527f4e6f20756e736f6c6420746f6b656e7320617661696c61626c6500000000000060448201526064016104aa565b6001546001600160a01b031663a9059cbb610e605f546001600160a01b031690565b6040516001600160e01b031960e084901b1681526001600160a01b039091166004820152602481018490526044016020604051808303815f875af1158015610eaa573d5f803e3d5ffd5b505050506040513d601f19601f82011682018060405250810190610ece9190611152565b505050565b610edb610fd0565b60075460ff16610f235760405162461bcd60e51b815260206004820152601360248201527214d85b1948185b1c9958591e4818db1bdcd959606a1b60448201526064016104aa565b6007805460ff191690556040517f4c013bd73202fde3c7cfe26ca486d0882f2c5b2fc9c761b15212f759bd2347dd905f90a1565b610f5f610fd0565b6001600160a01b038116610fc45760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b60648201526084016104aa565b610fcd81611029565b50565b5f546001600160a01b031633146108ab5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016104aa565b5f80546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b5f60208284031215611088575f80fd5b81356001600160a01b038116811461109e575f80fd5b9392505050565b5f602082840312156110b5575f80fd5b5035919050565b5f80604083850312156110cd575f80fd5b50508035926020909101359150565b634e487b7160e01b5f52601160045260245ffd5b8082028115828204841417611107576111076110dc565b92915050565b5f8261112757634e487b7160e01b5f52601260045260245ffd5b500490565b81810381811115611107576111076110dc565b80820180821115611107576111076110dc565b5f60208284031215611162575f80fd5b8151801515811461109e575f80fdfea2646970667358221220f07bc5ddc48c80961025d36d9ae0589a3b6490d8c1dd23fd03e605f1d85ea67f64736f6c63430008140033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000fc08df83c9702e731d3b976c520ac7b14fee3b60
-----Decoded View---------------
Arg [0] : _saleToken (address): 0xfc08Df83C9702E731d3b976C520Ac7b14feE3b60
-----Encoded View---------------
1 Constructor Arguments found :
Arg [0] : 000000000000000000000000fc08df83c9702e731d3b976c520ac7b14fee3b60
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.