Address Contract Verified
Address
0xe93AAb5779e706c73DAf8Bf849bb8E46Fb183691
Balance
0 ETH
Nonce
1
Code Size
14195 bytes
Creator
0xcC2E70f7...9FF4 at tx 0xd58a835c...c43e67
Indexed Transactions
0
Contract Bytecode
14195 bytes
0x608060405234801561001057600080fd5b50600436106101a95760003560e01c80636c0360eb116100f9578063af1806af11610097578063c87b56dd11610071578063c87b56dd14610494578063e985e9c5146104c4578063f247fdc7146104f4578063f2fde38b14610512576101a9565b8063af1806af14610440578063b88d4fde1461045c578063c2ca0ac514610478576101a9565b80637d94792a116100d35780637d94792a146103ca5780638da5cb5b146103e857806395d89b4114610406578063a22cb46514610424576101a9565b80636c0360eb1461037257806370a0823114610390578063715018a6146103c0576101a9565b806323b872dd11610166578063518302271161014057806351830227146102ec57806355f804b31461030a5780636352211e146103265780636a62784214610356576101a9565b806323b872dd1461029657806332cb6b0c146102b257806342842e0e146102d0576101a9565b806301ffc9a7146101ae57806306fdde03146101de578063081812fc146101fc578063095ea7b31461022c5780630ef7cc8e1461024857806318160ddd14610278575b600080fd5b6101c860048036038101906101c391906125af565b61052e565b6040516101d59190612a96565b60405180910390f35b6101e6610610565b6040516101f39190612ab1565b60405180910390f35b61021660048036038101906102119190612652565b6106a2565b6040516102239190612a2f565b60405180910390f35b6102466004803603810190610241919061256f565b610727565b005b610262600480360381019061025d9190612652565b61083f565b60405161026f9190612ab1565b60405180910390f35b610280610a3e565b60405161028d9190612d53565b60405180910390f35b6102b060048036038101906102ab9190612459565b610a44565b005b6102ba610aa4565b6040516102c79190612d53565b60405180910390f35b6102ea60048036038101906102e59190612459565b610aaa565b005b6102f4610aca565b6040516103019190612a96565b60405180910390f35b610324600480360381019061031f9190612609565b610add565b005b610340600480360381019061033b9190612652565b610baa565b60405161034d9190612a2f565b60405180910390f35b610370600480360381019061036b91906123ec565b610c5c565b005b61037a610d98565b6040516103879190612ab1565b60405180910390f35b6103aa60048036038101906103a591906123ec565b610e26565b6040516103b79190612d53565b60405180910390f35b6103c8610ede565b005b6103d2610f66565b6040516103df9190612d53565b60405180910390f35b6103f0610f6c565b6040516103fd9190612a2f565b60405180910390f35b61040e610f96565b60405161041b9190612ab1565b60405180910390f35b61043e6004803603810190610439919061252f565b611028565b005b61045a600480360381019061045591906123ec565b6111a9565b005b610476600480360381019061047191906124ac565b6112a0565b005b610492600480360381019061048d9190612652565b611302565b005b6104ae60048036038101906104a99190612652565b61140a565b6040516104bb9190612ab1565b60405180910390f35b6104de60048036038101906104d99190612419565b6114eb565b6040516104eb9190612a96565b60405180910390f35b6104fc61157f565b6040516105099190612a2f565b60405180910390f35b61052c600480360381019061052791906123ec565b6115a5565b005b60007f80ac58cd000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806105f957507f5b5e139f000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b8061060957506106088261169d565b5b9050919050565b60606000805461061f90612fd2565b80601f016020809104026020016040519081016040528092919081815260200182805461064b90612fd2565b80156106985780601f1061066d57610100808354040283529160200191610698565b820191906000526020600020905b81548152906001019060200180831161067b57829003601f168201915b5050505050905090565b60006106ad82611707565b6106ec576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016106e390612c53565b60405180910390fd5b6004600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b600061073282610baa565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156107a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161079a90612cd3565b60405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166107c2611773565b73ffffffffffffffffffffffffffffffffffffffff1614806107f157506107f0816107eb611773565b6114eb565b5b610830576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161082790612bb3565b60405180910390fd5b61083a838361177b565b505050565b60606008548210610885576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161087c90612b73565b60405180910390fd5b6000600a5414156108a757604051806020016040528060008152509050610a39565b60006122b867ffffffffffffffff8111156108c5576108c461316b565b5b6040519080825280602002602001820160405280156108f35781602001602082028036833780820191505090505b5090506000600a54905060005b6122b881101561093d578083828151811061091e5761091d61313c565b5b602002602001018181525050808061093590613035565b915050610900565b5060005b6122b8811015610a105760006122b88383604051602001610963929190612d6e565b6040516020818303038152906040528051906020012060001c610986919061307e565b905083818151811061099b5761099a61313c565b5b60200260200101518483815181106109b6576109b561313c565b5b60200260200101518584815181106109d1576109d061313c565b5b602002602001018684815181106109eb576109ea61313c565b5b6020026020010182815250828152505050508080610a0890613035565b915050610941565b50610a34828581518110610a2757610a2661313c565b5b6020026020010151611834565b925050505b919050565b60085481565b610a55610a4f611773565b82611995565b610a94576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a8b90612d13565b60405180910390fd5b610a9f838383611a73565b505050565b6122b881565b610ac5838383604051806020016040528060008152506112a0565b505050565b600960149054906101000a900460ff1681565b610ae5611773565b73ffffffffffffffffffffffffffffffffffffffff16610b03610f6c565b73ffffffffffffffffffffffffffffffffffffffff1614610b59576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b5090612c73565b60405180910390fd5b8060079080519060200190610b6f929190612200565b507f23c8c9488efebfd474e85a7956de6f39b17c7ab88502d42a623db2d8e382bbaa81604051610b9f9190612ab1565b60405180910390a150565b6000806002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610c53576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610c4a90612bf3565b60405180910390fd5b80915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161480610cea57503373ffffffffffffffffffffffffffffffffffffffff16610cd2610f6c565b73ffffffffffffffffffffffffffffffffffffffff16145b610d29576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d2090612d33565b60405180910390fd5b6122b860085410610d6f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d6690612c13565b60405180910390fd5b610d7b81600854611ccf565b600160086000828254610d8e9190612e61565b9250508190555050565b60078054610da590612fd2565b80601f0160208091040260200160405190810160405280929190818152602001828054610dd190612fd2565b8015610e1e5780601f10610df357610100808354040283529160200191610e1e565b820191906000526020600020905b815481529060010190602001808311610e0157829003601f168201915b505050505081565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610e97576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e8e90612bd3565b60405180910390fd5b600360008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b610ee6611773565b73ffffffffffffffffffffffffffffffffffffffff16610f04610f6c565b73ffffffffffffffffffffffffffffffffffffffff1614610f5a576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f5190612c73565b60405180910390fd5b610f646000611e9d565b565b600a5481565b6000600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b606060018054610fa590612fd2565b80601f0160208091040260200160405190810160405280929190818152602001828054610fd190612fd2565b801561101e5780601f10610ff35761010080835404028352916020019161101e565b820191906000526020600020905b81548152906001019060200180831161100157829003601f168201915b5050505050905090565b611030611773565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561109e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161109590612b53565b60405180910390fd5b80600560006110ab611773565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff16611158611773565b73ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c318360405161119d9190612a96565b60405180910390a35050565b6111b1611773565b73ffffffffffffffffffffffffffffffffffffffff166111cf610f6c565b73ffffffffffffffffffffffffffffffffffffffff1614611225576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161121c90612c73565b60405180910390fd5b80600960006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055507f76241367af61e976681523def49e6278fe161b836a982a53ce0cd224e8212c0f816040516112959190612a2f565b60405180910390a150565b6112b16112ab611773565b83611995565b6112f0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016112e790612d13565b60405180910390fd5b6112fc84848484611f63565b50505050565b61130a611773565b73ffffffffffffffffffffffffffffffffffffffff16611328610f6c565b73ffffffffffffffffffffffffffffffffffffffff161461137e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161137590612c73565b60405180910390fd5b600960149054906101000a900460ff16156113ce576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016113c590612cf3565b60405180910390fd5b60008111156113e35780600a819055506113ec565b6001600a819055505b6001600960146101000a81548160ff02191690831515021790555050565b606061141582611707565b611454576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161144b90612cb3565b60405180910390fd5b600061145e611fbf565b9050600960149054906101000a900460ff166114b8576000600584611483919061307e565b90508161148f82611834565b6040516020016114a0929190612a0b565b604051602081830303815290604052925050506114e6565b806114c28461083f565b6040516020016114d3929190612a0b565b6040516020818303038152906040529150505b919050565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6115ad611773565b73ffffffffffffffffffffffffffffffffffffffff166115cb610f6c565b73ffffffffffffffffffffffffffffffffffffffff1614611621576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161161890612c73565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415611691576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161168890612af3565b60405180910390fd5b61169a81611e9d565b50565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916827bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149050919050565b60008073ffffffffffffffffffffffffffffffffffffffff166002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614159050919050565b600033905090565b816004600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff166117ee83610baa565b73ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6060600082141561187c576040518060400160405280600181526020017f30000000000000000000000000000000000000000000000000000000000000008152509050611990565b600082905060005b600082146118ae57808061189790613035565b915050600a826118a79190612eb7565b9150611884565b60008167ffffffffffffffff8111156118ca576118c961316b565b5b6040519080825280601f01601f1916602001820160405280156118fc5781602001600182028036833780820191505090505b5090505b60008514611989576001826119159190612ee8565b9150600a85611924919061307e565b60306119309190612e61565b60f81b8183815181106119465761194561313c565b5b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a856119829190612eb7565b9450611900565b8093505050505b919050565b60006119a082611707565b6119df576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016119d690612b93565b60405180910390fd5b60006119ea83610baa565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161480611a5957508373ffffffffffffffffffffffffffffffffffffffff16611a41846106a2565b73ffffffffffffffffffffffffffffffffffffffff16145b80611a6a5750611a6981856114eb565b5b91505092915050565b8273ffffffffffffffffffffffffffffffffffffffff16611a9382610baa565b73ffffffffffffffffffffffffffffffffffffffff1614611ae9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611ae090612c93565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611b59576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b5090612b33565b60405180910390fd5b611b64838383612051565b611b6f60008261177b565b6001600360008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254611bbf9190612ee8565b925050819055506001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254611c169190612e61565b92505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4505050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611d3f576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d3690612c33565b60405180910390fd5b611d4881611707565b15611d88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d7f90612b13565b60405180910390fd5b611d9460008383612051565b6001600360008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000828254611de49190612e61565b92505081905550816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45050565b6000600660009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905081600660006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508173ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b611f6e848484611a73565b611f7a84848484612056565b611fb9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611fb090612ad3565b60405180910390fd5b50505050565b606060078054611fce90612fd2565b80601f0160208091040260200160405190810160405280929190818152602001828054611ffa90612fd2565b80156120475780601f1061201c57610100808354040283529160200191612047565b820191906000526020600020905b81548152906001019060200180831161202a57829003601f168201915b5050505050905090565b505050565b60006120778473ffffffffffffffffffffffffffffffffffffffff166121ed565b156121e0578373ffffffffffffffffffffffffffffffffffffffff1663150b7a026120a0611773565b8786866040518563ffffffff1660e01b81526004016120c29493929190612a4a565b602060405180830381600087803b1580156120dc57600080fd5b505af192505050801561210d57506040513d601f19601f8201168201806040525081019061210a91906125dc565b60015b612190573d806000811461213d576040519150601f19603f3d011682016040523d82523d6000602084013e612142565b606091505b50600081511415612188576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161217f90612ad3565b60405180910390fd5b805181602001fd5b63150b7a0260e01b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150506121e5565b600190505b949350505050565b600080823b905060008111915050919050565b82805461220c90612fd2565b90600052602060002090601f01602090048101928261222e5760008555612275565b82601f1061224757805160ff1916838001178555612275565b82800160010185558215612275579182015b82811115612274578251825591602001919060010190612259565b5b5090506122829190612286565b5090565b5b8082111561229f576000816000905550600101612287565b5090565b60006122b66122b184612dbc565b612d97565b9050828152602081018484840111156122d2576122d161319f565b5b6122dd848285612f90565b509392505050565b60006122f86122f384612ded565b612d97565b9050828152602081018484840111156123145761231361319f565b5b61231f848285612f90565b509392505050565b600081359050612336816136e1565b92915050565b60008135905061234b816136f8565b92915050565b6000813590506123608161370f565b92915050565b6000815190506123758161370f565b92915050565b600082601f8301126123905761238f61319a565b5b81356123a08482602086016122a3565b91505092915050565b600082601f8301126123be576123bd61319a565b5b81356123ce8482602086016122e5565b91505092915050565b6000813590506123e681613726565b92915050565b600060208284031215612402576124016131a9565b5b600061241084828501612327565b91505092915050565b600080604083850312156124305761242f6131a9565b5b600061243e85828601612327565b925050602061244f85828601612327565b9150509250929050565b600080600060608486031215612472576124716131a9565b5b600061248086828701612327565b935050602061249186828701612327565b92505060406124a2868287016123d7565b9150509250925092565b600080600080608085870312156124c6576124c56131a9565b5b60006124d487828801612327565b94505060206124e587828801612327565b93505060406124f6878288016123d7565b925050606085013567ffffffffffffffff811115612517576125166131a4565b5b6125238782880161237b565b91505092959194509250565b60008060408385031215612546576125456131a9565b5b600061255485828601612327565b92505060206125658582860161233c565b9150509250929050565b60008060408385031215612586576125856131a9565b5b600061259485828601612327565b92505060206125a5858286016123d7565b9150509250929050565b6000602082840312156125c5576125c46131a9565b5b60006125d384828501612351565b91505092915050565b6000602082840312156125f2576125f16131a9565b5b600061260084828501612366565b91505092915050565b60006020828403121561261f5761261e6131a9565b5b600082013567ffffffffffffffff81111561263d5761263c6131a4565b5b612649848285016123a9565b91505092915050565b600060208284031215612668576126676131a9565b5b6000612676848285016123d7565b91505092915050565b61268881612f1c565b82525050565b61269781612f2e565b82525050565b60006126a882612e1e565b6126b28185612e34565b93506126c2818560208601612f9f565b6126cb816131ae565b840191505092915050565b60006126e182612e29565b6126eb8185612e45565b93506126fb818560208601612f9f565b612704816131ae565b840191505092915050565b600061271a82612e29565b6127248185612e56565b9350612734818560208601612f9f565b80840191505092915050565b600061274d603283612e45565b9150612758826131bf565b604082019050919050565b6000612770602683612e45565b915061277b8261320e565b604082019050919050565b6000612793601c83612e45565b915061279e8261325d565b602082019050919050565b60006127b6602483612e45565b91506127c182613286565b604082019050919050565b60006127d9601983612e45565b91506127e4826132d5565b602082019050919050565b60006127fc601083612e45565b9150612807826132fe565b602082019050919050565b600061281f602c83612e45565b915061282a82613327565b604082019050919050565b6000612842603883612e45565b915061284d82613376565b604082019050919050565b6000612865602a83612e45565b9150612870826133c5565b604082019050919050565b6000612888602983612e45565b915061289382613414565b604082019050919050565b60006128ab601283612e45565b91506128b682613463565b602082019050919050565b60006128ce602083612e45565b91506128d98261348c565b602082019050919050565b60006128f1602c83612e45565b91506128fc826134b5565b604082019050919050565b6000612914602083612e45565b915061291f82613504565b602082019050919050565b6000612937602983612e45565b91506129428261352d565b604082019050919050565b600061295a602f83612e45565b91506129658261357c565b604082019050919050565b600061297d602183612e45565b9150612988826135cb565b604082019050919050565b60006129a0601b83612e45565b91506129ab8261361a565b602082019050919050565b60006129c3603183612e45565b91506129ce82613643565b604082019050919050565b60006129e6602b83612e45565b91506129f182613692565b604082019050919050565b612a0581612f86565b82525050565b6000612a17828561270f565b9150612a23828461270f565b91508190509392505050565b6000602082019050612a44600083018461267f565b92915050565b6000608082019050612a5f600083018761267f565b612a6c602083018661267f565b612a7960408301856129fc565b8181036060830152612a8b818461269d565b905095945050505050565b6000602082019050612aab600083018461268e565b92915050565b60006020820190508181036000830152612acb81846126d6565b905092915050565b60006020820190508181036000830152612aec81612740565b9050919050565b60006020820190508181036000830152612b0c81612763565b9050919050565b60006020820190508181036000830152612b2c81612786565b9050919050565b60006020820190508181036000830152612b4c816127a9565b9050919050565b60006020820190508181036000830152612b6c816127cc565b9050919050565b60006020820190508181036000830152612b8c816127ef565b9050919050565b60006020820190508181036000830152612bac81612812565b9050919050565b60006020820190508181036000830152612bcc81612835565b9050919050565b60006020820190508181036000830152612bec81612858565b9050919050565b60006020820190508181036000830152612c0c8161287b565b9050919050565b60006020820190508181036000830152612c2c8161289e565b9050919050565b60006020820190508181036000830152612c4c816128c1565b9050919050565b60006020820190508181036000830152612c6c816128e4565b9050919050565b60006020820190508181036000830152612c8c81612907565b9050919050565b60006020820190508181036000830152612cac8161292a565b9050919050565b60006020820190508181036000830152612ccc8161294d565b9050919050565b60006020820190508181036000830152612cec81612970565b9050919050565b60006020820190508181036000830152612d0c81612993565b9050919050565b60006020820190508181036000830152612d2c816129b6565b9050919050565b60006020820190508181036000830152612d4c816129d9565b9050919050565b6000602082019050612d6860008301846129fc565b92915050565b6000604082019050612d8360008301856129fc565b612d9060208301846129fc565b9392505050565b6000612da1612db2565b9050612dad8282613004565b919050565b6000604051905090565b600067ffffffffffffffff821115612dd757612dd661316b565b5b612de0826131ae565b9050602081019050919050565b600067ffffffffffffffff821115612e0857612e0761316b565b5b612e11826131ae565b9050602081019050919050565b600081519050919050565b600081519050919050565b600082825260208201905092915050565b600082825260208201905092915050565b600081905092915050565b6000612e6c82612f86565b9150612e7783612f86565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03821115612eac57612eab6130af565b5b828201905092915050565b6000612ec282612f86565b9150612ecd83612f86565b925082612edd57612edc6130de565b5b828204905092915050565b6000612ef382612f86565b9150612efe83612f86565b925082821015612f1157612f106130af565b5b828203905092915050565b6000612f2782612f66565b9050919050565b60008115159050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b82818337600083830152505050565b60005b83811015612fbd578082015181840152602081019050612fa2565b83811115612fcc576000848401525b50505050565b60006002820490506001821680612fea57607f821691505b60208210811415612ffe57612ffd61310d565b5b50919050565b61300d826131ae565b810181811067ffffffffffffffff8211171561302c5761302b61316b565b5b80604052505050565b600061304082612f86565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415613073576130726130af565b5b600182019050919050565b600061308982612f86565b915061309483612f86565b9250826130a4576130a36130de565b5b828206905092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080fd5b600080fd5b600080fd5b600080fd5b6000601f19601f8301169050919050565b7f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560008201527f63656976657220696d706c656d656e7465720000000000000000000000000000602082015250565b7f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160008201527f6464726573730000000000000000000000000000000000000000000000000000602082015250565b7f4552433732313a20746f6b656e20616c7265616479206d696e74656400000000600082015250565b7f4552433732313a207472616e7366657220746f20746865207a65726f2061646460008201527f7265737300000000000000000000000000000000000000000000000000000000602082015250565b7f4552433732313a20617070726f766520746f2063616c6c657200000000000000600082015250565b7f496e76616c696420746f6b656e20696400000000000000000000000000000000600082015250565b7f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860008201527f697374656e7420746f6b656e0000000000000000000000000000000000000000602082015250565b7f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760008201527f6e6572206e6f7220617070726f76656420666f7220616c6c0000000000000000602082015250565b7f4552433732313a2062616c616e636520717565727920666f7220746865207a6560008201527f726f206164647265737300000000000000000000000000000000000000000000602082015250565b7f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460008201527f656e7420746f6b656e0000000000000000000000000000000000000000000000602082015250565b7f45786365656473206d617820737570706c790000000000000000000000000000600082015250565b7f4552433732313a206d696e7420746f20746865207a65726f2061646472657373600082015250565b7f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860008201527f697374656e7420746f6b656e0000000000000000000000000000000000000000602082015250565b7f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572600082015250565b7f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960008201527f73206e6f74206f776e0000000000000000000000000000000000000000000000602082015250565b7f4552433732314d657461646174613a2055524920717565727920666f72206e6f60008201527f6e6578697374656e7420746f6b656e0000000000000000000000000000000000602082015250565b7f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560008201527f7200000000000000000000000000000000000000000000000000000000000000602082015250565b7f426c696e6420626f7820616c72656164792072657665616c6564210000000000600082015250565b7f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60008201527f776e6572206e6f7220617070726f766564000000000000000000000000000000602082015250565b7f63616c6c6572206d75737420626520486f6c795368787874537570657244726160008201527f6674206f72206f776e6572000000000000000000000000000000000000000000602082015250565b6136ea81612f1c565b81146136f557600080fd5b50565b61370181612f2e565b811461370c57600080fd5b50565b61371881612f3a565b811461372357600080fd5b50565b61372f81612f86565b811461373a57600080fd5b5056fea2646970667358221220eba45b4f9696d85047ae00921f9f31ba8af6d49268ddffba5c227e14484c3a4a64736f6c63430008070033
Verified Source Code Full Match
Compiler: v0.8.7+commit.e28d00a7
EVM: london
Optimization: No
HolyShxxtLeague.sol 109 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "@openzeppelin/contracts/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/utils/Strings.sol";
contract HolyShxxtLeague is ERC721, Ownable {
using Strings for uint256;
string public baseURI;
uint256 public constant MAX_SUPPLY = 8888;
uint256 public totalSupply;
address public holyShxxtSuperDraft;
bool public revealed = false;
uint256 public seed;
event SetHolyShxxtSuperDraft(address holyShxxtSuperDraft);
event SetBaseURI(string baseURI);
constructor(
string memory _name,
string memory _symbol,
string memory _baseURI
) ERC721(_name, _symbol) {
baseURI = _baseURI;
}
modifier onlyOwnerOrStore() {
require(
holyShxxtSuperDraft == msg.sender || owner() == msg.sender,
"caller must be HolyShxxtSuperDraft or owner"
);
_;
}
function setHolyShxxtSuperDraft(address _holyShxxtSuperDraft) external onlyOwner {
holyShxxtSuperDraft = _holyShxxtSuperDraft;
emit SetHolyShxxtSuperDraft(_holyShxxtSuperDraft);
}
function reveal(uint256 randomNumber) external onlyOwner {
require( !revealed, "Blind box already revealed!");
if (randomNumber > 0) seed = randomNumber;
else seed = 1;
revealed = true;
}
function setBaseURI(string memory _baseURI) external onlyOwner {
baseURI = _baseURI;
emit SetBaseURI(_baseURI);
}
function _baseURI() internal view virtual override returns (string memory) {
return baseURI;
}
function metadataOf(uint256 tokenId)
public
view
returns (string memory)
{
require( tokenId < totalSupply, "Invalid token id");
if (seed == 0) return "";
uint256[] memory metaIds = new uint256[](MAX_SUPPLY);
uint256 randomSeed = seed;
for (uint256 i = 0; i < MAX_SUPPLY; i++) {
metaIds[i] = i;
}
// shuffle meta id
for (uint256 i = 0; i < MAX_SUPPLY; i++) {
uint256 j = uint256(keccak256(abi.encode(randomSeed, i))) % MAX_SUPPLY;
(metaIds[i], metaIds[j]) = (metaIds[j], metaIds[i]);
}
return metaIds[tokenId].toString();
}
function tokenURI(uint256 _tokenId)
public
view
override
returns (string memory)
{
require(_exists(_tokenId), "ERC721Metadata: URI query for nonexistent token");
string memory base = _baseURI();
//only blind box before reveal
if (!revealed) {
uint256 blindbox = _tokenId % 5;
return string(abi.encodePacked(base, blindbox.toString())); //blind box
}
return string(abi.encodePacked(base, metadataOf(_tokenId)));
}
function mint(address _to) public onlyOwnerOrStore {
require(totalSupply < MAX_SUPPLY, "Exceeds max supply");
_mint(_to, totalSupply);
totalSupply += 1;
}
}
Address.sol 216 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @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) {
// This method relies on extcodesize, which returns 0 for contracts in
// construction, since the code is only stored at the end of the
// constructor execution.
uint256 size;
assembly {
size := extcodesize(account)
}
return size > 0;
}
/**
* @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");
(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");
require(isContract(target), "Address: call to non-contract");
(bool success, bytes memory returndata) = target.call{value: value}(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
return functionStaticCall(target, data, "Address: low-level static call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a static call.
*
* _Available since v3.3._
*/
function functionStaticCall(
address target,
bytes memory data,
string memory errorMessage
) internal view returns (bytes memory) {
require(isContract(target), "Address: static call to non-contract");
(bool success, bytes memory returndata) = target.staticcall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
return functionDelegateCall(target, data, "Address: low-level delegate call failed");
}
/**
* @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
* but performing a delegate call.
*
* _Available since v3.4._
*/
function functionDelegateCall(
address target,
bytes memory data,
string memory errorMessage
) internal returns (bytes memory) {
require(isContract(target), "Address: delegate call to non-contract");
(bool success, bytes memory returndata) = target.delegatecall(data);
return verifyCallResult(success, returndata, errorMessage);
}
/**
* @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
* revert reason using the provided one.
*
* _Available since v4.3._
*/
function verifyCallResult(
bool success,
bytes memory returndata,
string memory errorMessage
) internal pure returns (bytes memory) {
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
assembly {
let returndata_size := mload(returndata)
revert(add(32, returndata), returndata_size)
}
} else {
revert(errorMessage);
}
}
}
}
Context.sol 23 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @dev Provides information about the current execution context, including the
* sender of the transaction and its data. While these are generally available
* via msg.sender and msg.data, they should not be accessed in such a direct
* manner, since when dealing with meta-transactions the account sending and
* paying for execution may not be the actual sender (as far as an application
* is concerned).
*
* This contract is only required for intermediate, library-like contracts.
*/
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes calldata) {
return msg.data;
}
}
Strings.sol 66 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @dev String operations.
*/
library Strings {
bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";
/**
* @dev Converts a `uint256` to its ASCII `string` decimal representation.
*/
function toString(uint256 value) internal pure returns (string memory) {
// Inspired by OraclizeAPI's implementation - MIT licence
// https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol
if (value == 0) {
return "0";
}
uint256 temp = value;
uint256 digits;
while (temp != 0) {
digits++;
temp /= 10;
}
bytes memory buffer = new bytes(digits);
while (value != 0) {
digits -= 1;
buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
value /= 10;
}
return string(buffer);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
*/
function toHexString(uint256 value) internal pure returns (string memory) {
if (value == 0) {
return "0x00";
}
uint256 temp = value;
uint256 length = 0;
while (temp != 0) {
length++;
temp >>= 8;
}
return toHexString(value, length);
}
/**
* @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
*/
function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
bytes memory buffer = new bytes(2 * length + 2);
buffer[0] = "0";
buffer[1] = "x";
for (uint256 i = 2 * length + 1; i > 1; --i) {
buffer[i] = _HEX_SYMBOLS[value & 0xf];
value >>= 4;
}
require(value == 0, "Strings: hex length insufficient");
return string(buffer);
}
}
Ownable.sol 71 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "../utils/Context.sol";
/**
* @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.
*/
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() {
_setOwner(_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 {
_setOwner(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");
_setOwner(newOwner);
}
function _setOwner(address newOwner) private {
address oldOwner = _owner;
_owner = newOwner;
emit OwnershipTransferred(oldOwner, newOwner);
}
}
ERC721.sol 411 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";
/**
* @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
* the Metadata extension, but not including the Enumerable extension, which is available separately as
* {ERC721Enumerable}.
*/
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
using Address for address;
using Strings for uint256;
// Token name
string private _name;
// Token symbol
string private _symbol;
// Mapping from token ID to owner address
mapping(uint256 => address) private _owners;
// Mapping owner address to token count
mapping(address => uint256) private _balances;
// Mapping from token ID to approved address
mapping(uint256 => address) private _tokenApprovals;
// Mapping from owner to operator approvals
mapping(address => mapping(address => bool)) private _operatorApprovals;
/**
* @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
*/
constructor(string memory name_, string memory symbol_) {
_name = name_;
_symbol = symbol_;
}
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
return
interfaceId == type(IERC721).interfaceId ||
interfaceId == type(IERC721Metadata).interfaceId ||
super.supportsInterface(interfaceId);
}
/**
* @dev See {IERC721-balanceOf}.
*/
function balanceOf(address owner) public view virtual override returns (uint256) {
require(owner != address(0), "ERC721: balance query for the zero address");
return _balances[owner];
}
/**
* @dev See {IERC721-ownerOf}.
*/
function ownerOf(uint256 tokenId) public view virtual override returns (address) {
address owner = _owners[tokenId];
require(owner != address(0), "ERC721: owner query for nonexistent token");
return owner;
}
/**
* @dev See {IERC721Metadata-name}.
*/
function name() public view virtual override returns (string memory) {
return _name;
}
/**
* @dev See {IERC721Metadata-symbol}.
*/
function symbol() public view virtual override returns (string memory) {
return _symbol;
}
/**
* @dev See {IERC721Metadata-tokenURI}.
*/
function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");
string memory baseURI = _baseURI();
return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
}
/**
* @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
* token will be the concatenation of the `baseURI` and the `tokenId`. Empty
* by default, can be overriden in child contracts.
*/
function _baseURI() internal view virtual returns (string memory) {
return "";
}
/**
* @dev See {IERC721-approve}.
*/
function approve(address to, uint256 tokenId) public virtual override {
address owner = ERC721.ownerOf(tokenId);
require(to != owner, "ERC721: approval to current owner");
require(
_msgSender() == owner || isApprovedForAll(owner, _msgSender()),
"ERC721: approve caller is not owner nor approved for all"
);
_approve(to, tokenId);
}
/**
* @dev See {IERC721-getApproved}.
*/
function getApproved(uint256 tokenId) public view virtual override returns (address) {
require(_exists(tokenId), "ERC721: approved query for nonexistent token");
return _tokenApprovals[tokenId];
}
/**
* @dev See {IERC721-setApprovalForAll}.
*/
function setApprovalForAll(address operator, bool approved) public virtual override {
require(operator != _msgSender(), "ERC721: approve to caller");
_operatorApprovals[_msgSender()][operator] = approved;
emit ApprovalForAll(_msgSender(), operator, approved);
}
/**
* @dev See {IERC721-isApprovedForAll}.
*/
function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) {
return _operatorApprovals[owner][operator];
}
/**
* @dev See {IERC721-transferFrom}.
*/
function transferFrom(
address from,
address to,
uint256 tokenId
) public virtual override {
//solhint-disable-next-line max-line-length
require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
_transfer(from, to, tokenId);
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) public virtual override {
safeTransferFrom(from, to, tokenId, "");
}
/**
* @dev See {IERC721-safeTransferFrom}.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes memory _data
) public virtual override {
require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved");
_safeTransfer(from, to, tokenId, _data);
}
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* `_data` is additional data, it has no specified format and it is sent in call to `to`.
*
* This internal function is equivalent to {safeTransferFrom}, and can be used to e.g.
* implement alternative mechanisms to perform token transfer, such as signature-based.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeTransfer(
address from,
address to,
uint256 tokenId,
bytes memory _data
) internal virtual {
_transfer(from, to, tokenId);
require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer");
}
/**
* @dev Returns whether `tokenId` exists.
*
* Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}.
*
* Tokens start existing when they are minted (`_mint`),
* and stop existing when they are burned (`_burn`).
*/
function _exists(uint256 tokenId) internal view virtual returns (bool) {
return _owners[tokenId] != address(0);
}
/**
* @dev Returns whether `spender` is allowed to manage `tokenId`.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
require(_exists(tokenId), "ERC721: operator query for nonexistent token");
address owner = ERC721.ownerOf(tokenId);
return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
}
/**
* @dev Safely mints `tokenId` and transfers it to `to`.
*
* Requirements:
*
* - `tokenId` must not exist.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function _safeMint(address to, uint256 tokenId) internal virtual {
_safeMint(to, tokenId, "");
}
/**
* @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
* forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
*/
function _safeMint(
address to,
uint256 tokenId,
bytes memory _data
) internal virtual {
_mint(to, tokenId);
require(
_checkOnERC721Received(address(0), to, tokenId, _data),
"ERC721: transfer to non ERC721Receiver implementer"
);
}
/**
* @dev Mints `tokenId` and transfers it to `to`.
*
* WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
*
* Requirements:
*
* - `tokenId` must not exist.
* - `to` cannot be the zero address.
*
* Emits a {Transfer} event.
*/
function _mint(address to, uint256 tokenId) internal virtual {
require(to != address(0), "ERC721: mint to the zero address");
require(!_exists(tokenId), "ERC721: token already minted");
_beforeTokenTransfer(address(0), to, tokenId);
_balances[to] += 1;
_owners[tokenId] = to;
emit Transfer(address(0), to, tokenId);
}
/**
* @dev Destroys `tokenId`.
* The approval is cleared when the token is burned.
*
* Requirements:
*
* - `tokenId` must exist.
*
* Emits a {Transfer} event.
*/
function _burn(uint256 tokenId) internal virtual {
address owner = ERC721.ownerOf(tokenId);
_beforeTokenTransfer(owner, address(0), tokenId);
// Clear approvals
_approve(address(0), tokenId);
_balances[owner] -= 1;
delete _owners[tokenId];
emit Transfer(owner, address(0), tokenId);
}
/**
* @dev Transfers `tokenId` from `from` to `to`.
* As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
*
* Requirements:
*
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
*
* Emits a {Transfer} event.
*/
function _transfer(
address from,
address to,
uint256 tokenId
) internal virtual {
require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own");
require(to != address(0), "ERC721: transfer to the zero address");
_beforeTokenTransfer(from, to, tokenId);
// Clear approvals from the previous owner
_approve(address(0), tokenId);
_balances[from] -= 1;
_balances[to] += 1;
_owners[tokenId] = to;
emit Transfer(from, to, tokenId);
}
/**
* @dev Approve `to` to operate on `tokenId`
*
* Emits a {Approval} event.
*/
function _approve(address to, uint256 tokenId) internal virtual {
_tokenApprovals[tokenId] = to;
emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
}
/**
* @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address.
* The call is not executed if the target address is not a contract.
*
* @param from address representing the previous owner of the given token ID
* @param to target address that will receive the tokens
* @param tokenId uint256 ID of the token to be transferred
* @param _data bytes optional data to send along with the call
* @return bool whether the call correctly returned the expected magic value
*/
function _checkOnERC721Received(
address from,
address to,
uint256 tokenId,
bytes memory _data
) private returns (bool) {
if (to.isContract()) {
try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) {
return retval == IERC721Receiver.onERC721Received.selector;
} catch (bytes memory reason) {
if (reason.length == 0) {
revert("ERC721: transfer to non ERC721Receiver implementer");
} else {
assembly {
revert(add(32, reason), mload(reason))
}
}
}
} else {
return true;
}
}
/**
* @dev Hook that is called before any token transfer. This includes minting
* and burning.
*
* Calling conditions:
*
* - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
* transferred to `to`.
* - When `from` is zero, `tokenId` will be minted for `to`.
* - When `to` is zero, ``from``'s `tokenId` 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 tokenId
) internal virtual {}
}
IERC721.sol 142 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "../../utils/introspection/IERC165.sol";
/**
* @dev Required interface of an ERC721 compliant contract.
*/
interface IERC721 is IERC165 {
/**
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
*/
event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
*/
event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
/**
* @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
*/
event ApprovalForAll(address indexed owner, address indexed operator, bool approved);
/**
* @dev Returns the number of tokens in ``owner``'s account.
*/
function balanceOf(address owner) external view returns (uint256 balance);
/**
* @dev Returns the owner of the `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function ownerOf(uint256 tokenId) external view returns (address owner);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
* are aware of the ERC721 protocol to prevent tokens from being forever locked.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId
) external;
/**
* @dev Transfers `tokenId` token from `from` to `to`.
*
* WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
*
* Emits a {Transfer} event.
*/
function transferFrom(
address from,
address to,
uint256 tokenId
) external;
/**
* @dev Gives permission to `to` to transfer `tokenId` token to another account.
* The approval is cleared when the token is transferred.
*
* Only a single account can be approved at a time, so approving the zero address clears previous approvals.
*
* Requirements:
*
* - The caller must own the token or be an approved operator.
* - `tokenId` must exist.
*
* Emits an {Approval} event.
*/
function approve(address to, uint256 tokenId) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @dev Approve or remove `operator` as an operator for the caller.
* Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
*
* Requirements:
*
* - The `operator` cannot be the caller.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool _approved) external;
/**
* @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
*
* See {setApprovalForAll}
*/
function isApprovedForAll(address owner, address operator) external view returns (bool);
/**
* @dev Safely transfers `tokenId` token from `from` to `to`.
*
* Requirements:
*
* - `from` cannot be the zero address.
* - `to` cannot be the zero address.
* - `tokenId` token must exist and be owned by `from`.
* - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
* - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
*
* Emits a {Transfer} event.
*/
function safeTransferFrom(
address from,
address to,
uint256 tokenId,
bytes calldata data
) external;
}
ERC165.sol 28 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "./IERC165.sol";
/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
* for the additional interface id that will be supported. For example:
*
* ```solidity
* function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
* return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
* }
* ```
*
* Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
*/
abstract contract ERC165 is IERC165 {
/**
* @dev See {IERC165-supportsInterface}.
*/
function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
return interfaceId == type(IERC165).interfaceId;
}
}
IERC165.sol 24 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
/**
* @dev Returns true if this contract implements the interface defined by
* `interfaceId`. See the corresponding
* https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
* to learn more about how these ids are created.
*
* This function call must use less than 30 000 gas.
*/
function supportsInterface(bytes4 interfaceId) external view returns (bool);
}
IERC721Receiver.sol 26 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
/**
* @title ERC721 token receiver interface
* @dev Interface for any contract that wants to support safeTransfers
* from ERC721 asset contracts.
*/
interface IERC721Receiver {
/**
* @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
* by `operator` from `from`, this function is called.
*
* It must return its Solidity selector to confirm the token transfer.
* If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
*
* The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`.
*/
function onERC721Received(
address operator,
address from,
uint256 tokenId,
bytes calldata data
) external returns (bytes4);
}
IERC721Metadata.sol 26 lines
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.0;
import "../IERC721.sol";
/**
* @title ERC-721 Non-Fungible Token Standard, optional metadata extension
* @dev See https://eips.ethereum.org/EIPS/eip-721
*/
interface IERC721Metadata is IERC721 {
/**
* @dev Returns the token collection name.
*/
function name() external view returns (string memory);
/**
* @dev Returns the token collection symbol.
*/
function symbol() external view returns (string memory);
/**
* @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
*/
function tokenURI(uint256 tokenId) external view returns (string memory);
}
Read Contract
MAX_SUPPLY 0x32cb6b0c → uint256
balanceOf 0x70a08231 → uint256
baseURI 0x6c0360eb → string
getApproved 0x081812fc → address
holyShxxtSuperDraft 0xf247fdc7 → address
isApprovedForAll 0xe985e9c5 → bool
metadataOf 0x0ef7cc8e → string
name 0x06fdde03 → string
owner 0x8da5cb5b → address
ownerOf 0x6352211e → address
revealed 0x51830227 → bool
seed 0x7d94792a → uint256
supportsInterface 0x01ffc9a7 → bool
symbol 0x95d89b41 → string
tokenURI 0xc87b56dd → string
totalSupply 0x18160ddd → uint256
Write Contract 11 functions
These functions modify contract state and require a wallet transaction to execute.
approve 0x095ea7b3
address to
uint256 tokenId
mint 0x6a627842
address _to
renounceOwnership 0x715018a6
No parameters
reveal 0xc2ca0ac5
uint256 randomNumber
safeTransferFrom 0x42842e0e
address from
address to
uint256 tokenId
safeTransferFrom 0xb88d4fde
address from
address to
uint256 tokenId
bytes _data
setApprovalForAll 0xa22cb465
address operator
bool approved
setBaseURI 0x55f804b3
string _baseURI
setHolyShxxtSuperDraft 0xaf1806af
address _holyShxxtSuperDraft
transferFrom 0x23b872dd
address from
address to
uint256 tokenId
transferOwnership 0xf2fde38b
address newOwner
Recent Transactions
No transactions found for this address