Cryo Explorer Ethereum Mainnet

Address Contract Partially Verified

Address 0x0305f515fa978cf87226cf8A9776D25bcfb2Cc0B
Balance 1.4919 ETH
Nonce 1
Code Size 13647 bytes
Indexed Transactions 0
External Etherscan · Sourcify

Contract Bytecode

13647 bytes
0x6080604052600436106101855760003560e01c8063995b5aae116100d1578063d08893581161008a578063efdcd97411610064578063efdcd974146105a6578063f242ab41146105cf578063f2fde38b146105fa578063ffb54a99146106235761018c565b8063d088935814610502578063dd62ed3e1461052b578063e13b2007146105685761018c565b8063995b5aae146103ee5780639a7a23d61461041b578063a457c2d714610444578063a9059cbb14610481578063ae7ed567146104be578063c9567bf9146104eb5761018c565b8063313ce5671161013e578063715018a611610118578063715018a6146103585780638b4cee081461036f5780638da5cb5b1461039857806395d89b41146103c35761018c565b8063313ce567146102b357806339509351146102de57806370a082311461031b5761018c565b806306fdde0314610191578063095ea7b3146101bc5780630cc835a3146101f957806318160ddd14610222578063226036611461024d57806323b872dd146102765761018c565b3661018c57005b600080fd5b34801561019d57600080fd5b506101a661064e565b6040516101b39190612585565b60405180910390f35b3480156101c857600080fd5b506101e360048036038101906101de9190612640565b6106e0565b6040516101f0919061269b565b60405180910390f35b34801561020557600080fd5b50610220600480360381019061021b91906126b6565b6106fe565b005b34801561022e57600080fd5b50610237610804565b60405161024491906126f2565b60405180910390f35b34801561025957600080fd5b50610274600480360381019061026f9190612739565b61080e565b005b34801561028257600080fd5b5061029d60048036038101906102989190612779565b610933565b6040516102aa919061269b565b60405180910390f35b3480156102bf57600080fd5b506102c8610a2b565b6040516102d591906127e8565b60405180910390f35b3480156102ea57600080fd5b5061030560048036038101906103009190612640565b610a34565b604051610312919061269b565b60405180910390f35b34801561032757600080fd5b50610342600480360381019061033d9190612803565b610ae0565b60405161034f91906126f2565b60405180910390f35b34801561036457600080fd5b5061036d610b28565b005b34801561037b57600080fd5b50610396600480360381019061039191906126b6565b610bb0565b005b3480156103a457600080fd5b506103ad610cb6565b6040516103ba919061283f565b60405180910390f35b3480156103cf57600080fd5b506103d8610ce0565b6040516103e59190612585565b60405180910390f35b3480156103fa57600080fd5b50610403610d72565b6040516104129392919061285a565b60405180910390f35b34801561042757600080fd5b50610442600480360381019061043d9190612739565b610dab565b005b34801561045057600080fd5b5061046b60048036038101906104669190612640565b610ec3565b604051610478919061269b565b60405180910390f35b34801561048d57600080fd5b506104a860048036038101906104a39190612640565b610fae565b6040516104b5919061269b565b60405180910390f35b3480156104ca57600080fd5b506104d3610fcc565b6040516104e293929190612891565b60405180910390f35b3480156104f757600080fd5b50610500610ff2565b005b34801561050e57600080fd5b50610529600480360381019061052491906128c8565b6110d2565b005b34801561053757600080fd5b50610552600480360381019061054d919061291b565b61127d565b60405161055f91906126f2565b60405180910390f35b34801561057457600080fd5b5061058f600480360381019061058a9190612803565b611304565b60405161059d92919061295b565b60405180910390f35b3480156105b257600080fd5b506105cd60048036038101906105c89190612803565b6113aa565b005b3480156105db57600080fd5b506105e46114e6565b6040516105f1919061283f565b60405180910390f35b34801561060657600080fd5b50610621600480360381019061061c9190612803565b61150a565b005b34801561062f57600080fd5b50610638611601565b604051610645919061269b565b60405180910390f35b60606003805461065d906129b3565b80601f0160208091040260200160405190810160405280929190818152602001828054610689906129b3565b80156106d65780601f106106ab576101008083540402835291602001916106d6565b820191906000526020600020905b8154815290600101906020018083116106b957829003601f168201915b5050505050905090565b60006106f46106ed611614565b848461161c565b6001905092915050565b610706611614565b73ffffffffffffffffffffffffffffffffffffffff16610724610cb6565b73ffffffffffffffffffffffffffffffffffffffff161461077a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161077190612a30565b60405180910390fd5b6009548111156107bf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b690612ac2565b60405180910390fd5b7f28e297c7c282931a994191b735b01eaf17558295f761512a7047f4e1b8dc3b0b816009546040516107f2929190612ae2565b60405180910390a18060098190555050565b6000600254905090565b610816611614565b73ffffffffffffffffffffffffffffffffffffffff16610834610cb6565b73ffffffffffffffffffffffffffffffffffffffff161461088a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161088190612a30565b60405180910390fd5b80600b60008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff167f9d8f7706ea1113d1a167b526eca956215946dd36cc7df39eb16180222d8b5df782604051610927919061269b565b60405180910390a25050565b60006109408484846117e5565b6000600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600061098b611614565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905082811015610a0b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a0290612b7d565b60405180910390fd5b610a1f85610a17611614565b85840361161c565b60019150509392505050565b60006012905090565b6000610ad6610a41611614565b848460016000610a4f611614565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ad19190612bcc565b61161c565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610b30611614565b73ffffffffffffffffffffffffffffffffffffffff16610b4e610cb6565b73ffffffffffffffffffffffffffffffffffffffff1614610ba4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b9b90612a30565b60405180910390fd5b610bae6000611e68565b565b610bb8611614565b73ffffffffffffffffffffffffffffffffffffffff16610bd6610cb6565b73ffffffffffffffffffffffffffffffffffffffff1614610c2c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c2390612a30565b60405180910390fd5b600a54811115610c71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c6890612ac2565b60405180910390fd5b7f5bafec153d96f8ef37761b64348732b41a6b477401d244a5070f9f82d689adce81600a54604051610ca4929190612ae2565b60405180910390a180600a8190555050565b6000600560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060048054610cef906129b3565b80601f0160208091040260200160405190810160405280929190818152602001828054610d1b906129b3565b8015610d685780601f10610d3d57610100808354040283529160200191610d68565b820191906000526020600020905b815481529060010190602001808311610d4b57829003601f168201915b5050505050905090565b60008060006009549250600a549150600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050909192565b610db3611614565b73ffffffffffffffffffffffffffffffffffffffff16610dd1610cb6565b73ffffffffffffffffffffffffffffffffffffffff1614610e27576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e1e90612a30565b60405180910390fd5b7f00000000000000000000000061bc0e018a1332107f5d7f730fa39f703e24688173ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1603610eb5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610eac90612c72565b60405180910390fd5b610ebf8282611f2e565b5050565b60008060016000610ed2611614565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905082811015610f8f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f8690612d04565b60405180910390fd5b610fa3610f9a611614565b8585840361161c565b600191505092915050565b6000610fc2610fbb611614565b84846117e5565b6001905092915050565b6000806000600560169054906101000a900460ff16925060065491506007549050909192565b610ffa611614565b73ffffffffffffffffffffffffffffffffffffffff16611018610cb6565b73ffffffffffffffffffffffffffffffffffffffff161461106e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161106590612a30565b60405180910390fd5b6001600560146101000a81548160ff0219169083151502179055506001600560166101000a81548160ff0219169083151502179055507f799663458a5ef2936f7fa0c99b3336c69c25890f82974f04e811e5bb359186c760405160405180910390a1565b6110da611614565b73ffffffffffffffffffffffffffffffffffffffff166110f8610cb6565b73ffffffffffffffffffffffffffffffffffffffff161461114e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161114590612a30565b60405180910390fd5b6001821015611192576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161118990612d96565b60405180910390fd5b818110156111d5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016111cc90612e28565b60405180910390fd5b82600560166101000a81548160ff021916908315150217905550620186a0826111fc610804565b6112069190612e48565b6112109190612eb9565b600681905550620186a081611223610804565b61122d9190612e48565b6112379190612eb9565b6007819055507f52cd2cdb42ff0eeec9362d7ed5b04f64c8d022697128b5378fc51cea7e63c77983838360405161127093929190612891565b60405180910390a1505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600080600b60008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169150600c60008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff169050915091565b6113b2611614565b73ffffffffffffffffffffffffffffffffffffffff166113d0610cb6565b73ffffffffffffffffffffffffffffffffffffffff1614611426576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161141d90612a30565b60405180910390fd5b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f94223efa5e0ef633fcdce676def839a7ea220f7f45a1c693a4540846bc1ee14d60405160405180910390a380600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b7f00000000000000000000000061bc0e018a1332107f5d7f730fa39f703e24688181565b611512611614565b73ffffffffffffffffffffffffffffffffffffffff16611530610cb6565b73ffffffffffffffffffffffffffffffffffffffff1614611586576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161157d90612a30565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16036115f5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016115ec90612f5c565b60405180910390fd5b6115fe81611e68565b50565b600560149054906101000a900460ff1681565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361168b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161168290612fee565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036116fa576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016116f190613080565b60405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040516117d891906126f2565b60405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1603611854576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161184b90613112565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036118c3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016118ba906131a4565b60405180910390fd5b600081036118dc576118d783836000611fcf565b611e63565b6118e4610cb6565b73ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141580156119525750611922610cb6565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b801561198b5750600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b80156119c5575061dead73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b80156119de5750600560159054906101000a900460ff16155b15611ad957600560149054906101000a900460ff16611ad857600b60008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1680611a985750600b60008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b611ad7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611ace90613236565b60405180910390fd5b5b5b6000611ae430610ae0565b905060006006548210159050808015611b095750600560169054906101000a900460ff165b8015611b225750600560159054906101000a900460ff16155b8015611b785750600c60008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16155b8015611bce5750600b60008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16155b8015611c245750600b60008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16155b15611c68576001600560156101000a81548160ff021916908315150217905550611c4c61224e565b6000600560156101000a81548160ff0219169083151502179055505b6000600560159054906101000a900460ff16159050600b60008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff1680611d1e5750600b60008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff165b15611d2857600090505b60008115611e5357600c60008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff168015611d8b57506000600a54115b15611db1576064600a5486611da09190612e48565b611daa9190612eb9565b9050611e2f565b600c60008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff168015611e0c57506000600954115b15611e2e57606460095486611e219190612e48565b611e2b9190612eb9565b90505b5b6000811115611e4457611e43873083611fcf565b5b8085611e509190613256565b94505b611e5e878787611fcf565b505050505b505050565b6000600560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600560006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b80600c60008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508015158273ffffffffffffffffffffffffffffffffffffffff167fffa9187bf1f18bf477bd0ea1bcbb64e93b6a98132473929edfce215cd9b16fab60405160405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff160361203e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161203590613112565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036120ad576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016120a4906131a4565b60405180910390fd5b6120b883838361228c565b60008060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205490508181101561213e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401612135906132fc565b60405180910390fd5b8181036000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282546121d19190612bcc565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8460405161223591906126f2565b60405180910390a3612248848484612291565b50505050565b600061225930610ae0565b905060008103612269575061228a565b6007548111156122795760075490505b600081905061228781612296565b50505b565b505050565b505050565b6000600267ffffffffffffffff8111156122b3576122b261331c565b5b6040519080825280602002602001820160405280156122e15781602001602082028036833780820191505090505b50905030816000815181106122f9576122f861334b565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250507f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d73ffffffffffffffffffffffffffffffffffffffff1663ad5c46486040518163ffffffff1660e01b8152600401602060405180830381865afa15801561239e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123c2919061338f565b816001815181106123d6576123d561334b565b5b602002602001019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff168152505061243b307f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d8461161c565b7f0000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488d73ffffffffffffffffffffffffffffffffffffffff1663791ac94783600084600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16426040518663ffffffff1660e01b81526004016124bf9594939291906134bf565b600060405180830381600087803b1580156124d957600080fd5b505af11580156124ed573d6000803e3d6000fd5b505050505050565b600081519050919050565b600082825260208201905092915050565b60005b8381101561252f578082015181840152602081019050612514565b60008484015250505050565b6000601f19601f8301169050919050565b6000612557826124f5565b6125618185612500565b9350612571818560208601612511565b61257a8161253b565b840191505092915050565b6000602082019050818103600083015261259f818461254c565b905092915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006125d7826125ac565b9050919050565b6125e7816125cc565b81146125f257600080fd5b50565b600081359050612604816125de565b92915050565b6000819050919050565b61261d8161260a565b811461262857600080fd5b50565b60008135905061263a81612614565b92915050565b60008060408385031215612657576126566125a7565b5b6000612665858286016125f5565b92505060206126768582860161262b565b9150509250929050565b60008115159050919050565b61269581612680565b82525050565b60006020820190506126b0600083018461268c565b92915050565b6000602082840312156126cc576126cb6125a7565b5b60006126da8482850161262b565b91505092915050565b6126ec8161260a565b82525050565b600060208201905061270760008301846126e3565b92915050565b61271681612680565b811461272157600080fd5b50565b6000813590506127338161270d565b92915050565b600080604083850312156127505761274f6125a7565b5b600061275e858286016125f5565b925050602061276f85828601612724565b9150509250929050565b600080600060608486031215612792576127916125a7565b5b60006127a0868287016125f5565b93505060206127b1868287016125f5565b92505060406127c28682870161262b565b9150509250925092565b600060ff82169050919050565b6127e2816127cc565b82525050565b60006020820190506127fd60008301846127d9565b92915050565b600060208284031215612819576128186125a7565b5b6000612827848285016125f5565b91505092915050565b612839816125cc565b82525050565b60006020820190506128546000830184612830565b92915050565b600060608201905061286f60008301866126e3565b61287c60208301856126e3565b6128896040830184612830565b949350505050565b60006060820190506128a6600083018661268c565b6128b360208301856126e3565b6128c060408301846126e3565b949350505050565b6000806000606084860312156128e1576128e06125a7565b5b60006128ef86828701612724565b93505060206129008682870161262b565b92505060406129118682870161262b565b9150509250925092565b60008060408385031215612932576129316125a7565b5b6000612940858286016125f5565b9250506020612951858286016125f5565b9150509250929050565b6000604082019050612970600083018561268c565b61297d602083018461268c565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b600060028204905060018216806129cb57607f821691505b6020821081036129de576129dd612984565b5b50919050565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b6000612a1a602083612500565b9150612a25826129e4565b602082019050919050565b60006020820190508181036000830152612a4981612a0d565b9050919050565b7f4e6577206665652068617320746f206265206c6f776572207468616e2074686560008201527f2063757272656e74206665650000000000000000000000000000000000000000602082015250565b6000612aac602c83612500565b9150612ab782612a50565b604082019050919050565b60006020820190508181036000830152612adb81612a9f565b9050919050565b6000604082019050612af760008301856126e3565b612b0460208301846126e3565b9392505050565b7f45524332303a207472616e7366657220616d6f756e742065786365656473206160008201527f6c6c6f77616e6365000000000000000000000000000000000000000000000000602082015250565b6000612b67602883612500565b9150612b7282612b0b565b604082019050919050565b60006020820190508181036000830152612b9681612b5a565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000612bd78261260a565b9150612be28361260a565b9250828201905080821115612bfa57612bf9612b9d565b5b92915050565b7f54686520706169722063616e6e6f742062652072656d6f7665642066726f6d2060008201527f6175746f6d617465644d61726b65744d616b6572506169727300000000000000602082015250565b6000612c5c603983612500565b9150612c6782612c00565b604082019050919050565b60006020820190508181036000830152612c8b81612c4f565b9050919050565b7f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760008201527f207a65726f000000000000000000000000000000000000000000000000000000602082015250565b6000612cee602583612500565b9150612cf982612c92565b604082019050919050565b60006020820190508181036000830152612d1d81612ce1565b9050919050565b7f5377617020616d6f756e742063616e6e6f74206265206c6f776572207468616e60008201527f20302e3030312520746f74616c20737570706c792e0000000000000000000000602082015250565b6000612d80603583612500565b9150612d8b82612d24565b604082019050919050565b60006020820190508181036000830152612daf81612d73565b9050919050565b7f6d6178696d756d20616d6f756e742063616e742062652068696768657220746860008201527f616e206d696e696d756d00000000000000000000000000000000000000000000602082015250565b6000612e12602a83612500565b9150612e1d82612db6565b604082019050919050565b60006020820190508181036000830152612e4181612e05565b9050919050565b6000612e538261260a565b9150612e5e8361260a565b9250828202612e6c8161260a565b91508282048414831517612e8357612e82612b9d565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000612ec48261260a565b9150612ecf8361260a565b925082612edf57612ede612e8a565b5b828204905092915050565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b6000612f46602683612500565b9150612f5182612eea565b604082019050919050565b60006020820190508181036000830152612f7581612f39565b9050919050565b7f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b6000612fd8602483612500565b9150612fe382612f7c565b604082019050919050565b6000602082019050818103600083015261300781612fcb565b9050919050565b7f45524332303a20617070726f766520746f20746865207a65726f20616464726560008201527f7373000000000000000000000000000000000000000000000000000000000000602082015250565b600061306a602283612500565b91506130758261300e565b604082019050919050565b600060208201905081810360008301526130998161305d565b9050919050565b7f45524332303a207472616e736665722066726f6d20746865207a65726f20616460008201527f6472657373000000000000000000000000000000000000000000000000000000602082015250565b60006130fc602583612500565b9150613107826130a0565b604082019050919050565b6000602082019050818103600083015261312b816130ef565b9050919050565b7f45524332303a207472616e7366657220746f20746865207a65726f206164647260008201527f6573730000000000000000000000000000000000000000000000000000000000602082015250565b600061318e602383612500565b915061319982613132565b604082019050919050565b600060208201905081810360008301526131bd81613181565b9050919050565b7f5f7472616e736665723a3a2054726164696e67206973206e6f7420616374697660008201527f652e000000000000000000000000000000000000000000000000000000000000602082015250565b6000613220602283612500565b915061322b826131c4565b604082019050919050565b6000602082019050818103600083015261324f81613213565b9050919050565b60006132618261260a565b915061326c8361260a565b925082820390508181111561328457613283612b9d565b5b92915050565b7f45524332303a207472616e7366657220616d6f756e742065786365656473206260008201527f616c616e63650000000000000000000000000000000000000000000000000000602082015250565b60006132e6602683612500565b91506132f18261328a565b604082019050919050565b60006020820190508181036000830152613315816132d9565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600081519050613389816125de565b92915050565b6000602082840312156133a5576133a46125a7565b5b60006133b38482850161337a565b91505092915050565b6000819050919050565b6000819050919050565b60006133eb6133e66133e1846133bc565b6133c6565b61260a565b9050919050565b6133fb816133d0565b82525050565b600081519050919050565b600082825260208201905092915050565b6000819050602082019050919050565b613436816125cc565b82525050565b6000613448838361342d565b60208301905092915050565b6000602082019050919050565b600061346c82613401565b613476818561340c565b93506134818361341d565b8060005b838110156134b2578151613499888261343c565b97506134a483613454565b925050600181019050613485565b5085935050505092915050565b600060a0820190506134d460008301886126e3565b6134e160208301876133f2565b81810360408301526134f38186613461565b90506135026060830185612830565b61350f60808301846126e3565b969550505050505056fea264697066735822122090a44015638900c79c9c68d6bb82ca66ef4e59ba843e078039422b904521654364736f6c63430008130033

Verified Source Code Partial Match

Compiler: v0.8.19+commit.7dd6d404 EVM: paris Optimization: No
PEPE20.sol 981 lines
/*
 * SPDX-License-Identifier: MIT
 * https://t.me/Pepe2Portal
 * https://pepe20.vip/
 * https://twitter.com/pepe2coineth
 */

pragma solidity 0.8.19;

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

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

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

contract ERC20 is Context, IERC20, IERC20Metadata {
    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 18;
    }

    /**
     * @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 upd 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);

        uint256 currentAllowance = _allowances[sender][_msgSender()];
        require(
            currentAllowance >= amount,
            "ERC20: transfer amount exceeds allowance"
        );
        unchecked {
            _approve(sender, _msgSender(), currentAllowance - amount);
        }

        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 upd allowance.
     *
     * Requirements:
     *
     * - `spender` cannot be the zero address.
     */
    function increaseAllowance(
        address spender,
        uint256 addedValue
    ) public virtual returns (bool) {
        _approve(
            _msgSender(),
            spender,
            _allowances[_msgSender()][spender] + 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 upd 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) {
        uint256 currentAllowance = _allowances[_msgSender()][spender];
        require(
            currentAllowance >= subtractedValue,
            "ERC20: decreased allowance below zero"
        );
        unchecked {
            _approve(_msgSender(), spender, currentAllowance - subtractedValue);
        }

        return true;
    }

    /**
     * @dev Moves `amount` of tokens from `sender` to `recipient`.
     *
     * This 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);

        uint256 senderBalance = _balances[sender];
        require(
            senderBalance >= amount,
            "ERC20: transfer amount exceeds balance"
        );
        unchecked {
            _balances[sender] = senderBalance - amount;
        }
        _balances[recipient] += amount;

        emit Transfer(sender, recipient, amount);

        _afterTokenTransfer(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 += amount;
        _balances[account] += amount;
        emit Transfer(address(0), account, amount);

        _afterTokenTransfer(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);

        uint256 accountBalance = _balances[account];
        require(accountBalance >= amount, "ERC20: burn amount exceeds balance");
        unchecked {
            _balances[account] = accountBalance - amount;
        }
        _totalSupply -= amount;

        emit Transfer(account, address(0), amount);

        _afterTokenTransfer(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 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 {}

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens
     * has been transferred to `to`.
     * - when `from` is zero, `amount` tokens have been minted for `to`.
     * - when `to` is zero, `amount` of ``from``'s tokens have been 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 _afterTokenTransfer(
        address from,
        address to,
        uint256 amount
    ) internal virtual {}
}

abstract 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() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual 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 {
        _transferOwnership(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"
        );
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

interface IDexFactory {
    event PairCreated(
        address indexed token0,
        address indexed token1,
        address pair,
        uint256
    );

    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(uint256) external view returns (address pair);

    function allPairsLength() external view returns (uint256);

    function createPair(
        address tokenA,
        address tokenB
    ) external returns (address pair);

    function setFeeTo(address) external;

    function setFeeToSetter(address) external;
}

interface IDexRouter {
    function factory() external pure returns (address);

    function WETH() external pure returns (address);

    function addLiquidity(
        address tokenA,
        address tokenB,
        uint256 amountADesired,
        uint256 amountBDesired,
        uint256 amountAMin,
        uint256 amountBMin,
        address to,
        uint256 deadline
    ) external returns (uint256 amountA, uint256 amountB, uint256 liquidity);

    function addLiquidityETH(
        address token,
        uint256 amountTokenDesired,
        uint256 amountTokenMin,
        uint256 amountETHMin,
        address to,
        uint256 deadline
    )
        external
        payable
        returns (uint256 amountToken, uint256 amountETH, uint256 liquidity);

    function swapExactTokensForTokensSupportingFeeOnTransferTokens(
        uint256 amountIn,
        uint256 amountOutMin,
        address[] calldata path,
        address to,
        uint256 deadline
    ) external;

    function swapExactETHForTokensSupportingFeeOnTransferTokens(
        uint256 amountOutMin,
        address[] calldata path,
        address to,
        uint256 deadline
    ) external payable;

    function swapExactTokensForETHSupportingFeeOnTransferTokens(
        uint256 amountIn,
        uint256 amountOutMin,
        address[] calldata path,
        address to,
        uint256 deadline
    ) external;
}

contract PEPE20 is ERC20, Ownable {
    IDexRouter private immutable dexRouter;
    address public immutable dexPair;

    bool public tradingOpen = false;

    // Swapback
    bool private swapping;
    bool private swapbackEnabled = false;
    uint256 private swapBackValueMin;
    uint256 private swapBackValueMax;

    // Fees
    address private feeReceiver;

    uint256 private buyFee;
    uint256 private sellFee;

    /******************/

    mapping(address => bool) private isFeeExempt;
    mapping(address => bool) private automatedMarketMakerPairs;

    // store addresses that a automatic market maker pairs. Any transfer *to* these addresses
    // could be subject to a maximum transfer amount

    event TradingEnabled();
    event ExcludeFromFees(address indexed account, bool isExcluded);
    event SetAutomatedMarketMakerPair(address indexed pair, bool indexed value);
    event BuyFeeUpdated(uint256 newFee, uint256 oldFee);
    event SellFeeUpdated(uint256 newFee, uint256 oldFee);

    event SwapbackSettingsUpdated(
        bool enabled,
        uint256 swapBackValueMin,
        uint256 swapBackValueMax
    );

    event feeReceiverUpdated(
        address indexed newWallet,
        address indexed oldWallet
    );

    constructor() ERC20("Pepe 2.0", "PEPE2.0") {
        IDexRouter _dexRouter = IDexRouter(
            0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D
        );

        dexRouter = _dexRouter;

        dexPair = IDexFactory(_dexRouter.factory()).createPair(
            address(this),
            _dexRouter.WETH()
        );
        _setAutomatedMarketMakerPair(address(dexPair), true);

        uint256 _buyFee = 5;
        uint256 _sellFee = 5;

        uint256 totalSupply = 469_000_000_000_000 * 10 ** decimals();

        swapBackValueMin = (totalSupply * 1) / 1000;
        swapBackValueMax = (totalSupply * 1) / 100;

        buyFee = _buyFee;
        sellFee = _sellFee;
        feeReceiver = address(0xb45facF73FEa542Db61D12A2eb3141Ec1Db79664);

        // exclude from paying fees or having max transaction amount
        excludeFromTaxes(msg.sender, true);
        excludeFromTaxes(address(this), true);
        excludeFromTaxes(address(0xdead), true);
        excludeFromTaxes(feeReceiver, true);

        transferOwnership(msg.sender);

        /*
            _mint is an internal function in ERC20.sol that is only called here,
            and CANNOT be called ever again
        */
        _mint(msg.sender, totalSupply);
    }

    receive() external payable {}

    /**
     * @notice  Opens public trading for the token
     * @dev     onlyOwner.
     */
    function openTrading() external onlyOwner {
        tradingOpen = true;
        swapbackEnabled = true;
        emit TradingEnabled();
    }

    /**
     * @notice sets if swapback is enabled and sets the minimum and maximum amounts
     * @dev onlyOwner.
     * Emits an {SwapbackSettingsUpdated} event
     * @param _enabled If swapback is enabled
     * @param _min The minimum amount of tokens the contract must have before swapping tokens for ETH. Base 100000, so 1% = 1000.
     * @param _max The maximum amount of tokens the contract can swap for ETH. Base 100000, so 1% = 1000.
     */
    function setSwapBackSettings(
        bool _enabled,
        uint256 _min,
        uint256 _max
    ) external onlyOwner {
        require(
            _min >= 1,
            "Swap amount cannot be lower than 0.001% total supply."
        );
        require(_max >= _min, "maximum amount cant be higher than minimum");

        swapbackEnabled = _enabled;
        swapBackValueMin = (totalSupply() * _min) / 100000;
        swapBackValueMax = (totalSupply() * _max) / 100000;
        emit SwapbackSettingsUpdated(_enabled, _min, _max);
    }

    /**
     * @notice Sets the fees for buys
     * @dev onlyOwner.
     * Emits a {BuyFeeUpdated} event
     * @param _newFee The fee for the marketing wallet. Has to be lower than the current fee
     */
    function setBuyFee(uint256 _newFee) external onlyOwner {
        require(
            _newFee <= buyFee,
            "New fee has to be lower than the current fee"
        );
        emit BuyFeeUpdated(_newFee, buyFee);
        buyFee = _newFee;
    }

    /**
     * @notice Sets the fees for sells
     * @dev onlyOwner.
     * Emits a {SellFeeUpdated} event
     * @param _newFee The fee for the marketing wallet. Has to be lower than the current fee
     */
    function setSellFee(uint256 _newFee) external onlyOwner {
        require(
            _newFee <= sellFee,
            "New fee has to be lower than the current fee"
        );
        emit SellFeeUpdated(_newFee, sellFee);
        sellFee = _newFee;
    }

    /**
     * @notice Sets if an address is excluded from fees
     * @dev onlyOwner.
     * Emits an {ExcludeFromFees} event
     * @param account The wallet to update
     * @param excluded If the wallet is excluded or not
     */
    function excludeFromTaxes(address account, bool excluded) public onlyOwner {
        isFeeExempt[account] = excluded;
        emit ExcludeFromFees(account, excluded);
    }

    /**
     * @notice Sets an address as a new liquidity pair. You probably dont want to do this.
     * @dev onlyOwner.
     * Emits a {SetAutomatedMarketMakerPair} event
     * @param pair the address of the pair
     * @param value If the pair is a automated market maker pair or not
     */
    function setAutomatedMarketMakerPair(
        address pair,
        bool value
    ) public onlyOwner {
        require(
            pair != dexPair,
            "The pair cannot be removed from automatedMarketMakerPairs"
        );

        _setAutomatedMarketMakerPair(pair, value);
    }

    /**
     * @notice Sets the marketing wallet
     * @dev onlyOwner.
     * Emits an {feeReceiverUpdated} event
     * @param newWallet The new marketing wallet
     */
    function setFeeReceiver(address newWallet) external onlyOwner {
        emit feeReceiverUpdated(newWallet, feeReceiver);
        feeReceiver = newWallet;
    }

    /**
     * @notice  Information about the swapback settings
     * @return  _swapbackEnabled  if swapback is enabled
     * @return  _swapBackValueMin  the minimum amount of tokens in the contract balance to trigger swapback
     * @return  _swapBackValueMax  the maximum amount of tokens in the contract balance to trigger swapback
     */
    function swapbackInfo()
        external
        view
        returns (
            bool _swapbackEnabled,
            uint256 _swapBackValueMin,
            uint256 _swapBackValueMax
        )
    {
        _swapbackEnabled = swapbackEnabled;
        _swapBackValueMin = swapBackValueMin;
        _swapBackValueMax = swapBackValueMax;
    }

    /**
     * @notice Fees for buys, sells, and transfers
     * @return _buyFee The total fee for buys
     * @return _sellFee The total fee for sells
     * @return _feeReceiver The address that receives the fees
     */
    function feeInfo()
        external
        view
        returns (uint256 _buyFee, uint256 _sellFee, address _feeReceiver)
    {
        _buyFee = buyFee;
        _sellFee = sellFee;
        _feeReceiver = feeReceiver;
    }

    /**
     * @notice  If the wallet is excluded from fees and max transaction amount and if the wallet is a automated market maker pair
     * @param   _target  The wallet to check
     * @return  _isFeeExempt  If the wallet is excluded from fees
     * @return  _automatedMarketMakerPairs If the wallet is a automated market maker pair
     */
    function checkMappings(
        address _target
    )
        external
        view
        returns (bool _isFeeExempt, bool _automatedMarketMakerPairs)
    {
        _isFeeExempt = isFeeExempt[_target];
        _automatedMarketMakerPairs = automatedMarketMakerPairs[_target];
    }

    function _setAutomatedMarketMakerPair(address pair, bool value) private {
        automatedMarketMakerPairs[pair] = value;

        emit SetAutomatedMarketMakerPair(pair, value);
    }

    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 (
            from != owner() &&
            to != owner() &&
            to != address(0) &&
            to != address(0xdead) &&
            !swapping
        ) {
            if (!tradingOpen) {
                require(
                    isFeeExempt[from] || isFeeExempt[to],
                    "_transfer:: Trading is not active."
                );
            }
        }

        uint256 contractTokenBalance = balanceOf(address(this));

        bool canSwap = contractTokenBalance >= swapBackValueMin;

        if (
            canSwap &&
            swapbackEnabled &&
            !swapping &&
            !automatedMarketMakerPairs[from] &&
            !isFeeExempt[from] &&
            !isFeeExempt[to]
        ) {
            swapping = true;

            swapBack();

            swapping = false;
        }

        bool takeFee = !swapping;

        // if any account belongs to _isExcludedFromFee account then remove the fee
        if (isFeeExempt[from] || isFeeExempt[to]) {
            takeFee = false;
        }

        uint256 fees = 0;
        // only take fees on buys/sells, do not take on wallet transfers
        if (takeFee) {
            // on sell
            if (automatedMarketMakerPairs[to] && sellFee > 0) {
                fees = (amount * sellFee) / (100);
            }
            // on buy
            else if (automatedMarketMakerPairs[from] && buyFee > 0) {
                fees = (amount * buyFee) / (100);
            }

            if (fees > 0) {
                super._transfer(from, address(this), fees);
            }

            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] = dexRouter.WETH();

        _approve(address(this), address(dexRouter), tokenAmount);

        // make the swap
        dexRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(
            tokenAmount,
            0, // accept any amount of ETH
            path,
            feeReceiver,
            block.timestamp
        );
    }

    function swapBack() private {
        uint256 contractBalance = balanceOf(address(this));
        if (contractBalance == 0) {
            return;
        }

        if (contractBalance > swapBackValueMax) {
            contractBalance = swapBackValueMax;
        }

        uint256 amountToSwapForETH = contractBalance;

        swapTokensForEth(amountToSwapForETH);
    }
}

Read Contract

allowance 0xdd62ed3e → uint256
balanceOf 0x70a08231 → uint256
checkMappings 0xe13b2007 → bool, bool
decimals 0x313ce567 → uint8
dexPair 0xf242ab41 → address
feeInfo 0x995b5aae → uint256, uint256, address
name 0x06fdde03 → string
owner 0x8da5cb5b → address
swapbackInfo 0xae7ed567 → bool, uint256, uint256
symbol 0x95d89b41 → string
totalSupply 0x18160ddd → uint256
tradingOpen 0xffb54a99 → bool

Write Contract 14 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
excludeFromTaxes 0x22603661
address account
bool excluded
increaseAllowance 0x39509351
address spender
uint256 addedValue
returns: bool
openTrading 0xc9567bf9
No parameters
renounceOwnership 0x715018a6
No parameters
setAutomatedMarketMakerPair 0x9a7a23d6
address pair
bool value
setBuyFee 0x0cc835a3
uint256 _newFee
setFeeReceiver 0xefdcd974
address newWallet
setSellFee 0x8b4cee08
uint256 _newFee
setSwapBackSettings 0xd0889358
bool _enabled
uint256 _min
uint256 _max
transfer 0xa9059cbb
address recipient
uint256 amount
returns: bool
transferFrom 0x23b872dd
address sender
address recipient
uint256 amount
returns: bool
transferOwnership 0xf2fde38b
address newOwner

Token Balances (1)

View Transfers →
WETH 0

Recent Transactions

No transactions found for this address