Address Contract Partially Verified
Address
0xBC1F9D1cA2cC9dEC0e8006948507e9ce6087Dd8c
Balance
0 ETH
Nonce
1
Code Size
10389 bytes
Creator
0xb9372960...2416 at tx 0x10f3c184...a325a3
Indexed Transactions
0
Contract Bytecode
10389 bytes
0x60806040526004361061032d5760003560e01c80638a8c523c116101a5578063adb873bd116100ec578063d85ba06311610095578063e71dc3f51161006f578063e71dc3f51461091e578063f203acb614610934578063f2fde38b1461094a578063f8b45b051461096a57600080fd5b8063d85ba063146108ac578063dd62ed3e146108c2578063e2f456051461090857600080fd5b8063c0246668116100c6578063c02466681461085c578063c876d0b91461087c578063c8c8ebe41461089657600080fd5b8063adb873bd146107f5578063b62496f51461080b578063bbc0c7421461083b57600080fd5b80639c3b4fdc1161014e578063a0d82dc511610128578063a0d82dc51461079f578063a457c2d7146107b5578063a9059cbb146107d557600080fd5b80639c3b4fdc146107535780639fccce32146107695780639fdc48241461077f57600080fd5b806395d89b411161017f57806395d89b4114610708578063975d71e21461071d5780639a7a23d61461073357600080fd5b80638a8c523c146106b55780638da5cb5b146106ca5780638ea5220f146106e857600080fd5b806327c8f8351161027457806366ca9b831161021d57806370a08231116101f757806370a0823114610634578063715018a61461066a5780637571336a1461067f5780637ab439831461069f57600080fd5b806366ca9b83146105dd5780636a486a8e146105fd5780636ddd17131461061357600080fd5b806349bd5a5e1161024e57806349bd5a5e1461054f5780634a62bb65146105835780634fbee193146105a457600080fd5b806327c8f835146104fd578063313ce56714610513578063395093511461052f57600080fd5b80631694505e116102d65780631d777856116102b05780631d777856146104a75780631fa07da5146104bd57806323b872dd146104dd57600080fd5b80631694505e1461042657806318160ddd146104725780631816467f1461048757600080fd5b8063095ea7b311610307578063095ea7b3146103a657806310d5de53146103d6578063150de0bb1461040657600080fd5b806302dbd8f814610339578063047fc9aa1461035b57806306fdde031461038457600080fd5b3661033457005b600080fd5b34801561034557600080fd5b506103596103543660046124aa565b610980565b005b34801561036757600080fd5b5061037160095481565b6040519081526020015b60405180910390f35b34801561039057600080fd5b50610399610a3a565b60405161037b91906124cc565b3480156103b257600080fd5b506103c66103c1366004612536565b610acc565b604051901515815260200161037b565b3480156103e257600080fd5b506103c66103f1366004612562565b60196020526000908152604090205460ff1681565b34801561041257600080fd5b5061035961042136600461257f565b610ae3565b34801561043257600080fd5b5061045a7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d81565b6040516001600160a01b03909116815260200161037b565b34801561047e57600080fd5b50600254610371565b34801561049357600080fd5b506103596104a2366004612562565b610b49565b3480156104b357600080fd5b5061037160135481565b3480156104c957600080fd5b506103596104d836600461257f565b610bc0565b3480156104e957600080fd5b506103c66104f8366004612598565b610c23565b34801561050957600080fd5b5061045a61dead81565b34801561051f57600080fd5b506040516006815260200161037b565b34801561053b57600080fd5b506103c661054a366004612536565b610c8c565b34801561055b57600080fd5b5061045a7f0000000000000000000000003c2bb8d2fe23c0e7b1ebcd2e9250bb8a2acb60f981565b34801561058f57600080fd5b50600a546103c690600160a01b900460ff1681565b3480156105b057600080fd5b506103c66105bf366004612562565b6001600160a01b031660009081526018602052604090205460ff1690565b3480156105e957600080fd5b506103596105f83660046124aa565b610cc2565b34801561060957600080fd5b5061037160125481565b34801561061f57600080fd5b50600a546103c690600160b01b900460ff1681565b34801561064057600080fd5b5061037161064f366004612562565b6001600160a01b031660009081526020819052604090205490565b34801561067657600080fd5b50610359610d73565b34801561068b57600080fd5b5061035961069a3660046125d9565b610e12565b3480156106ab57600080fd5b5061037160155481565b3480156106c157600080fd5b50610359610e85565b3480156106d657600080fd5b506005546001600160a01b031661045a565b3480156106f457600080fd5b50600a5461045a906001600160a01b031681565b34801561071457600080fd5b50610399610f08565b34801561072957600080fd5b5061037160165481565b34801561073f57600080fd5b5061035961074e3660046125d9565b610f17565b34801561075f57600080fd5b50610371600e5481565b34801561077557600080fd5b5061037160145481565b34801561078b57600080fd5b5061035961079a36600461257f565b611011565b3480156107ab57600080fd5b5061037160115481565b3480156107c157600080fd5b506103c66107d0366004612536565b61105e565b3480156107e157600080fd5b506103c66107f0366004612536565b6110ad565b34801561080157600080fd5b5061037160105481565b34801561081757600080fd5b506103c6610826366004612562565b601a6020526000908152604090205460ff1681565b34801561084757600080fd5b50600a546103c690600160a81b900460ff1681565b34801561086857600080fd5b506103596108773660046125d9565b6110ba565b34801561088857600080fd5b50600c546103c69060ff1681565b3480156108a257600080fd5b5061037160065481565b3480156108b857600080fd5b50610371600f5481565b3480156108ce57600080fd5b506103716108dd366004612617565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b34801561091457600080fd5b5061037160075481565b34801561092a57600080fd5b50610371600d5481565b34801561094057600080fd5b5061037160175481565b34801561095657600080fd5b50610359610965366004612562565b611161565b34801561097657600080fd5b5061037160085481565b6005546001600160a01b031633146109cd5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064015b60405180910390fd5b601082905560118190556109e1818361265b565b601281905560191015610a365760405162461bcd60e51b815260206004820152601d60248201527f4d757374206b656570206665657320617420323525206f72206c65737300000060448201526064016109c4565b5050565b606060038054610a4990612673565b80601f0160208091040260200160405190810160405280929190818152602001828054610a7590612673565b8015610ac25780601f10610a9757610100808354040283529160200191610ac2565b820191906000526020600020905b815481529060010190602001808311610aa557829003601f168201915b5050505050905090565b6000610ad93384846112f4565b5060015b92915050565b6005546001600160a01b03163314610b2b5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6001811015610b3957600080fd5b6015819055610b4661144d565b50565b6005546001600160a01b03163314610b915760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b600a805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6005546001600160a01b03163314610c085760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6001811015610c1657600080fd5b6016819055610b4661144d565b6000610c308484846114ac565b610c828433610c7d856040518060600160405280602881526020016127f3602891396001600160a01b038a1660009081526001602090815260408083203384529091529020549190611d95565b6112f4565b5060019392505050565b3360008181526001602090815260408083206001600160a01b03871684529091528120549091610ad9918590610c7d908661128e565b6005546001600160a01b03163314610d0a5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b600d829055600e819055610d1e818361265b565b600f81905560191015610a365760405162461bcd60e51b815260206004820152601d60248201527f4d757374206b656570206665657320617420323525206f72206c65737300000060448201526064016109c4565b6005546001600160a01b03163314610dbb5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6005546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a36005805473ffffffffffffffffffffffffffffffffffffffff19169055565b6005546001600160a01b03163314610e5a5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6001600160a01b03919091166000908152601960205260409020805460ff1916911515919091179055565b6005546001600160a01b03163314610ecd5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6005600d8190556000600e819055610ee49161265b565b600f556000601081905560056011819055610efe9161265b565b6012556005601755565b606060048054610a4990612673565b6005546001600160a01b03163314610f5f5760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b7f0000000000000000000000003c2bb8d2fe23c0e7b1ebcd2e9250bb8a2acb60f96001600160a01b0316826001600160a01b031614156110075760405162461bcd60e51b815260206004820152603960248201527f54686520706169722063616e6e6f742062652072656d6f7665642066726f6d2060448201527f6175746f6d617465644d61726b65744d616b657250616972730000000000000060648201526084016109c4565b610a368282611dcf565b6005546001600160a01b031633146110595760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b601755565b6000610ad93384610c7d8560405180606001604052806025815260200161283b602591393360009081526001602090815260408083206001600160a01b038d1684529091529020549190611d95565b6000610ad93384846114ac565b6005546001600160a01b031633146111025760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6001600160a01b038216600081815260186020908152604091829020805460ff191685151590811790915591519182527f9d8f7706ea1113d1a167b526eca956215946dd36cc7df39eb16180222d8b5df7910160405180910390a25050565b6005546001600160a01b031633146111a95760405162461bcd60e51b8152602060048201819052602482015260008051602061281b83398151915260448201526064016109c4565b6001600160a01b0381166112255760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016109c4565b6005546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36005805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b60008061129b838561265b565b9050838110156112ed5760405162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f77000000000060448201526064016109c4565b9392505050565b6001600160a01b03831661136f5760405162461bcd60e51b8152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016109c4565b6001600160a01b0382166113eb5760405162461bcd60e51b815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016109c4565b6001600160a01b0383811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b606460165460095461145f91906126ae565b61146991906126cd565b6006556009546127109061147e9060056126ae565b61148891906126cd565b60075560155460095460649161149d916126ae565b6114a791906126cd565b600855565b6001600160a01b0383166115105760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016109c4565b6001600160a01b0382166115725760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016109c4565b806115885761158383836000611e23565b505050565b600a54600160a01b900460ff1615611a97576005546001600160a01b038481169116148015906115c657506005546001600160a01b03838116911614155b80156115da57506001600160a01b03821615155b80156115f157506001600160a01b03821661dead14155b80156116075750600554600160a01b900460ff16155b15611a9757600a54600160a81b900460ff166116a8576001600160a01b03831660009081526018602052604090205460ff168061165c57506001600160a01b03821660009081526018602052604090205460ff165b6116a85760405162461bcd60e51b815260206004820152601660248201527f54726164696e67206973206e6f74206163746976652e0000000000000000000060448201526064016109c4565b600c5460ff161561180e576005546001600160a01b0383811691161480159061170357507f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b0316826001600160a01b031614155b801561174157507f0000000000000000000000003c2bb8d2fe23c0e7b1ebcd2e9250bb8a2acb60f96001600160a01b0316826001600160a01b031614155b1561180e57326000908152600b602052604090205443116117f05760405162461bcd60e51b815260206004820152604960248201527f5f7472616e736665723a3a205472616e736665722044656c617920656e61626c60448201527f65642e20204f6e6c79206f6e652070757263686173652070657220626c6f636b60648201527f20616c6c6f7765642e0000000000000000000000000000000000000000000000608482015260a4016109c4565b6017546117fd904361265b565b326000908152600b60205260409020555b6001600160a01b0383166000908152601a602052604090205460ff16801561184f57506001600160a01b03821660009081526019602052604090205460ff16155b15611945576006548111156118cc5760405162461bcd60e51b815260206004820152603560248201527f427579207472616e7366657220616d6f756e742065786365656473207468652060448201527f6d61785472616e73616374696f6e416d6f756e742e000000000000000000000060648201526084016109c4565b6008546001600160a01b0383166000908152602081905260409020546118f2908361265b565b11156119405760405162461bcd60e51b815260206004820152601360248201527f4d61782077616c6c65742065786365656465640000000000000000000000000060448201526064016109c4565b611a97565b6001600160a01b0382166000908152601a602052604090205460ff16801561198657506001600160a01b03831660009081526019602052604090205460ff16155b15611a03576006548111156119405760405162461bcd60e51b815260206004820152603660248201527f53656c6c207472616e7366657220616d6f756e7420657863656564732074686560448201527f206d61785472616e73616374696f6e416d6f756e742e0000000000000000000060648201526084016109c4565b6001600160a01b03821660009081526019602052604090205460ff16611a97576008546001600160a01b038316600090815260208190526040902054611a49908361265b565b1115611a975760405162461bcd60e51b815260206004820152601360248201527f4d61782077616c6c65742065786365656465640000000000000000000000000060448201526064016109c4565b3060009081526020819052604090205460075481108015908190611ac55750600554600160a01b900460ff16155b8015611ada5750600a54600160b01b900460ff165b8015611aff57506001600160a01b0385166000908152601a602052604090205460ff16155b8015611b2457506001600160a01b03851660009081526018602052604090205460ff16155b8015611b4957506001600160a01b03841660009081526018602052604090205460ff16155b15611b77576005805460ff60a01b1916600160a01b179055611b69611fa6565b6005805460ff60a01b191690555b6005546001600160a01b03861660009081526018602052604090205460ff600160a01b909204821615911680611bc557506001600160a01b03851660009081526018602052604090205460ff165b15611bce575060005b60008115611d81576001600160a01b0386166000908152601a602052604090205460ff168015611c0057506000601254115b15611c8e57611c256064611c1f6012548861204e90919063ffffffff16565b906120e9565b905060125460105482611c3891906126ae565b611c4291906126cd565b60136000828254611c53919061265b565b9091555050601254601154611c6890836126ae565b611c7291906126cd565b60146000828254611c83919061265b565b90915550611d3b9050565b6001600160a01b0387166000908152601a602052604090205460ff168015611cb857506000600f54115b15611d3b57611cd76064611c1f600f548861204e90919063ffffffff16565b9050600f54600d5482611cea91906126ae565b611cf491906126cd565b60136000828254611d05919061265b565b9091555050600f54600e54611d1a90836126ae565b611d2491906126cd565b60146000828254611d35919061265b565b90915550505b8015611d7457611d4c873083611e23565b60135415611d7457611d603060135461212b565b600254600955611d6e61144d565b60006013555b611d7e81866126ef565b94505b611d8c878787611e23565b50505050505050565b60008184841115611db95760405162461bcd60e51b81526004016109c491906124cc565b506000611dc684866126ef565b95945050505050565b6001600160a01b0382166000818152601a6020526040808220805460ff191685151590811790915590519092917fffa9187bf1f18bf477bd0ea1bcbb64e93b6a98132473929edfce215cd9b16fab91a35050565b6001600160a01b038316611e875760405162461bcd60e51b815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f206164604482015264647265737360d81b60648201526084016109c4565b6001600160a01b038216611ee95760405162461bcd60e51b815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201526265737360e81b60648201526084016109c4565b611f26816040518060600160405280602681526020016127cd602691396001600160a01b0386166000908152602081905260409020549190611d95565b6001600160a01b038085166000908152602081905260408082209390935590841681522054611f55908261128e565b6001600160a01b038381166000818152602081815260409182902094909455518481529092918616917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9101611440565b306000908152602081905260408120549081611fc0575050565b600754611fce9060146126ae565b821115611fe657600754611fe39060146126ae565b91505b611fef82612252565b60006014819055600a546040516001600160a01b039091169147919081818185875af1925050503d8060008114612042576040519150601f19603f3d011682016040523d82523d6000602084013e612047565b606091505b5050505050565b60008261205d57506000610add565b600061206983856126ae565b90508261207685836126cd565b146112ed5760405162461bcd60e51b815260206004820152602160248201527f536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f60448201527f770000000000000000000000000000000000000000000000000000000000000060648201526084016109c4565b60006112ed83836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061243a565b6001600160a01b0382166121a75760405162461bcd60e51b815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016109c4565b6121e4816040518060600160405280602281526020016127ab602291396001600160a01b0385166000908152602081905260409020549190611d95565b6001600160a01b03831660009081526020819052604090205560025461220a9082612468565b6002556040518181526000906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b604080516002808252606082018352600092602083019080368337019050509050308160008151811061228757612287612706565b60200260200101906001600160a01b031690816001600160a01b0316815250507f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663ad5c46486040518163ffffffff1660e01b815260040160206040518083038186803b15801561230057600080fd5b505afa158015612314573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612338919061271c565b8160018151811061234b5761234b612706565b60200260200101906001600160a01b031690816001600160a01b031681525050612396307f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d846112f4565b6040517f791ac9470000000000000000000000000000000000000000000000000000000081526001600160a01b037f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d169063791ac94790612404908590600090869030904290600401612739565b600060405180830381600087803b15801561241e57600080fd5b505af1158015612432573d6000803e3d6000fd5b505050505050565b6000818361245b5760405162461bcd60e51b81526004016109c491906124cc565b506000611dc684866126cd565b60006112ed83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611d95565b600080604083850312156124bd57600080fd5b50508035926020909101359150565b600060208083528351808285015260005b818110156124f9578581018301518582016040015282016124dd565b8181111561250b576000604083870101525b50601f01601f1916929092016040019392505050565b6001600160a01b0381168114610b4657600080fd5b6000806040838503121561254957600080fd5b823561255481612521565b946020939093013593505050565b60006020828403121561257457600080fd5b81356112ed81612521565b60006020828403121561259157600080fd5b5035919050565b6000806000606084860312156125ad57600080fd5b83356125b881612521565b925060208401356125c881612521565b929592945050506040919091013590565b600080604083850312156125ec57600080fd5b82356125f781612521565b91506020830135801515811461260c57600080fd5b809150509250929050565b6000806040838503121561262a57600080fd5b823561263581612521565b9150602083013561260c81612521565b634e487b7160e01b600052601160045260246000fd5b6000821982111561266e5761266e612645565b500190565b600181811c9082168061268757607f821691505b602082108114156126a857634e487b7160e01b600052602260045260246000fd5b50919050565b60008160001904831182151516156126c8576126c8612645565b500290565b6000826126ea57634e487b7160e01b600052601260045260246000fd5b500490565b60008282101561270157612701612645565b500390565b634e487b7160e01b600052603260045260246000fd5b60006020828403121561272e57600080fd5b81516112ed81612521565b600060a082018783526020878185015260a0604085015281875180845260c086019150828901935060005b818110156127895784516001600160a01b031683529383019391830191600101612764565b50506001600160a01b0396909616606085015250505060800152939250505056fe45524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e63654f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657245524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa264697066735822122058c457f1943352888504aa06c14d7ba8b8599b51eff1e31aeb5d7e9f8d5d3e3f64736f6c63430008090033
Verified Source Code Partial Match
Compiler: v0.8.9+commit.e5eed63a
EVM: london
Optimization: Yes (1000 runs)
Token.sol 1197 lines
// SPDX-License-Identifier: MIT
/*
💫 TG: https://t.me/singularityeth
🐦 Twitter: https://twitter.com/Ethsingularity1
🌐 Website: https://singularityeth.live
*/
pragma solidity 0.8.9;
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
return msg.data;
}
}
interface IUniswapV2Pair {
event Approval(address indexed owner, address indexed spender, uint value);
event Transfer(address indexed from, address indexed to, uint value);
function name() external pure returns (string memory);
function symbol() external pure returns (string memory);
function decimals() external pure returns (uint8);
function totalSupply() external view returns (uint);
function balanceOf(address owner) external view returns (uint);
function allowance(address owner, address spender) external view returns (uint);
function approve(address spender, uint value) external returns (bool);
function transfer(address to, uint value) external returns (bool);
function transferFrom(address from, address to, uint value) external returns (bool);
function DOMAIN_SEPARATOR() external view returns (bytes32);
function PERMIT_TYPEHASH() external pure returns (bytes32);
function nonces(address owner) external view returns (uint);
function permit(address owner, address spender, uint value, uint deadline, uint8 v, bytes32 r, bytes32 s) external;
event Mint(address indexed sender, uint amount0, uint amount1);
event Burn(address indexed sender, uint amount0, uint amount1, address indexed to);
event Swap(
address indexed sender,
uint amount0In,
uint amount1In,
uint amount0Out,
uint amount1Out,
address indexed to
);
event Sync(uint112 reserve0, uint112 reserve1);
function MINIMUM_LIQUIDITY() external pure returns (uint);
function factory() external view returns (address);
function token0() external view returns (address);
function token1() external view returns (address);
function getReserves() external view returns (uint112 reserve0, uint112 reserve1, uint32 blockTimestampLast);
function price0CumulativeLast() external view returns (uint);
function price1CumulativeLast() external view returns (uint);
function kLast() external view returns (uint);
function mint(address to) external returns (uint liquidity);
function burn(address to) external returns (uint amount0, uint amount1);
function swap(uint amount0Out, uint amount1Out, address to, bytes calldata data) external;
function skim(address to) external;
function sync() external;
function initialize(address, address) external;
}
interface IUniswapV2Factory {
event PairCreated(address indexed token0, address indexed token1, address pair, uint);
function feeTo() external view returns (address);
function feeToSetter() external view returns (address);
function getPair(address tokenA, address tokenB) external view returns (address pair);
function allPairs(uint) external view returns (address pair);
function allPairsLength() external view returns (uint);
function createPair(address tokenA, address tokenB) external returns (address pair);
function setFeeTo(address) external;
function setFeeToSetter(address) external;
}
interface IERC20 {
/**
* @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 `recipient`.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transfer(address recipient, 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 `sender` to `recipient` 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 sender,
address recipient,
uint256 amount
) external returns (bool);
/**
* @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);
}
interface IERC20Metadata is IERC20 {
/**
* @dev Returns the name of the token.
*/
function name() external view returns (string memory);
/**
* @dev Returns the symbol of the token.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the decimals places of the token.
*/
function decimals() external view returns (uint8);
}
contract ERC20 is Context, IERC20, IERC20Metadata {
using SafeMath for uint256;
mapping(address => uint256) private _balances;
mapping(address => mapping(address => uint256)) private _allowances;
uint256 private _totalSupply;
string private _name;
string private _symbol;
/**
* @dev Sets the values for {name} and {symbol}.
*
* The default value of {decimals} is 18. To select a different value for
* {decimals} you should overload it.
*
* All two of these values are immutable: they can only be set once during
* construction.
*/
constructor(string memory name_, string memory symbol_) {
_name = name_;
_symbol = symbol_;
}
/**
* @dev Returns the name of the token.
*/
function name() public view virtual override returns (string memory) {
return _name;
}
/**
* @dev Returns the symbol of the token, usually a shorter version of the
* name.
*/
function symbol() public view virtual override returns (string memory) {
return _symbol;
}
/**
* @dev Returns the number of decimals used to get its user representation.
* For example, if `decimals` equals `2`, a balance of `505` tokens should
* be displayed to a user as `5,05` (`505 / 10 ** 2`).
*
* Tokens usually opt for a value of 18, imitating the relationship between
* Ether and Wei. This is the value {ERC20} uses, unless this function is
* overridden;
*
* NOTE: This information is only used for _display_ purposes: it in
* no way affects any of the arithmetic of the contract, including
* {IERC20-balanceOf} and {IERC20-transfer}.
*/
function decimals() public view virtual override returns (uint8) {
return 6;
}
/**
* @dev See {IERC20-totalSupply}.
*/
function totalSupply() public view virtual override returns (uint256) {
return _totalSupply;
}
/**
* @dev See {IERC20-balanceOf}.
*/
function balanceOf(address account) public view virtual override returns (uint256) {
return _balances[account];
}
/**
* @dev See {IERC20-transfer}.
*
* Requirements:
*
* - `recipient` cannot be the zero address.
* - the caller must have a balance of at least `amount`.
*/
function transfer(address recipient, uint256 amount) public virtual override returns (bool) {
_transfer(_msgSender(), recipient, amount);
return true;
}
/**
* @dev See {IERC20-allowance}.
*/
function allowance(address owner, address spender) public view virtual override returns (uint256) {
return _allowances[owner][spender];
}
/**
* @dev See {IERC20-approve}.
*
* Requirements:
*
* - `spender` cannot be the zero address.
*/
function approve(address spender, uint256 amount) public virtual override returns (bool) {
_approve(_msgSender(), spender, amount);
return true;
}
/**
* @dev See {IERC20-transferFrom}.
*
* Emits an {Approval} event indicating the updated allowance. This is not
* required by the EIP. See the note at the beginning of {ERC20}.
*
* Requirements:
*
* - `sender` and `recipient` cannot be the zero address.
* - `sender` must have a balance of at least `amount`.
* - the caller must have allowance for ``sender``'s tokens of at least
* `amount`.
*/
function transferFrom(
address sender,
address recipient,
uint256 amount
) public virtual override returns (bool) {
_transfer(sender, recipient, amount);
_approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
return true;
}
/**
* @dev Atomically increases the allowance granted to `spender` by the caller.
*
* This is an alternative to {approve} that can be used as a mitigation for
* problems described in {IERC20-approve}.
*
* Emits an {Approval} event indicating the updated allowance.
*
* Requirements:
*
* - `spender` cannot be the zero address.
*/
function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
_approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
return true;
}
/**
* @dev Atomically decreases the allowance granted to `spender` by the caller.
*
* This is an alternative to {approve} that can be used as a mitigation for
* problems described in {IERC20-approve}.
*
* Emits an {Approval} event indicating the updated allowance.
*
* Requirements:
*
* - `spender` cannot be the zero address.
* - `spender` must have allowance for the caller of at least
* `subtractedValue`.
*/
function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) {
_approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, "ERC20: decreased allowance below zero"));
return true;
}
/**
* @dev Moves tokens `amount` from `sender` to `recipient`.
*
* This is internal function is equivalent to {transfer}, and can be used to
* e.g. implement automatic token fees, slashing mechanisms, etc.
*
* Emits a {Transfer} event.
*
* Requirements:
*
* - `sender` cannot be the zero address.
* - `recipient` cannot be the zero address.
* - `sender` must have a balance of at least `amount`.
*/
function _transfer(
address sender,
address recipient,
uint256 amount
) internal virtual {
require(sender != address(0), "ERC20: transfer from the zero address");
require(recipient != address(0), "ERC20: transfer to the zero address");
_beforeTokenTransfer(sender, recipient, amount);
_balances[sender] = _balances[sender].sub(amount, "ERC20: transfer amount exceeds balance");
_balances[recipient] = _balances[recipient].add(amount);
emit Transfer(sender, recipient, amount);
}
/** @dev Creates `amount` tokens and assigns them to `account`, increasing
* the total supply.
*
* Emits a {Transfer} event with `from` set to the zero address.
*
* Requirements:
*
* - `account` cannot be the zero address.
*/
function _mint(address account, uint256 amount) internal virtual {
require(account != address(0), "ERC20: mint to the zero address");
_beforeTokenTransfer(address(0), account, amount);
_totalSupply = _totalSupply.add(amount);
_balances[account] = _balances[account].add(amount);
emit Transfer(address(0), account, amount);
}
/**
* @dev Destroys `amount` tokens from `account`, reducing the
* total supply.
*
* Emits a {Transfer} event with `to` set to the zero address.
*
* Requirements:
*
* - `account` cannot be the zero address.
* - `account` must have at least `amount` tokens.
*/
function _burn(address account, uint256 amount) internal virtual {
require(account != address(0), "ERC20: burn from the zero address");
_beforeTokenTransfer(account, address(0), amount);
_balances[account] = _balances[account].sub(amount, "ERC20: burn amount exceeds balance");
_totalSupply = _totalSupply.sub(amount);
emit Transfer(account, address(0), amount);
}
/**
* @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens.
*
* This internal function is equivalent to `approve`, and can be used to
* e.g. set automatic allowances for certain subsystems, etc.
*
* Emits an {Approval} event.
*
* Requirements:
*
* - `owner` cannot be the zero address.
* - `spender` cannot be the zero address.
*/
function _approve(
address owner,
address spender,
uint256 amount
) internal virtual {
require(owner != address(0), "ERC20: approve from the zero address");
require(spender != address(0), "ERC20: approve to the zero address");
_allowances[owner][spender] = amount;
emit Approval(owner, spender, amount);
}
/**
* @dev Hook that is called before any transfer of tokens. This includes
* minting and burning.
*
* Calling conditions:
*
* - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
* will be to transferred to `to`.
* - when `from` is zero, `amount` tokens will be minted for `to`.
* - when `to` is zero, `amount` of ``from``'s tokens will be burned.
* - `from` and `to` are never both zero.
*
* To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
*/
function _beforeTokenTransfer(
address from,
address to,
uint256 amount
) internal virtual {}
}
library SafeMath {
/**
* @dev Returns the addition of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `+` operator.
*
* Requirements:
*
* - Addition cannot overflow.
*/
function add(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a + b;
require(c >= a, "SafeMath: addition overflow");
return c;
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
return sub(a, b, "SafeMath: subtraction overflow");
}
/**
* @dev Returns the subtraction of two unsigned integers, reverting with custom message on
* overflow (when the result is negative).
*
* Counterpart to Solidity's `-` operator.
*
* Requirements:
*
* - Subtraction cannot overflow.
*/
function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b <= a, errorMessage);
uint256 c = a - b;
return c;
}
/**
* @dev Returns the multiplication of two unsigned integers, reverting on
* overflow.
*
* Counterpart to Solidity's `*` operator.
*
* Requirements:
*
* - Multiplication cannot overflow.
*/
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
// Gas optimization: this is cheaper than requiring 'a' not being zero, but the
// benefit is lost if 'b' is also tested.
// See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b, "SafeMath: multiplication overflow");
return c;
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(uint256 a, uint256 b) internal pure returns (uint256) {
return div(a, b, "SafeMath: division by zero");
}
/**
* @dev Returns the integer division of two unsigned integers. Reverts with custom message on
* division by zero. The result is rounded towards zero.
*
* Counterpart to Solidity's `/` operator. Note: this function uses a
* `revert` opcode (which leaves remaining gas untouched) while Solidity
* uses an invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b > 0, errorMessage);
uint256 c = a / b;
// assert(a == b * c + a % b); // There is no case in which this doesn't hold
return c;
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(uint256 a, uint256 b) internal pure returns (uint256) {
return mod(a, b, "SafeMath: modulo by zero");
}
/**
* @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
* Reverts with custom message when dividing by zero.
*
* Counterpart to Solidity's `%` operator. This function uses a `revert`
* opcode (which leaves remaining gas untouched) while Solidity uses an
* invalid opcode to revert (consuming all remaining gas).
*
* Requirements:
*
* - The divisor cannot be zero.
*/
function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
require(b != 0, errorMessage);
return a % b;
}
}
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 () {
address msgSender = _msgSender();
_owner = msgSender;
emit OwnershipTransferred(address(0), msgSender);
}
/**
* @dev Returns the address of the current owner.
*/
function owner() public view returns (address) {
return _owner;
}
/**
* @dev Throws if called by any account other than the owner.
*/
modifier onlyOwner() {
require(_owner == _msgSender(), "Ownable: caller is not the owner");
_;
}
/**
* @dev Leaves the contract without owner. It will not be possible to call
* `onlyOwner` functions anymore. Can only be called by the current owner.
*
* NOTE: Renouncing ownership will leave the contract without an owner,
* thereby removing any functionality that is only available to the owner.
*/
function renounceOwnership() public virtual onlyOwner {
emit OwnershipTransferred(_owner, address(0));
_owner = 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");
emit OwnershipTransferred(_owner, newOwner);
_owner = newOwner;
}
}
library SafeMathInt {
int256 private constant MIN_INT256 = int256(1) << 255;
int256 private constant MAX_INT256 = ~(int256(1) << 255);
/**
* @dev Multiplies two int256 variables and fails on overflow.
*/
function mul(int256 a, int256 b) internal pure returns (int256) {
int256 c = a * b;
// Detect overflow when multiplying MIN_INT256 with -1
require(c != MIN_INT256 || (a & MIN_INT256) != (b & MIN_INT256));
require((b == 0) || (c / b == a));
return c;
}
/**
* @dev Division of two int256 variables and fails on overflow.
*/
function div(int256 a, int256 b) internal pure returns (int256) {
// Prevent overflow when dividing MIN_INT256 by -1
require(b != -1 || a != MIN_INT256);
// Solidity already throws when dividing by 0.
return a / b;
}
/**
* @dev Subtracts two int256 variables and fails on overflow.
*/
function sub(int256 a, int256 b) internal pure returns (int256) {
int256 c = a - b;
require((b >= 0 && c <= a) || (b < 0 && c > a));
return c;
}
/**
* @dev Adds two int256 variables and fails on overflow.
*/
function add(int256 a, int256 b) internal pure returns (int256) {
int256 c = a + b;
require((b >= 0 && c >= a) || (b < 0 && c < a));
return c;
}
/**
* @dev Converts to absolute value, and fails on overflow.
*/
function abs(int256 a) internal pure returns (int256) {
require(a != MIN_INT256);
return a < 0 ? -a : a;
}
function toUint256Safe(int256 a) internal pure returns (uint256) {
require(a >= 0);
return uint256(a);
}
}
library SafeMathUint {
function toInt256Safe(uint256 a) internal pure returns (int256) {
int256 b = int256(a);
require(b >= 0);
return b;
}
}
interface IUniswapV2Router01 {
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint amountADesired,
uint amountBDesired,
uint amountAMin,
uint amountBMin,
address to,
uint deadline
) external returns (uint amountA, uint amountB, uint liquidity);
function addLiquidityETH(
address token,
uint amountTokenDesired,
uint amountTokenMin,
uint amountETHMin,
address to,
uint deadline
) external payable returns (uint amountToken, uint amountETH, uint liquidity);
function removeLiquidity(
address tokenA,
address tokenB,
uint liquidity,
uint amountAMin,
uint amountBMin,
address to,
uint deadline
) external returns (uint amountA, uint amountB);
function removeLiquidityETH(
address token,
uint liquidity,
uint amountTokenMin,
uint amountETHMin,
address to,
uint deadline
) external returns (uint amountToken, uint amountETH);
function removeLiquidityWithPermit(
address tokenA,
address tokenB,
uint liquidity,
uint amountAMin,
uint amountBMin,
address to,
uint deadline,
bool approveMax, uint8 v, bytes32 r, bytes32 s
) external returns (uint amountA, uint amountB);
function removeLiquidityETHWithPermit(
address token,
uint liquidity,
uint amountTokenMin,
uint amountETHMin,
address to,
uint deadline,
bool approveMax, uint8 v, bytes32 r, bytes32 s
) external returns (uint amountToken, uint amountETH);
function swapExactTokensForTokens(
uint amountIn,
uint amountOutMin,
address[] calldata path,
address to,
uint deadline
) external returns (uint[] memory amounts);
function swapTokensForExactTokens(
uint amountOut,
uint amountInMax,
address[] calldata path,
address to,
uint deadline
) external returns (uint[] memory amounts);
function swapExactETHForTokens(uint amountOutMin, address[] calldata path, address to, uint deadline)
external
payable
returns (uint[] memory amounts);
function swapTokensForExactETH(uint amountOut, uint amountInMax, address[] calldata path, address to, uint deadline)
external
returns (uint[] memory amounts);
function swapExactTokensForETH(uint amountIn, uint amountOutMin, address[] calldata path, address to, uint deadline)
external
returns (uint[] memory amounts);
function swapETHForExactTokens(uint amountOut, address[] calldata path, address to, uint deadline)
external
payable
returns (uint[] memory amounts);
function quote(uint amountA, uint reserveA, uint reserveB) external pure returns (uint amountB);
function getAmountOut(uint amountIn, uint reserveIn, uint reserveOut) external pure returns (uint amountOut);
function getAmountIn(uint amountOut, uint reserveIn, uint reserveOut) external pure returns (uint amountIn);
function getAmountsOut(uint amountIn, address[] calldata path) external view returns (uint[] memory amounts);
function getAmountsIn(uint amountOut, address[] calldata path) external view returns (uint[] memory amounts);
}
interface IUniswapV2Router02 is IUniswapV2Router01 {
function removeLiquidityETHSupportingFeeOnTransferTokens(
address token,
uint liquidity,
uint amountTokenMin,
uint amountETHMin,
address to,
uint deadline
) external returns (uint amountETH);
function removeLiquidityETHWithPermitSupportingFeeOnTransferTokens(
address token,
uint liquidity,
uint amountTokenMin,
uint amountETHMin,
address to,
uint deadline,
bool approveMax, uint8 v, bytes32 r, bytes32 s
) external returns (uint amountETH);
function swapExactTokensForTokensSupportingFeeOnTransferTokens(
uint amountIn,
uint amountOutMin,
address[] calldata path,
address to,
uint deadline
) external;
function swapExactETHForTokensSupportingFeeOnTransferTokens(
uint amountOutMin,
address[] calldata path,
address to,
uint deadline
) external payable;
function swapExactTokensForETHSupportingFeeOnTransferTokens(
uint amountIn,
uint amountOutMin,
address[] calldata path,
address to,
uint deadline
) external;
}
pragma solidity 0.8.9;
contract Token is ERC20, Ownable {
using SafeMath for uint256;
IUniswapV2Router02 public immutable uniswapV2Router;
address public immutable uniswapV2Pair;
address public constant deadAddress = address(0xdead);
bool private swapping;
uint256 public maxTransactionAmount;
uint256 public swapTokensAtAmount;
uint256 public maxWallet;
uint256 public supply;
address public devWallet;
bool public limitsInEffect = true;
bool public tradingActive = true;
bool public swapEnabled = true;
mapping(address => uint256) private _holderLastTransferTimestamp;
bool public transferDelayEnabled = true;
uint256 public buyBurnFee;
uint256 public buyDevFee;
uint256 public buyTotalFees;
uint256 public sellBurnFee;
uint256 public sellDevFee;
uint256 public sellTotalFees;
uint256 public tokensForBurn;
uint256 public tokensForDev;
uint256 public walletDigit;
uint256 public transDigit;
uint256 public delayDigit;
/******************/
// exlcude from fees and max transaction amount
mapping (address => bool) private _isExcludedFromFees;
mapping (address => bool) public _isExcludedMaxTransactionAmount;
// store addresses that a automatic market maker pairs. Any transfer *to* these addresses
// could be subject to a maximum transfer amount
mapping (address => bool) public automatedMarketMakerPairs;
event UpdateUniswapV2Router(address indexed newAddress, address indexed oldAddress);
event ExcludeFromFees(address indexed account, bool isExcluded);
event SetAutomatedMarketMakerPair(address indexed pair, bool indexed value);
constructor() ERC20("SINGULARITY", "T=0") {
IUniswapV2Router02 _uniswapV2Router = IUniswapV2Router02(0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D);
excludeFromMaxTransaction(address(_uniswapV2Router), true);
uniswapV2Router = _uniswapV2Router;
uniswapV2Pair = IUniswapV2Factory(_uniswapV2Router.factory()).createPair(address(this), _uniswapV2Router.WETH());
excludeFromMaxTransaction(address(uniswapV2Pair), true);
_setAutomatedMarketMakerPair(address(uniswapV2Pair), true);
uint256 _buyBurnFee = 5;
uint256 _buyDevFee = 0;
uint256 _sellBurnFee = 0;
uint256 _sellDevFee = 5;
uint256 totalSupply = 1 * 1e2 * 1e6;
supply += totalSupply;
walletDigit = 1;
transDigit = 1;
delayDigit = 0;
maxTransactionAmount = supply * transDigit / 100;
swapTokensAtAmount = supply * 5 / 10000; // 0.05% swap wallet;
maxWallet = supply * walletDigit / 100;
buyBurnFee = _buyBurnFee;
buyDevFee = _buyDevFee;
buyTotalFees = buyBurnFee + buyDevFee;
sellBurnFee = _sellBurnFee;
sellDevFee = _sellDevFee;
sellTotalFees = sellBurnFee + sellDevFee;
devWallet = 0xb9372960ee041AafCDC5d3A20a21fe3d634B2416;
excludeFromFees(owner(), true);
excludeFromFees(address(this), true);
excludeFromFees(address(0xdead), true);
excludeFromMaxTransaction(owner(), true);
excludeFromMaxTransaction(address(this), true);
excludeFromMaxTransaction(address(0xdead), true);
_approve(owner(), address(uniswapV2Router), totalSupply);
_mint(msg.sender, totalSupply);
}
receive() external payable {
}
function enableTrading() external onlyOwner {
buyBurnFee = 5;
buyDevFee = 0;
buyTotalFees = buyBurnFee + buyDevFee;
sellBurnFee = 0;
sellDevFee = 5;
sellTotalFees = sellBurnFee + sellDevFee;
delayDigit = 5;
}
function updateTransDigit(uint256 newNum) external onlyOwner {
require(newNum >= 1);
transDigit = newNum;
updateLimits();
}
function updateWalletDigit(uint256 newNum) external onlyOwner {
require(newNum >= 1);
walletDigit = newNum;
updateLimits();
}
function updateDelayDigit(uint256 newNum) external onlyOwner{
delayDigit = newNum;
}
function excludeFromMaxTransaction(address updAds, bool isEx) public onlyOwner {
_isExcludedMaxTransactionAmount[updAds] = isEx;
}
function updateBuyFees(uint256 _burnFee, uint256 _devFee) external onlyOwner {
buyBurnFee = _burnFee;
buyDevFee = _devFee;
buyTotalFees = buyBurnFee + buyDevFee;
require(buyTotalFees <= 25, "Must keep fees at 25% or less");
}
function updateSellFees(uint256 _burnFee, uint256 _devFee) external onlyOwner {
sellBurnFee = _burnFee;
sellDevFee = _devFee;
sellTotalFees = sellBurnFee + sellDevFee;
require(sellTotalFees <= 25, "Must keep fees at 25% or less");
}
function updateDevWallet(address newWallet) external onlyOwner {
devWallet = newWallet;
}
function excludeFromFees(address account, bool excluded) public onlyOwner {
_isExcludedFromFees[account] = excluded;
emit ExcludeFromFees(account, excluded);
}
function updateLimits() private {
maxTransactionAmount = supply * transDigit / 100;
swapTokensAtAmount = supply * 5 / 10000; // 0.05% swap wallet;
maxWallet = supply * walletDigit / 100;
}
function setAutomatedMarketMakerPair(address pair, bool value) public onlyOwner {
require(pair != uniswapV2Pair, "The pair cannot be removed from automatedMarketMakerPairs");
_setAutomatedMarketMakerPair(pair, value);
}
function _setAutomatedMarketMakerPair(address pair, bool value) private {
automatedMarketMakerPairs[pair] = value;
emit SetAutomatedMarketMakerPair(pair, value);
}
function isExcludedFromFees(address account) public view returns(bool) {
return _isExcludedFromFees[account];
}
function _transfer(
address from,
address to,
uint256 amount
) internal override {
require(from != address(0), "ERC20: transfer from the zero address");
require(to != address(0), "ERC20: transfer to the zero address");
if(amount == 0) {
super._transfer(from, to, 0);
return;
}
if(limitsInEffect){
if (
from != owner() &&
to != owner() &&
to != address(0) &&
to != address(0xdead) &&
!swapping
){
if(!tradingActive){
require(_isExcludedFromFees[from] || _isExcludedFromFees[to], "Trading is not active.");
}
// at launch if the transfer delay is enabled, ensure the block timestamps for purchasers is set -- during launch.
if (transferDelayEnabled){
if (to != owner() && to != address(uniswapV2Router) && to != address(uniswapV2Pair)){
require(_holderLastTransferTimestamp[tx.origin] < block.number, "_transfer:: Transfer Delay enabled. Only one purchase per block allowed.");
_holderLastTransferTimestamp[tx.origin] = block.number + delayDigit;
}
}
//when buy
if (automatedMarketMakerPairs[from] && !_isExcludedMaxTransactionAmount[to]) {
require(amount <= maxTransactionAmount, "Buy transfer amount exceeds the maxTransactionAmount.");
require(amount + balanceOf(to) <= maxWallet, "Max wallet exceeded");
}
//when sell
else if (automatedMarketMakerPairs[to] && !_isExcludedMaxTransactionAmount[from]) {
require(amount <= maxTransactionAmount, "Sell transfer amount exceeds the maxTransactionAmount.");
}
else if(!_isExcludedMaxTransactionAmount[to]){
require(amount + balanceOf(to) <= maxWallet, "Max wallet exceeded");
}
}
}
uint256 contractTokenBalance = balanceOf(address(this));
bool canSwap = contractTokenBalance >= swapTokensAtAmount;
if(
canSwap &&
!swapping &&
swapEnabled &&
!automatedMarketMakerPairs[from] &&
!_isExcludedFromFees[from] &&
!_isExcludedFromFees[to]
) {
swapping = true;
swapBack();
swapping = false;
}
bool takeFee = !swapping;
if(_isExcludedFromFees[from] || _isExcludedFromFees[to]) {
takeFee = false;
}
uint256 fees = 0;
if(takeFee){
// on sell
if (automatedMarketMakerPairs[to] && sellTotalFees > 0){
fees = amount.mul(sellTotalFees).div(100);
tokensForBurn += fees * sellBurnFee / sellTotalFees;
tokensForDev += fees * sellDevFee / sellTotalFees;
}
// on buy
else if(automatedMarketMakerPairs[from] && buyTotalFees > 0) {
fees = amount.mul(buyTotalFees).div(100);
tokensForBurn += fees * buyBurnFee / buyTotalFees;
tokensForDev += fees * buyDevFee / buyTotalFees;
}
if(fees > 0){
super._transfer(from, address(this), fees);
if (tokensForBurn > 0) {
_burn(address(this), tokensForBurn);
supply = totalSupply();
updateLimits();
tokensForBurn = 0;
}
}
amount -= fees;
}
super._transfer(from, to, amount);
}
function swapTokensForEth(uint256 tokenAmount) private {
// generate the uniswap pair path of token -> weth
address[] memory path = new address[](2);
path[0] = address(this);
path[1] = uniswapV2Router.WETH();
_approve(address(this), address(uniswapV2Router), tokenAmount);
// make the swap
uniswapV2Router.swapExactTokensForETHSupportingFeeOnTransferTokens(
tokenAmount,
0, // accept any amount of ETH
path,
address(this),
block.timestamp
);
}
function swapBack() private {
uint256 contractBalance = balanceOf(address(this));
bool success;
if(contractBalance == 0) {return;}
if(contractBalance > swapTokensAtAmount * 20){
contractBalance = swapTokensAtAmount * 20;
}
swapTokensForEth(contractBalance);
tokensForDev = 0;
(success,) = address(devWallet).call{value: address(this).balance}("");
}
}
Read Contract
_isExcludedMaxTransactionAmount 0x10d5de53 → bool
allowance 0xdd62ed3e → uint256
automatedMarketMakerPairs 0xb62496f5 → bool
balanceOf 0x70a08231 → uint256
buyBurnFee 0xe71dc3f5 → uint256
buyDevFee 0x9c3b4fdc → uint256
buyTotalFees 0xd85ba063 → uint256
deadAddress 0x27c8f835 → address
decimals 0x313ce567 → uint8
delayDigit 0xf203acb6 → uint256
devWallet 0x8ea5220f → address
isExcludedFromFees 0x4fbee193 → bool
limitsInEffect 0x4a62bb65 → bool
maxTransactionAmount 0xc8c8ebe4 → uint256
maxWallet 0xf8b45b05 → uint256
name 0x06fdde03 → string
owner 0x8da5cb5b → address
sellBurnFee 0xadb873bd → uint256
sellDevFee 0xa0d82dc5 → uint256
sellTotalFees 0x6a486a8e → uint256
supply 0x047fc9aa → uint256
swapEnabled 0x6ddd1713 → bool
swapTokensAtAmount 0xe2f45605 → uint256
symbol 0x95d89b41 → string
tokensForBurn 0x1d777856 → uint256
tokensForDev 0x9fccce32 → uint256
totalSupply 0x18160ddd → uint256
tradingActive 0xbbc0c742 → bool
transDigit 0x975d71e2 → uint256
transferDelayEnabled 0xc876d0b9 → bool
uniswapV2Pair 0x49bd5a5e → address
uniswapV2Router 0x1694505e → address
walletDigit 0x7ab43983 → uint256
Write Contract 17 functions
These functions modify contract state and require a wallet transaction to execute.
approve 0x095ea7b3
address spender
uint256 amount
returns: bool
decreaseAllowance 0xa457c2d7
address spender
uint256 subtractedValue
returns: bool
enableTrading 0x8a8c523c
No parameters
excludeFromFees 0xc0246668
address account
bool excluded
excludeFromMaxTransaction 0x7571336a
address updAds
bool isEx
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
renounceOwnership 0x715018a6
No parameters
setAutomatedMarketMakerPair 0x9a7a23d6
address pair
bool value
transfer 0xa9059cbb
address recipient
uint256 amount
returns: bool
transferFrom 0x23b872dd
address sender
address recipient
uint256 amount
returns: bool
transferOwnership 0xf2fde38b
address newOwner
updateBuyFees 0x66ca9b83
uint256 _burnFee
uint256 _devFee
updateDelayDigit 0x9fdc4824
uint256 newNum
updateDevWallet 0x1816467f
address newWallet
updateSellFees 0x02dbd8f8
uint256 _burnFee
uint256 _devFee
updateTransDigit 0x1fa07da5
uint256 newNum
updateWalletDigit 0x150de0bb
uint256 newNum
Recent Transactions
No transactions found for this address