Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
TokenTracker
Latest 25 from a total of 358 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Set Approval For... | 21177963 | 32 days ago | IN | 0 ETH | 0.00096896 | ||||
Set Approval For... | 19537342 | 262 days ago | IN | 0 ETH | 0.00051703 | ||||
Set Approval For... | 18044805 | 471 days ago | IN | 0 ETH | 0.00056633 | ||||
Set Approval For... | 17583759 | 535 days ago | IN | 0 ETH | 0.00051343 | ||||
Claim Burgers | 17153567 | 596 days ago | IN | 0 ETH | 0.0051014 | ||||
Claim Burgers | 17045919 | 611 days ago | IN | 0 ETH | 0.00296626 | ||||
Set Approval For... | 17009833 | 616 days ago | IN | 0 ETH | 0.00051713 | ||||
Claim Burgers | 16970566 | 622 days ago | IN | 0 ETH | 0.00473945 | ||||
Claim Burgers | 16889798 | 633 days ago | IN | 0 ETH | 0.00172145 | ||||
Claim Burgers | 16867140 | 636 days ago | IN | 0 ETH | 0.00318364 | ||||
Claim Burgers | 16859367 | 638 days ago | IN | 0 ETH | 0.00181095 | ||||
Claim Burgers | 16828586 | 642 days ago | IN | 0 ETH | 0.00254653 | ||||
Claim Burgers | 16741186 | 654 days ago | IN | 0 ETH | 0.00186125 | ||||
Set Approval For... | 16679778 | 663 days ago | IN | 0 ETH | 0.00165156 | ||||
Claim Burgers | 16660088 | 666 days ago | IN | 0 ETH | 0.00425093 | ||||
Claim Burgers | 16636685 | 669 days ago | IN | 0 ETH | 0.02418166 | ||||
Claim Burgers | 16612468 | 672 days ago | IN | 0 ETH | 0.00208679 | ||||
Claim Burgers | 16606158 | 673 days ago | IN | 0 ETH | 0.00268276 | ||||
Claim Burgers | 16599221 | 674 days ago | IN | 0 ETH | 0.00458515 | ||||
Set Approval For... | 16586221 | 676 days ago | IN | 0 ETH | 0.00181264 | ||||
Set Approval For... | 16586165 | 676 days ago | IN | 0 ETH | 0.00178863 | ||||
Claim Burgers | 16571759 | 678 days ago | IN | 0 ETH | 0.00748898 | ||||
Claim Burgers | 16525193 | 684 days ago | IN | 0 ETH | 0.00320318 | ||||
Claim Burgers | 16505394 | 687 days ago | IN | 0 ETH | 0.00148044 | ||||
Claim Burgers | 16483398 | 690 days ago | IN | 0 ETH | 0.00158283 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
Burger
Compiler Version
v0.8.9+commit.e5eed63a
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts/token/ERC1155/ERC1155.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "./Grill2.sol"; error BurningNotActive(); error ClaimingNotActive(); error CallerIsNotABurner(); error InsufficientClaimsRemaining(); /** * @title Burgers * @author Matt Carter * June 6, 2022 * * This contract is for accounts to claim emission tokens (burgers) from their grill stakes. * Burgers have a `tokenId` of 1 and are burnable by owner-set `burner` addresses. */ contract Burger is ERC1155, Ownable { using Strings for uint256; /// contract instances /// Grill2 public immutable TheGrill; Grill2 public SpecialGrill; /// is claiming/burning/special grill active /// bool public isClaiming = false; bool public isBurning = false; bool public isSpecial = false; /// the number of burgers minted/burned /// uint256 public totalMints; uint256 public totalBurns; /// addresses allowed to burn burgers /// mapping(address => bool) public burners; /// the number of claims used by each account /// mapping(address => uint256) public claimsUsed; /// the number of burgers burned by each account /// mapping(address => uint256) public accountBurns; /// the number of burgers burned by each burner /// mapping(address => uint256) public burnerBurns; /// ============ CONSTRUCTOR ============ /// /** * Sets the initial base URI and address for the grill * @param _URI The baseURI for each token * @param aGrill The address of the astro grill contract */ constructor(string memory _URI, address aGrill) ERC1155(_URI) { TheGrill = Grill2(aGrill); } /// ============ INTERNAL ============ /// /** * Gets the total number of burgers `account` has earned from the grill(s) * @param account The address to lookup * @return quantity The number of claims */ function _totalClaimsEarned(address account) internal view returns (uint256 quantity) { quantity += TheGrill.totalClaims(account); /// @dev additionally counts special grill stakes /// if (isSpecial) { quantity += SpecialGrill.totalClaims(account); } } /// ============ OWNER ============ /// /** * Sets the new base URI for tokens * @param _URI The new base URI * @notice Uses the format: baselink.com/{}.json */ function setURI(string memory _URI) public onlyOwner { _setURI(_URI); } /** * Toggles if claiming tokens is allowed */ function toggleClaiming() public onlyOwner { isClaiming = !isClaiming; } /** * Toggles if burning tokens is allowed */ function toggleBurning() public onlyOwner { isBurning = !isBurning; } /** * Approve an address to burn burgers * @param account The burner address * @param status The status of the approval * @notice A burner should be a contract address that correctly handles the burning of an operators tokens */ function setBurner(address account, bool status) public onlyOwner { burners[account] = status; } /** * Mints `quantity` burgers to `account` without restrictions * @param quantity The number of tokens to mint * @param account The address to mint the tokens to */ function ownerMint(uint256 quantity, address account) public onlyOwner { _mint(account, 1, quantity, "0x00"); totalMints += quantity; } /** * Toggles if the special grill is running */ function toggleSpecial() public onlyOwner { isSpecial = !isSpecial; } /** * Sets the special grill interface * @param aGrill The address of the special grill */ function setSpecial(address aGrill) public onlyOwner { SpecialGrill = Grill2(aGrill); } /// ============ PUBLIC ============ /// /** * Mints `quantity` burgers to caller * @param quantity The number of burgers caller is trying to mint */ function claimBurgers(uint256 quantity) public { if (!isClaiming) { revert ClaimingNotActive(); } if (claimsUsed[msg.sender] + quantity > _totalClaimsEarned(msg.sender)) { revert InsufficientClaimsRemaining(); } /// @dev mints `quantity` tokens with `tokenId` 1 to caller /// _mint(msg.sender, 1, quantity, "0x00"); /// @dev sets contract state /// claimsUsed[msg.sender] += quantity; totalMints += quantity; } /** * Burns burgers on behalf of `account` * @param account The address having it's burgers burned * @param quantity The number of burgers to burn * @notice Only burners may call this function */ function burnBurger(address account, uint256 quantity) public { if (!isBurning) { revert BurningNotActive(); } if (!burners[msg.sender]) { revert CallerIsNotABurner(); } /// @dev burns `quantity` tokens of `tokenId` 1 for `account` /// _burn(account, 1, quantity); /// @dev sets contract state /// totalBurns += quantity; accountBurns[account] += quantity; burnerBurns[msg.sender] += quantity; } /// ============ READ-ONLY ============ /// /** * Gets the balance of burgers for `account` * @param account The address to lookup * @return _balance The number of burgers * @notice burgers have a `tokenId` of 1 */ function balanceOf(address account) public view returns (uint256 _balance) { _balance = balanceOf(account, 1); } /** * Gets the total number of burgers in circulation * @return _totalSupply The number of burgers */ function totalSupply() public view returns (uint256 _totalSupply) { _totalSupply = totalMints - totalBurns; } /** * Gets the number of claims `account` has remaining * @param account The address to lookup * @return _remaining The number of claims */ function tokenClaimsLeft(address account) public view returns (uint256 _remaining) { _remaining = _totalClaimsEarned(account) - claimsUsed[account]; } }
//SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/token/ERC1155/utils/ERC1155Holder.sol"; error CallerBlacklisted(); error CallerNotTokenOwner(); error CallerNotTokenStaker(); error StakingNotActive(); error ZeroEmissionRate(); /** * Interfaces astrobull contract */ interface ISUPER1155 { function balanceOf(address _owner, uint256 _id) external view returns (uint256); function groupBalances(uint256 groupId, address from) external view returns (uint256); function safeTransferFrom( address _from, address _to, uint256 _id, uint256 _amount, bytes calldata _data ) external; function safeBatchTransferFrom( address _from, address _to, uint256[] memory _ids, uint256[] memory _amounts, bytes memory _data ) external; } /** * Interfaces old grill contract */ interface IGRILL { struct Stake { bool status; address staker; uint256 timestamp; } function getStake(uint256 _tokenId) external view returns (Stake memory _stake); function getIdsOfAddr(address _operator) external view returns (uint256[] memory _addrStakes); } /** * @title Grill2.0 * @author Matt Carter, degendeveloper.eth * 6 June, 2022 * * The purpose of this contract is to optimize gas consumption when adding new stakes and * removing previous stakes from the initial grill contract @ 0xE11AF478aF241FAb926f4c111d50139Ae003F7fd. * * Users will use this new grill contract when adding and removing stakes. This new contract * is also responsible for counting emission tokens and setting new emission rates. * * This contract is whitelisted to move the first grill's tokens via proxy registry in the super1155 contract. * * This contract should be set as the `proxyRegistryAddress` in the parent contract. This * allows the new grill to move tokens on behalf of the old grill. */ contract Grill2 is Ownable, ERC1155Holder { using Counters for Counters.Counter; uint256 internal constant MAX_INT = 2**256 - 1; /// contract instances /// ISUPER1155 public constant Parent = ISUPER1155(0x71B11Ac923C967CD5998F23F6dae0d779A6ac8Af); IGRILL public immutable OldGrill; /// the number of times the emission rate changes /// Counters.Counter internal emChanges; /// is adding stakes allowed /// bool public isStaking = true; /// the number of stakes added & removed by each account (this contract) /// mapping(address => Counters.Counter) internal stakesAddedPerAccount; mapping(address => Counters.Counter) internal stakesRemovedPerAccount; /// each Stake by tokenId (this contract) /// mapping(uint256 => Stake) public stakeStorage; /// each tokenId by index for an account (this contract) /// mapping(address => mapping(uint256 => uint256)) public accountStakes; /// each Emission by index (this contract) /// mapping(uint256 => Emission) public emissionStorage; /// the number of emission tokens earned be each account from removed stakes /// mapping(address => uint256) public unstakedClaims; /// accounts that can not add new stakes /// mapping(address => bool) public blacklist; /// list of new proxies for Parent tokens /// mapping(address => address) public proxies; /** * Stores information for an emission change * @param rate The number of seconds to earn 1 emission token * @param timestamp The block.timestamp this emission rate is set */ struct Emission { uint256 rate; uint256 timestamp; } /** * Stores information for a stake * @param staker The address who creates this stake * @param timestamp The block.timestamp this stake is created * @param accountSlot The index for this stake in `accountStakes` */ struct Stake { address staker; uint256 timestamp; uint256 accountSlot; } /// ============ CONSTRUCTOR ============ /// /** * Initializes contract instances and sets the initial emission rate * @param _grillAddr The address for the first grill contract * @notice `1652054400` is Mon, 09 May 2022 00:00:00 GMT * @notice '3600 * 24 * 45' is the number of seconds in 45 days */ constructor(address _grillAddr) { OldGrill = IGRILL(_grillAddr); emissionStorage[emChanges.current()] = Emission(3600 * 24 * 45, 1652054400); } /// ============ OWNER ============ /// /** * Sets a proxy transferer for `account`s tokens * @param account The address whose tokens to move * @param operator The address being proxied as an approved operator for `account` * @notice The team will use this contract as a proxy for old grill tokens */ function setProxyForAccount(address account, address operator) public onlyOwner { proxies[account] = operator; } /** * Removes a proxy transferer for `account`s tokens * @param account The address losing its proxy transferer */ function removeProxyForAccount(address account) public onlyOwner { delete proxies[account]; } /** * Allows/unallows the addition of new stakes */ function toggleStaking() public onlyOwner { isStaking = !isStaking; } /** * Allows/unallows an account to add new stakes * @param account The address to set status for * @param status The status being set * @notice A staker is always able to remove their stakes regardless of blacklist status */ function blacklistAccount(address account, bool status) public onlyOwner { blacklist[account] = status; } /** * Stops emission token counting by setting an emission rate of the max-int number of seconds * @notice No tokens can be earned with an emission rate this long * @notice To continue emissions counting, the owner must set a new emission rate */ function pauseEmissions() public onlyOwner { _setEmissionRate(MAX_INT); } /** * Sets a new rate for earning emission tokens * @param _seconds The number of seconds a token must be staked for to earn 1 emission token */ function setEmissionRate(uint256 _seconds) public onlyOwner { _setEmissionRate(_seconds); } /// ============ PUBLIC ============ /// /** * Stakes an array of tokenIds with this contract to earn emission tokens * @param tokenIds An array of tokenIds to stake * @param amounts An array of amounts of each tokenId to stake * @notice Caller must `setApprovalForAll()` to true in the parent contract using this contract's address * before it can move their tokens */ function addStakes(uint256[] memory tokenIds, uint256[] memory amounts) public { if (!isStaking) { revert StakingNotActive(); } if (blacklist[msg.sender]) { revert CallerBlacklisted(); } /// @dev verifies caller owns each token /// for (uint256 i = 0; i < tokenIds.length; ++i) { uint256 _tokenId = tokenIds[i]; if (Parent.balanceOf(msg.sender, _tokenId) == 0) { revert CallerNotTokenOwner(); } /// @dev sets contract state /// _addStake(msg.sender, _tokenId); } /// @dev transfers tokens from caller to this contract /// Parent.safeBatchTransferFrom( msg.sender, address(this), tokenIds, amounts, "0x00" ); } /** * Removes an array of tokenIds staked in this contract and/or the old one * @param oldTokenIds The tokenIds being unstaked from the old contract * @param oldAmounts The number of each token being unstaked * @param newTokenIds The tokenIds being unstaked from this contract * @param newAmounts The number of each token being unstaked */ function removeStakes( uint256[] memory oldTokenIds, uint256[] memory oldAmounts, uint256[] memory newTokenIds, uint256[] memory newAmounts ) public { if (oldTokenIds.length > 0) { /// @dev verifies caller staked each token /// for (uint256 i = 0; i < oldTokenIds.length; ++i) { uint256 _tokenId = oldTokenIds[i]; IGRILL.Stake memory _thisStake = OldGrill.getStake(_tokenId); if (_thisStake.staker != msg.sender) { revert CallerNotTokenStaker(); } /// @dev increments emissions earned for caller /// unstakedClaims[msg.sender] += countEmissions(_thisStake.timestamp); } /// @dev transfers tokens from old contract to caller /// Parent.safeBatchTransferFrom( address(OldGrill), msg.sender, oldTokenIds, oldAmounts, "0x00" ); } if (newTokenIds.length > 0) { /// @dev verifies caller staked each token /// for (uint256 i = 0; i < newTokenIds.length; ++i) { uint256 _tokenId = newTokenIds[i]; if (stakeStorage[_tokenId].staker != msg.sender) { revert CallerNotTokenStaker(); } /// @dev sets contract state /// _removeStake(_tokenId); } /// @dev transfers tokens from this contract to caller /// Parent.safeBatchTransferFrom( address(this), msg.sender, newTokenIds, newAmounts, "0x00" ); } } /** * Counts the number of emission tokens a timestamp has earned * @param _timestamp The timestamp a token was staked * @return _c The number of emission tokens a stake has earned since `_timestamp` */ function countEmissions(uint256 _timestamp) public view returns (uint256 _c) { /// @dev if timestamp is before contract creation or later than now return 0 /// if ( _timestamp < emissionStorage[0].timestamp || _timestamp > block.timestamp ) { _c = 0; } else { /** * @dev finds the most recent emission rate _timestamp comes after * Example: * emChanges: *0...........1............2.....................3...........* * timeline: *(deploy)....x............x.....(timestamp).....x......(now)* */ uint256 minT; for (uint256 i = 1; i <= emChanges.current(); ++i) { if (emissionStorage[i].timestamp < _timestamp) { minT += 1; } } /// @dev counts all emissions earned starting from minT -> now /// for (uint256 i = minT; i <= emChanges.current(); ++i) { uint256 tSmall = emissionStorage[i].timestamp; uint256 tBig = emissionStorage[i + 1].timestamp; // 0 if not set yet if (i == minT) { tSmall = _timestamp; } if (i == emChanges.current()) { tBig = block.timestamp; } _c += (tBig - tSmall) / emissionStorage[i].rate; } } } /// ============ INTERNAL ============ /// /** * Helper function that sets contract state when adding a stake to this contract * @param staker The address to make the stake for * @param tokenId The tokenId being staked */ function _addStake(address staker, uint256 tokenId) internal { /// @dev increments slots filled by staker /// stakesAddedPerAccount[staker].increment(); /// @dev fills new slot (account => index => tokenId) /// accountStakes[staker][stakesAddedPerAccount[staker].current()] = tokenId; /// @dev add new stake to storage /// stakeStorage[tokenId] = Stake( staker, block.timestamp, stakesAddedPerAccount[staker].current() ); } /** * Helper function that sets contract state when removing a stake from this contract * @param tokenId The tokenId being un-staked * @notice This function is not called when removing stakes from the old contract */ function _removeStake(uint256 tokenId) internal { /// @dev copies the stake being removed /// Stake memory _thisStake = stakeStorage[tokenId]; /// @dev increments slots emptied by staker /// stakesRemovedPerAccount[_thisStake.staker].increment(); /// @dev increments emissions earned for removing this stake /// unstakedClaims[_thisStake.staker] += countEmissions(_thisStake.timestamp); /// @dev empty staker's slot (account => index => 0) /// delete accountStakes[_thisStake.staker][_thisStake.accountSlot]; /// @dev removes stake from storage /// delete stakeStorage[tokenId]; } /** * Helper function that sets contract state when emission changes occur * @param _seconds The number of seconds a token must be staked for to earn 1 emission token * @notice The emission rate cannot be 0 seconds */ function _setEmissionRate(uint256 _seconds) private { if (_seconds == 0) { revert ZeroEmissionRate(); } emChanges.increment(); emissionStorage[emChanges.current()] = Emission(_seconds, block.timestamp); } /** * Helper function that gets the number of stakes an account has active with this contract * @param account The address to lookup * @return _active The number stakes */ function _activeStakesCountPerAccount(address account) internal view returns (uint256 _active) { _active = stakesAddedPerAccount[account].current() - stakesRemovedPerAccount[account].current(); } /** * Helper function that gets the number of stakes an account has active with the old contract * @param account The address to lookup * @return _active The number of stakes not yet removed from the old contract */ function _activeStakesCountPerAccountOld(address account) internal view returns (uint256 _active) { uint256[] memory oldStakes = OldGrill.getIdsOfAddr(account); for (uint256 i = 0; i < oldStakes.length; ++i) { if (Parent.balanceOf(address(OldGrill), oldStakes[i]) == 1) { _active += 1; } } } /// ============ READ-ONLY ============ /// /** * Gets tokenIds for `account`s active stakes in this contract * @param account The address to lookup * @return _ids Array of tokenIds */ function stakedIdsPerAccount(address account) public view returns (uint256[] memory _ids) { _ids = new uint256[](_activeStakesCountPerAccount(account)); /// @dev finds all slots still filled /// uint256 found; for (uint256 i = 1; i <= stakesAddedPerAccount[account].current(); ++i) { if (accountStakes[account][i] != 0) { _ids[found++] = accountStakes[account][i]; } } } /** * Gets tokenIds for `account`s active stakes in the old contract * @param account The address to lookup * @return _ids Array of tokenIds */ function stakedIdsPerAccountOld(address account) public view returns (uint256[] memory _ids) { /// @dev gets all tokenIds account had staked /// uint256[] memory oldStakes = OldGrill.getIdsOfAddr(account); /// @dev finds all tokenIds still active in old contract /// _ids = new uint256[](_activeStakesCountPerAccountOld(account)); uint256 found; for (uint256 i = 0; i < oldStakes.length; ++i) { if (Parent.balanceOf(address(OldGrill), oldStakes[i]) == 1) { _ids[found++] = oldStakes[i]; } } } /** * Gets the total number of emission changes to date * @return _changes The current number of changes to emission rates */ function emissionChanges() external view returns (uint256 _changes) { _changes = emChanges.current(); } /** * Gets the number of emission tokens `account` has earned from their active stakes * @param account The address to lookup * @return _earned The number of claims * @notice Uses stakes from new and old contract */ function stakedClaims(address account) public view returns (uint256 _earned) { /// @dev counts emissions for each active stake in this contract /// uint256[] memory ownedIds = stakedIdsPerAccount(account); for (uint256 i; i < ownedIds.length; ++i) { _earned += countEmissions(stakeStorage[ownedIds[i]].timestamp); } /// @dev counts emissions for each active stake in old contract /// uint256[] memory ownedIdsOld = stakedIdsPerAccountOld(account); for (uint256 i; i < ownedIdsOld.length; ++i) { _earned += countEmissions(OldGrill.getStake(ownedIdsOld[i]).timestamp); } } /** * Gets the number of emission tokens `account` has earned from their active and removed stakes * @param account The address to lookup * @return _earned The number of emissions _operator has earned from all past and current stakes * @notice Uses stakes from new and old contract */ function totalClaims(address account) external view returns (uint256 _earned) { _earned = unstakedClaims[account] + stakedClaims(account); } /** * Gets the Stake object from this grill contract * @param tokenId The tokenId to get stake for * @return _s The Stake object */ function stakeStorageGetter(uint256 tokenId) public view returns (Stake memory _s) { _s = stakeStorage[tokenId]; } /** * Gets the Stake object from the old grill contract * @param tokenId The tokenId to get stake for * @return _og The old Stake object */ function stakeStorageOld(uint256 tokenId) public view returns (IGRILL.Stake memory _og) { _og = OldGrill.getStake(tokenId); } }
//SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "erc721a/contracts/ERC721A.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Counters.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "./Burger.sol"; error MintingNotActive(); error AstrobullAlreadyClaimed(); /** * @title Metabulls * @author Matt Carter * June 6, 2022 * * This contract is an implementation of chiru lab's erc721a contract and is used for minting * 3d metaverse bulls. To mint a metabull, an account will input tokenIds of astrobulls * they are using to claim; meaning the account must own each astrobull or be the staker of it, * and each astrobull can only be used once. The contract will store which astrobull traits to * give each metabull. Users will burn burgers for each metabull they mint. */ contract MetaBull is ERC721A, Ownable { using Strings for uint256; /// contract instances /// Burger public immutable BurgerContract; Grill2 public immutable GrillContract; ISUPER1155 public constant Astro = ISUPER1155(0x71B11Ac923C967CD5998F23F6dae0d779A6ac8Af); address public constant OldGrill = 0xE11AF478aF241FAb926f4c111d50139Ae003F7fd; /// if minting is active /// bool public isMinting; /// if tokens are revealed /// bool public isRevealed; /// the number of burgers to burn each mint /// uint256 public burnScalar = 2; /// the number of burgers burned by this contract /// uint256 public totalBurns; /// the base uri for all tokens /// string public URI; /// if an astrobull has been claimed for yet /// mapping(uint256 => bool) public portedIds; /// which astrobull traits to give each metabull /// mapping(uint256 => uint256) public portingMeta; /// the number of burgers each account has burned /// mapping(address => uint256) public accountBurns; /// ============ CONSTRUCTOR ============ /// /** * Sets the initial base uri and address for the burger contract * @param _URI The baseURI for each token * @param burgerAddr The address of the burger contract * @param grillAddr The address of the grill contract */ constructor( string memory _URI, address burgerAddr, address grillAddr ) ERC721A("METABULLS", "MBULL") { URI = _URI; BurgerContract = Burger(burgerAddr); GrillContract = Grill2(grillAddr); } /// ============ INTERNAL ============ /// /** * Overrides tokens to start at index 1 instead of 0 * @return _id The tokenId of the first token */ function _startTokenId() internal pure override returns (uint256 _id) { _id = 1; } /// ============ OWNER ============ /// /** * Sets a new base URI for tokens * @param _URI The new baseURI for each token */ function setURI(string memory _URI) public onlyOwner { URI = _URI; } /** * Toggles if minting is allowed. */ function toggleMinting() public onlyOwner { isMinting = !isMinting; } /** * Toggles if tokens are revealed. */ function toggleReveal() public onlyOwner { isRevealed = !isRevealed; } /** * Sets the quantity of burgers an account must burn to mint each metabull * @param _burnScalar The number of burgers to burn */ function setBurnScalar(uint256 _burnScalar) public onlyOwner { burnScalar = _burnScalar; } /** * Mints `quantity` tokens to `account` * @param quantity The number of tokens to mint * @param account The address to mint the tokens to * @notice Each token an owner mints will point to a 0 in the portingMeta mapping * since it does not share traits with a minted astrobull */ function ownerMint(uint256 quantity, address account) public onlyOwner { _safeMint(account, quantity); } /// ============ PUBLIC ============ /// /** * Mints a metabull for each astrobull input * @param astrobullIds An array of astrobull IDs caller is claiming metabulls for * @notice The caller must own each astrobull ID they are claiming for; meaning it must * be removed from the grill before use */ function claimBull(uint256[] memory astrobullIds) public { if (!isMinting) { revert MintingNotActive(); } /// @dev gets the first tokenId being minted /// uint256 currentIndex = _currentIndex; for (uint256 i = 0; i < astrobullIds.length; ++i) { if (!_checkOwnerShip(msg.sender, astrobullIds[i])) { revert CallerNotTokenOwner(); } if (portedIds[astrobullIds[i]]) { revert AstrobullAlreadyClaimed(); } /// @dev sets the astrobull traits to give each metabull being minted /// portingMeta[currentIndex] = astrobullIds[i]; /// @dev sets contract state /// portedIds[astrobullIds[i]] = true; /// @dev sets the next tokenId being minted /// currentIndex += 1; } /// burn caller's burgers /// uint256 toBurn = burnScalar * astrobullIds.length; BurgerContract.burnBurger(msg.sender, toBurn); /// sets contract state /// totalBurns += toBurn; accountBurns[msg.sender] += toBurn; /// mint metabulls to caller /// _safeMint(msg.sender, astrobullIds.length); } /// ============ INTERNAL ============ /// /** * Checks if `account` is the owner or staker of `tokenId` * @param account The address to check ownership for * @param tokenId The tokenId to check ownership of * @return _b If `account` is the owner or staker of `tokenId` */ function _checkOwnerShip(address account, uint256 tokenId) internal view returns (bool _b) { _b = false; /// @dev first checks if account owns token /// if (Astro.balanceOf(account, tokenId) == 1) { _b = true; } /// @dev next, checks if token is staked in the old grill and caller is staker /// else if (Astro.balanceOf(address(OldGrill), tokenId) == 1) { if (GrillContract.stakeStorageOld(tokenId).staker == account) { _b = true; } } /// @dev last, checks if token is staked in current grill and caller is staker /// else if (GrillContract.stakeStorageGetter(tokenId).staker == account) { _b = true; } } /// ============ READ-ONLY ============ /// /** * Gets a token's URI * @param _tokenId The tokenId to lookup * @return _URI The token's uri */ function tokenURI(uint256 _tokenId) public view override returns (string memory _URI) { if (isRevealed) { _URI = string(abi.encodePacked(URI, _tokenId.toString(), ".json")); } else { _URI = URI; } } }
//SPDX-License-Identifier: MIT pragma solidity ^0.8.9; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; import "./Burger.sol"; error ExceedsMaxClaims(); error InvalidTokenAmount(); error CallerIsNotTokenOwner(); error CallerNotInCommunity(); /** * @title Physical Bulls * @author Matt Carter * June 6, 2022 * * This contract handles the payment and verification for pre-ordering physical bulls. Users * will pre-order physical bulls by exchanging erc20 tokens and burning burgers. */ contract PhysicalBull is Ownable { using Strings for uint256; using SafeERC20 for IERC20; /// contract instances /// IERC20 public erc20; Burger public immutable BurgerContract; Grill2 public immutable GrillContract; ISUPER1155 public constant Astro = ISUPER1155(0x71B11Ac923C967CD5998F23F6dae0d779A6ac8Af); /// if claiming is active /// bool public isClaiming = false; /// the current erc20 payment receiver /// address public vault; /// the number of physical bulls claimed /// uint256 public totalClaims; /// the max number of claims an account can make /// uint256 public maxClaims = 3; /// the number of burgers burned by this contract /// uint256 public totalBurns; /// the number of burgers to burn for 1 physical bull /// uint256 public burnScalar = 1; /// the amount of erc20 tokens to claim 1 physical bull /// uint256 public erc20Cost = 100000000; // 100.000000 $USDC /// the number of burgers each account has burned /// mapping(address => uint256) public accountBurns; /// the number of physcal bulls each account has claimed /// mapping(address => uint256) public accountClaims; /** * @param _vault The address to receive erc20 tokens * @param _erc20 The contract address of the erc20 contract to use for payments * @param _burger The address of the burger contract * @param _grill The address of the new grill contract */ constructor( address _vault, address _erc20, address _burger, address _grill ) { vault = _vault; erc20 = IERC20(_erc20); BurgerContract = Burger(_burger); GrillContract = Grill2(_grill); } /// ============ OWNER ============ /// /** * Toggles if claiming is active */ function toggleClaiming() public onlyOwner { isClaiming = !isClaiming; } /** * Sets the cost for each bull claim * @param _erc20Cost The number of erc20 tokens to transfer */ function setERC20Cost(uint256 _erc20Cost) public onlyOwner { erc20Cost = _erc20Cost; } /** * Sets the erc20 contract address to use for payments * @param _erc20 The erc20 contract address */ function setERC20Address(address _erc20) public onlyOwner { erc20 = IERC20(_erc20); } /** * Sets the number of burgers to burn for each bull claim * @param _burnScalar The number of burgers to burn */ function setBurnScalar(uint256 _burnScalar) public onlyOwner { burnScalar = _burnScalar; } /** * Sets the limit for the max number of claims per account * @param _maxClaims The max number of claims per account */ function setMaxClaims(uint256 _maxClaims) public onlyOwner { maxClaims = _maxClaims; } /** * Sets the address for receiving erc20 payments * @param _vault The address to receive payments */ function setVault(address _vault) public onlyOwner { vault = _vault; } /// ============ INTERNAL ============ /// /** * Checks if `account` owns any astrobulls or has any active stakes * @param account The address to lookup * @return _b If `account` owns or is the staker of > 0 astrobulls * @notice Checks both old and new grill contracts for active stakes */ function _checkCommunityStatus(address account) internal view returns (bool _b) { _b = false; /// @dev first check if caller owns > 0 astrobulls /// if (Astro.groupBalances(1, account) > 0) { _b = true; } /// @dev next, check if caller has any active stakes in the old grill /// else if (GrillContract.stakedIdsPerAccountOld(account).length > 0) { _b = true; } /// @dev lastly, check if caller has any active stakes in the new grill /// else if (GrillContract.stakedIdsPerAccount(account).length > 0) { _b = true; } } /// ============ PUBLIC ============ /// /** * Claims `quantity` number of physical bulls if caller owns > 0 astrobulls * @param quantity The number of bulls to claim * @notice Caller will send `erc20Cost` * `quantity` tokens to `vault` * @notice Caller must give this contract a sufficient allowance to send their erc20 tokens */ function claimBulls(uint256 quantity) public { if (!isClaiming) { revert ClaimingNotActive(); } if (!_checkCommunityStatus(msg.sender)) { revert CallerNotInCommunity(); } if (accountClaims[msg.sender] + quantity > maxClaims) { revert ExceedsMaxClaims(); } if (quantity == 0) { revert InvalidTokenAmount(); } /// @dev sends erc20 tokens from caller to vault /// erc20.safeTransferFrom(msg.sender, vault, quantity * erc20Cost); /// @dev burns caller's burgers /// uint256 toBurn = burnScalar * quantity; BurgerContract.burnBurger(msg.sender, burnScalar * quantity); /// @dev sets contract state /// totalBurns += toBurn; accountBurns[msg.sender] += toBurn; totalClaims += quantity; accountClaims[msg.sender] += quantity; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC1155/ERC1155.sol) pragma solidity ^0.8.0; import "./IERC1155.sol"; import "./IERC1155Receiver.sol"; import "./extensions/IERC1155MetadataURI.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */ contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json string private _uri; /** * @dev See {_setURI}. */ constructor(string memory uri_) { _setURI(uri_); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155).interfaceId || interfaceId == type(IERC1155MetadataURI).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the same URI for *all* token types. It relies * on the token type ID substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * Clients calling this function must replace the `\{id\}` substring with the * actual token type ID. */ function uri(uint256) public view virtual override returns (string memory) { return _uri; } /** * @dev See {IERC1155-balanceOf}. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) public view virtual override returns (uint256) { require(account != address(0), "ERC1155: balance query for the zero address"); return _balances[id][account]; } /** * @dev See {IERC1155-balanceOfBatch}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] memory accounts, uint256[] memory ids) public view virtual override returns (uint256[] memory) { require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch"); uint256[] memory batchBalances = new uint256[](accounts.length); for (uint256 i = 0; i < accounts.length; ++i) { batchBalances[i] = balanceOf(accounts[i], ids[i]); } return batchBalances; } /** * @dev See {IERC1155-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { _setApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC1155-isApprovedForAll}. */ function isApprovedForAll(address account, address operator) public view virtual override returns (bool) { return _operatorApprovals[account][operator]; } /** * @dev See {IERC1155-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not owner nor approved" ); _safeTransferFrom(from, to, id, amount, data); } /** * @dev See {IERC1155-safeBatchTransferFrom}. */ function safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: transfer caller is not owner nor approved" ); _safeBatchTransferFrom(from, to, ids, amounts, data); } /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, from, to, ids, amounts, data); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; emit TransferSingle(operator, from, to, id, amount); _afterTokenTransfer(operator, from, to, ids, amounts, data); _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; } emit TransferBatch(operator, from, to, ids, amounts); _afterTokenTransfer(operator, from, to, ids, amounts, data); _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data); } /** * @dev Sets a new URI for all token types, by relying on the token type ID * substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * By this mechanism, any occurrence of the `\{id\}` substring in either the * URI or any of the amounts in the JSON file at said URI will be replaced by * clients with the token type ID. * * For example, the `https://token-cdn-domain/\{id\}.json` URI would be * interpreted by clients as * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json` * for token type ID 0x4cce0. * * See {uri}. * * Because these URIs cannot be meaningfully represented by the {URI} event, * this function emits no events. */ function _setURI(string memory newuri) internal virtual { _uri = newuri; } /** * @dev Creates `amount` tokens of token type `id`, and assigns them to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint( address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); _balances[id][to] += amount; emit TransferSingle(operator, address(0), to, id, amount); _afterTokenTransfer(operator, address(0), to, ids, amounts, data); _doSafeTransferAcceptanceCheck(operator, address(0), to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); for (uint256 i = 0; i < ids.length; i++) { _balances[ids[i]][to] += amounts[i]; } emit TransferBatch(operator, address(0), to, ids, amounts); _afterTokenTransfer(operator, address(0), to, ids, amounts, data); _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data); } /** * @dev Destroys `amount` tokens of token type `id` from `from` * * Requirements: * * - `from` cannot be the zero address. * - `from` must have at least `amount` tokens of token type `id`. */ function _burn( address from, uint256 id, uint256 amount ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); uint256[] memory ids = _asSingletonArray(id); uint256[] memory amounts = _asSingletonArray(amount); _beforeTokenTransfer(operator, from, address(0), ids, amounts, ""); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } emit TransferSingle(operator, from, address(0), id, amount); _afterTokenTransfer(operator, from, address(0), ids, amounts, ""); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Requirements: * * - `ids` and `amounts` must have the same length. */ function _burnBatch( address from, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(from != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, address(0), ids, amounts, ""); for (uint256 i = 0; i < ids.length; i++) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][from] = fromBalance - amount; } } emit TransferBatch(operator, from, address(0), ids, amounts); _afterTokenTransfer(operator, from, address(0), ids, amounts, ""); } /** * @dev Approve `operator` to operate on all of `owner` tokens * * Emits a {ApprovalForAll} event. */ function _setApprovalForAll( address owner, address operator, bool approved ) internal virtual { require(owner != operator, "ERC1155: setting approval status for self"); _operatorApprovals[owner][operator] = approved; emit ApprovalForAll(owner, operator, approved); } /** * @dev Hook that is called before any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` and `amount` pair): * * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens * of token type `id` will be transferred to `to`. * - When `from` is zero, `amount` tokens of token type `id` will be minted * for `to`. * - when `to` is zero, `amount` of ``from``'s tokens of token type `id` * will be burned. * - `from` and `to` are never both zero. * - `ids` and `amounts` have the same, non-zero length. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual {} /** * @dev Hook that is called after any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` and `amount` pair): * * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens * of token type `id` will be transferred to `to`. * - When `from` is zero, `amount` tokens of token type `id` will be minted * for `to`. * - when `to` is zero, `amount` of ``from``'s tokens of token type `id` * will be burned. * - `from` and `to` are never both zero. * - `ids` and `amounts` have the same, non-zero length. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _afterTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual {} function _doSafeTransferAcceptanceCheck( address operator, address from, address to, uint256 id, uint256 amount, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) { if (response != IERC1155Receiver.onERC1155Received.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _doSafeBatchTransferAcceptanceCheck( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns ( bytes4 response ) { if (response != IERC1155Receiver.onERC1155BatchReceived.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) { uint256[] memory array = new uint256[](1); array[0] = element; return array; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) 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() { _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); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Counters.sol) pragma solidity ^0.8.0; /** * @title Counters * @author Matt Condon (@shrugs) * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number * of elements in a mapping, issuing ERC721 ids, or counting request ids. * * Include with `using Counters for Counters.Counter;` */ library Counters { struct Counter { // This variable should never be directly accessed by users of the library: interactions must be restricted to // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add // this feature: see https://github.com/ethereum/solidity/issues/4637 uint256 _value; // default: 0 } function current(Counter storage counter) internal view returns (uint256) { return counter._value; } function increment(Counter storage counter) internal { unchecked { counter._value += 1; } } function decrement(Counter storage counter) internal { uint256 value = counter._value; require(value > 0, "Counter: decrement overflow"); unchecked { counter._value = value - 1; } } function reset(Counter storage counter) internal { counter._value = 0; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) 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); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC1155/IERC1155.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC1155 compliant contract, as defined in the * https://eips.ethereum.org/EIPS/eip-1155[EIP]. * * _Available since v3.1._ */ interface IERC1155 is IERC165 { /** * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`. */ event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value); /** * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all * transfers. */ event TransferBatch( address indexed operator, address indexed from, address indexed to, uint256[] ids, uint256[] values ); /** * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to * `approved`. */ event ApprovalForAll(address indexed account, address indexed operator, bool approved); /** * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI. * * If an {URI} event was emitted for `id`, the standard * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value * returned by {IERC1155MetadataURI-uri}. */ event URI(string value, uint256 indexed id); /** * @dev Returns the amount of tokens of token type `id` owned by `account`. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) external view returns (uint256); /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids) external view returns (uint256[] memory); /** * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`, * * Emits an {ApprovalForAll} event. * * Requirements: * * - `operator` cannot be the caller. */ function setApprovalForAll(address operator, bool approved) external; /** * @dev Returns true if `operator` is approved to transfer ``account``'s tokens. * * See {setApprovalForAll}. */ function isApprovedForAll(address account, address operator) external view returns (bool); /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If the caller is not `from`, it must be have been approved to spend ``from``'s tokens via {setApprovalForAll}. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes calldata data ) external; /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function safeBatchTransferFrom( address from, address to, uint256[] calldata ids, uint256[] calldata amounts, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/IERC1155Receiver.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev _Available since v3.1._ */ interface IERC1155Receiver is IERC165 { /** * @dev Handles the receipt of a single ERC1155 token type. This function is * called at the end of a `safeTransferFrom` after the balance has been updated. * * NOTE: To accept the transfer, this must return * `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` * (i.e. 0xf23a6e61, or its own function selector). * * @param operator The address which initiated the transfer (i.e. msg.sender) * @param from The address which previously owned the token * @param id The ID of the token being transferred * @param value The amount of tokens being transferred * @param data Additional data with no specified format * @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed */ function onERC1155Received( address operator, address from, uint256 id, uint256 value, bytes calldata data ) external returns (bytes4); /** * @dev Handles the receipt of a multiple ERC1155 token types. This function * is called at the end of a `safeBatchTransferFrom` after the balances have * been updated. * * NOTE: To accept the transfer(s), this must return * `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` * (i.e. 0xbc197c81, or its own function selector). * * @param operator The address which initiated the batch transfer (i.e. msg.sender) * @param from The address which previously owned the token * @param ids An array containing ids of each token being transferred (order and length must match values array) * @param values An array containing amounts of each token being transferred (order and length must match ids array) * @param data Additional data with no specified format * @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed */ function onERC1155BatchReceived( address operator, address from, uint256[] calldata ids, uint256[] calldata values, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC1155/extensions/IERC1155MetadataURI.sol) pragma solidity ^0.8.0; import "../IERC1155.sol"; /** * @dev Interface of the optional ERC1155MetadataExtension interface, as defined * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP]. * * _Available since v3.1._ */ interface IERC1155MetadataURI is IERC1155 { /** * @dev Returns the URI for token type `id`. * * If the `\{id\}` substring is present in the URI, it must be replaced by * clients with the actual token type ID. */ function uri(uint256 id) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @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 * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 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); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) 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; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) 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; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) 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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC1155/utils/ERC1155Holder.sol) pragma solidity ^0.8.0; import "./ERC1155Receiver.sol"; /** * Simple implementation of `ERC1155Receiver` that will allow a contract to hold ERC1155 tokens. * * IMPORTANT: When inheriting this contract, you must include a way to use the received tokens, otherwise they will be * stuck. * * @dev _Available since v3.1._ */ contract ERC1155Holder is ERC1155Receiver { function onERC1155Received( address, address, uint256, uint256, bytes memory ) public virtual override returns (bytes4) { return this.onERC1155Received.selector; } function onERC1155BatchReceived( address, address, uint256[] memory, uint256[] memory, bytes memory ) public virtual override returns (bytes4) { return this.onERC1155BatchReceived.selector; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC1155/utils/ERC1155Receiver.sol) pragma solidity ^0.8.0; import "../IERC1155Receiver.sol"; import "../../../utils/introspection/ERC165.sol"; /** * @dev _Available since v3.1._ */ abstract contract ERC1155Receiver is ERC165, IERC1155Receiver { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155Receiver).interfaceId || super.supportsInterface(interfaceId); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; import "../IERC20.sol"; import "../../../utils/Address.sol"; /** * @title SafeERC20 * @dev Wrappers around ERC20 operations that throw on failure (when the token * contract returns false). Tokens that return no value (and instead revert or * throw on failure) are also supported, non-reverting calls are assumed to be * successful. * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. */ library SafeERC20 { using Address for address; function safeTransfer( IERC20 token, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } function safeTransferFrom( IERC20 token, address from, address to, uint256 value ) internal { _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** * @dev Deprecated. This function has issues similar to the ones found in * {IERC20-approve}, and its usage is discouraged. * * Whenever possible, use {safeIncreaseAllowance} and * {safeDecreaseAllowance} instead. */ function safeApprove( IERC20 token, address spender, uint256 value ) internal { // safeApprove should only be called when setting an initial allowance, // or when resetting it to zero. To increase and decrease it, use // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' require( (value == 0) || (token.allowance(address(this), spender) == 0), "SafeERC20: approve from non-zero to non-zero allowance" ); _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } function safeIncreaseAllowance( IERC20 token, address spender, uint256 value ) internal { uint256 newAllowance = token.allowance(address(this), spender) + value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } function safeDecreaseAllowance( IERC20 token, address spender, uint256 value ) internal { unchecked { uint256 oldAllowance = token.allowance(address(this), spender); require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); uint256 newAllowance = oldAllowance - value; _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } /** * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement * on the return value: the return value is optional (but if data is returned, it must not be false). * @param token The token targeted by the call. * @param data The call data (encoded using abi.encode or one of its variants). */ function _callOptionalReturn(IERC20 token, bytes memory data) private { // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since // we're implementing it ourselves. We use {Address.functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); if (returndata.length > 0) { // Return data is optional require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC20 standard as defined in the EIP. */ interface IERC20 { /** * @dev Emitted when `value` tokens are moved from one account (`from`) to * another (`to`). * * Note that `value` may be zero. */ event Transfer(address indexed from, address indexed to, uint256 value); /** * @dev Emitted when the allowance of a `spender` for an `owner` is set by * a call to {approve}. `value` is the new allowance. */ event Approval(address indexed owner, address indexed spender, uint256 value); /** * @dev 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 `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ function transfer(address to, 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 `from` to `to` 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 from, address to, uint256 amount ) external returns (bool); }
// SPDX-License-Identifier: MIT // ERC721A Contracts v3.3.0 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721A.sol'; import '@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol'; import '@openzeppelin/contracts/utils/Address.sol'; import '@openzeppelin/contracts/utils/Context.sol'; import '@openzeppelin/contracts/utils/Strings.sol'; import '@openzeppelin/contracts/utils/introspection/ERC165.sol'; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension. Built to optimize for lower gas during batch mints. * * Assumes serials are sequentially minted starting at _startTokenId() (defaults to 0, e.g. 0, 1, 2, 3..). * * Assumes that an owner cannot have more than 2**64 - 1 (max value of uint64) of supply. * * Assumes that the maximum token id cannot exceed 2**256 - 1 (max value of uint256). */ contract ERC721A is Context, ERC165, IERC721A { using Address for address; using Strings for uint256; // The tokenId of the next token to be minted. uint256 internal _currentIndex; // The number of tokens burned. uint256 internal _burnCounter; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to ownership details // An empty struct value does not necessarily mean the token is unowned. See _ownershipOf implementation for details. mapping(uint256 => TokenOwnership) internal _ownerships; // Mapping owner address to address data mapping(address => AddressData) private _addressData; // 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; constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; _currentIndex = _startTokenId(); } /** * To change the starting tokenId, please override this function. */ function _startTokenId() internal view virtual returns (uint256) { return 0; } /** * @dev Burned tokens are calculated here, use _totalMinted() if you want to count just minted tokens. */ function totalSupply() public view override returns (uint256) { // Counter underflow is impossible as _burnCounter cannot be incremented // more than _currentIndex - _startTokenId() times unchecked { return _currentIndex - _burnCounter - _startTokenId(); } } /** * Returns the total amount of tokens minted in the contract. */ function _totalMinted() internal view returns (uint256) { // Counter underflow is impossible as _currentIndex does not decrement, // and it is initialized to _startTokenId() unchecked { return _currentIndex - _startTokenId(); } } /** * @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 override returns (uint256) { if (owner == address(0)) revert BalanceQueryForZeroAddress(); return uint256(_addressData[owner].balance); } /** * Returns the number of tokens minted by `owner`. */ function _numberMinted(address owner) internal view returns (uint256) { return uint256(_addressData[owner].numberMinted); } /** * Returns the number of tokens burned by or on behalf of `owner`. */ function _numberBurned(address owner) internal view returns (uint256) { return uint256(_addressData[owner].numberBurned); } /** * Returns the auxillary data for `owner`. (e.g. number of whitelist mint slots used). */ function _getAux(address owner) internal view returns (uint64) { return _addressData[owner].aux; } /** * Sets the auxillary data for `owner`. (e.g. number of whitelist mint slots used). * If there are multiple variables, please pack them into a uint64. */ function _setAux(address owner, uint64 aux) internal { _addressData[owner].aux = aux; } /** * Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around in the collection over time. */ function _ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) { uint256 curr = tokenId; unchecked { if (_startTokenId() <= curr) if (curr < _currentIndex) { TokenOwnership memory ownership = _ownerships[curr]; if (!ownership.burned) { if (ownership.addr != address(0)) { return ownership; } // Invariant: // There will always be an ownership that has an address and is not burned // before an ownership that does not have an address and is not burned. // Hence, curr will not underflow. while (true) { curr--; ownership = _ownerships[curr]; if (ownership.addr != address(0)) { return ownership; } } } } } revert OwnerQueryForNonexistentToken(); } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view override returns (address) { return _ownershipOf(tokenId).addr; } /** * @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) { if (!_exists(tokenId)) revert URIQueryForNonexistentToken(); 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 override { address owner = ERC721A.ownerOf(tokenId); if (to == owner) revert ApprovalToCurrentOwner(); if (_msgSender() != owner) if(!isApprovedForAll(owner, _msgSender())) { revert ApprovalCallerNotOwnerNorApproved(); } _approve(to, tokenId, owner); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { if (operator == _msgSender()) revert ApproveToCaller(); _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 { _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 { _transfer(from, to, tokenId); if (to.isContract()) if(!_checkContractOnERC721Received(from, to, tokenId, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } /** * @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`), */ function _exists(uint256 tokenId) internal view returns (bool) { return _startTokenId() <= tokenId && tokenId < _currentIndex && !_ownerships[tokenId].burned; } /** * @dev Equivalent to `_safeMint(to, quantity, '')`. */ function _safeMint(address to, uint256 quantity) internal { _safeMint(to, quantity, ''); } /** * @dev Safely mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - If `to` refers to a smart contract, it must implement * {IERC721Receiver-onERC721Received}, which is called for each safe transfer. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1 // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1 unchecked { _addressData[to].balance += uint64(quantity); _addressData[to].numberMinted += uint64(quantity); _ownerships[startTokenId].addr = to; _ownerships[startTokenId].startTimestamp = uint64(block.timestamp); uint256 updatedIndex = startTokenId; uint256 end = updatedIndex + quantity; if (to.isContract()) { do { emit Transfer(address(0), to, updatedIndex); if (!_checkContractOnERC721Received(address(0), to, updatedIndex++, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } while (updatedIndex < end); // Reentrancy protection if (_currentIndex != startTokenId) revert(); } else { do { emit Transfer(address(0), to, updatedIndex++); } while (updatedIndex < end); } _currentIndex = updatedIndex; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _mint(address to, uint256 quantity) internal { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // balance or numberMinted overflow if current value of either + quantity > 1.8e19 (2**64) - 1 // updatedIndex overflows if _currentIndex + quantity > 1.2e77 (2**256) - 1 unchecked { _addressData[to].balance += uint64(quantity); _addressData[to].numberMinted += uint64(quantity); _ownerships[startTokenId].addr = to; _ownerships[startTokenId].startTimestamp = uint64(block.timestamp); uint256 updatedIndex = startTokenId; uint256 end = updatedIndex + quantity; do { emit Transfer(address(0), to, updatedIndex++); } while (updatedIndex < end); _currentIndex = updatedIndex; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Transfers `tokenId` from `from` to `to`. * * 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 ) private { TokenOwnership memory prevOwnership = _ownershipOf(tokenId); if (prevOwnership.addr != from) revert TransferFromIncorrectOwner(); bool isApprovedOrOwner = (_msgSender() == from || isApprovedForAll(from, _msgSender()) || getApproved(tokenId) == _msgSender()); if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved(); if (to == address(0)) revert TransferToZeroAddress(); _beforeTokenTransfers(from, to, tokenId, 1); // Clear approvals from the previous owner _approve(address(0), tokenId, from); // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256. unchecked { _addressData[from].balance -= 1; _addressData[to].balance += 1; TokenOwnership storage currSlot = _ownerships[tokenId]; currSlot.addr = to; currSlot.startTimestamp = uint64(block.timestamp); // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it. // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls. uint256 nextTokenId = tokenId + 1; TokenOwnership storage nextSlot = _ownerships[nextTokenId]; if (nextSlot.addr == address(0)) { // This will suffice for checking _exists(nextTokenId), // as a burned slot cannot contain the zero address. if (nextTokenId != _currentIndex) { nextSlot.addr = from; nextSlot.startTimestamp = prevOwnership.startTimestamp; } } } emit Transfer(from, to, tokenId); _afterTokenTransfers(from, to, tokenId, 1); } /** * @dev Equivalent to `_burn(tokenId, false)`. */ function _burn(uint256 tokenId) internal virtual { _burn(tokenId, false); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId, bool approvalCheck) internal virtual { TokenOwnership memory prevOwnership = _ownershipOf(tokenId); address from = prevOwnership.addr; if (approvalCheck) { bool isApprovedOrOwner = (_msgSender() == from || isApprovedForAll(from, _msgSender()) || getApproved(tokenId) == _msgSender()); if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved(); } _beforeTokenTransfers(from, address(0), tokenId, 1); // Clear approvals from the previous owner _approve(address(0), tokenId, from); // Underflow of the sender's balance is impossible because we check for // ownership above and the recipient's balance can't realistically overflow. // Counter overflow is incredibly unrealistic as tokenId would have to be 2**256. unchecked { AddressData storage addressData = _addressData[from]; addressData.balance -= 1; addressData.numberBurned += 1; // Keep track of who burned the token, and the timestamp of burning. TokenOwnership storage currSlot = _ownerships[tokenId]; currSlot.addr = from; currSlot.startTimestamp = uint64(block.timestamp); currSlot.burned = true; // If the ownership slot of tokenId+1 is not explicitly set, that means the burn initiator owns it. // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls. uint256 nextTokenId = tokenId + 1; TokenOwnership storage nextSlot = _ownerships[nextTokenId]; if (nextSlot.addr == address(0)) { // This will suffice for checking _exists(nextTokenId), // as a burned slot cannot contain the zero address. if (nextTokenId != _currentIndex) { nextSlot.addr = from; nextSlot.startTimestamp = prevOwnership.startTimestamp; } } } emit Transfer(from, address(0), tokenId); _afterTokenTransfers(from, address(0), tokenId, 1); // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times. unchecked { _burnCounter++; } } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve( address to, uint256 tokenId, address owner ) private { _tokenApprovals[tokenId] = to; emit Approval(owner, to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target 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 _checkContractOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert TransferToNonERC721ReceiverImplementer(); } else { assembly { revert(add(32, reason), mload(reason)) } } } } /** * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting. * And also called before burning one token. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * 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, `tokenId` will be burned by `from`. * - `from` and `to` are never both zero. */ function _beforeTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes * minting. * And also called after one token has been burned. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * Calling conditions: * * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been * transferred to `to`. * - When `from` is zero, `tokenId` has been minted for `to`. * - When `to` is zero, `tokenId` has been burned by `from`. * - `from` and `to` are never both zero. */ function _afterTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} }
// SPDX-License-Identifier: MIT // ERC721A Contracts v3.3.0 // Creator: Chiru Labs pragma solidity ^0.8.4; import '@openzeppelin/contracts/token/ERC721/IERC721.sol'; import '@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol'; /** * @dev Interface of an ERC721A compliant contract. */ interface IERC721A is IERC721, IERC721Metadata { /** * The caller must own the token or be an approved operator. */ error ApprovalCallerNotOwnerNorApproved(); /** * The token does not exist. */ error ApprovalQueryForNonexistentToken(); /** * The caller cannot approve to their own address. */ error ApproveToCaller(); /** * The caller cannot approve to the current owner. */ error ApprovalToCurrentOwner(); /** * Cannot query the balance for the zero address. */ error BalanceQueryForZeroAddress(); /** * Cannot mint to the zero address. */ error MintToZeroAddress(); /** * The quantity of tokens minted must be more than zero. */ error MintZeroQuantity(); /** * The token does not exist. */ error OwnerQueryForNonexistentToken(); /** * The caller must own the token or be an approved operator. */ error TransferCallerNotOwnerNorApproved(); /** * The token must be owned by `from`. */ error TransferFromIncorrectOwner(); /** * Cannot safely transfer to a contract that does not implement the ERC721Receiver interface. */ error TransferToNonERC721ReceiverImplementer(); /** * Cannot transfer to the zero address. */ error TransferToZeroAddress(); /** * The token does not exist. */ error URIQueryForNonexistentToken(); // Compiler will pack this into a single 256bit word. struct TokenOwnership { // The address of the owner. address addr; // Keeps track of the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; } // Compiler will pack this into a single 256bit word. struct AddressData { // Realistically, 2**64-1 is more than enough. uint64 balance; // Keeps track of mint count with minimal overhead for tokenomics. uint64 numberMinted; // Keeps track of burn count with minimal overhead for tokenomics. uint64 numberBurned; // For miscellaneous variable(s) pertaining to the address // (e.g. number of whitelist mint slots used). // If there are multiple variables, please pack them into a uint64. uint64 aux; } /** * @dev Returns the total amount of tokens stored by the contract. * * Burned tokens are calculated here, use `_totalMinted()` if you want to count just minted tokens. */ function totalSupply() external view returns (uint256); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721Receiver.sol) 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 `IERC721Receiver.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.6.0) (token/ERC721/IERC721.sol) 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`. * * 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; /** * @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 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 the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @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); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) 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); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "abi" ] } } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"_URI","type":"string"},{"internalType":"address","name":"aGrill","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"BurningNotActive","type":"error"},{"inputs":[],"name":"CallerIsNotABurner","type":"error"},{"inputs":[],"name":"ClaimingNotActive","type":"error"},{"inputs":[],"name":"InsufficientClaimsRemaining","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[],"name":"SpecialGrill","outputs":[{"internalType":"contract Grill2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"TheGrill","outputs":[{"internalType":"contract Grill2","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"accountBurns","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"_balance","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"burnBurger","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"burnerBurns","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"burners","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"}],"name":"claimBurgers","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"claimsUsed","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isBurning","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isClaiming","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isSpecial","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"quantity","type":"uint256"},{"internalType":"address","name":"account","type":"address"}],"name":"ownerMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"bool","name":"status","type":"bool"}],"name":"setBurner","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"aGrill","type":"address"}],"name":"setSpecial","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_URI","type":"string"}],"name":"setURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"toggleBurning","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleClaiming","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleSpecial","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"}],"name":"tokenClaimsLeft","outputs":[{"internalType":"uint256","name":"_remaining","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalBurns","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalMints","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"_totalSupply","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
60a06040526004805462ffffff60a01b191690553480156200002057600080fd5b5060405162002518380380620025188339810160408190526200004391620001b2565b816200004f816200006e565b506200005b3362000087565b6001600160a01b031660805250620002e0565b805162000083906002906020840190620000d9565b5050565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b828054620000e790620002a3565b90600052602060002090601f0160209004810192826200010b576000855562000156565b82601f106200012657805160ff191683800117855562000156565b8280016001018555821562000156579182015b828111156200015657825182559160200191906001019062000139565b506200016492915062000168565b5090565b5b8082111562000164576000815560010162000169565b634e487b7160e01b600052604160045260246000fd5b80516001600160a01b0381168114620001ad57600080fd5b919050565b60008060408385031215620001c657600080fd5b82516001600160401b0380821115620001de57600080fd5b818501915085601f830112620001f357600080fd5b8151818111156200020857620002086200017f565b604051601f8201601f19908116603f011681019083821181831017156200023357620002336200017f565b816040528281526020935088848487010111156200025057600080fd5b600091505b8282101562000274578482018401518183018501529083019062000255565b82821115620002865760008484830101525b95506200029891505085820162000195565b925050509250929050565b600181811c90821680620002b857607f821691505b60208210811415620002da57634e487b7160e01b600052602260045260246000fd5b50919050565b60805161221562000303600039600081816103ec015261115b01526122156000f3fe608060405234801561001057600080fd5b50600436106102055760003560e01c806370a082311161011a578063bedf94bb116100ad578063edb0a6931161007c578063edb0a69314610498578063f242432a146104ab578063f2fde38b146104be578063f55c09e2146104d1578063f7ba1ba9146104f157600080fd5b8063bedf94bb1461042e578063c7ffa66c14610441578063d52c57e014610449578063e985e9c51461045c57600080fd5b80638da5cb5b116100e95780638da5cb5b146103c3578063a22cb465146103d4578063a72563a5146103e7578063b190a1d41461040e57600080fd5b806370a082311461038c578063715018a61461039f5780637cc6cb7a146103a75780638010fc45146103bb57600080fd5b806322dcb0a71161019d5780634e1273f41161016c5780634e1273f41461032957806359bc3472146103495780635b7c82101461035c5780635dcaf24e14610370578063694ca01d1461038357600080fd5b806322dcb0a7146102cf5780632eb2c2d6146102d75780633b678f8b146102ea57806344bb2438146102fe57600080fd5b80630d895ee1116101d95780630d895ee11461028b5780630e89341c1461029e57806318160ddd146102be5780631f21bfbf146102c657600080fd5b8062fdd58e1461020a57806301ffc9a71461023057806302fe53051461025357806303d41e0e14610268575b600080fd5b61021d61021836600461191c565b610511565b6040519081526020015b60405180910390f35b61024361023e36600461195c565b6105a8565b6040519015158152602001610227565b610266610261366004611a21565b6105fa565b005b610243610276366004611a72565b60076020526000908152604090205460ff1681565b610266610299366004611a8d565b610630565b6102b16102ac366004611ac9565b610685565b6040516102279190611b2f565b61021d610719565b61021d60055481565b610266610730565b6102666102e5366004611bf7565b61077b565b60045461024390600160b01b900460ff1681565b600454610311906001600160a01b031681565b6040516001600160a01b039091168152602001610227565b61033c610337366004611ca1565b610812565b6040516102279190611da7565b61026661035736600461191c565b61093c565b60045461024390600160a81b900460ff1681565b61026661037e366004611ac9565b610a0e565b61021d60065481565b61021d61039a366004611a72565b610ae4565b610266610af1565b60045461024390600160a01b900460ff1681565b610266610b27565b6003546001600160a01b0316610311565b6102666103e2366004611a8d565b610b72565b6103117f000000000000000000000000000000000000000000000000000000000000000081565b61021d61041c366004611a72565b600a6020526000908152604090205481565b61021d61043c366004611a72565b610b81565b610266610bad565b610266610457366004611dba565b610bf8565b61024361046a366004611de6565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b6102666104a6366004611a72565b610c5d565b6102666104b9366004611e10565b610ca9565b6102666104cc366004611a72565b610d30565b61021d6104df366004611a72565b60086020526000908152604090205481565b61021d6104ff366004611a72565b60096020526000908152604090205481565b60006001600160a01b0383166105825760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60006001600160e01b03198216636cdb3d1360e11b14806105d957506001600160e01b031982166303a24d0760e21b145b806105f457506301ffc9a760e01b6001600160e01b03198316145b92915050565b6003546001600160a01b031633146106245760405162461bcd60e51b815260040161057990611e75565b61062d81610dc8565b50565b6003546001600160a01b0316331461065a5760405162461bcd60e51b815260040161057990611e75565b6001600160a01b03919091166000908152600760205260409020805460ff1916911515919091179055565b60606002805461069490611eaa565b80601f01602080910402602001604051908101604052809291908181526020018280546106c090611eaa565b801561070d5780601f106106e25761010080835404028352916020019161070d565b820191906000526020600020905b8154815290600101906020018083116106f057829003601f168201915b50505050509050919050565b600060065460055461072b9190611efb565b905090565b6003546001600160a01b0316331461075a5760405162461bcd60e51b815260040161057990611e75565b6004805460ff60a81b198116600160a81b9182900460ff1615909102179055565b6001600160a01b0385163314806107975750610797853361046a565b6107fe5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b6064820152608401610579565b61080b8585858585610ddb565b5050505050565b606081518351146108775760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610579565b6000835167ffffffffffffffff81111561089357610893611980565b6040519080825280602002602001820160405280156108bc578160200160208202803683370190505b50905060005b8451811015610934576109078582815181106108e0576108e0611f12565b60200260200101518583815181106108fa576108fa611f12565b6020026020010151610511565b82828151811061091957610919611f12565b602090810291909101015261092d81611f28565b90506108c2565b509392505050565b600454600160a81b900460ff166109665760405163468a29f160e01b815260040160405180910390fd5b3360009081526007602052604090205460ff1661099657604051631e72908160e21b815260040160405180910390fd5b6109a282600183610fb8565b80600660008282546109b49190611f43565b90915550506001600160a01b038216600090815260096020526040812080548392906109e1908490611f43565b9091555050336000908152600a602052604081208054839290610a05908490611f43565b90915550505050565b600454600160a01b900460ff16610a38576040516321f143f360e11b815260040160405180910390fd5b610a4133611139565b33600090815260086020526040902054610a5c908390611f43565b1115610a7b5760405163e2ff321760e01b815260040160405180910390fd5b610aa433600183604051806040016040528060048152602001630307830360e41b815250611284565b3360009081526008602052604081208054839290610ac3908490611f43565b925050819055508060056000828254610adc9190611f43565b909155505050565b60006105f4826001610511565b6003546001600160a01b03163314610b1b5760405162461bcd60e51b815260040161057990611e75565b610b25600061138f565b565b6003546001600160a01b03163314610b515760405162461bcd60e51b815260040161057990611e75565b6004805460ff60a01b198116600160a01b9182900460ff1615909102179055565b610b7d3383836113e1565b5050565b6001600160a01b038116600090815260086020526040812054610ba383611139565b6105f49190611efb565b6003546001600160a01b03163314610bd75760405162461bcd60e51b815260040161057990611e75565b6004805460ff60b01b198116600160b01b9182900460ff1615909102179055565b6003546001600160a01b03163314610c225760405162461bcd60e51b815260040161057990611e75565b610c4b81600184604051806040016040528060048152602001630307830360e41b815250611284565b8160056000828254610a059190611f43565b6003546001600160a01b03163314610c875760405162461bcd60e51b815260040161057990611e75565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b038516331480610cc55750610cc5853361046a565b610d235760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610579565b61080b85858585856114c2565b6003546001600160a01b03163314610d5a5760405162461bcd60e51b815260040161057990611e75565b6001600160a01b038116610dbf5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610579565b61062d8161138f565b8051610b7d90600290602084019061186c565b8151835114610e3d5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610579565b6001600160a01b038416610e635760405162461bcd60e51b815260040161057990611f5b565b3360005b8451811015610f4a576000858281518110610e8457610e84611f12565b602002602001015190506000858381518110610ea257610ea2611f12565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015610ef25760405162461bcd60e51b815260040161057990611fa0565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290610f2f908490611f43565b9250508190555050505080610f4390611f28565b9050610e67565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051610f9a929190611fea565b60405180910390a4610fb08187878787876115ec565b505050505050565b6001600160a01b03831661101a5760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610579565b33600061102684611757565b9050600061103384611757565b60408051602080820183526000918290528882528181528282206001600160a01b038b16835290522054909150848110156110bc5760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610579565b6000868152602081815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a90529092908816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46040805160208101909152600090525b50505050505050565b6040516304054ed960e41b81526001600160a01b0382811660048301526000917f000000000000000000000000000000000000000000000000000000000000000090911690634054ed909060240160206040518083038186803b15801561119f57600080fd5b505afa1580156111b3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111d79190612018565b6111e19082611f43565b600454909150600160b01b900460ff161561127f57600480546040516304054ed960e41b81526001600160a01b0385811693820193909352911690634054ed909060240160206040518083038186803b15801561123d57600080fd5b505afa158015611251573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112759190612018565b6105f49082611f43565b919050565b6001600160a01b0384166112e45760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610579565b3360006112f085611757565b905060006112fd85611757565b90506000868152602081815260408083206001600160a01b038b1684529091528120805487929061132f908490611f43565b909155505060408051878152602081018790526001600160a01b03808a1692600092918716917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4611130836000898989896117a2565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b031614156114555760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610579565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166114e85760405162461bcd60e51b815260040161057990611f5b565b3360006114f485611757565b9050600061150185611757565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156115445760405162461bcd60e51b815260040161057990611fa0565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a16825281208054889290611581908490611f43565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46115e1848a8a8a8a8a6117a2565b505050505050505050565b6001600160a01b0384163b15610fb05760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906116309089908990889088908890600401612031565b602060405180830381600087803b15801561164a57600080fd5b505af192505050801561167a575060408051601f3d908101601f191682019092526116779181019061208f565b60015b611727576116866120ac565b806308c379a014156116c0575061169b6120c8565b806116a657506116c2565b8060405162461bcd60e51b81526004016105799190611b2f565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610579565b6001600160e01b0319811663bc197c8160e01b146111305760405162461bcd60e51b815260040161057990612152565b6040805160018082528183019092526060916000919060208083019080368337019050509050828160008151811061179157611791611f12565b602090810291909101015292915050565b6001600160a01b0384163b15610fb05760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e61906117e6908990899088908890889060040161219a565b602060405180830381600087803b15801561180057600080fd5b505af1925050508015611830575060408051601f3d908101601f1916820190925261182d9181019061208f565b60015b61183c576116866120ac565b6001600160e01b0319811663f23a6e6160e01b146111305760405162461bcd60e51b815260040161057990612152565b82805461187890611eaa565b90600052602060002090601f01602090048101928261189a57600085556118e0565b82601f106118b357805160ff19168380011785556118e0565b828001600101855582156118e0579182015b828111156118e05782518255916020019190600101906118c5565b506118ec9291506118f0565b5090565b5b808211156118ec57600081556001016118f1565b80356001600160a01b038116811461127f57600080fd5b6000806040838503121561192f57600080fd5b61193883611905565b946020939093013593505050565b6001600160e01b03198116811461062d57600080fd5b60006020828403121561196e57600080fd5b813561197981611946565b9392505050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff811182821017156119bc576119bc611980565b6040525050565b600067ffffffffffffffff8311156119dd576119dd611980565b6040516119f4601f8501601f191660200182611996565b809150838152848484011115611a0957600080fd5b83836020830137600060208583010152509392505050565b600060208284031215611a3357600080fd5b813567ffffffffffffffff811115611a4a57600080fd5b8201601f81018413611a5b57600080fd5b611a6a848235602084016119c3565b949350505050565b600060208284031215611a8457600080fd5b61197982611905565b60008060408385031215611aa057600080fd5b611aa983611905565b915060208301358015158114611abe57600080fd5b809150509250929050565b600060208284031215611adb57600080fd5b5035919050565b6000815180845260005b81811015611b0857602081850181015186830182015201611aec565b81811115611b1a576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006119796020830184611ae2565b600067ffffffffffffffff821115611b5c57611b5c611980565b5060051b60200190565b600082601f830112611b7757600080fd5b81356020611b8482611b42565b604051611b918282611996565b83815260059390931b8501820192828101915086841115611bb157600080fd5b8286015b84811015611bcc5780358352918301918301611bb5565b509695505050505050565b600082601f830112611be857600080fd5b611979838335602085016119c3565b600080600080600060a08688031215611c0f57600080fd5b611c1886611905565b9450611c2660208701611905565b9350604086013567ffffffffffffffff80821115611c4357600080fd5b611c4f89838a01611b66565b94506060880135915080821115611c6557600080fd5b611c7189838a01611b66565b93506080880135915080821115611c8757600080fd5b50611c9488828901611bd7565b9150509295509295909350565b60008060408385031215611cb457600080fd5b823567ffffffffffffffff80821115611ccc57600080fd5b818501915085601f830112611ce057600080fd5b81356020611ced82611b42565b604051611cfa8282611996565b83815260059390931b8501820192828101915089841115611d1a57600080fd5b948201945b83861015611d3f57611d3086611905565b82529482019490820190611d1f565b96505086013592505080821115611d5557600080fd5b50611d6285828601611b66565b9150509250929050565b600081518084526020808501945080840160005b83811015611d9c57815187529582019590820190600101611d80565b509495945050505050565b6020815260006119796020830184611d6c565b60008060408385031215611dcd57600080fd5b82359150611ddd60208401611905565b90509250929050565b60008060408385031215611df957600080fd5b611e0283611905565b9150611ddd60208401611905565b600080600080600060a08688031215611e2857600080fd5b611e3186611905565b9450611e3f60208701611905565b93506040860135925060608601359150608086013567ffffffffffffffff811115611e6957600080fd5b611c9488828901611bd7565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600181811c90821680611ebe57607f821691505b60208210811415611edf57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600082821015611f0d57611f0d611ee5565b500390565b634e487b7160e01b600052603260045260246000fd5b6000600019821415611f3c57611f3c611ee5565b5060010190565b60008219821115611f5657611f56611ee5565b500190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000611ffd6040830185611d6c565b828103602084015261200f8185611d6c565b95945050505050565b60006020828403121561202a57600080fd5b5051919050565b6001600160a01b0386811682528516602082015260a06040820181905260009061205d90830186611d6c565b828103606084015261206f8186611d6c565b905082810360808401526120838185611ae2565b98975050505050505050565b6000602082840312156120a157600080fd5b815161197981611946565b600060033d11156120c55760046000803e5060005160e01c5b90565b600060443d10156120d65790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561210657505050505090565b828501915081518181111561211e5750505050505090565b843d87010160208285010111156121385750505050505090565b61214760208286010187611996565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a0608082018190526000906121d490830184611ae2565b97965050505050505056fea2646970667358221220662d6784e8c15e1546e337e700f05708897e4f2eefb1ee36744e7cdf40f5ca3164736f6c63430008090033000000000000000000000000000000000000000000000000000000000000004000000000000000000000000090dd49e039b6c1343cdd59c7032c51a9f769823f00000000000000000000000000000000000000000000000000000000000000236d656469612e617374726f6672656e732e636f6d2f6275726765722f7b7d2e6a736f6e0000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106102055760003560e01c806370a082311161011a578063bedf94bb116100ad578063edb0a6931161007c578063edb0a69314610498578063f242432a146104ab578063f2fde38b146104be578063f55c09e2146104d1578063f7ba1ba9146104f157600080fd5b8063bedf94bb1461042e578063c7ffa66c14610441578063d52c57e014610449578063e985e9c51461045c57600080fd5b80638da5cb5b116100e95780638da5cb5b146103c3578063a22cb465146103d4578063a72563a5146103e7578063b190a1d41461040e57600080fd5b806370a082311461038c578063715018a61461039f5780637cc6cb7a146103a75780638010fc45146103bb57600080fd5b806322dcb0a71161019d5780634e1273f41161016c5780634e1273f41461032957806359bc3472146103495780635b7c82101461035c5780635dcaf24e14610370578063694ca01d1461038357600080fd5b806322dcb0a7146102cf5780632eb2c2d6146102d75780633b678f8b146102ea57806344bb2438146102fe57600080fd5b80630d895ee1116101d95780630d895ee11461028b5780630e89341c1461029e57806318160ddd146102be5780631f21bfbf146102c657600080fd5b8062fdd58e1461020a57806301ffc9a71461023057806302fe53051461025357806303d41e0e14610268575b600080fd5b61021d61021836600461191c565b610511565b6040519081526020015b60405180910390f35b61024361023e36600461195c565b6105a8565b6040519015158152602001610227565b610266610261366004611a21565b6105fa565b005b610243610276366004611a72565b60076020526000908152604090205460ff1681565b610266610299366004611a8d565b610630565b6102b16102ac366004611ac9565b610685565b6040516102279190611b2f565b61021d610719565b61021d60055481565b610266610730565b6102666102e5366004611bf7565b61077b565b60045461024390600160b01b900460ff1681565b600454610311906001600160a01b031681565b6040516001600160a01b039091168152602001610227565b61033c610337366004611ca1565b610812565b6040516102279190611da7565b61026661035736600461191c565b61093c565b60045461024390600160a81b900460ff1681565b61026661037e366004611ac9565b610a0e565b61021d60065481565b61021d61039a366004611a72565b610ae4565b610266610af1565b60045461024390600160a01b900460ff1681565b610266610b27565b6003546001600160a01b0316610311565b6102666103e2366004611a8d565b610b72565b6103117f00000000000000000000000090dd49e039b6c1343cdd59c7032c51a9f769823f81565b61021d61041c366004611a72565b600a6020526000908152604090205481565b61021d61043c366004611a72565b610b81565b610266610bad565b610266610457366004611dba565b610bf8565b61024361046a366004611de6565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b6102666104a6366004611a72565b610c5d565b6102666104b9366004611e10565b610ca9565b6102666104cc366004611a72565b610d30565b61021d6104df366004611a72565b60086020526000908152604090205481565b61021d6104ff366004611a72565b60096020526000908152604090205481565b60006001600160a01b0383166105825760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000908152602081815260408083206001600160a01b03949094168352929052205490565b60006001600160e01b03198216636cdb3d1360e11b14806105d957506001600160e01b031982166303a24d0760e21b145b806105f457506301ffc9a760e01b6001600160e01b03198316145b92915050565b6003546001600160a01b031633146106245760405162461bcd60e51b815260040161057990611e75565b61062d81610dc8565b50565b6003546001600160a01b0316331461065a5760405162461bcd60e51b815260040161057990611e75565b6001600160a01b03919091166000908152600760205260409020805460ff1916911515919091179055565b60606002805461069490611eaa565b80601f01602080910402602001604051908101604052809291908181526020018280546106c090611eaa565b801561070d5780601f106106e25761010080835404028352916020019161070d565b820191906000526020600020905b8154815290600101906020018083116106f057829003601f168201915b50505050509050919050565b600060065460055461072b9190611efb565b905090565b6003546001600160a01b0316331461075a5760405162461bcd60e51b815260040161057990611e75565b6004805460ff60a81b198116600160a81b9182900460ff1615909102179055565b6001600160a01b0385163314806107975750610797853361046a565b6107fe5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b6064820152608401610579565b61080b8585858585610ddb565b5050505050565b606081518351146108775760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610579565b6000835167ffffffffffffffff81111561089357610893611980565b6040519080825280602002602001820160405280156108bc578160200160208202803683370190505b50905060005b8451811015610934576109078582815181106108e0576108e0611f12565b60200260200101518583815181106108fa576108fa611f12565b6020026020010151610511565b82828151811061091957610919611f12565b602090810291909101015261092d81611f28565b90506108c2565b509392505050565b600454600160a81b900460ff166109665760405163468a29f160e01b815260040160405180910390fd5b3360009081526007602052604090205460ff1661099657604051631e72908160e21b815260040160405180910390fd5b6109a282600183610fb8565b80600660008282546109b49190611f43565b90915550506001600160a01b038216600090815260096020526040812080548392906109e1908490611f43565b9091555050336000908152600a602052604081208054839290610a05908490611f43565b90915550505050565b600454600160a01b900460ff16610a38576040516321f143f360e11b815260040160405180910390fd5b610a4133611139565b33600090815260086020526040902054610a5c908390611f43565b1115610a7b5760405163e2ff321760e01b815260040160405180910390fd5b610aa433600183604051806040016040528060048152602001630307830360e41b815250611284565b3360009081526008602052604081208054839290610ac3908490611f43565b925050819055508060056000828254610adc9190611f43565b909155505050565b60006105f4826001610511565b6003546001600160a01b03163314610b1b5760405162461bcd60e51b815260040161057990611e75565b610b25600061138f565b565b6003546001600160a01b03163314610b515760405162461bcd60e51b815260040161057990611e75565b6004805460ff60a01b198116600160a01b9182900460ff1615909102179055565b610b7d3383836113e1565b5050565b6001600160a01b038116600090815260086020526040812054610ba383611139565b6105f49190611efb565b6003546001600160a01b03163314610bd75760405162461bcd60e51b815260040161057990611e75565b6004805460ff60b01b198116600160b01b9182900460ff1615909102179055565b6003546001600160a01b03163314610c225760405162461bcd60e51b815260040161057990611e75565b610c4b81600184604051806040016040528060048152602001630307830360e41b815250611284565b8160056000828254610a059190611f43565b6003546001600160a01b03163314610c875760405162461bcd60e51b815260040161057990611e75565b600480546001600160a01b0319166001600160a01b0392909216919091179055565b6001600160a01b038516331480610cc55750610cc5853361046a565b610d235760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610579565b61080b85858585856114c2565b6003546001600160a01b03163314610d5a5760405162461bcd60e51b815260040161057990611e75565b6001600160a01b038116610dbf5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610579565b61062d8161138f565b8051610b7d90600290602084019061186c565b8151835114610e3d5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610579565b6001600160a01b038416610e635760405162461bcd60e51b815260040161057990611f5b565b3360005b8451811015610f4a576000858281518110610e8457610e84611f12565b602002602001015190506000858381518110610ea257610ea2611f12565b602090810291909101810151600084815280835260408082206001600160a01b038e168352909352919091205490915081811015610ef25760405162461bcd60e51b815260040161057990611fa0565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b16825281208054849290610f2f908490611f43565b9250508190555050505080610f4390611f28565b9050610e67565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051610f9a929190611fea565b60405180910390a4610fb08187878787876115ec565b505050505050565b6001600160a01b03831661101a5760405162461bcd60e51b815260206004820152602360248201527f455243313135353a206275726e2066726f6d20746865207a65726f206164647260448201526265737360e81b6064820152608401610579565b33600061102684611757565b9050600061103384611757565b60408051602080820183526000918290528882528181528282206001600160a01b038b16835290522054909150848110156110bc5760405162461bcd60e51b8152602060048201526024808201527f455243313135353a206275726e20616d6f756e7420657863656564732062616c604482015263616e636560e01b6064820152608401610579565b6000868152602081815260408083206001600160a01b038b81168086529184528285208a8703905582518b81529384018a90529092908816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46040805160208101909152600090525b50505050505050565b6040516304054ed960e41b81526001600160a01b0382811660048301526000917f00000000000000000000000090dd49e039b6c1343cdd59c7032c51a9f769823f90911690634054ed909060240160206040518083038186803b15801561119f57600080fd5b505afa1580156111b3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111d79190612018565b6111e19082611f43565b600454909150600160b01b900460ff161561127f57600480546040516304054ed960e41b81526001600160a01b0385811693820193909352911690634054ed909060240160206040518083038186803b15801561123d57600080fd5b505afa158015611251573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112759190612018565b6105f49082611f43565b919050565b6001600160a01b0384166112e45760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610579565b3360006112f085611757565b905060006112fd85611757565b90506000868152602081815260408083206001600160a01b038b1684529091528120805487929061132f908490611f43565b909155505060408051878152602081018790526001600160a01b03808a1692600092918716917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4611130836000898989896117a2565b600380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b031614156114555760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610579565b6001600160a01b03838116600081815260016020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6001600160a01b0384166114e85760405162461bcd60e51b815260040161057990611f5b565b3360006114f485611757565b9050600061150185611757565b90506000868152602081815260408083206001600160a01b038c168452909152902054858110156115445760405162461bcd60e51b815260040161057990611fa0565b6000878152602081815260408083206001600160a01b038d8116855292528083208985039055908a16825281208054889290611581908490611f43565b909155505060408051888152602081018890526001600160a01b03808b16928c821692918816917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a46115e1848a8a8a8a8a6117a2565b505050505050505050565b6001600160a01b0384163b15610fb05760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906116309089908990889088908890600401612031565b602060405180830381600087803b15801561164a57600080fd5b505af192505050801561167a575060408051601f3d908101601f191682019092526116779181019061208f565b60015b611727576116866120ac565b806308c379a014156116c0575061169b6120c8565b806116a657506116c2565b8060405162461bcd60e51b81526004016105799190611b2f565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610579565b6001600160e01b0319811663bc197c8160e01b146111305760405162461bcd60e51b815260040161057990612152565b6040805160018082528183019092526060916000919060208083019080368337019050509050828160008151811061179157611791611f12565b602090810291909101015292915050565b6001600160a01b0384163b15610fb05760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e61906117e6908990899088908890889060040161219a565b602060405180830381600087803b15801561180057600080fd5b505af1925050508015611830575060408051601f3d908101601f1916820190925261182d9181019061208f565b60015b61183c576116866120ac565b6001600160e01b0319811663f23a6e6160e01b146111305760405162461bcd60e51b815260040161057990612152565b82805461187890611eaa565b90600052602060002090601f01602090048101928261189a57600085556118e0565b82601f106118b357805160ff19168380011785556118e0565b828001600101855582156118e0579182015b828111156118e05782518255916020019190600101906118c5565b506118ec9291506118f0565b5090565b5b808211156118ec57600081556001016118f1565b80356001600160a01b038116811461127f57600080fd5b6000806040838503121561192f57600080fd5b61193883611905565b946020939093013593505050565b6001600160e01b03198116811461062d57600080fd5b60006020828403121561196e57600080fd5b813561197981611946565b9392505050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f1916810167ffffffffffffffff811182821017156119bc576119bc611980565b6040525050565b600067ffffffffffffffff8311156119dd576119dd611980565b6040516119f4601f8501601f191660200182611996565b809150838152848484011115611a0957600080fd5b83836020830137600060208583010152509392505050565b600060208284031215611a3357600080fd5b813567ffffffffffffffff811115611a4a57600080fd5b8201601f81018413611a5b57600080fd5b611a6a848235602084016119c3565b949350505050565b600060208284031215611a8457600080fd5b61197982611905565b60008060408385031215611aa057600080fd5b611aa983611905565b915060208301358015158114611abe57600080fd5b809150509250929050565b600060208284031215611adb57600080fd5b5035919050565b6000815180845260005b81811015611b0857602081850181015186830182015201611aec565b81811115611b1a576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006119796020830184611ae2565b600067ffffffffffffffff821115611b5c57611b5c611980565b5060051b60200190565b600082601f830112611b7757600080fd5b81356020611b8482611b42565b604051611b918282611996565b83815260059390931b8501820192828101915086841115611bb157600080fd5b8286015b84811015611bcc5780358352918301918301611bb5565b509695505050505050565b600082601f830112611be857600080fd5b611979838335602085016119c3565b600080600080600060a08688031215611c0f57600080fd5b611c1886611905565b9450611c2660208701611905565b9350604086013567ffffffffffffffff80821115611c4357600080fd5b611c4f89838a01611b66565b94506060880135915080821115611c6557600080fd5b611c7189838a01611b66565b93506080880135915080821115611c8757600080fd5b50611c9488828901611bd7565b9150509295509295909350565b60008060408385031215611cb457600080fd5b823567ffffffffffffffff80821115611ccc57600080fd5b818501915085601f830112611ce057600080fd5b81356020611ced82611b42565b604051611cfa8282611996565b83815260059390931b8501820192828101915089841115611d1a57600080fd5b948201945b83861015611d3f57611d3086611905565b82529482019490820190611d1f565b96505086013592505080821115611d5557600080fd5b50611d6285828601611b66565b9150509250929050565b600081518084526020808501945080840160005b83811015611d9c57815187529582019590820190600101611d80565b509495945050505050565b6020815260006119796020830184611d6c565b60008060408385031215611dcd57600080fd5b82359150611ddd60208401611905565b90509250929050565b60008060408385031215611df957600080fd5b611e0283611905565b9150611ddd60208401611905565b600080600080600060a08688031215611e2857600080fd5b611e3186611905565b9450611e3f60208701611905565b93506040860135925060608601359150608086013567ffffffffffffffff811115611e6957600080fd5b611c9488828901611bd7565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b600181811c90821680611ebe57607f821691505b60208210811415611edf57634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052601160045260246000fd5b600082821015611f0d57611f0d611ee5565b500390565b634e487b7160e01b600052603260045260246000fd5b6000600019821415611f3c57611f3c611ee5565b5060010190565b60008219821115611f5657611f56611ee5565b500190565b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b604081526000611ffd6040830185611d6c565b828103602084015261200f8185611d6c565b95945050505050565b60006020828403121561202a57600080fd5b5051919050565b6001600160a01b0386811682528516602082015260a06040820181905260009061205d90830186611d6c565b828103606084015261206f8186611d6c565b905082810360808401526120838185611ae2565b98975050505050505050565b6000602082840312156120a157600080fd5b815161197981611946565b600060033d11156120c55760046000803e5060005160e01c5b90565b600060443d10156120d65790565b6040516003193d81016004833e81513d67ffffffffffffffff816024840111818411171561210657505050505090565b828501915081518181111561211e5750505050505090565b843d87010160208285010111156121385750505050505090565b61214760208286010187611996565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a0608082018190526000906121d490830184611ae2565b97965050505050505056fea2646970667358221220662d6784e8c15e1546e337e700f05708897e4f2eefb1ee36744e7cdf40f5ca3164736f6c63430008090033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000000000000004000000000000000000000000090dd49e039b6c1343cdd59c7032c51a9f769823f00000000000000000000000000000000000000000000000000000000000000236d656469612e617374726f6672656e732e636f6d2f6275726765722f7b7d2e6a736f6e0000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _URI (string): media.astrofrens.com/burger/{}.json
Arg [1] : aGrill (address): 0x90DD49e039B6C1343cDd59c7032c51a9f769823F
-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000040
Arg [1] : 00000000000000000000000090dd49e039b6c1343cdd59c7032c51a9f769823f
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000023
Arg [3] : 6d656469612e617374726f6672656e732e636f6d2f6275726765722f7b7d2e6a
Arg [4] : 736f6e0000000000000000000000000000000000000000000000000000000000
Deployed Bytecode Sourcemap
661:5409:18:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2185:228:1;;;;;;:::i;:::-;;:::i;:::-;;;597:25:24;;;585:2;570:18;2185:228:1;;;;;;;;1236:305;;;;;;:::i;:::-;;:::i;:::-;;;1184:14:24;;1177:22;1159:41;;1147:2;1132:18;1236:305:1;1019:187:24;2494:77:18;;;;;;:::i;:::-;;:::i;:::-;;1124:39;;;;;;:::i;:::-;;;;;;;;;;;;;;;;3091:102;;;;;;:::i;:::-;;:::i;1940:103:1:-;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;5625:115:18:-;;;:::i;1022:25::-;;;;;;2766:75;;;:::i;4060:430:1:-;;;;;;:::i;:::-;;:::i;943:29:18:-;;;;;-1:-1:-1;;;943:29:18;;;;;;795:26;;;;;-1:-1:-1;;;;;795:26:18;;;;;;-1:-1:-1;;;;;6227:32:24;;;6209:51;;6197:2;6182:18;795:26:18;6048:218:24;2570:508:1;;;;;;:::i;:::-;;:::i;:::-;;;;;;;:::i;4702:449:18:-;;;;;;:::i;:::-;;:::i;910:29::-;;;;;-1:-1:-1;;;910:29:18;;;;;;4025:460;;;;;;:::i;:::-;;:::i;1051:25::-;;;;;;5390:118;;;;;;:::i;:::-;;:::i;1668:101:0:-;;;:::i;876:30:18:-;;;;;-1:-1:-1;;;876:30:18;;;;;;2630:78;;;:::i;1036:85:0:-;1108:6;;-1:-1:-1;;;;;1108:6:0;1036:85;;3146:153:1;;;;;;:::i;:::-;;:::i;759:32:18:-;;;;;1428:46;;;;;;:::i;:::-;;;;;;;;;;;;;;5898:170;;;;;;:::i;:::-;;:::i;3583:75::-;;;:::i;3377:145::-;;;;;;:::i;:::-;;:::i;3366:166:1:-;;;;;;:::i;:::-;-1:-1:-1;;;;;3488:27:1;;;3465:4;3488:27;;;:18;:27;;;;;;;;:37;;;;;;;;;;;;;;;3366:166;3764:93:18;;;;;;:::i;:::-;;:::i;3599:389:1:-;;;;;;:::i;:::-;;:::i;1918:198:0:-;;;;;;:::i;:::-;;:::i;1219:45:18:-;;;;;;:::i;:::-;;;;;;;;;;;;;;1323:47;;;;;;:::i;:::-;;;;;;;;;;;;;;2185:228:1;2271:7;-1:-1:-1;;;;;2298:21:1;;2290:77;;;;-1:-1:-1;;;2290:77:1;;9735:2:24;2290:77:1;;;9717:21:24;9774:2;9754:18;;;9747:30;9813:34;9793:18;;;9786:62;-1:-1:-1;;;9864:18:24;;;9857:41;9915:19;;2290:77:1;;;;;;;;;-1:-1:-1;2384:9:1;:13;;;;;;;;;;;-1:-1:-1;;;;;2384:22:1;;;;;;;;;;;;2185:228::o;1236:305::-;1338:4;-1:-1:-1;;;;;;1373:41:1;;-1:-1:-1;;;1373:41:1;;:109;;-1:-1:-1;;;;;;;1430:52:1;;-1:-1:-1;;;1430:52:1;1373:109;:161;;;-1:-1:-1;;;;;;;;;;937:40:16;;;1498:36:1;1354:180;1236:305;-1:-1:-1;;1236:305:1:o;2494:77:18:-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;2553:13:18::1;2561:4;2553:7;:13::i;:::-;2494:77:::0;:::o;3091:102::-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;-1:-1:-1;;;;;3163:16:18;;;::::1;;::::0;;;:7:::1;:16;::::0;;;;:25;;-1:-1:-1;;3163:25:18::1;::::0;::::1;;::::0;;;::::1;::::0;;3091:102::o;1940:103:1:-;2000:13;2032:4;2025:11;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1940:103;;;:::o;5625:115:18:-;5669:20;5725:10;;5712;;:23;;;;:::i;:::-;5697:38;;5625:115;:::o;2766:75::-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;2827:9:18::1;::::0;;-1:-1:-1;;;;2814:22:18;::::1;-1:-1:-1::0;;;2827:9:18;;;::::1;;;2826:10;2814:22:::0;;::::1;;::::0;;2766:75::o;4060:430:1:-;-1:-1:-1;;;;;4285:20:1;;719:10:13;4285:20:1;;:60;;-1:-1:-1;4309:36:1;4326:4;719:10:13;3366:166:1;:::i;4309:36::-;4264:157;;;;-1:-1:-1;;;4264:157:1;;11155:2:24;4264:157:1;;;11137:21:24;11194:2;11174:18;;;11167:30;11233:34;11213:18;;;11206:62;-1:-1:-1;;;11284:18:24;;;11277:48;11342:19;;4264:157:1;10953:414:24;4264:157:1;4431:52;4454:4;4460:2;4464:3;4469:7;4478:4;4431:22;:52::i;:::-;4060:430;;;;;:::o;2570:508::-;2721:16;2780:3;:10;2761:8;:15;:29;2753:83;;;;-1:-1:-1;;;2753:83:1;;11574:2:24;2753:83:1;;;11556:21:24;11613:2;11593:18;;;11586:30;11652:34;11632:18;;;11625:62;-1:-1:-1;;;11703:18:24;;;11696:39;11752:19;;2753:83:1;11372:405:24;2753:83:1;2847:30;2894:8;:15;2880:30;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;2880:30:1;;2847:63;;2926:9;2921:120;2945:8;:15;2941:1;:19;2921:120;;;3000:30;3010:8;3019:1;3010:11;;;;;;;;:::i;:::-;;;;;;;3023:3;3027:1;3023:6;;;;;;;;:::i;:::-;;;;;;;3000:9;:30::i;:::-;2981:13;2995:1;2981:16;;;;;;;;:::i;:::-;;;;;;;;;;:49;2962:3;;;:::i;:::-;;;2921:120;;;-1:-1:-1;3058:13:1;2570:508;-1:-1:-1;;;2570:508:1:o;4702:449:18:-;4775:9;;-1:-1:-1;;;4775:9:18;;;;4770:56;;4801:18;;-1:-1:-1;;;4801:18:18;;;;;;;;;;;4770:56;4844:10;4836:19;;;;:7;:19;;;;;;;;4831:68;;4872:20;;-1:-1:-1;;;4872:20:18;;;;;;;;;;;4831:68;4974:27;4980:7;4989:1;4992:8;4974:5;:27::i;:::-;5058:8;5044:10;;:22;;;;;;;:::i;:::-;;;;-1:-1:-1;;;;;;;5072:21:18;;;;;;:12;:21;;;;;:33;;5097:8;;5072:21;:33;;5097:8;;5072:33;:::i;:::-;;;;-1:-1:-1;;5123:10:18;5111:23;;;;:11;:23;;;;;:35;;5138:8;;5111:23;:35;;5138:8;;5111:35;:::i;:::-;;;;-1:-1:-1;;;;4702:449:18:o;4025:460::-;4083:10;;-1:-1:-1;;;4083:10:18;;;;4078:58;;4110:19;;-1:-1:-1;;;4110:19:18;;;;;;;;;;;4078:58;4181:30;4200:10;4181:18;:30::i;:::-;4156:10;4145:22;;;;:10;:22;;;;;;:33;;4170:8;;4145:33;:::i;:::-;:66;4141:123;;;4228:29;;-1:-1:-1;;;4228:29:18;;;;;;;;;;;4141:123;4337:38;4343:10;4355:1;4358:8;4337:38;;;;;;;;;;;;;-1:-1:-1;;;4337:38:18;;;:5;:38::i;:::-;4429:10;4418:22;;;;:10;:22;;;;;:34;;4444:8;;4418:22;:34;;4444:8;;4418:34;:::i;:::-;;;;;;;;4472:8;4458:10;;:22;;;;;;;:::i;:::-;;;;-1:-1:-1;;;4025:460:18:o;5390:118::-;5447:16;5482:21;5492:7;5501:1;5482:9;:21::i;1668:101:0:-;1108:6;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;1732:30:::1;1759:1;1732:18;:30::i;:::-;1668:101::o:0;2630:78:18:-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;2693:10:18::1;::::0;;-1:-1:-1;;;;2679:24:18;::::1;-1:-1:-1::0;;;2693:10:18;;;::::1;;;2692:11;2679:24:::0;;::::1;;::::0;;2630:78::o;3146:153:1:-;3240:52;719:10:13;3273:8:1;3283;3240:18;:52::i;:::-;3146:153;;:::o;5898:170:18:-;-1:-1:-1;;;;;6044:19:18;;5973:18;6044:19;;;:10;:19;;;;;;6014:27;6055:7;6014:18;:27::i;:::-;:49;;;;:::i;3583:75::-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;3644:9:18::1;::::0;;-1:-1:-1;;;;3631:22:18;::::1;-1:-1:-1::0;;;3644:9:18;;;::::1;;;3643:10;3631:22:::0;;::::1;;::::0;;3583:75::o;3377:145::-;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;3454:35:18::1;3460:7;3469:1;3472:8;3454:35;;;;;;;;;;;;;-1:-1:-1::0;;;3454:35:18::1;;::::0;:5:::1;:35::i;:::-;3509:8;3495:10;;:22;;;;;;;:::i;3764:93::-:0;1108:6:0;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;3823:12:18::1;:29:::0;;-1:-1:-1;;;;;;3823:29:18::1;-1:-1:-1::0;;;;;3823:29:18;;;::::1;::::0;;;::::1;::::0;;3764:93::o;3599:389:1:-;-1:-1:-1;;;;;3799:20:1;;719:10:13;3799:20:1;;:60;;-1:-1:-1;3823:36:1;3840:4;719:10:13;3366:166:1;:::i;3823:36::-;3778:148;;;;-1:-1:-1;;;3778:148:1;;12389:2:24;3778:148:1;;;12371:21:24;12428:2;12408:18;;;12401:30;12467:34;12447:18;;;12440:62;-1:-1:-1;;;12518:18:24;;;12511:39;12567:19;;3778:148:1;12187:405:24;3778:148:1;3936:45;3954:4;3960:2;3964;3968:6;3976:4;3936:17;:45::i;1918:198:0:-;1108:6;;-1:-1:-1;;;;;1108:6:0;719:10:13;1248:23:0;1240:68;;;;-1:-1:-1;;;1240:68:0;;;;;;;:::i;:::-;-1:-1:-1;;;;;2006:22:0;::::1;1998:73;;;::::0;-1:-1:-1;;;1998:73:0;;12799:2:24;1998:73:0::1;::::0;::::1;12781:21:24::0;12838:2;12818:18;;;12811:30;12877:34;12857:18;;;12850:62;-1:-1:-1;;;12928:18:24;;;12921:36;12974:19;;1998:73:0::1;12597:402:24::0;1998:73:0::1;2081:28;2100:8;2081:18;:28::i;8171:86:1:-:0;8237:13;;;;:4;;:13;;;;;:::i;6233:1115::-;6453:7;:14;6439:3;:10;:28;6431:81;;;;-1:-1:-1;;;6431:81:1;;13206:2:24;6431:81:1;;;13188:21:24;13245:2;13225:18;;;13218:30;13284:34;13264:18;;;13257:62;-1:-1:-1;;;13335:18:24;;;13328:38;13383:19;;6431:81:1;13004:404:24;6431:81:1;-1:-1:-1;;;;;6530:16:1;;6522:66;;;;-1:-1:-1;;;6522:66:1;;;;;;;:::i;:::-;719:10:13;6599:16:1;6712:411;6736:3;:10;6732:1;:14;6712:411;;;6767:10;6780:3;6784:1;6780:6;;;;;;;;:::i;:::-;;;;;;;6767:19;;6800:14;6817:7;6825:1;6817:10;;;;;;;;:::i;:::-;;;;;;;;;;;;6842:19;6864:13;;;;;;;;;;-1:-1:-1;;;;;6864:19:1;;;;;;;;;;;;6817:10;;-1:-1:-1;6905:21:1;;;;6897:76;;;;-1:-1:-1;;;6897:76:1;;;;;;;:::i;:::-;7015:9;:13;;;;;;;;;;;-1:-1:-1;;;;;7015:19:1;;;;;;;;;;7037:20;;;7015:42;;7085:17;;;;;;;:27;;7037:20;;7015:9;7085:27;;7037:20;;7085:27;:::i;:::-;;;;;;;;6753:370;;;6748:3;;;;:::i;:::-;;;6712:411;;;;7168:2;-1:-1:-1;;;;;7138:47:1;7162:4;-1:-1:-1;;;;;7138:47:1;7152:8;-1:-1:-1;;;;;7138:47:1;;7172:3;7177:7;7138:47;;;;;;;:::i;:::-;;;;;;;;7266:75;7302:8;7312:4;7318:2;7322:3;7327:7;7336:4;7266:35;:75::i;:::-;6421:927;6233:1115;;;;;:::o;10715:786::-;-1:-1:-1;;;;;10837:18:1;;10829:66;;;;-1:-1:-1;;;10829:66:1;;14902:2:24;10829:66:1;;;14884:21:24;14941:2;14921:18;;;14914:30;14980:34;14960:18;;;14953:62;-1:-1:-1;;;15031:18:24;;;15024:33;15074:19;;10829:66:1;14700:399:24;10829:66:1;719:10:13;10906:16:1;10970:21;10988:2;10970:17;:21::i;:::-;10947:44;;11001:24;11028:25;11046:6;11028:17;:25::i;:::-;11064:66;;;;;;;;;-1:-1:-1;11064:66:1;;;;11163:13;;;;;;;;;-1:-1:-1;;;;;11163:19:1;;;;;;;;11001:52;;-1:-1:-1;11200:21:1;;;;11192:70;;;;-1:-1:-1;;;11192:70:1;;15306:2:24;11192:70:1;;;15288:21:24;15345:2;15325:18;;;15318:30;15384:34;15364:18;;;15357:62;-1:-1:-1;;;15435:18:24;;;15428:34;15479:19;;11192:70:1;15104:400:24;11192:70:1;11296:9;:13;;;;;;;;;;;-1:-1:-1;;;;;11296:19:1;;;;;;;;;;;;11318:20;;;11296:42;;11364:54;;15683:25:24;;;15724:18;;;15717:34;;;11296:19:1;;11364:54;;;;;;15656:18:24;11364:54:1;;;;;;;11429:65;;;;;;;;;11473:1;11429:65;;;10819:682;;;;10715:786;;;:::o;2022:290:18:-;2140:29;;-1:-1:-1;;;2140:29:18;;-1:-1:-1;;;;;6227:32:24;;;2140:29:18;;;6209:51:24;2102:16:18;;2140:8;:20;;;;;;6182:18:24;;2140:29:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;2128:41;;;;:::i;:::-;2237:9;;2128:41;;-1:-1:-1;;;;2237:9:18;;;;2233:75;;;2268:12;;;:33;;-1:-1:-1;;;2268:33:18;;-1:-1:-1;;;;;6227:32:24;;;2268:33:18;;;6209:51:24;;;;2268:12:18;;;:24;;6182:18:24;;2268:33:18;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;2256:45;;;;:::i;2233:75::-;2022:290;;;:::o;8630:709:1:-;-1:-1:-1;;;;;8777:16:1;;8769:62;;;;-1:-1:-1;;;8769:62:1;;16153:2:24;8769:62:1;;;16135:21:24;16192:2;16172:18;;;16165:30;16231:34;16211:18;;;16204:62;-1:-1:-1;;;16282:18:24;;;16275:31;16323:19;;8769:62:1;15951:397:24;8769:62:1;719:10:13;8842:16:1;8906:21;8924:2;8906:17;:21::i;:::-;8883:44;;8937:24;8964:25;8982:6;8964:17;:25::i;:::-;8937:52;;9077:9;:13;;;;;;;;;;;-1:-1:-1;;;;;9077:17:1;;;;;;;;;:27;;9098:6;;9077:9;:27;;9098:6;;9077:27;:::i;:::-;;;;-1:-1:-1;;9119:52:1;;;15683:25:24;;;15739:2;15724:18;;15717:34;;;-1:-1:-1;;;;;9119:52:1;;;;9152:1;;9119:52;;;;;;15656:18:24;9119:52:1;;;;;;;9258:74;9289:8;9307:1;9311:2;9315;9319:6;9327:4;9258:30;:74::i;2270:187:0:-;2362:6;;;-1:-1:-1;;;;;2378:17:0;;;-1:-1:-1;;;;;;2378:17:0;;;;;;;2410:40;;2362:6;;;2378:17;2362:6;;2410:40;;2343:16;;2410:40;2333:124;2270:187;:::o;12773:323:1:-;12923:8;-1:-1:-1;;;;;12914:17:1;:5;-1:-1:-1;;;;;12914:17:1;;;12906:71;;;;-1:-1:-1;;;12906:71:1;;16555:2:24;12906:71:1;;;16537:21:24;16594:2;16574:18;;;16567:30;16633:34;16613:18;;;16606:62;-1:-1:-1;;;16684:18:24;;;16677:39;16733:19;;12906:71:1;16353:405:24;12906:71:1;-1:-1:-1;;;;;12987:25:1;;;;;;;:18;:25;;;;;;;;:35;;;;;;;;;;;;;:46;;-1:-1:-1;;12987:46:1;;;;;;;;;;13048:41;;1159::24;;;13048::1;;1132:18:24;13048:41:1;;;;;;;12773:323;;;:::o;4940:947::-;-1:-1:-1;;;;;5121:16:1;;5113:66;;;;-1:-1:-1;;;5113:66:1;;;;;;;:::i;:::-;719:10:13;5190:16:1;5254:21;5272:2;5254:17;:21::i;:::-;5231:44;;5285:24;5312:25;5330:6;5312:17;:25::i;:::-;5285:52;;5419:19;5441:13;;;;;;;;;;;-1:-1:-1;;;;;5441:19:1;;;;;;;;;;5478:21;;;;5470:76;;;;-1:-1:-1;;;5470:76:1;;;;;;;:::i;:::-;5580:9;:13;;;;;;;;;;;-1:-1:-1;;;;;5580:19:1;;;;;;;;;;5602:20;;;5580:42;;5642:17;;;;;;;:27;;5602:20;;5580:9;5642:27;;5602:20;;5642:27;:::i;:::-;;;;-1:-1:-1;;5685:46:1;;;15683:25:24;;;15739:2;15724:18;;15717:34;;;-1:-1:-1;;;;;5685:46:1;;;;;;;;;;;;;;15656:18:24;5685:46:1;;;;;;;5812:68;5843:8;5853:4;5859:2;5863;5867:6;5875:4;5812:30;:68::i;:::-;5103:784;;;;4940:947;;;;;:::o;16127:792::-;-1:-1:-1;;;;;16359:13:1;;1465:19:12;:23;16355:558:1;;16394:79;;-1:-1:-1;;;16394:79:1;;-1:-1:-1;;;;;16394:43:1;;;;;:79;;16438:8;;16448:4;;16454:3;;16459:7;;16468:4;;16394:79;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;16394:79:1;;;;;;;;-1:-1:-1;;16394:79:1;;;;;;;;;;;;:::i;:::-;;;16390:513;;;;:::i;:::-;;;;;;;;;;:::i;:::-;;;;;;;;16779:6;16772:14;;-1:-1:-1;;;16772:14:1;;;;;;;;:::i;16390:513::-;;;16826:62;;-1:-1:-1;;;16826:62:1;;18911:2:24;16826:62:1;;;18893:21:24;18950:2;18930:18;;;18923:30;18989:34;18969:18;;;18962:62;-1:-1:-1;;;19040:18:24;;;19033:50;19100:19;;16826:62:1;18709:416:24;16390:513:1;-1:-1:-1;;;;;;16552:60:1;;-1:-1:-1;;;16552:60:1;16548:157;;16636:50;;-1:-1:-1;;;16636:50:1;;;;;;;:::i;16925:193::-;17044:16;;;17058:1;17044:16;;;;;;;;;16991;;17019:22;;17044:16;;;;;;;;;;;;-1:-1:-1;17044:16:1;17019:41;;17081:7;17070:5;17076:1;17070:8;;;;;;;;:::i;:::-;;;;;;;;;;:18;17106:5;16925:193;-1:-1:-1;;16925:193:1:o;15396:725::-;-1:-1:-1;;;;;15603:13:1;;1465:19:12;:23;15599:516:1;;15638:72;;-1:-1:-1;;;15638:72:1;;-1:-1:-1;;;;;15638:38:1;;;;;:72;;15677:8;;15687:4;;15693:2;;15697:6;;15705:4;;15638:72;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;15638:72:1;;;;;;;;-1:-1:-1;;15638:72:1;;;;;;;;;;;;:::i;:::-;;;15634:471;;;;:::i;:::-;-1:-1:-1;;;;;;15759:55:1;;-1:-1:-1;;;15759:55:1;15755:152;;15838:50;;-1:-1:-1;;;15838:50:1;;;;;;;:::i;-1:-1:-1:-;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;14:173:24;82:20;;-1:-1:-1;;;;;131:31:24;;121:42;;111:70;;177:1;174;167:12;192:254;260:6;268;321:2;309:9;300:7;296:23;292:32;289:52;;;337:1;334;327:12;289:52;360:29;379:9;360:29;:::i;:::-;350:39;436:2;421:18;;;;408:32;;-1:-1:-1;;;192:254:24:o;633:131::-;-1:-1:-1;;;;;;707:32:24;;697:43;;687:71;;754:1;751;744:12;769:245;827:6;880:2;868:9;859:7;855:23;851:32;848:52;;;896:1;893;886:12;848:52;935:9;922:23;954:30;978:5;954:30;:::i;:::-;1003:5;769:245;-1:-1:-1;;;769:245:24:o;1211:127::-;1272:10;1267:3;1263:20;1260:1;1253:31;1303:4;1300:1;1293:15;1327:4;1324:1;1317:15;1343:249;1453:2;1434:13;;-1:-1:-1;;1430:27:24;1418:40;;1488:18;1473:34;;1509:22;;;1470:62;1467:88;;;1535:18;;:::i;:::-;1571:2;1564:22;-1:-1:-1;;1343:249:24:o;1597:469::-;1662:5;1696:18;1688:6;1685:30;1682:56;;;1718:18;;:::i;:::-;1767:2;1761:9;1779:69;1836:2;1815:15;;-1:-1:-1;;1811:29:24;1842:4;1807:40;1761:9;1779:69;:::i;:::-;1866:6;1857:15;;1896:6;1888;1881:22;1936:3;1927:6;1922:3;1918:16;1915:25;1912:45;;;1953:1;1950;1943:12;1912:45;2003:6;1998:3;1991:4;1983:6;1979:17;1966:44;2058:1;2051:4;2042:6;2034;2030:19;2026:30;2019:41;;1597:469;;;;;:::o;2071:451::-;2140:6;2193:2;2181:9;2172:7;2168:23;2164:32;2161:52;;;2209:1;2206;2199:12;2161:52;2249:9;2236:23;2282:18;2274:6;2271:30;2268:50;;;2314:1;2311;2304:12;2268:50;2337:22;;2390:4;2382:13;;2378:27;-1:-1:-1;2368:55:24;;2419:1;2416;2409:12;2368:55;2442:74;2508:7;2503:2;2490:16;2485:2;2481;2477:11;2442:74;:::i;:::-;2432:84;2071:451;-1:-1:-1;;;;2071:451:24:o;2527:186::-;2586:6;2639:2;2627:9;2618:7;2614:23;2610:32;2607:52;;;2655:1;2652;2645:12;2607:52;2678:29;2697:9;2678:29;:::i;2718:347::-;2783:6;2791;2844:2;2832:9;2823:7;2819:23;2815:32;2812:52;;;2860:1;2857;2850:12;2812:52;2883:29;2902:9;2883:29;:::i;:::-;2873:39;;2962:2;2951:9;2947:18;2934:32;3009:5;3002:13;2995:21;2988:5;2985:32;2975:60;;3031:1;3028;3021:12;2975:60;3054:5;3044:15;;;2718:347;;;;;:::o;3070:180::-;3129:6;3182:2;3170:9;3161:7;3157:23;3153:32;3150:52;;;3198:1;3195;3188:12;3150:52;-1:-1:-1;3221:23:24;;3070:180;-1:-1:-1;3070:180:24:o;3255:472::-;3297:3;3335:5;3329:12;3362:6;3357:3;3350:19;3387:1;3397:162;3411:6;3408:1;3405:13;3397:162;;;3473:4;3529:13;;;3525:22;;3519:29;3501:11;;;3497:20;;3490:59;3426:12;3397:162;;;3577:6;3574:1;3571:13;3568:87;;;3643:1;3636:4;3627:6;3622:3;3618:16;3614:27;3607:38;3568:87;-1:-1:-1;3709:2:24;3688:15;-1:-1:-1;;3684:29:24;3675:39;;;;3716:4;3671:50;;3255:472;-1:-1:-1;;3255:472:24:o;3732:220::-;3881:2;3870:9;3863:21;3844:4;3901:45;3942:2;3931:9;3927:18;3919:6;3901:45;:::i;3957:183::-;4017:4;4050:18;4042:6;4039:30;4036:56;;;4072:18;;:::i;:::-;-1:-1:-1;4117:1:24;4113:14;4129:4;4109:25;;3957:183::o;4145:724::-;4199:5;4252:3;4245:4;4237:6;4233:17;4229:27;4219:55;;4270:1;4267;4260:12;4219:55;4306:6;4293:20;4332:4;4355:43;4395:2;4355:43;:::i;:::-;4427:2;4421:9;4439:31;4467:2;4459:6;4439:31;:::i;:::-;4505:18;;;4597:1;4593:10;;;;4581:23;;4577:32;;;4539:15;;;;-1:-1:-1;4621:15:24;;;4618:35;;;4649:1;4646;4639:12;4618:35;4685:2;4677:6;4673:15;4697:142;4713:6;4708:3;4705:15;4697:142;;;4779:17;;4767:30;;4817:12;;;;4730;;4697:142;;;-1:-1:-1;4857:6:24;4145:724;-1:-1:-1;;;;;;4145:724:24:o;4874:221::-;4916:5;4969:3;4962:4;4954:6;4950:17;4946:27;4936:55;;4987:1;4984;4977:12;4936:55;5009:80;5085:3;5076:6;5063:20;5056:4;5048:6;5044:17;5009:80;:::i;5100:943::-;5254:6;5262;5270;5278;5286;5339:3;5327:9;5318:7;5314:23;5310:33;5307:53;;;5356:1;5353;5346:12;5307:53;5379:29;5398:9;5379:29;:::i;:::-;5369:39;;5427:38;5461:2;5450:9;5446:18;5427:38;:::i;:::-;5417:48;;5516:2;5505:9;5501:18;5488:32;5539:18;5580:2;5572:6;5569:14;5566:34;;;5596:1;5593;5586:12;5566:34;5619:61;5672:7;5663:6;5652:9;5648:22;5619:61;:::i;:::-;5609:71;;5733:2;5722:9;5718:18;5705:32;5689:48;;5762:2;5752:8;5749:16;5746:36;;;5778:1;5775;5768:12;5746:36;5801:63;5856:7;5845:8;5834:9;5830:24;5801:63;:::i;:::-;5791:73;;5917:3;5906:9;5902:19;5889:33;5873:49;;5947:2;5937:8;5934:16;5931:36;;;5963:1;5960;5953:12;5931:36;;5986:51;6029:7;6018:8;6007:9;6003:24;5986:51;:::i;:::-;5976:61;;;5100:943;;;;;;;;:::o;6271:1208::-;6389:6;6397;6450:2;6438:9;6429:7;6425:23;6421:32;6418:52;;;6466:1;6463;6456:12;6418:52;6506:9;6493:23;6535:18;6576:2;6568:6;6565:14;6562:34;;;6592:1;6589;6582:12;6562:34;6630:6;6619:9;6615:22;6605:32;;6675:7;6668:4;6664:2;6660:13;6656:27;6646:55;;6697:1;6694;6687:12;6646:55;6733:2;6720:16;6755:4;6778:43;6818:2;6778:43;:::i;:::-;6850:2;6844:9;6862:31;6890:2;6882:6;6862:31;:::i;:::-;6928:18;;;7016:1;7012:10;;;;7004:19;;7000:28;;;6962:15;;;;-1:-1:-1;7040:19:24;;;7037:39;;;7072:1;7069;7062:12;7037:39;7096:11;;;;7116:148;7132:6;7127:3;7124:15;7116:148;;;7198:23;7217:3;7198:23;:::i;:::-;7186:36;;7149:12;;;;7242;;;;7116:148;;;7283:6;-1:-1:-1;;7327:18:24;;7314:32;;-1:-1:-1;;7358:16:24;;;7355:36;;;7387:1;7384;7377:12;7355:36;;7410:63;7465:7;7454:8;7443:9;7439:24;7410:63;:::i;:::-;7400:73;;;6271:1208;;;;;:::o;7484:435::-;7537:3;7575:5;7569:12;7602:6;7597:3;7590:19;7628:4;7657:2;7652:3;7648:12;7641:19;;7694:2;7687:5;7683:14;7715:1;7725:169;7739:6;7736:1;7733:13;7725:169;;;7800:13;;7788:26;;7834:12;;;;7869:15;;;;7761:1;7754:9;7725:169;;;-1:-1:-1;7910:3:24;;7484:435;-1:-1:-1;;;;;7484:435:24:o;7924:261::-;8103:2;8092:9;8085:21;8066:4;8123:56;8175:2;8164:9;8160:18;8152:6;8123:56;:::i;8398:254::-;8466:6;8474;8527:2;8515:9;8506:7;8502:23;8498:32;8495:52;;;8543:1;8540;8533:12;8495:52;8579:9;8566:23;8556:33;;8608:38;8642:2;8631:9;8627:18;8608:38;:::i;:::-;8598:48;;8398:254;;;;;:::o;8657:260::-;8725:6;8733;8786:2;8774:9;8765:7;8761:23;8757:32;8754:52;;;8802:1;8799;8792:12;8754:52;8825:29;8844:9;8825:29;:::i;:::-;8815:39;;8873:38;8907:2;8896:9;8892:18;8873:38;:::i;8922:606::-;9026:6;9034;9042;9050;9058;9111:3;9099:9;9090:7;9086:23;9082:33;9079:53;;;9128:1;9125;9118:12;9079:53;9151:29;9170:9;9151:29;:::i;:::-;9141:39;;9199:38;9233:2;9222:9;9218:18;9199:38;:::i;:::-;9189:48;;9284:2;9273:9;9269:18;9256:32;9246:42;;9335:2;9324:9;9320:18;9307:32;9297:42;;9390:3;9379:9;9375:19;9362:33;9418:18;9410:6;9407:30;9404:50;;;9450:1;9447;9440:12;9404:50;9473:49;9514:7;9505:6;9494:9;9490:22;9473:49;:::i;9945:356::-;10147:2;10129:21;;;10166:18;;;10159:30;10225:34;10220:2;10205:18;;10198:62;10292:2;10277:18;;9945:356::o;10306:380::-;10385:1;10381:12;;;;10428;;;10449:61;;10503:4;10495:6;10491:17;10481:27;;10449:61;10556:2;10548:6;10545:14;10525:18;10522:38;10519:161;;;10602:10;10597:3;10593:20;10590:1;10583:31;10637:4;10634:1;10627:15;10665:4;10662:1;10655:15;10519:161;;10306:380;;;:::o;10691:127::-;10752:10;10747:3;10743:20;10740:1;10733:31;10783:4;10780:1;10773:15;10807:4;10804:1;10797:15;10823:125;10863:4;10891:1;10888;10885:8;10882:34;;;10896:18;;:::i;:::-;-1:-1:-1;10933:9:24;;10823:125::o;11782:127::-;11843:10;11838:3;11834:20;11831:1;11824:31;11874:4;11871:1;11864:15;11898:4;11895:1;11888:15;11914:135;11953:3;-1:-1:-1;;11974:17:24;;11971:43;;;11994:18;;:::i;:::-;-1:-1:-1;12041:1:24;12030:13;;11914:135::o;12054:128::-;12094:3;12125:1;12121:6;12118:1;12115:13;12112:39;;;12131:18;;:::i;:::-;-1:-1:-1;12167:9:24;;12054:128::o;13413:401::-;13615:2;13597:21;;;13654:2;13634:18;;;13627:30;13693:34;13688:2;13673:18;;13666:62;-1:-1:-1;;;13759:2:24;13744:18;;13737:35;13804:3;13789:19;;13413:401::o;13819:406::-;14021:2;14003:21;;;14060:2;14040:18;;;14033:30;14099:34;14094:2;14079:18;;14072:62;-1:-1:-1;;;14165:2:24;14150:18;;14143:40;14215:3;14200:19;;13819:406::o;14230:465::-;14487:2;14476:9;14469:21;14450:4;14513:56;14565:2;14554:9;14550:18;14542:6;14513:56;:::i;:::-;14617:9;14609:6;14605:22;14600:2;14589:9;14585:18;14578:50;14645:44;14682:6;14674;14645:44;:::i;:::-;14637:52;14230:465;-1:-1:-1;;;;;14230:465:24:o;15762:184::-;15832:6;15885:2;15873:9;15864:7;15860:23;15856:32;15853:52;;;15901:1;15898;15891:12;15853:52;-1:-1:-1;15924:16:24;;15762:184;-1:-1:-1;15762:184:24:o;16763:827::-;-1:-1:-1;;;;;17160:15:24;;;17142:34;;17212:15;;17207:2;17192:18;;17185:43;17122:3;17259:2;17244:18;;17237:31;;;17085:4;;17291:57;;17328:19;;17320:6;17291:57;:::i;:::-;17396:9;17388:6;17384:22;17379:2;17368:9;17364:18;17357:50;17430:44;17467:6;17459;17430:44;:::i;:::-;17416:58;;17523:9;17515:6;17511:22;17505:3;17494:9;17490:19;17483:51;17551:33;17577:6;17569;17551:33;:::i;:::-;17543:41;16763:827;-1:-1:-1;;;;;;;;16763:827:24:o;17595:249::-;17664:6;17717:2;17705:9;17696:7;17692:23;17688:32;17685:52;;;17733:1;17730;17723:12;17685:52;17765:9;17759:16;17784:30;17808:5;17784:30;:::i;17849:179::-;17884:3;17926:1;17908:16;17905:23;17902:120;;;17972:1;17969;17966;17951:23;-1:-1:-1;18009:1:24;18003:8;17998:3;17994:18;17902:120;17849:179;:::o;18033:671::-;18072:3;18114:4;18096:16;18093:26;18090:39;;;18033:671;:::o;18090:39::-;18156:2;18150:9;-1:-1:-1;;18221:16:24;18217:25;;18214:1;18150:9;18193:50;18272:4;18266:11;18296:16;18331:18;18402:2;18395:4;18387:6;18383:17;18380:25;18375:2;18367:6;18364:14;18361:45;18358:58;;;18409:5;;;;;18033:671;:::o;18358:58::-;18446:6;18440:4;18436:17;18425:28;;18482:3;18476:10;18509:2;18501:6;18498:14;18495:27;;;18515:5;;;;;;18033:671;:::o;18495:27::-;18599:2;18580:16;18574:4;18570:27;18566:36;18559:4;18550:6;18545:3;18541:16;18537:27;18534:69;18531:82;;;18606:5;;;;;;18033:671;:::o;18531:82::-;18622:57;18673:4;18664:6;18656;18652:19;18648:30;18642:4;18622:57;:::i;:::-;-1:-1:-1;18695:3:24;;18033:671;-1:-1:-1;;;;;18033:671:24:o;19130:404::-;19332:2;19314:21;;;19371:2;19351:18;;;19344:30;19410:34;19405:2;19390:18;;19383:62;-1:-1:-1;;;19476:2:24;19461:18;;19454:38;19524:3;19509:19;;19130:404::o;19539:561::-;-1:-1:-1;;;;;19836:15:24;;;19818:34;;19888:15;;19883:2;19868:18;;19861:43;19935:2;19920:18;;19913:34;;;19978:2;19963:18;;19956:34;;;19798:3;20021;20006:19;;19999:32;;;19761:4;;20048:46;;20074:19;;20066:6;20048:46;:::i;:::-;20040:54;19539:561;-1:-1:-1;;;;;;;19539:561:24:o
Swarm Source
ipfs://662d6784e8c15e1546e337e700f05708897e4f2eefb1ee36744e7cdf40f5ca31
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.