Feature Tip: Add private address tag to any address under My Name Tag !
Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 127 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
Value | ||||
---|---|---|---|---|---|---|---|---|---|
Withdraw Ether B... | 19370697 | 124 days ago | IN | 0 ETH | 0.00275891 | ||||
Set Presale Stag... | 19370656 | 124 days ago | IN | 0 ETH | 0.00261808 | ||||
Transfer | 19370650 | 124 days ago | IN | 0.25 ETH | 0.0117255 | ||||
Transfer | 19370646 | 124 days ago | IN | 0.17 ETH | 0.00549488 | ||||
Transfer | 19370643 | 124 days ago | IN | 0.25 ETH | 0.00351765 | ||||
Transfer | 19370642 | 124 days ago | IN | 0.4 ETH | 0.00275296 | ||||
Transfer | 19370641 | 124 days ago | IN | 0.4 ETH | 0.00279599 | ||||
Transfer | 19370641 | 124 days ago | IN | 0.4 ETH | 0.00572325 | ||||
Transfer | 19370637 | 124 days ago | IN | 0.4 ETH | 0.00512042 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.1 ETH | 0.00475683 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.4 ETH | 0.00255205 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.4 ETH | 0.00475857 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.4 ETH | 0.00475864 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.4 ETH | 0.00475864 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.18 ETH | 0.00475871 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.15 ETH | 0.00475871 | ||||
Transfer | 19370636 | 124 days ago | IN | 0.4 ETH | 0.00552023 | ||||
Transfer | 19370635 | 124 days ago | IN | 0.4 ETH | 0.00433641 | ||||
Transfer | 19370635 | 124 days ago | IN | 0.4 ETH | 0.00449358 | ||||
Set Whitelist | 19370633 | 124 days ago | IN | 0 ETH | 0.00444424 | ||||
Transfer | 19370632 | 124 days ago | IN | 0.4 ETH | 0.00456654 | ||||
Transfer | 19370632 | 124 days ago | IN | 0.1 ETH | 0.00456654 | ||||
Transfer | 19370632 | 124 days ago | IN | 0.4 ETH | 0.00456654 | ||||
Transfer | 19370632 | 124 days ago | IN | 0.3 ETH | 0.00456654 | ||||
Transfer | 19370632 | 124 days ago | IN | 0.4 ETH | 0.00456654 |
Latest 1 internal transaction
Advanced mode:
Parent Transaction Hash | Block | From | To | Value | ||
---|---|---|---|---|---|---|
19370697 | 124 days ago | 30 ETH |
Loading...
Loading
Contract Name:
LooterPresale
Compiler Version
v0.8.20+commit.a1b79de6
Optimization Enabled:
Yes with 200 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.9; import "@openzeppelin/contracts/token/ERC20/IERC20.sol"; contract LooterPresale { address immutable owner; IERC20 public token; uint256 public presaleStage = 0; // 0: not started, 1: round one, 2: round two, 3: ended, 4: claim active uint256 public constant slotTokenAmount = 0.2 * 100_000_000 * 1e18; uint256 public constant slotETHAmount = 0.4 ether; uint256 public constant cap = 30 ether; mapping(address => uint256) public whitelist; mapping(address => uint256) public contributions; constructor() { owner = msg.sender; } function setToken(address token_) external { require(msg.sender == owner, "not owner"); token = IERC20(token_); } function setWhitelist( address[] memory participants, uint256 round ) external { require(msg.sender == owner, "not owner"); for (uint256 i = 0; i < participants.length; i++) { whitelist[participants[i]] = round; } } function setPresaleStage(uint256 newStage) external { require(msg.sender == owner, "not owner"); presaleStage = newStage; } function withdrawTokensByOwner() external { require(msg.sender == owner, "not owner"); token.transfer(owner, token.balanceOf(address(this))); } function withdrawEtherByOwner() external { require(msg.sender == owner, "not owner"); payable(owner).transfer(address(this).balance); } function claim() external { require(presaleStage == 4, "claim not active"); uint256 tokenAmount = (contributions[msg.sender] * slotTokenAmount) / slotETHAmount; IERC20(token).transfer(msg.sender, tokenAmount); } receive() external payable { require(presaleStage > 0, "presale not active"); require(presaleStage < 3, "presale ended"); require(address(this).balance <= cap, "presale cap reached"); require( whitelist[msg.sender] == presaleStage, "not whitelisted for this round" ); uint256 contribution = contributions[msg.sender] + msg.value; contributions[msg.sender] = contribution; require(contribution >= 0.1 ether, "0.1 ETH minimum"); require(contribution <= slotETHAmount, "slot allowance exceeded"); } }
// 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); }
{ "optimizer": { "enabled": true, "runs": 200 }, "evmVersion": "paris", "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"cap","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"claim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"contributions","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"presaleStage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"newStage","type":"uint256"}],"name":"setPresaleStage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"token_","type":"address"}],"name":"setToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"participants","type":"address[]"},{"internalType":"uint256","name":"round","type":"uint256"}],"name":"setWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"slotETHAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"slotTokenAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token","outputs":[{"internalType":"contract IERC20","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelist","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdrawEtherByOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawTokensByOwner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
60a0604052600060015534801561001557600080fd5b5033608052608051610b4161005f6000396000818161049d015281816105070152818161056e015281816107500152818161079d0152818161084c01526108960152610b416000f3fe6080604052600436106100c65760003560e01c806355f025851161007f5780638d814a8c116100595780638d814a8c146103f8578063936528a6146104185780639b19251a1461042d578063fc0c546a1461045a57600080fd5b806355f02585146103a357806368b09ded146103c25780637cde403d146103d857600080fd5b8063144fa6d7146102e0578063355274ea1461030057806342e94c90146103305780634b399a001461035d5780634e71d92d14610372578063514a3cb11461038757600080fd5b366102db576000600154116101175760405162461bcd60e51b815260206004820152601260248201527170726573616c65206e6f742061637469766560701b60448201526064015b60405180910390fd5b6003600154106101595760405162461bcd60e51b815260206004820152600d60248201526c1c1c995cd85b1948195b991959609a1b604482015260640161010e565b6801a055690d9db800004711156101a85760405162461bcd60e51b81526020600482015260136024820152721c1c995cd85b194818d85c081c995858da1959606a1b604482015260640161010e565b60015433600090815260026020526040902054146102085760405162461bcd60e51b815260206004820152601e60248201527f6e6f742077686974656c697374656420666f72207468697320726f756e640000604482015260640161010e565b336000908152600360205260408120546102239034906108f4565b336000908152600360205260409020819055905067016345785d8a00008110156102815760405162461bcd60e51b815260206004820152600f60248201526e302e3120455448206d696e696d756d60881b604482015260640161010e565b67058d15e1762800008111156102d95760405162461bcd60e51b815260206004820152601760248201527f736c6f7420616c6c6f77616e6365206578636565646564000000000000000000604482015260640161010e565b005b600080fd5b3480156102ec57600080fd5b506102d96102fb366004610929565b610492565b34801561030c57600080fd5b5061031d6801a055690d9db8000081565b6040519081526020015b60405180910390f35b34801561033c57600080fd5b5061031d61034b366004610929565b60036020526000908152604090205481565b34801561036957600080fd5b506102d96104fc565b34801561037e57600080fd5b506102d961064c565b34801561039357600080fd5b5061031d67058d15e17628000081565b3480156103af57600080fd5b5061031d6a108b2a2c2802909400000081565b3480156103ce57600080fd5b5061031d60015481565b3480156103e457600080fd5b506102d96103f336600461094b565b610745565b34801561040457600080fd5b506102d961041336600461097a565b610792565b34801561042457600080fd5b506102d9610841565b34801561043957600080fd5b5061031d610448366004610929565b60026020526000908152604090205481565b34801561046657600080fd5b5060005461047a906001600160a01b031681565b6040516001600160a01b039091168152602001610327565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146104da5760405162461bcd60e51b815260040161010e90610a45565b600080546001600160a01b0319166001600160a01b0392909216919091179055565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146105445760405162461bcd60e51b815260040161010e90610a45565b6000546040516370a0823160e01b81523060048201526001600160a01b039091169063a9059cbb907f00000000000000000000000000000000000000000000000000000000000000009083906370a0823190602401602060405180830381865afa1580156105b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105da9190610a68565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af1158015610625573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106499190610a81565b50565b6001546004146106915760405162461bcd60e51b815260206004820152601060248201526f636c61696d206e6f742061637469766560801b604482015260640161010e565b3360009081526003602052604081205467058d15e176280000906106c1906a108b2a2c2802909400000090610aa3565b6106cb9190610aba565b60005460405163a9059cbb60e01b8152336004820152602481018390529192506001600160a01b03169063a9059cbb906044016020604051808303816000875af115801561071d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107419190610a81565b5050565b336001600160a01b037f0000000000000000000000000000000000000000000000000000000000000000161461078d5760405162461bcd60e51b815260040161010e90610a45565b600155565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146107da5760405162461bcd60e51b815260040161010e90610a45565b60005b825181101561083c5781600260008584815181106107fd576107fd610adc565b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002081905550808061083490610af2565b9150506107dd565b505050565b336001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016146108895760405162461bcd60e51b815260040161010e90610a45565b6040516001600160a01b037f000000000000000000000000000000000000000000000000000000000000000016904780156108fc02916000818181858888f19350505050158015610649573d6000803e3d6000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115610907576109076108de565b92915050565b80356001600160a01b038116811461092457600080fd5b919050565b60006020828403121561093b57600080fd5b6109448261090d565b9392505050565b60006020828403121561095d57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561098d57600080fd5b823567ffffffffffffffff808211156109a557600080fd5b818501915085601f8301126109b957600080fd5b81356020828211156109cd576109cd610964565b8160051b604051601f19603f830116810181811086821117156109f2576109f2610964565b604052928352818301935084810182019289841115610a1057600080fd5b948201945b83861015610a3557610a268661090d565b85529482019493820193610a15565b9997909101359750505050505050565b6020808252600990820152683737ba1037bbb732b960b91b604082015260600190565b600060208284031215610a7a57600080fd5b5051919050565b600060208284031215610a9357600080fd5b8151801515811461094457600080fd5b8082028115828204841417610907576109076108de565b600082610ad757634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b600060018201610b0457610b046108de565b506001019056fea2646970667358221220004b3590edb2e9d2f1eb3016dc0eab8bf2c6d199161ecab5c5f5676809a1d9af64736f6c63430008140033
Deployed Bytecode
0x6080604052600436106100c65760003560e01c806355f025851161007f5780638d814a8c116100595780638d814a8c146103f8578063936528a6146104185780639b19251a1461042d578063fc0c546a1461045a57600080fd5b806355f02585146103a357806368b09ded146103c25780637cde403d146103d857600080fd5b8063144fa6d7146102e0578063355274ea1461030057806342e94c90146103305780634b399a001461035d5780634e71d92d14610372578063514a3cb11461038757600080fd5b366102db576000600154116101175760405162461bcd60e51b815260206004820152601260248201527170726573616c65206e6f742061637469766560701b60448201526064015b60405180910390fd5b6003600154106101595760405162461bcd60e51b815260206004820152600d60248201526c1c1c995cd85b1948195b991959609a1b604482015260640161010e565b6801a055690d9db800004711156101a85760405162461bcd60e51b81526020600482015260136024820152721c1c995cd85b194818d85c081c995858da1959606a1b604482015260640161010e565b60015433600090815260026020526040902054146102085760405162461bcd60e51b815260206004820152601e60248201527f6e6f742077686974656c697374656420666f72207468697320726f756e640000604482015260640161010e565b336000908152600360205260408120546102239034906108f4565b336000908152600360205260409020819055905067016345785d8a00008110156102815760405162461bcd60e51b815260206004820152600f60248201526e302e3120455448206d696e696d756d60881b604482015260640161010e565b67058d15e1762800008111156102d95760405162461bcd60e51b815260206004820152601760248201527f736c6f7420616c6c6f77616e6365206578636565646564000000000000000000604482015260640161010e565b005b600080fd5b3480156102ec57600080fd5b506102d96102fb366004610929565b610492565b34801561030c57600080fd5b5061031d6801a055690d9db8000081565b6040519081526020015b60405180910390f35b34801561033c57600080fd5b5061031d61034b366004610929565b60036020526000908152604090205481565b34801561036957600080fd5b506102d96104fc565b34801561037e57600080fd5b506102d961064c565b34801561039357600080fd5b5061031d67058d15e17628000081565b3480156103af57600080fd5b5061031d6a108b2a2c2802909400000081565b3480156103ce57600080fd5b5061031d60015481565b3480156103e457600080fd5b506102d96103f336600461094b565b610745565b34801561040457600080fd5b506102d961041336600461097a565b610792565b34801561042457600080fd5b506102d9610841565b34801561043957600080fd5b5061031d610448366004610929565b60026020526000908152604090205481565b34801561046657600080fd5b5060005461047a906001600160a01b031681565b6040516001600160a01b039091168152602001610327565b336001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d55816146104da5760405162461bcd60e51b815260040161010e90610a45565b600080546001600160a01b0319166001600160a01b0392909216919091179055565b336001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d55816146105445760405162461bcd60e51b815260040161010e90610a45565b6000546040516370a0823160e01b81523060048201526001600160a01b039091169063a9059cbb907f000000000000000000000000000000000007700824831b0b57fd046faa37d5589083906370a0823190602401602060405180830381865afa1580156105b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105da9190610a68565b6040516001600160e01b031960e085901b1681526001600160a01b03909216600483015260248201526044016020604051808303816000875af1158015610625573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106499190610a81565b50565b6001546004146106915760405162461bcd60e51b815260206004820152601060248201526f636c61696d206e6f742061637469766560801b604482015260640161010e565b3360009081526003602052604081205467058d15e176280000906106c1906a108b2a2c2802909400000090610aa3565b6106cb9190610aba565b60005460405163a9059cbb60e01b8152336004820152602481018390529192506001600160a01b03169063a9059cbb906044016020604051808303816000875af115801561071d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107419190610a81565b5050565b336001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d558161461078d5760405162461bcd60e51b815260040161010e90610a45565b600155565b336001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d55816146107da5760405162461bcd60e51b815260040161010e90610a45565b60005b825181101561083c5781600260008584815181106107fd576107fd610adc565b60200260200101516001600160a01b03166001600160a01b0316815260200190815260200160002081905550808061083490610af2565b9150506107dd565b505050565b336001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d55816146108895760405162461bcd60e51b815260040161010e90610a45565b6040516001600160a01b037f000000000000000000000000000000000007700824831b0b57fd046faa37d55816904780156108fc02916000818181858888f19350505050158015610649573d6000803e3d6000fd5b634e487b7160e01b600052601160045260246000fd5b80820180821115610907576109076108de565b92915050565b80356001600160a01b038116811461092457600080fd5b919050565b60006020828403121561093b57600080fd5b6109448261090d565b9392505050565b60006020828403121561095d57600080fd5b5035919050565b634e487b7160e01b600052604160045260246000fd5b6000806040838503121561098d57600080fd5b823567ffffffffffffffff808211156109a557600080fd5b818501915085601f8301126109b957600080fd5b81356020828211156109cd576109cd610964565b8160051b604051601f19603f830116810181811086821117156109f2576109f2610964565b604052928352818301935084810182019289841115610a1057600080fd5b948201945b83861015610a3557610a268661090d565b85529482019493820193610a15565b9997909101359750505050505050565b6020808252600990820152683737ba1037bbb732b960b91b604082015260600190565b600060208284031215610a7a57600080fd5b5051919050565b600060208284031215610a9357600080fd5b8151801515811461094457600080fd5b8082028115828204841417610907576109076108de565b600082610ad757634e487b7160e01b600052601260045260246000fd5b500490565b634e487b7160e01b600052603260045260246000fd5b600060018201610b0457610b046108de565b506001019056fea2646970667358221220004b3590edb2e9d2f1eb3016dc0eab8bf2c6d199161ecab5c5f5676809a1d9af64736f6c63430008140033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 26 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ 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.