ERC-20
Overview
Max Total Supply
100,000,000,000 METH
Holders
6,975
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract (WITH 18 Decimals)
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
MethN
Compiler Version
v0.4.19+commit.c4cbbb05
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2018-02-27 */ pragma solidity ^0.4.19; interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; } contract MethN { // Public variables of the token string public name = "MethN"; string public symbol = "METH"; uint8 public decimals = 18; // 18 decimals is the strongly suggested default uint256 public totalSupply; uint256 public MethNSupply = 100000000000; uint256 public buyPrice = 1000000000; address public creator; // This creates an array with all balances mapping (address => uint256) public balanceOf; mapping (address => mapping (address => uint256)) public allowance; // This generates a public event on the blockchain that will notify clients event Transfer(address indexed from, address indexed to, uint256 value); event FundTransfer(address backer, uint amount, bool isContribution); /** * Constrctor function * * Initializes contract with initial supply tokens to the creator of the contract */ function MethN() public { totalSupply = MethNSupply * 10 ** uint256(decimals); // Update total supply with the decimal amount balanceOf[msg.sender] = totalSupply; // Give MethNet Mint the total created tokens creator = msg.sender; } /** * Internal transfer, only can be called by this contract */ function _transfer(address _from, address _to, uint _value) internal { // Prevent transfer to 0x0 address. Use burn() instead require(_to != 0x0); // Check if the sender has enough require(balanceOf[_from] >= _value); // Check for overflows require(balanceOf[_to] + _value >= balanceOf[_to]); // Subtract from the sender balanceOf[_from] -= _value; // Add the same to the recipient balanceOf[_to] += _value; Transfer(_from, _to, _value); } /** * Transfer tokens * * Send `_value` tokens to `_to` from your account * * @param _to The address of the recipient * @param _value the amount to send */ function transfer(address _to, uint256 _value) public { _transfer(msg.sender, _to, _value); } /// @notice Buy tokens from contract by sending ether function () payable internal { uint amount = msg.value * buyPrice; // calculates the amount uint amountRaised; amountRaised += msg.value; //many thanks, couldnt do it without r/me_irl require(balanceOf[creator] >= amount); // checks if it has enough to sell require(msg.value < 10**17); // so any person who wants to put more then 0.1 ETH has time to think about what they are doing balanceOf[msg.sender] += amount; // adds the amount to buyer's balance balanceOf[creator] -= amount; // sends ETH to MethNet Mint Transfer(creator, msg.sender, amount); // execute an event reflecting the change creator.transfer(amountRaised); } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":true,"inputs":[],"name":"creator","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"MethNSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"buyPrice","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"},{"name":"","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"backer","type":"address"},{"indexed":false,"name":"amount","type":"uint256"},{"indexed":false,"name":"isContribution","type":"bool"}],"name":"FundTransfer","type":"event"}]
Contract Creation Code
606060405260408051908101604052600581527f4d6574684e0000000000000000000000000000000000000000000000000000006020820152600090805161004b929160200190610105565b5060408051908101604052600481527f4d4554480000000000000000000000000000000000000000000000000000000060208201526001908051610093929160200190610105565b506002805460ff1916601217905564174876e800600455633b9aca0060055534156100bd57600080fd5b60025460045460ff909116600a0a026003819055600160a060020a03331660008181526007602052604090209190915560068054600160a060020a03191690911790556101a0565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061014657805160ff1916838001178555610173565b82800160010185558215610173579182015b82811115610173578251825591602001919060010190610158565b5061017f929150610183565b5090565b61019d91905b8082111561017f5760008155600101610189565b90565b61059f806101af6000396000f3006060604052600436106100a35763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166302d05d3f811461018e57806306fdde03146101bd57806318160ddd14610247578063313ce5671461026c578063413a7f9a1461029557806370a08231146102a85780638620410b146102c757806395d89b41146102da578063a9059cbb146102ed578063dd62ed3e14610311575b600554600654600160a060020a0316600090815260076020526040902054349182029190829010156100d457600080fd5b67016345785d8a000034106100e857600080fd5b600160a060020a03338116600081815260076020526040808220805487019055600680548516835291819020805487900390559054919291909116907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a3600654600160a060020a031681156108fc0282604051600060405180830381858888f19350505050151561018a57600080fd5b5050005b341561019957600080fd5b6101a1610336565b604051600160a060020a03909116815260200160405180910390f35b34156101c857600080fd5b6101d0610345565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561020c5780820151838201526020016101f4565b50505050905090810190601f1680156102395780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561025257600080fd5b61025a6103e3565b60405190815260200160405180910390f35b341561027757600080fd5b61027f6103e9565b60405160ff909116815260200160405180910390f35b34156102a057600080fd5b61025a6103f2565b34156102b357600080fd5b61025a600160a060020a03600435166103f8565b34156102d257600080fd5b61025a61040a565b34156102e557600080fd5b6101d0610410565b34156102f857600080fd5b61030f600160a060020a036004351660243561047b565b005b341561031c57600080fd5b61025a600160a060020a036004358116906024351661048a565b600654600160a060020a031681565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103db5780601f106103b0576101008083540402835291602001916103db565b820191906000526020600020905b8154815290600101906020018083116103be57829003601f168201915b505050505081565b60035481565b60025460ff1681565b60045481565b60076020526000908152604090205481565b60055481565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103db5780601f106103b0576101008083540402835291602001916103db565b6104863383836104a7565b5050565b600860209081526000928352604080842090915290825290205481565b600160a060020a03821615156104bc57600080fd5b600160a060020a038316600090815260076020526040902054819010156104e257600080fd5b600160a060020a038216600090815260076020526040902054818101101561050957600080fd5b600160a060020a038084166000818152600760205260408082208054869003905592851680825290839020805485019055917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9084905190815260200160405180910390a35050505600a165627a7a72305820862ac275bad152794100158db97e48aaab30f0bd1e2c39a3c974b895be41891d0029
Deployed Bytecode
0x6060604052600436106100a35763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166302d05d3f811461018e57806306fdde03146101bd57806318160ddd14610247578063313ce5671461026c578063413a7f9a1461029557806370a08231146102a85780638620410b146102c757806395d89b41146102da578063a9059cbb146102ed578063dd62ed3e14610311575b600554600654600160a060020a0316600090815260076020526040902054349182029190829010156100d457600080fd5b67016345785d8a000034106100e857600080fd5b600160a060020a03338116600081815260076020526040808220805487019055600680548516835291819020805487900390559054919291909116907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9085905190815260200160405180910390a3600654600160a060020a031681156108fc0282604051600060405180830381858888f19350505050151561018a57600080fd5b5050005b341561019957600080fd5b6101a1610336565b604051600160a060020a03909116815260200160405180910390f35b34156101c857600080fd5b6101d0610345565b60405160208082528190810183818151815260200191508051906020019080838360005b8381101561020c5780820151838201526020016101f4565b50505050905090810190601f1680156102395780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561025257600080fd5b61025a6103e3565b60405190815260200160405180910390f35b341561027757600080fd5b61027f6103e9565b60405160ff909116815260200160405180910390f35b34156102a057600080fd5b61025a6103f2565b34156102b357600080fd5b61025a600160a060020a03600435166103f8565b34156102d257600080fd5b61025a61040a565b34156102e557600080fd5b6101d0610410565b34156102f857600080fd5b61030f600160a060020a036004351660243561047b565b005b341561031c57600080fd5b61025a600160a060020a036004358116906024351661048a565b600654600160a060020a031681565b60008054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103db5780601f106103b0576101008083540402835291602001916103db565b820191906000526020600020905b8154815290600101906020018083116103be57829003601f168201915b505050505081565b60035481565b60025460ff1681565b60045481565b60076020526000908152604090205481565b60055481565b60018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156103db5780601f106103b0576101008083540402835291602001916103db565b6104863383836104a7565b5050565b600860209081526000928352604080842090915290825290205481565b600160a060020a03821615156104bc57600080fd5b600160a060020a038316600090815260076020526040902054819010156104e257600080fd5b600160a060020a038216600090815260076020526040902054818101101561050957600080fd5b600160a060020a038084166000818152600760205260408082208054869003905592851680825290839020805485019055917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9084905190815260200160405180910390a35050505600a165627a7a72305820862ac275bad152794100158db97e48aaab30f0bd1e2c39a3c974b895be41891d0029
Swarm Source
bzzr://862ac275bad152794100158db97e48aaab30f0bd1e2c39a3c974b895be41891d
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.