Cryo Explorer Ethereum Mainnet

Address Contract Partially Verified

Address 0x25fA408ad8768AA6eA4F1Ccf6E38D72a863b5139
Balance 0.021212 ETH
Nonce 1
Code Size 13430 bytes
Indexed Transactions 0
External Etherscan · Sourcify

Contract Bytecode

13430 bytes
0x6080604052600436106102e85760003560e01c806370a0823111610190578063c0b0fda2116100dc578063dd46706411610095578063e2f456051161006f578063e2f4560514610a69578063ea2f0b3714610a7e578063f19ae79314610ab1578063f2fde38b14610aea576102ef565b8063dd467064146109ef578063dd62ed3e14610a19578063e0f07e3a14610a54576102ef565b8063c0b0fda21461090c578063c49b9a8014610921578063cea269581461094d578063d1a1f31814610977578063d4ed7b3f1461098c578063d543dbeb146109c5576102ef565b80638ee88c5311610149578063a69df4b511610123578063a69df4b51461087f578063a9059cbb14610894578063afa4f3b2146108cd578063b6c52324146108f7576102ef565b80638ee88c531461080757806395d89b4114610831578063a457c2d714610846576102ef565b806370a082311461074d578063715018a6146107805780637d1db4a51461079557806384c00ef0146107aa57806388f82020146107bf5780638da5cb5b146107f2576102ef565b80633685d4191161024f5780634549b039116102085780634a74bb02116101e25780634a74bb02146106bd57806352390c02146106d25780635342acb4146107055780636bc87c3a14610738576102ef565b80634549b0391461064c578063457c194c1461067e57806349bd5a5e146106a8576102ef565b80633685d41914610559578063395093511461058c5780633b124fe7146105c55780633bd5d173146105da5780633c9f861d14610604578063437823ec14610619576102ef565b806318160ddd116102a157806318160ddd146104645780631c1d97471461047957806322976e0d146104ac57806323b872dd146104c15780632d83811914610504578063313ce5671461052e576102ef565b8063061c82d0146102f457806306fdde031461032057806307dce0f8146103aa578063095ea7b3146103bf57806313114a9d1461040c5780631694505e14610433576102ef565b366102ef57005b600080fd5b34801561030057600080fd5b5061031e6004803603602081101561031757600080fd5b5035610b1d565b005b34801561032c57600080fd5b50610335610b7a565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561036f578181015183820152602001610357565b50505050905090810190601f16801561039c5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b3480156103b657600080fd5b5061031e610c10565b3480156103cb57600080fd5b506103f8600480360360408110156103e257600080fd5b506001600160a01b038135169060200135610d32565b604080519115158252519081900360200190f35b34801561041857600080fd5b50610421610d50565b60408051918252519081900360200190f35b34801561043f57600080fd5b50610448610d56565b604080516001600160a01b039092168252519081900360200190f35b34801561047057600080fd5b50610421610d7a565b34801561048557600080fd5b5061031e6004803603602081101561049c57600080fd5b50356001600160a01b0316610d80565b3480156104b857600080fd5b50610421610dfa565b3480156104cd57600080fd5b506103f8600480360360608110156104e457600080fd5b506001600160a01b03813581169160208101359091169060400135610e00565b34801561051057600080fd5b506104216004803603602081101561052757600080fd5b5035610e87565b34801561053a57600080fd5b50610543610ee9565b6040805160ff9092168252519081900360200190f35b34801561056557600080fd5b5061031e6004803603602081101561057c57600080fd5b50356001600160a01b0316610ef2565b34801561059857600080fd5b506103f8600480360360408110156105af57600080fd5b506001600160a01b0381351690602001356110b3565b3480156105d157600080fd5b50610421611101565b3480156105e657600080fd5b5061031e600480360360208110156105fd57600080fd5b5035611107565b34801561061057600080fd5b506104216111e1565b34801561062557600080fd5b5061031e6004803603602081101561063c57600080fd5b50356001600160a01b03166111e7565b34801561065857600080fd5b506104216004803603604081101561066f57600080fd5b50803590602001351515611263565b34801561068a57600080fd5b5061031e600480360360208110156106a157600080fd5b50356112f5565b3480156106b457600080fd5b50610448611352565b3480156106c957600080fd5b506103f8611376565b3480156106de57600080fd5b5061031e600480360360208110156106f557600080fd5b50356001600160a01b0316611384565b34801561071157600080fd5b506103f86004803603602081101561072857600080fd5b50356001600160a01b031661150a565b34801561074457600080fd5b50610421611528565b34801561075957600080fd5b506104216004803603602081101561077057600080fd5b50356001600160a01b031661152e565b34801561078c57600080fd5b5061031e611590565b3480156107a157600080fd5b50610421611620565b3480156107b657600080fd5b50610421611626565b3480156107cb57600080fd5b506103f8600480360360208110156107e257600080fd5b50356001600160a01b031661162c565b3480156107fe57600080fd5b5061044861164a565b34801561081357600080fd5b5061031e6004803603602081101561082a57600080fd5b5035611659565b34801561083d57600080fd5b506103356116b6565b34801561085257600080fd5b506103f86004803603604081101561086957600080fd5b506001600160a01b038135169060200135611717565b34801561088b57600080fd5b5061031e61177f565b3480156108a057600080fd5b506103f8600480360360408110156108b757600080fd5b506001600160a01b03813516906020013561186d565b3480156108d957600080fd5b5061031e600480360360208110156108f057600080fd5b5035611881565b34801561090357600080fd5b506104216118de565b34801561091857600080fd5b506104216118e4565b34801561092d57600080fd5b5061031e6004803603602081101561094457600080fd5b503515156118ea565b34801561095957600080fd5b5061031e6004803603602081101561097057600080fd5b5035611991565b34801561098357600080fd5b5061031e6119ee565b34801561099857600080fd5b5061031e600480360360408110156109af57600080fd5b506001600160a01b038135169060200135611a80565b3480156109d157600080fd5b5061031e600480360360208110156109e857600080fd5b5035611af3565b3480156109fb57600080fd5b5061031e60048036036020811015610a1257600080fd5b5035611b71565b348015610a2557600080fd5b5061042160048036036040811015610a3c57600080fd5b506001600160a01b0381358116916020013516611c0f565b348015610a6057600080fd5b50610448611c3a565b348015610a7557600080fd5b50610421611c49565b348015610a8a57600080fd5b5061031e60048036036020811015610aa157600080fd5b50356001600160a01b0316611c4f565b348015610abd57600080fd5b5061031e60048036036040811015610ad457600080fd5b506001600160a01b038135169060200135611cc8565b348015610af657600080fd5b5061031e60048036036020811015610b0d57600080fd5b50356001600160a01b0316611db5565b610b25611e9b565b6000546001600160a01b03908116911614610b75576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601155565b600e8054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c065780601f10610bdb57610100808354040283529160200191610c06565b820191906000526020600020905b815481529060010190602001808311610be957829003601f168201915b5050505050905090565b610c18611e9b565b6000546001600160a01b03908116911614610c68576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6019548015610d2f57601a805460ff19166001179055610c8781611e9f565b60095460405147916000916001600160a01b039091169083908381818185875af1925050503d8060008114610cd8576040519150601f19603f3d011682016040523d82523d6000602084013e610cdd565b606091505b5050905080610d1d5760405162461bcd60e51b815260040180806020018281038252603681526020018061334e6036913960400191505060405180910390fd5b50506000601955601a805460ff191690555b50565b6000610d46610d3f611e9b565b84846120b6565b5060015b92915050565b600c5490565b7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d81565b600a5490565b610d88611e9b565b6000546001600160a01b03908116911614610dd8576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b600980546001600160a01b0319166001600160a01b0392909216919091179055565b60175481565b6000610e0d8484846121a2565b610e7d84610e19611e9b565b610e78856040518060600160405280602881526020016132bd602891396001600160a01b038a16600090815260056020526040812090610e57611e9b565b6001600160a01b03168152602081019190915260400160002054919061247b565b6120b6565b5060019392505050565b6000600b54821115610eca5760405162461bcd60e51b815260040180806020018281038252602a815260200180613202602a913960400191505060405180910390fd5b6000610ed4612512565b9050610ee08382612535565b9150505b919050565b60105460ff1690565b610efa611e9b565b6000546001600160a01b03908116911614610f4a576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6001600160a01b03811660009081526007602052604090205460ff16610fb7576040805162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c756465640000000000604482015290519081900360640190fd5b60005b6008548110156110af57816001600160a01b031660088281548110610fdb57fe5b6000918252602090912001546001600160a01b031614156110a75760088054600019810190811061100857fe5b600091825260209091200154600880546001600160a01b03909216918390811061102e57fe5b600091825260208083209190910180546001600160a01b0319166001600160a01b039485161790559184168152600482526040808220829055600790925220805460ff19169055600880548061108057fe5b600082815260209020810160001990810180546001600160a01b03191690550190556110af565b600101610fba565b5050565b6000610d466110c0611e9b565b84610e7885600560006110d1611e9b565b6001600160a01b03908116825260208083019390935260409182016000908120918c16815292529020549061257e565b60115481565b6000611111611e9b565b6001600160a01b03811660009081526007602052604090205490915060ff161561116c5760405162461bcd60e51b815260040180806020018281038252602c8152602001806133cd602c913960400191505060405180910390fd5b6000611177836125d8565b505050506001600160a01b0384166000908152600360205260409020549192506111a391905082612627565b6001600160a01b038316600090815260036020526040902055600b546111c99082612627565b600b55600c546111d9908461257e565b600c55505050565b600d5490565b6111ef611e9b565b6000546001600160a01b0390811691161461123f576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6001600160a01b03166000908152600660205260409020805460ff19166001179055565b6000600a548311156112bc576040805162461bcd60e51b815260206004820152601f60248201527f416d6f756e74206d757374206265206c657373207468616e20737570706c7900604482015290519081900360640190fd5b816112db5760006112cc846125d8565b50939550610d4a945050505050565b60006112e6846125d8565b50929550610d4a945050505050565b6112fd611e9b565b6000546001600160a01b0390811691161461134d576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601755565b7f000000000000000000000000523906d7991c920d5a40690133c6c21b40f3f48181565b601a54610100900460ff1681565b61138c611e9b565b6000546001600160a01b039081169116146113dc576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6001600160a01b03811660009081526007602052604090205460ff161561144a576040805162461bcd60e51b815260206004820152601b60248201527f4163636f756e7420697320616c7265616479206578636c756465640000000000604482015290519081900360640190fd5b6001600160a01b038116600090815260036020526040902054156114a4576001600160a01b03811660009081526003602052604090205461148a90610e87565b6001600160a01b0382166000908152600460205260409020555b6001600160a01b03166000818152600760205260408120805460ff191660019081179091556008805491820181559091527ff3f7a9fe364faab93b216da50a3214154f22a0a2b415b23a84c8169e8b636ee30180546001600160a01b0319169091179055565b6001600160a01b031660009081526006602052604090205460ff1690565b60135481565b6001600160a01b03811660009081526007602052604081205460ff161561156e57506001600160a01b038116600090815260046020526040902054610ee4565b6001600160a01b038216600090815260036020526040902054610d4a90610e87565b611598611e9b565b6000546001600160a01b039081169116146115e8576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b600080546040516001600160a01b0390911690600080516020613305833981519152908390a3600080546001600160a01b0319169055565b601b5481565b60195481565b6001600160a01b031660009081526007602052604090205460ff1690565b6000546001600160a01b031690565b611661611e9b565b6000546001600160a01b039081169116146116b1576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601355565b600f8054604080516020601f6002600019610100600188161502019095169490940493840181900481028201810190925282815260609390929091830182828015610c065780601f10610bdb57610100808354040283529160200191610c06565b6000610d46611724611e9b565b84610e788560405180606001604052806025815260200161341c602591396005600061174e611e9b565b6001600160a01b03908116825260208083019390935260409182016000908120918d1681529252902054919061247b565b6001546001600160a01b031633146117c85760405162461bcd60e51b81526004018080602001828103825260238152602001806133f96023913960400191505060405180910390fd5b600254421161181e576040805162461bcd60e51b815260206004820152601f60248201527f436f6e7472616374206973206c6f636b656420756e74696c2037206461797300604482015290519081900360640190fd5b600154600080546040516001600160a01b03938416939091169160008051602061330583398151915291a3600154600080546001600160a01b0319166001600160a01b03909216919091179055565b6000610d4661187a611e9b565b84846121a2565b611889611e9b565b6000546001600160a01b039081169116146118d9576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601c55565b60025490565b60155481565b6118f2611e9b565b6000546001600160a01b03908116911614611942576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601a8054821515610100810261ff00199092169190911790915560408051918252517f53726dfcaf90650aa7eb35524f4d3220f07413c8d6cb404cc8c18bf5591bc1599181900360200190a150565b611999611e9b565b6000546001600160a01b039081169116146119e9576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b601555565b6119f6611e9b565b6000546001600160a01b03908116911614611a46576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6000601954611a543061152e565b0390508015610d2f57601a805460ff19166001179055611a7381612669565b601a805460ff1916905550565b611a88611e9b565b6000546001600160a01b03908116911614611ad8576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b611ae06126ef565b611aeb30838361274e565b6110af61288b565b611afb611e9b565b6000546001600160a01b03908116911614611b4b576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b611b6b6064611b6583600a546128a590919063ffffffff16565b90612535565b601b5550565b611b79611e9b565b6000546001600160a01b03908116911614611bc9576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b60008054600180546001600160a01b03199081166001600160a01b038416179091551681554282016002556040518190600080516020613305833981519152908290a350565b6001600160a01b03918216600090815260056020908152604080832093909416825291909152205490565b6009546001600160a01b031681565b601c5481565b611c57611e9b565b6000546001600160a01b03908116911614611ca7576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6001600160a01b03166000908152600660205260409020805460ff19169055565b611cd0611e9b565b6000546001600160a01b03908116911614611d20576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6040516000906001600160a01b0384169083908381818185875af1925050503d8060008114611d6b576040519150601f19603f3d011682016040523d82523d6000602084013e611d70565b606091505b5050905080611db05760405162461bcd60e51b815260040180806020018281038252603681526020018061334e6036913960400191505060405180910390fd5b505050565b611dbd611e9b565b6000546001600160a01b03908116911614611e0d576040805162461bcd60e51b815260206004820181905260248201526000805160206132e5833981519152604482015290519081900360640190fd5b6001600160a01b038116611e525760405162461bcd60e51b815260040180806020018281038252602681526020018061322c6026913960400191505060405180910390fd5b600080546040516001600160a01b038085169392169160008051602061330583398151915291a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b3390565b60408051600280825260608083018452926020830190803683370190505090503081600081518110611ecd57fe5b60200260200101906001600160a01b031690816001600160a01b0316815250507f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663ad5c46486040518163ffffffff1660e01b815260040160206040518083038186803b158015611f4657600080fd5b505afa158015611f5a573d6000803e3d6000fd5b505050506040513d6020811015611f7057600080fd5b5051815182906001908110611f8157fe5b60200260200101906001600160a01b031690816001600160a01b031681525050611fcc307f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d846120b6565b7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663791ac9478360008430426040518663ffffffff1660e01b81526004018086815260200185815260200180602001846001600160a01b03168152602001838152602001828103825285818151815260200191508051906020019060200280838360005b83811015612071578181015183820152602001612059565b505050509050019650505050505050600060405180830381600087803b15801561209a57600080fd5b505af11580156120ae573d6000803e3d6000fd5b505050505050565b6001600160a01b0383166120fb5760405162461bcd60e51b81526004018080602001828103825260248152602001806133a96024913960400191505060405180910390fd5b6001600160a01b0382166121405760405162461bcd60e51b81526004018080602001828103825260228152602001806132526022913960400191505060405180910390fd5b6001600160a01b03808416600081815260056020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b6001600160a01b0383166121e75760405162461bcd60e51b81526004018080602001828103825260258152602001806133846025913960400191505060405180910390fd5b6001600160a01b03821661222c5760405162461bcd60e51b81526004018080602001828103825260238152602001806131df6023913960400191505060405180910390fd5b6000811161226b5760405162461bcd60e51b81526004018080602001828103825260298152602001806133256029913960400191505060405180910390fd5b601a5460ff166123755761227d61164a565b6001600160a01b0316836001600160a01b0316141580156122b757506122a161164a565b6001600160a01b0316826001600160a01b031614155b801561232f57507f000000000000000000000000523906d7991c920d5a40690133c6c21b40f3f4816001600160a01b0316836001600160a01b0316148061232f57507f000000000000000000000000523906d7991c920d5a40690133c6c21b40f3f4816001600160a01b0316826001600160a01b0316145b1561237557601b548111156123755760405162461bcd60e51b81526004018080602001828103825260288152602001806132746028913960400191505060405180910390fd5b60006019546123833061152e565b0390506000601c5482101590508080156123a05750601a5460ff16155b80156123de57507f000000000000000000000000523906d7991c920d5a40690133c6c21b40f3f4816001600160a01b0316856001600160a01b031614155b80156123f15750601a54610100900460ff165b1561241f57601a805460ff1916600117905561240c82612669565b6124146128fe565b601a805460ff191690555b601a546001600160a01b03861660009081526006602052604090205460ff9182161591168061246657506001600160a01b03851660009081526006602052604090205460ff165b1561246f575060005b6120ae868686846129b0565b6000818484111561250a5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b838110156124cf5781810151838201526020016124b7565b50505050905090810190601f1680156124fc5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b505050900390565b600080600061251f612b24565b909250905061252e8282612535565b9250505090565b600061257783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612c87565b9392505050565b600082820183811015612577576040805162461bcd60e51b815260206004820152601b60248201527f536166654d6174683a206164646974696f6e206f766572666c6f770000000000604482015290519081900360640190fd5b60008060008060008060008060006125ef8a612cec565b925092509250600080600061260d8d8686612608612512565b612d50565b919f909e50909c50959a5093985091965092945050505050565b600061257783836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061247b565b6000612676826002612535565b905060006126848383612627565b90504761269083611e9f565b600061269c4783612627565b90506126a88382612dde565b604080518581526020810183905280820185905290517f17bbfb9a6069321b6ded73bd96327c9e6b7212a5cd51ff219cd61370acafb5619181900360600190a15050505050565b6011541580156126ff5750601354155b801561270b5750601554155b80156127175750601754155b156127215761274c565b6011805460125560138054601455601580546016556017805460185560009384905591839055829055555b565b600080600080600080612760876125d8565b6001600160a01b038f16600090815260036020526040902054959b509399509197509550935091506127929087612627565b6001600160a01b03808b1660009081526003602052604080822093909355908a16815220546127c1908661257e565b6001600160a01b0389166000908152600360205260408120919091556127e688612edc565b905060006127fc6127f5612512565b83906128a5565b905060006128098a612ef8565b905060006128186127f5612512565b9050612825858383612f14565b61283188878587612fc5565b8b6001600160a01b03168d6001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef896040518082815260200191505060405180910390a350505050505050505050505050565b601254601155601454601355601654601555601854601755565b6000826128b457506000610d4a565b828202828482816128c157fe5b04146125775760405162461bcd60e51b815260040180806020018281038252602181526020018061329c6021913960400191505060405180910390fd5b6019548015610d2f5761291081611e9f565b60095460405147916000916001600160a01b039091169083908381818185875af1925050503d8060008114612961576040519150601f19603f3d011682016040523d82523d6000602084013e612966565b606091505b50509050806129a65760405162461bcd60e51b815260040180806020018281038252603681526020018061334e6036913960400191505060405180910390fd5b5050600060195550565b806129bd576129bd6126ef565b6001600160a01b03841660009081526007602052604090205460ff1680156129fe57506001600160a01b03831660009081526007602052604090205460ff16155b15612a1357612a0e848484613017565b612b11565b6001600160a01b03841660009081526007602052604090205460ff16158015612a5457506001600160a01b03831660009081526007602052604090205460ff165b15612a6457612a0e84848461308a565b6001600160a01b03841660009081526007602052604090205460ff16158015612aa657506001600160a01b03831660009081526007602052604090205460ff16155b15612ab657612a0e84848461274e565b6001600160a01b03841660009081526007602052604090205460ff168015612af657506001600160a01b03831660009081526007602052604090205460ff165b15612b0657612a0e848484613133565b612b1184848461274e565b80612b1e57612b1e61288b565b50505050565b600b54600a546000918291825b600854811015612c5557826003600060088481548110612b4d57fe5b60009182526020808320909101546001600160a01b031683528201929092526040019020541180612bb25750816004600060088481548110612b8b57fe5b60009182526020808320909101546001600160a01b03168352820192909252604001902054115b15612bc957600b54600a5494509450505050612c83565b612c096003600060088481548110612bdd57fe5b60009182526020808320909101546001600160a01b031683528201929092526040019020548490612627565b9250612c4b6004600060088481548110612c1f57fe5b60009182526020808320909101546001600160a01b031683528201929092526040019020548390612627565b9150600101612b31565b50600a54600b54612c6591612535565b821015612c7d57600b54600a54935093505050612c83565b90925090505b9091565b60008183612cd65760405162461bcd60e51b81526020600482018181528351602484015283519092839260449091019190850190808383600083156124cf5781810151838201526020016124b7565b506000838581612ce257fe5b0495945050505050565b600080600080612cfb856131a6565b90506000612d08866131c2565b90506000612d1587612edc565b90506000612d2288612ef8565b90508181016000612d3f82612d3987818e8b612627565b90612627565b9a9599509397509395505050505050565b6000808080612d5f88866128a5565b90506000612d6d88876128a5565b90506000612d7b88886128a5565b90506000612d888b612edc565b90506000612d96828a6128a5565b90506000612da38d612ef8565b90506000612db1828c6128a5565b90506000612dc782612d3986818a818e8e612627565b979f979e50959c50959a5050505050505050505050565b612e09307f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d846120b6565b7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d6001600160a01b031663f305d719823085600080612e4661164a565b426040518863ffffffff1660e01b815260040180876001600160a01b03168152602001868152602001858152602001848152602001836001600160a01b0316815260200182815260200196505050505050506060604051808303818588803b158015612eb157600080fd5b505af1158015612ec5573d6000803e3d6000fd5b50505050506040513d6060811015612b1e57600080fd5b6000610d4a6064611b65601554856128a590919063ffffffff16565b6000610d4a6064611b65601754856128a590919063ffffffff16565b6000612f1e612512565b90506000612f2c85836128a5565b30600090815260036020526040902054909150612f55908490612f4f908461257e565b9061257e565b30600090815260036020526040902055601954612f72908561257e565b6019553060009081526007602052604090205460ff1615612fbe5730600090815260046020526040902054612fad908590612f4f908861257e565b306000908152600460205260409020555b5050505050565b612fde82612d3986600b5461262790919063ffffffff16565b600b55600c54612fee908461257e565b600c55600d54612ffe908261257e565b600d55600a5461300e9082612627565b600a5550505050565b600080600080600080613029876125d8565b6001600160a01b038f16600090815260046020526040902054959b5093995091975095509350915061305b9088612627565b6001600160a01b038a166000908152600460209081526040808320939093556003905220546127929087612627565b60008060008060008061309c876125d8565b6001600160a01b038f16600090815260036020526040902054959b509399509197509550935091506130ce9087612627565b6001600160a01b03808b16600090815260036020908152604080832094909455918b16815260049091522054613104908461257e565b6001600160a01b0389166000908152600460209081526040808320939093556003905220546127c1908661257e565b600080600080600080613145876125d8565b6001600160a01b038f16600090815260046020526040902054959b509399509197509550935091506131779088612627565b6001600160a01b038a166000908152600460209081526040808320939093556003905220546130ce9087612627565b6000610d4a6064611b65601154856128a590919063ffffffff16565b6000610d4a6064611b65601354856128a590919063ffffffff1656fe45524332303a207472616e7366657220746f20746865207a65726f2061646472657373416d6f756e74206d757374206265206c657373207468616e20746f74616c207265666c656374696f6e734f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f20616464726573735472616e7366657220616d6f756e74206578636565647320746865206d61785478416d6f756e742e536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7745524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e63654f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65728be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05472616e7366657220616d6f756e74206d7573742062652067726561746572207468616e207a65726f416464726573733a20756e61626c6520746f20657874726163742076616c75652c207478206d6179206861766520726576657274656445524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f20616464726573734578636c75646564206164647265737365732063616e6e6f742063616c6c20746869732066756e6374696f6e596f7520646f6e27742068617665207065726d697373696f6e20746f20756e6c6f636b45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa264697066735822122029731ea1630dfc802919b3a18f1beafbb4d907a4a877c69532d50f50344bab9864736f6c634300060c0033

Verified Source Code Partial Match

Compiler: v0.6.12+commit.27d51765 EVM: istanbul Optimization: Yes (200 runs)
GATSBY.sol 1115 lines
/**
 *Submitted for verification at Etherscan.io on 2022-10-19
*/

 

pragma solidity ^0.6.12;
// SPDX-License-Identifier: Unlicensed
interface IERC20 {

    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);
}



/**
 * @dev Wrappers over Solidity's arithmetic operations with added overflow
 * checks.
 *
 * Arithmetic operations in Solidity wrap on overflow. This can easily result
 * in bugs, because programmers usually assume that an overflow raises an
 * error, which is the standard behavior in high level programming languages.
 * `SafeMath` restores this intuition by reverting the transaction when an
 * operation overflows.
 *
 * Using this library instead of the unchecked operations eliminates an entire
 * class of bugs, so it's recommended to use it always.
 */
 
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;
    }
}

abstract contract Context {
    function _msgSender() internal view virtual returns (address payable) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes memory) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}


/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
        // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
        // for accounts without code, i.e. `keccak256('')`
        bytes32 codehash;
        bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
        // solhint-disable-next-line no-inline-assembly
        assembly { codehash := extcodehash(account) }
        return (codehash != accountHash && codehash != 0x0);
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (bool success, ) = recipient.call{ value: amount }("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain`call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
      return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {
        return _functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        return _functionCallWithValue(target, data, value, errorMessage);
    }

    function _functionCallWithValue(address target, bytes memory data, uint256 weiValue, string memory errorMessage) private returns (bytes memory) {
        require(isContract(target), "Address: call to non-contract");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.call{ value: weiValue }(data);
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
contract Ownable is Context {
    address private _owner;
    address private _previousOwner;
    uint256 private _lockTime;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor () internal {
        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;
    }

    function geUnlockTime() public view returns (uint256) {
        return _lockTime;
    }

    //Locks the contract for owner for the amount of time provided
    function lock(uint256 time) public virtual onlyOwner {
        _previousOwner = _owner;
        _owner = address(0);
        _lockTime = now + time;
        emit OwnershipTransferred(_owner, address(0));
    }
    
    //Unlocks the contract for owner when _lockTime is exceeds
    function unlock() public virtual {
        require(_previousOwner == msg.sender, "You don't have permission to unlock");
        require(now > _lockTime , "Contract is locked until 7 days");
        emit OwnershipTransferred(_owner, _previousOwner);
        _owner = _previousOwner;
    }
}


interface IUniswapV2Factory {
    function createPair(address tokenA, address tokenB) external returns (address pair);
}

interface IUniswapV2Router01 {
    function factory() external pure returns (address);
    function WETH() external pure returns (address);
    function addLiquidityETH(
        address token,
        uint amountTokenDesired,
        uint amountTokenMin,
        uint amountETHMin,
        address to,
        uint deadline
    ) external payable returns (uint amountToken, uint amountETH, uint liquidity);
}


interface IUniswapV2Router02 is IUniswapV2Router01 {
    function swapExactTokensForETHSupportingFeeOnTransferTokens(
        uint amountIn,
        uint amountOutMin,
        address[] calldata path,
        address to,
        uint deadline
    ) external;
}



contract GATSBY is Context, IERC20, Ownable {
    using SafeMath for uint256;
    using Address for address;

    mapping (address => uint256) private _rOwned;
    mapping (address => uint256) private _tOwned;
    mapping (address => mapping (address => uint256)) private _allowances;

    mapping (address => bool) private _isExcludedFromFee;

    mapping (address => bool) private _isExcluded;
    address[] private _excluded;
    
    address public marketingaddress = 0xC626b8502FF72AAa7385AAf4aa202B05225249b3;
 
    uint256 private constant MAX = ~uint256(0);
    uint256 private _tTotal = 1_000_000_000_000_000 * 10**18;
    uint256 private _rTotal = (MAX - (MAX % _tTotal));
    uint256 private _tFeeTotal;
    
    uint256 private _tBurnTotal;
    
    string private _name = "Gatsby Inu";
    string private _symbol = "GATSBY";
    uint8 private _decimals = 18;
    
    uint256 public _taxFee = 1;
    uint256 private _previousTaxFee = _taxFee;
    
    uint256 public _liquidityFee = 0;
    uint256 private _previousLiquidityFee = _liquidityFee;
    
    uint256 public _burnFee = 1;
    uint256 private _previousburnFee = _burnFee;

    uint256 public _marketingFee = 3;
    uint256 private _previousmarketingFee = _marketingFee;
    uint256 public _pendingMarketingFee;

    IUniswapV2Router02 public immutable uniswapV2Router;
    address public immutable uniswapV2Pair;
    
    bool inSwapAndLiquify;
    bool public swapAndLiquifyEnabled = true;
    
    uint256 public _maxTxAmount = 20_000_000_000_000 * 10**18;
    uint256 public swapTokensAtAmount = 5_000_000_000_000 * 10**18;
    
    event MinTokensBeforeSwapUpdated(uint256 minTokensBeforeSwap);
    event SwapAndLiquifyEnabledUpdated(bool enabled);
    event SwapAndLiquify(
        uint256 tokensSwapped,
        uint256 ethReceived,
        uint256 tokensIntoLiqudity
    );
    
    
    constructor () public 
      
      {
          
        _rOwned[_msgSender()] = _rTotal;
        
        IUniswapV2Router02 _uniswapV2Router = IUniswapV2Router02(0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D);
         // Create a uniswap pair for this new token
        uniswapV2Pair = IUniswapV2Factory(_uniswapV2Router.factory())
            .createPair(address(this), _uniswapV2Router.WETH());
                                              
        // set the rest of the contract variables
        uniswapV2Router = _uniswapV2Router;
        
        //exclude owner and this contract from fee
        _isExcludedFromFee[owner()] = true;
        _isExcludedFromFee[address(this)] = true;
        
        emit Transfer(address(0), _msgSender(), _tTotal);
    }

    function name() public view returns (string memory) {
        return _name;
    }

    function symbol() public view returns (string memory) {
        return _symbol;
    }

    function decimals() public view returns (uint8) {
        return _decimals;
    }

    function totalSupply() public view override returns (uint256) {
        return _tTotal;
    }

    function balanceOf(address account) public view override returns (uint256) {
        if (_isExcluded[account]) return _tOwned[account];
        return tokenFromReflection(_rOwned[account]);
    }

    function transfer(address recipient, uint256 amount) public override returns (bool) {
        _transfer(_msgSender(), recipient, amount);
        return true;
    }

    function allowance(address owner, address spender) public view override returns (uint256) {
        return _allowances[owner][spender];
    }

    function approve(address spender, uint256 amount) public override returns (bool) {
        _approve(_msgSender(), spender, amount);
        return true;
    }

    function transferFrom(address sender, address recipient, uint256 amount) public override returns (bool) {
        _transfer(sender, recipient, amount);
        _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "ERC20: transfer amount exceeds allowance"));
        return true;
    }

    function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) {
        _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));
        return true;
    }

    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;
    }

    function isExcludedFromReward(address account) public view returns (bool) {
        return _isExcluded[account];
    }

    function totalFees() public view returns (uint256) {
        return _tFeeTotal;
    }
    
    function totalBurn() public view returns (uint256) {
        return _tBurnTotal;
    }

    function deliver(uint256 tAmount) public {
        address sender = _msgSender();
        require(!_isExcluded[sender], "Excluded addresses cannot call this function");
        (uint256 rAmount,,,,,) = _getValues(tAmount);
        _rOwned[sender] = _rOwned[sender].sub(rAmount);
        _rTotal = _rTotal.sub(rAmount);
        _tFeeTotal = _tFeeTotal.add(tAmount);
    }

    function reflectionFromToken(uint256 tAmount, bool deductTransferFee) public view returns(uint256) {
        require(tAmount <= _tTotal, "Amount must be less than supply");
        if (!deductTransferFee) {
            (uint256 rAmount,,,,,) = _getValues(tAmount);
            return rAmount;
        } else {
            (,uint256 rTransferAmount,,,,) = _getValues(tAmount);
            return rTransferAmount;
        }
    }

    function tokenFromReflection(uint256 rAmount) public view returns(uint256) {
        require(rAmount <= _rTotal, "Amount must be less than total reflections");
        uint256 currentRate =  _getRate();
        return rAmount.div(currentRate);
    }

    function excludeFromReward(address account) public onlyOwner() {
        // require(account != 0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D, 'We can not exclude Uniswap router.');
        require(!_isExcluded[account], "Account is already excluded");
        if(_rOwned[account] > 0) {
            _tOwned[account] = tokenFromReflection(_rOwned[account]);
        }
        _isExcluded[account] = true;
        _excluded.push(account);
    }

    function includeInReward(address account) external onlyOwner() {
        require(_isExcluded[account], "Account is already excluded");
        for (uint256 i = 0; i < _excluded.length; i++) {
            if (_excluded[i] == account) {
                _excluded[i] = _excluded[_excluded.length - 1];
                _tOwned[account] = 0;
                _isExcluded[account] = false;
                _excluded.pop();
                break;
            }
        }
    }
        function _transferBothExcluded(address sender, address recipient, uint256 tAmount) private {
        (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount);
        _tOwned[sender] = _tOwned[sender].sub(tAmount);
        _rOwned[sender] = _rOwned[sender].sub(rAmount);
        _tOwned[recipient] = _tOwned[recipient].add(tTransferAmount);
        _rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);      
        
 
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 rburnfee = tburnFee.mul(_getRate());       
        
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        uint256 rmarketingfee = tmarketingFee.mul(_getRate());

        _takeLiquidityAndMarketingFee(tLiquidity, tmarketingFee, rmarketingfee);
        _reflectFee(rFee, tFee, rburnfee,tburnFee );
        emit Transfer(sender, recipient, tTransferAmount);
    }
    
        function excludeFromFee(address account) public onlyOwner {
        _isExcludedFromFee[account] = true;
    }
    
    function includeInFee(address account) public onlyOwner {
        _isExcludedFromFee[account] = false;
    }
    
    function setTaxFeePercent(uint256 taxFee) external onlyOwner() {
        _taxFee = taxFee;
    }
    
    function setLiquidityFeePercent(uint256 liquidityFee) external onlyOwner() {
        _liquidityFee = liquidityFee;
    }

     function setBurnFeePercent(uint256 burnfee) external onlyOwner() {
        _burnFee = burnfee;
    }

     function setMarketingFeePercent(uint256 marketingfee) external onlyOwner() {
        _marketingFee = marketingfee;
    }
   
    function setMaxTxPercent(uint256 maxTxPercent) external onlyOwner() {
        _maxTxAmount = _tTotal.mul(maxTxPercent).div(
            10**2
        );
    }

    function setSwapAndLiquifyEnabled(bool _enabled) public onlyOwner {
        swapAndLiquifyEnabled = _enabled;
        emit SwapAndLiquifyEnabledUpdated(_enabled);
    }
    
     //to recieve ETH from uniswapV2Router when swaping
    receive() external payable {}

    function _reflectFee(uint256 rFee, uint256 tFee, uint256 rBurn, uint256 tBurn ) private {
       _rTotal = _rTotal.sub(rFee).sub(rBurn);
        _tFeeTotal = _tFeeTotal.add(tFee);
        _tBurnTotal = _tBurnTotal.add(tBurn);
        _tTotal = _tTotal.sub(tBurn);
    }

    function _getValues(uint256 tAmount) private view returns (uint256, uint256, uint256, uint256, uint256, uint256) {
        (uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getTValues(tAmount);
        (uint256 rAmount, uint256 rTransferAmount, uint256 rFee) = _getRValues(tAmount, tFee, tLiquidity, _getRate());
        return (rAmount, rTransferAmount, rFee, tTransferAmount, tFee, tLiquidity);
    }

    function _getTValues(uint256 tAmount) private view returns (uint256, uint256, uint256) {
        uint256 tFee = calculateTaxFee(tAmount);
        uint256 tLiquidity = calculateLiquidityFee(tAmount);
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        
        uint256 extrafee = tburnFee + tmarketingFee;
        
        uint256 tTransferAmount = tAmount.sub(tFee).sub(tLiquidity).sub(extrafee);
        return (tTransferAmount, tFee, tLiquidity);
    }
    
    
    function _getRValues(uint256 tAmount, uint256 tFee, uint256 tLiquidity, uint256 currentRate) private view returns (uint256, uint256, uint256) {
        uint256 rAmount = tAmount.mul(currentRate);
        uint256 rFee = tFee.mul(currentRate);
        uint256 rLiquidity = tLiquidity.mul(currentRate);
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 rburnfee = tburnFee.mul(currentRate);
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        uint256 rmarketingfee = tmarketingFee.mul(currentRate);
        
        uint256 rTransferAmount = rAmount.sub(rFee).sub(rLiquidity).sub(rburnfee).sub(rmarketingfee);
        return (rAmount, rTransferAmount, rFee);
    }
    
    
    
    function _getRate() private view returns(uint256) {
        (uint256 rSupply, uint256 tSupply) = _getCurrentSupply();
        return rSupply.div(tSupply);
    }


    function _getCurrentSupply() private view returns(uint256, uint256) {
        uint256 rSupply = _rTotal;
        uint256 tSupply = _tTotal;      
        for (uint256 i = 0; i < _excluded.length; i++) {
            if (_rOwned[_excluded[i]] > rSupply || _tOwned[_excluded[i]] > tSupply) return (_rTotal, _tTotal);
            rSupply = rSupply.sub(_rOwned[_excluded[i]]);
            tSupply = tSupply.sub(_tOwned[_excluded[i]]);
        }
        if (rSupply < _rTotal.div(_tTotal)) return (_rTotal, _tTotal);
        return (rSupply, tSupply);
    }
    
    
    function _takeLiquidityAndMarketingFee(uint256 tLiquidity, uint256 tmarketing, uint rmarketing) private {
        uint256 currentRate =  _getRate();
        uint256 rLiquidity = tLiquidity.mul(currentRate);
        _rOwned[address(this)] = _rOwned[address(this)].add(rLiquidity).add(rmarketing);
        _pendingMarketingFee = _pendingMarketingFee.add(tmarketing);
        if(_isExcluded[address(this)])
            _tOwned[address(this)] = _tOwned[address(this)].add(tLiquidity).add(tmarketing);
    }
    
    function calculateTaxFee(uint256 _amount) private view returns (uint256) {
        return _amount.mul(_taxFee).div(
            10**2
        );
    }

    function calculateLiquidityFee(uint256 _amount) private view returns (uint256) {
        return _amount.mul(_liquidityFee).div(
            10**2
        );
    }
    
    function calculateBurnFee(uint256 _amount) private view returns (uint256) {
        return _amount.mul(_burnFee).div(
            10**2
        );
    }

    function calculateMarketingFee(uint256 _amount) private view returns (uint256) {
        return _amount.mul(_marketingFee).div(
            10**2
        );
    }
    
    function removeAllFee() private {
        if(_taxFee == 0 && _liquidityFee == 0 && _burnFee == 0 && _marketingFee == 0 ) return;
        
        _previousTaxFee = _taxFee;
        _previousLiquidityFee = _liquidityFee;
        _previousburnFee = _burnFee;
       _previousmarketingFee = _marketingFee;

        
        _taxFee = 0;
        _liquidityFee = 0;
        _burnFee = 0;
        _marketingFee = 0;
        
    }
    
    function restoreAllFee() private {
        _taxFee = _previousTaxFee;
        _liquidityFee = _previousLiquidityFee;
        _burnFee = _previousburnFee;
        _marketingFee = _previousmarketingFee;

    }
    
    function isExcludedFromFee(address account) public view returns(bool) {
        return _isExcludedFromFee[account];
    }

    function _approve(address owner, address spender, uint256 amount) private {
        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);
    }

    function _transfer(
        address from,
        address to,
        uint256 amount
    ) private {
        require(from != address(0), "ERC20: transfer from the zero address");
        require(to != address(0), "ERC20: transfer to the zero address");
        require(amount > 0, "Transfer amount must be greater than zero");
        
        if (!inSwapAndLiquify) {
            if(from != owner() && to != owner() && (from == uniswapV2Pair || to == uniswapV2Pair )) {
                require(amount <= _maxTxAmount, "Transfer amount exceeds the maxTxAmount.");
            }
        }    

        uint256 contractTokenBalanceforLP = balanceOf(address(this)) - _pendingMarketingFee;
                
        bool canSwap = contractTokenBalanceforLP >= swapTokensAtAmount;
        if (
            canSwap &&
            !inSwapAndLiquify &&
            from != uniswapV2Pair &&
            swapAndLiquifyEnabled
        ) {
            inSwapAndLiquify = true;
            //add liquidity
            swapAndLiquify(contractTokenBalanceforLP);
            // send markeing fee to marketing add
            swapAndSendMarketingFee();
            inSwapAndLiquify = false;
        }
        
        //indicates if fee should be deducted from transfer
        bool takeFee = !inSwapAndLiquify;
        
        //if any account belongs to _isExcludedFromFee account then remove the fee
        if(_isExcludedFromFee[from] || _isExcludedFromFee[to]){
            takeFee = false;
        }
        
        //transfer amount, it will take tax, burn, liquidity fee
        _tokenTransfer(from,to,amount,takeFee);
    }
    
  

    function swapAndLiquify(uint256 contractTokenBalance) private {
        // split the contract balance into halves                    //   100
        uint256 half = contractTokenBalance.div(2);                  //   50
        uint256 otherHalf = contractTokenBalance.sub(half);          //   50

        // capture the contract's current ETH balance.
        // this is so that we can capture exactly the amount of ETH that the
        // swap creates, and not make the liquidity event include any ETH that
        // has been manually sent to the contract
        uint256 initialBalance = address(this).balance;              //   bnb     

        // swap tokens for ETH
        swapTokensForEth(half); // <- this breaks the ETH -> HATE swap when swap+liquify is triggered

        // how much ETH did we just swap into?
        uint256 newBalance = address(this).balance.sub(initialBalance);

        // add liquidity to uniswap
        addLiquidity(otherHalf, newBalance);                      
        
        emit SwapAndLiquify(half, newBalance, otherHalf);
    }

    function swapOnDemand() external onlyOwner {
        uint256 contractTokenBalanceforlp = balanceOf(address(this)) - _pendingMarketingFee;
        if (contractTokenBalanceforlp>0) {
        inSwapAndLiquify = true;    
        swapAndLiquify(contractTokenBalanceforlp);
        inSwapAndLiquify = false;
        }  
    }

    function swapAndSendMarketingFee() private {
        uint pendingMarketingFee = _pendingMarketingFee;
        if (pendingMarketingFee > 0) 
        {
        swapTokensForEth(pendingMarketingFee);
        uint amount = address(this).balance;
        (bool success, ) = address(marketingaddress).call{ value: amount }("");
        require(success, "Address: unable to extract value, tx may have reverted");
        _pendingMarketingFee = 0;
        }
    }

    function claimMarketingFees() external onlyOwner {
        uint pendingMarketingFee = _pendingMarketingFee;
        if (pendingMarketingFee > 0) 
        {
        inSwapAndLiquify = true;    
        swapTokensForEth(pendingMarketingFee);
        uint amount = address(this).balance;
        (bool success, ) = address(marketingaddress).call{ value: amount }("");
        require(success, "Address: unable to extract value, tx may have reverted");
        _pendingMarketingFee = 0;
        inSwapAndLiquify = false;    
        }
    }


    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 addLiquidity(uint256 tokenAmount, uint256 ethAmount) private {
        // approve token transfer to cover all possible scenarios
        _approve(address(this), address(uniswapV2Router), tokenAmount);

        // add the liquidity
        uniswapV2Router.addLiquidityETH{value: ethAmount}(
            address(this),
            tokenAmount,
            0, // slippage is unavoidable
            0, // slippage is unavoidable
            owner(),
            block.timestamp
        );
    }

    //this method is responsible for taking all fee, if takeFee is true
    function _tokenTransfer(address sender, address recipient, uint256 amount,bool takeFee) private {
        if(!takeFee)
            removeAllFee();
        
        if (_isExcluded[sender] && !_isExcluded[recipient]) {
            _transferFromExcluded(sender, recipient, amount);
        } else if (!_isExcluded[sender] && _isExcluded[recipient]) {
            _transferToExcluded(sender, recipient, amount);
        } else if (!_isExcluded[sender] && !_isExcluded[recipient]) {
            _transferStandard(sender, recipient, amount);
        } else if (_isExcluded[sender] && _isExcluded[recipient]) {
            _transferBothExcluded(sender, recipient, amount);
        } else {
            _transferStandard(sender, recipient, amount);
        }
        
        if(!takeFee)
            restoreAllFee();
    }

    function _transferStandard(address sender, address recipient, uint256 tAmount) private {
        (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount);
        _rOwned[sender] = _rOwned[sender].sub(rAmount);
        _rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);
        
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 rburnfee = tburnFee.mul(_getRate());
       
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        uint256 rmarketingfee = tmarketingFee.mul(_getRate());
    
        _takeLiquidityAndMarketingFee(tLiquidity, tmarketingFee, rmarketingfee);
        _reflectFee(rFee, tFee, rburnfee,tburnFee );
        
        emit Transfer(sender, recipient, tTransferAmount);
    }
    
    
    
    function _transferToExcluded(address sender, address recipient, uint256 tAmount) private {
        (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount);
        _rOwned[sender] = _rOwned[sender].sub(rAmount);
        _tOwned[recipient] = _tOwned[recipient].add(tTransferAmount);
        _rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);    
        
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 rburnfee = tburnFee.mul(_getRate());
        
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        uint256 rmarketingfee = tmarketingFee.mul(_getRate());
        
        _takeLiquidityAndMarketingFee(tLiquidity, tmarketingFee, rmarketingfee);
        _reflectFee(rFee, tFee, rburnfee,tburnFee );
        emit Transfer(sender, recipient, tTransferAmount);
    }
    
    
    

    function _transferFromExcluded(address sender, address recipient, uint256 tAmount) private {
        (uint256 rAmount, uint256 rTransferAmount, uint256 rFee, uint256 tTransferAmount, uint256 tFee, uint256 tLiquidity) = _getValues(tAmount);
        _tOwned[sender] = _tOwned[sender].sub(tAmount);
        _rOwned[sender] = _rOwned[sender].sub(rAmount);
        _rOwned[recipient] = _rOwned[recipient].add(rTransferAmount);   
        
        uint256 tburnFee = calculateBurnFee(tAmount);
        uint256 rburnfee = tburnFee.mul(_getRate());
        
        uint256 tmarketingFee = calculateMarketingFee(tAmount);
        uint256 rmarketingfee = tmarketingFee.mul(_getRate());
        
        _takeLiquidityAndMarketingFee(tLiquidity, tmarketingFee, rmarketingfee);
        _reflectFee(rFee, tFee, rburnfee,tburnFee );
        emit Transfer(sender, recipient, tTransferAmount);
    }
    
    
    function changemarketingwallet(address _newaddress) public onlyOwner {
        marketingaddress = _newaddress; 
    }

    function setSwapTokensAtAmount(uint256 amount) external onlyOwner{
        swapTokensAtAmount = amount;
    }
    
    
    function migrateToken(address _newadress , uint256 _amount) public onlyOwner {
        removeAllFee();
        _transferStandard(address(this), _newadress, _amount);
        restoreAllFee();
    }


    function migrateGasToken(address payable _newadd,uint256 amount) public onlyOwner {
        (bool success, ) = address(_newadd).call{ value: amount }("");
        require(success, "Address: unable to extract value, tx may have reverted");    
    }   
}

Read Contract

_burnFee 0xc0b0fda2 → uint256
_liquidityFee 0x6bc87c3a → uint256
_marketingFee 0x22976e0d → uint256
_maxTxAmount 0x7d1db4a5 → uint256
_pendingMarketingFee 0x84c00ef0 → uint256
_taxFee 0x3b124fe7 → uint256
allowance 0xdd62ed3e → uint256
balanceOf 0x70a08231 → uint256
decimals 0x313ce567 → uint8
geUnlockTime 0xb6c52324 → uint256
isExcludedFromFee 0x5342acb4 → bool
isExcludedFromReward 0x88f82020 → bool
marketingaddress 0xe0f07e3a → address
name 0x06fdde03 → string
owner 0x8da5cb5b → address
reflectionFromToken 0x4549b039 → uint256
swapAndLiquifyEnabled 0x4a74bb02 → bool
swapTokensAtAmount 0xe2f45605 → uint256
symbol 0x95d89b41 → string
tokenFromReflection 0x2d838119 → uint256
totalBurn 0x3c9f861d → uint256
totalFees 0x13114a9d → uint256
totalSupply 0x18160ddd → uint256
uniswapV2Pair 0x49bd5a5e → address
uniswapV2Router 0x1694505e → address

Write Contract 26 functions

These functions modify contract state and require a wallet transaction to execute.

approve 0x095ea7b3
address spender
uint256 amount
returns: bool
changemarketingwallet 0x1c1d9747
address _newaddress
claimMarketingFees 0x07dce0f8
No parameters
decreaseAllowance 0xa457c2d7
address spender
uint256 subtractedValue
returns: bool
deliver 0x3bd5d173
uint256 tAmount
excludeFromFee 0x437823ec
address account
excludeFromReward 0x52390c02
address account
includeInFee 0xea2f0b37
address account
includeInReward 0x3685d419
address account
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
lock 0xdd467064
uint256 time
migrateGasToken 0xf19ae793
address _newadd
uint256 amount
migrateToken 0xd4ed7b3f
address _newadress
uint256 _amount
renounceOwnership 0x715018a6
No parameters
setBurnFeePercent 0xcea26958
uint256 burnfee
setLiquidityFeePercent 0x8ee88c53
uint256 liquidityFee
setMarketingFeePercent 0x457c194c
uint256 marketingfee
setMaxTxPercent 0xd543dbeb
uint256 maxTxPercent
setSwapAndLiquifyEnabled 0xc49b9a80
bool _enabled
setSwapTokensAtAmount 0xafa4f3b2
uint256 amount
setTaxFeePercent 0x061c82d0
uint256 taxFee
swapOnDemand 0xd1a1f318
No parameters
transfer 0xa9059cbb
address recipient
uint256 amount
returns: bool
transferFrom 0x23b872dd
address sender
address recipient
uint256 amount
returns: bool
transferOwnership 0xf2fde38b
address newOwner
unlock 0xa69df4b5
No parameters

Recent Transactions

No transactions found for this address