ERC-721
Overview
Max Total Supply
2,964 ADMNC
Holders
2,485
Market
Volume (24H)
0.0108 ETH
Min Price (24H)
$19.83 @ 0.005399 ETH
Max Price (24H)
$19.83 @ 0.005400 ETH
Other Info
Token Contract
Balance
1 ADMNCLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
AdidasMoncler
Compiler Version
v0.8.21+commit.d9974bed
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.21; import "@openzeppelin/contracts/access/Ownable.sol"; import "erc721a/contracts/extensions/ERC721ABurnable.sol"; import "erc721a/contracts/extensions/ERC721AQueryable.sol"; import "@openzeppelin/contracts/token/common/ERC2981.sol"; /** * @title AdidasMoncler * @notice This contract governs the issue of 3,000 NFTs of The Explorer by Moncler and adidas Originals * @dev Batch mints ERC721 to provided addresses */ contract AdidasMoncler is ERC721ABurnable, ERC721AQueryable, ERC2981, Ownable { /// @dev Metadata base URI string public baseUri; /// @dev Max supply of token uint256 public constant MAX_SUPPLY = 3000; /// @dev Token name string private _name; /// @dev Token symbol string private _symbol; /// @dev contractURI string private _contractURI; constructor( string memory __name, string memory __symbol, string memory _baseUri, string memory _uri, address _royaltyReceiver, uint96 _royaltyValue ) ERC721A(__name, __symbol) { _name = __name; _symbol = __symbol; baseUri = _baseUri; _contractURI = _uri; _setDefaultRoyalty(_royaltyReceiver, _royaltyValue); } /** * @notice Returns the name of the ERC721 token. * @return The name of the token. */ function name() public view virtual override(ERC721A, IERC721A) returns (string memory) { return _name; } /** * @notice Returns the symbol of the ERC721 token. * @return The symbol of the token. */ function symbol() public view virtual override(ERC721A, IERC721A) returns (string memory) { return _symbol; } /** * @notice Allows the owner to change the name and symbol of the ERC721 token. * @dev Only callable by the owner. * @param newName The new name for the token. * @param newSymbol The new symbol for the token. */ function setNameAndSymbol(string calldata newName, string calldata newSymbol) public onlyOwner { _name = newName; _symbol = newSymbol; } /** * @notice Returns the base URI for the token's metadata. * @return The current base URI. */ function _baseURI() internal view virtual override returns (string memory) { return baseUri; } /** * @notice Changes the base URI for the token metadata. * @dev Only callable by the owner. * @param _baseUri The new base URI. */ function setBaseUri(string calldata _baseUri) public onlyOwner { baseUri = _baseUri; } /** * @notice Returns the contract's metadata URI. * @return The URI of the contract. */ function contractURI() public view returns (string memory) { return _contractURI; } /** * @notice Changes the contract's URI. * @dev Only callable by the owner. * @param newContractURI The new contract URI. */ function setContractUri(string calldata newContractURI) public onlyOwner { _contractURI = newContractURI; } /** * @notice Sets royalties for tarding. * @dev Only callable by the owner. * @param receiver The new royalty receiver. * @param value The new royalty amount. */ function setRoyalties(address receiver, uint96 value) public onlyOwner { _setDefaultRoyalty(receiver, value); } /** * @notice Mints multiple ERC721 tokens. * @dev Only callable by the owner. * @param to An array of addresses to which to mint one token each. */ function batchMint(address[] calldata to) external onlyOwner { uint256 count = to.length; require(totalSupply() + count <= MAX_SUPPLY, "Mint would exceed max supply"); unchecked { for (uint256 i = 0; i < count; i++) { _mint(to[i], 1); } } } /** * @notice Checks if the contract supports a given interface. * @dev Overrides supportsInterface from multiple inherited contracts. * @param interfaceId The id of the interface to check. * @return bool True if the interface is supported, false otherwise. */ function supportsInterface( bytes4 interfaceId ) public view virtual override(IERC721A, ERC721A, ERC2981) returns (bool) { // Supports the following `interfaceId`s: // - IERC165: 0x01ffc9a7 // - IERC721: 0x80ac58cd // - IERC721Metadata: 0x5b5e139f // - IERC2981: 0x2a55205a return ERC721A.supportsInterface(interfaceId) || ERC2981.supportsInterface(interfaceId); } function _startTokenId() internal pure override returns (uint256) { return 1; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (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 Throws if called by any account other than the owner. */ modifier onlyOwner() { _checkOwner(); _; } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if the sender is not the owner. */ function _checkOwner() internal view virtual { require(owner() == _msgSender(), "Ownable: caller is not the owner"); } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby disabling 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 (last updated v4.9.0) (interfaces/IERC2981.sol) pragma solidity ^0.8.0; import "../utils/introspection/IERC165.sol"; /** * @dev Interface for the NFT Royalty Standard. * * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal * support for royalty payments across all NFT marketplaces and ecosystem participants. * * _Available since v4.5._ */ interface IERC2981 is IERC165 { /** * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of * exchange. The royalty amount is denominated and should be paid in that same unit of exchange. */ function royaltyInfo( uint256 tokenId, uint256 salePrice ) external view returns (address receiver, uint256 royaltyAmount); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.9.0) (token/common/ERC2981.sol) pragma solidity ^0.8.0; import "../../interfaces/IERC2981.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information. * * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first. * * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the * fee is specified in basis points by default. * * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported. * * _Available since v4.5._ */ abstract contract ERC2981 is IERC2981, ERC165 { struct RoyaltyInfo { address receiver; uint96 royaltyFraction; } RoyaltyInfo private _defaultRoyaltyInfo; mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) { return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId); } /** * @inheritdoc IERC2981 */ function royaltyInfo(uint256 tokenId, uint256 salePrice) public view virtual override returns (address, uint256) { RoyaltyInfo memory royalty = _tokenRoyaltyInfo[tokenId]; if (royalty.receiver == address(0)) { royalty = _defaultRoyaltyInfo; } uint256 royaltyAmount = (salePrice * royalty.royaltyFraction) / _feeDenominator(); return (royalty.receiver, royaltyAmount); } /** * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an * override. */ function _feeDenominator() internal pure virtual returns (uint96) { return 10000; } /** * @dev Sets the royalty information that all ids in this contract will default to. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: invalid receiver"); _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Removes default royalty information. */ function _deleteDefaultRoyalty() internal virtual { delete _defaultRoyaltyInfo; } /** * @dev Sets the royalty information for a specific token id, overriding the global default. * * Requirements: * * - `receiver` cannot be the zero address. * - `feeNumerator` cannot be greater than the fee denominator. */ function _setTokenRoyalty(uint256 tokenId, address receiver, uint96 feeNumerator) internal virtual { require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice"); require(receiver != address(0), "ERC2981: Invalid parameters"); _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator); } /** * @dev Resets royalty information for the token id back to the global default. */ function _resetTokenRoyalty(uint256 tokenId) internal virtual { delete _tokenRoyaltyInfo[tokenId]; } }
// 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 // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721A.sol'; /** * @dev Interface of ERC721 token receiver. */ interface ERC721A__IERC721Receiver { function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); } /** * @title ERC721A * * @dev Implementation of the [ERC721](https://eips.ethereum.org/EIPS/eip-721) * Non-Fungible Token Standard, including the Metadata extension. * Optimized for lower gas during batch mints. * * Token IDs are minted in sequential order (e.g. 0, 1, 2, 3, ...) * starting from `_startTokenId()`. * * Assumptions: * * - An owner cannot have more than 2**64 - 1 (max value of uint64) of supply. * - The maximum token ID cannot exceed 2**256 - 1 (max value of uint256). */ contract ERC721A is IERC721A { // Bypass for a `--via-ir` bug (https://github.com/chiru-labs/ERC721A/pull/364). struct TokenApprovalRef { address value; } // ============================================================= // CONSTANTS // ============================================================= // Mask of an entry in packed address data. uint256 private constant _BITMASK_ADDRESS_DATA_ENTRY = (1 << 64) - 1; // The bit position of `numberMinted` in packed address data. uint256 private constant _BITPOS_NUMBER_MINTED = 64; // The bit position of `numberBurned` in packed address data. uint256 private constant _BITPOS_NUMBER_BURNED = 128; // The bit position of `aux` in packed address data. uint256 private constant _BITPOS_AUX = 192; // Mask of all 256 bits in packed address data except the 64 bits for `aux`. uint256 private constant _BITMASK_AUX_COMPLEMENT = (1 << 192) - 1; // The bit position of `startTimestamp` in packed ownership. uint256 private constant _BITPOS_START_TIMESTAMP = 160; // The bit mask of the `burned` bit in packed ownership. uint256 private constant _BITMASK_BURNED = 1 << 224; // The bit position of the `nextInitialized` bit in packed ownership. uint256 private constant _BITPOS_NEXT_INITIALIZED = 225; // The bit mask of the `nextInitialized` bit in packed ownership. uint256 private constant _BITMASK_NEXT_INITIALIZED = 1 << 225; // The bit position of `extraData` in packed ownership. uint256 private constant _BITPOS_EXTRA_DATA = 232; // Mask of all 256 bits in a packed ownership except the 24 bits for `extraData`. uint256 private constant _BITMASK_EXTRA_DATA_COMPLEMENT = (1 << 232) - 1; // The mask of the lower 160 bits for addresses. uint256 private constant _BITMASK_ADDRESS = (1 << 160) - 1; // The maximum `quantity` that can be minted with {_mintERC2309}. // This limit is to prevent overflows on the address data entries. // For a limit of 5000, a total of 3.689e15 calls to {_mintERC2309} // is required to cause an overflow, which is unrealistic. uint256 private constant _MAX_MINT_ERC2309_QUANTITY_LIMIT = 5000; // The `Transfer` event signature is given by: // `keccak256(bytes("Transfer(address,address,uint256)"))`. bytes32 private constant _TRANSFER_EVENT_SIGNATURE = 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef; // ============================================================= // STORAGE // ============================================================= // The next token ID to be minted. uint256 private _currentIndex; // The number of tokens burned. uint256 private _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 {_packedOwnershipOf} implementation for details. // // Bits Layout: // - [0..159] `addr` // - [160..223] `startTimestamp` // - [224] `burned` // - [225] `nextInitialized` // - [232..255] `extraData` mapping(uint256 => uint256) private _packedOwnerships; // Mapping owner address to address data. // // Bits Layout: // - [0..63] `balance` // - [64..127] `numberMinted` // - [128..191] `numberBurned` // - [192..255] `aux` mapping(address => uint256) private _packedAddressData; // Mapping from token ID to approved address. mapping(uint256 => TokenApprovalRef) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; // ============================================================= // CONSTRUCTOR // ============================================================= constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; _currentIndex = _startTokenId(); } // ============================================================= // TOKEN COUNTING OPERATIONS // ============================================================= /** * @dev Returns the starting token ID. * To change the starting token ID, please override this function. */ function _startTokenId() internal view virtual returns (uint256) { return 0; } /** * @dev Returns the next token ID to be minted. */ function _nextTokenId() internal view virtual returns (uint256) { return _currentIndex; } /** * @dev Returns the total number of tokens in existence. * Burned tokens will reduce the count. * To get the total number of tokens minted, please see {_totalMinted}. */ function totalSupply() public view virtual override returns (uint256) { // Counter underflow is impossible as _burnCounter cannot be incremented // more than `_currentIndex - _startTokenId()` times. unchecked { return _currentIndex - _burnCounter - _startTokenId(); } } /** * @dev Returns the total amount of tokens minted in the contract. */ function _totalMinted() internal view virtual returns (uint256) { // Counter underflow is impossible as `_currentIndex` does not decrement, // and it is initialized to `_startTokenId()`. unchecked { return _currentIndex - _startTokenId(); } } /** * @dev Returns the total number of tokens burned. */ function _totalBurned() internal view virtual returns (uint256) { return _burnCounter; } // ============================================================= // ADDRESS DATA OPERATIONS // ============================================================= /** * @dev Returns the number of tokens in `owner`'s account. */ function balanceOf(address owner) public view virtual override returns (uint256) { if (owner == address(0)) revert BalanceQueryForZeroAddress(); return _packedAddressData[owner] & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens minted by `owner`. */ function _numberMinted(address owner) internal view returns (uint256) { return (_packedAddressData[owner] >> _BITPOS_NUMBER_MINTED) & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the number of tokens burned by or on behalf of `owner`. */ function _numberBurned(address owner) internal view returns (uint256) { return (_packedAddressData[owner] >> _BITPOS_NUMBER_BURNED) & _BITMASK_ADDRESS_DATA_ENTRY; } /** * Returns the auxiliary data for `owner`. (e.g. number of whitelist mint slots used). */ function _getAux(address owner) internal view returns (uint64) { return uint64(_packedAddressData[owner] >> _BITPOS_AUX); } /** * Sets the auxiliary 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 virtual { uint256 packed = _packedAddressData[owner]; uint256 auxCasted; // Cast `aux` with assembly to avoid redundant masking. assembly { auxCasted := aux } packed = (packed & _BITMASK_AUX_COMPLEMENT) | (auxCasted << _BITPOS_AUX); _packedAddressData[owner] = packed; } // ============================================================= // IERC165 // ============================================================= /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified) * to learn more about how these ids are created. * * This function call must use less than 30000 gas. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { // The interface IDs are constants representing the first 4 bytes // of the XOR of all function selectors in the interface. // See: [ERC165](https://eips.ethereum.org/EIPS/eip-165) // (e.g. `bytes4(i.functionA.selector ^ i.functionB.selector ^ ...)`) return interfaceId == 0x01ffc9a7 || // ERC165 interface ID for ERC165. interfaceId == 0x80ac58cd || // ERC165 interface ID for ERC721. interfaceId == 0x5b5e139f; // ERC165 interface ID for ERC721Metadata. } // ============================================================= // IERC721Metadata // ============================================================= /** * @dev Returns the token collection name. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev Returns the token collection symbol. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ 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, _toString(tokenId))) : ''; } /** * @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, it can be overridden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ''; } // ============================================================= // OWNERSHIPS OPERATIONS // ============================================================= /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { return address(uint160(_packedOwnershipOf(tokenId))); } /** * @dev Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around over time. */ function _ownershipOf(uint256 tokenId) internal view virtual returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnershipOf(tokenId)); } /** * @dev Returns the unpacked `TokenOwnership` struct at `index`. */ function _ownershipAt(uint256 index) internal view virtual returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnerships[index]); } /** * @dev Initializes the ownership slot minted at `index` for efficiency purposes. */ function _initializeOwnershipAt(uint256 index) internal virtual { if (_packedOwnerships[index] == 0) { _packedOwnerships[index] = _packedOwnershipOf(index); } } /** * Returns the packed ownership data of `tokenId`. */ function _packedOwnershipOf(uint256 tokenId) private view returns (uint256) { uint256 curr = tokenId; unchecked { if (_startTokenId() <= curr) if (curr < _currentIndex) { uint256 packed = _packedOwnerships[curr]; // If not burned. if (packed & _BITMASK_BURNED == 0) { // Invariant: // There will always be an initialized ownership slot // (i.e. `ownership.addr != address(0) && ownership.burned == false`) // before an unintialized ownership slot // (i.e. `ownership.addr == address(0) && ownership.burned == false`) // Hence, `curr` will not underflow. // // We can directly compare the packed value. // If the address is zero, packed will be zero. while (packed == 0) { packed = _packedOwnerships[--curr]; } return packed; } } } revert OwnerQueryForNonexistentToken(); } /** * @dev Returns the unpacked `TokenOwnership` struct from `packed`. */ function _unpackedOwnership(uint256 packed) private pure returns (TokenOwnership memory ownership) { ownership.addr = address(uint160(packed)); ownership.startTimestamp = uint64(packed >> _BITPOS_START_TIMESTAMP); ownership.burned = packed & _BITMASK_BURNED != 0; ownership.extraData = uint24(packed >> _BITPOS_EXTRA_DATA); } /** * @dev Packs ownership data into a single uint256. */ function _packOwnershipData(address owner, uint256 flags) private view returns (uint256 result) { assembly { // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean. owner := and(owner, _BITMASK_ADDRESS) // `owner | (block.timestamp << _BITPOS_START_TIMESTAMP) | flags`. result := or(owner, or(shl(_BITPOS_START_TIMESTAMP, timestamp()), flags)) } } /** * @dev Returns the `nextInitialized` flag set if `quantity` equals 1. */ function _nextInitializedFlag(uint256 quantity) private pure returns (uint256 result) { // For branchless setting of the `nextInitialized` flag. assembly { // `(quantity == 1) << _BITPOS_NEXT_INITIALIZED`. result := shl(_BITPOS_NEXT_INITIALIZED, eq(quantity, 1)) } } // ============================================================= // APPROVAL OPERATIONS // ============================================================= /** * @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) public payable virtual override { address owner = ownerOf(tokenId); if (_msgSenderERC721A() != owner) if (!isApprovedForAll(owner, _msgSenderERC721A())) { revert ApprovalCallerNotOwnerNorApproved(); } _tokenApprovals[tokenId].value = to; emit Approval(owner, to, tokenId); } /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return _tokenApprovals[tokenId].value; } /** * @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) public virtual override { _operatorApprovals[_msgSenderERC721A()][operator] = approved; emit ApprovalForAll(_msgSenderERC721A(), operator, approved); } /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @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. See {_mint}. */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _startTokenId() <= tokenId && tokenId < _currentIndex && // If within bounds, _packedOwnerships[tokenId] & _BITMASK_BURNED == 0; // and not burned. } /** * @dev Returns whether `msgSender` is equal to `approvedAddress` or `owner`. */ function _isSenderApprovedOrOwner( address approvedAddress, address owner, address msgSender ) private pure returns (bool result) { assembly { // Mask `owner` to the lower 160 bits, in case the upper bits somehow aren't clean. owner := and(owner, _BITMASK_ADDRESS) // Mask `msgSender` to the lower 160 bits, in case the upper bits somehow aren't clean. msgSender := and(msgSender, _BITMASK_ADDRESS) // `msgSender == owner || msgSender == approvedAddress`. result := or(eq(msgSender, owner), eq(msgSender, approvedAddress)) } } /** * @dev Returns the storage slot and value for the approved address of `tokenId`. */ function _getApprovedSlotAndAddress(uint256 tokenId) private view returns (uint256 approvedAddressSlot, address approvedAddress) { TokenApprovalRef storage tokenApproval = _tokenApprovals[tokenId]; // The following is equivalent to `approvedAddress = _tokenApprovals[tokenId].value`. assembly { approvedAddressSlot := tokenApproval.slot approvedAddress := sload(approvedAddressSlot) } } // ============================================================= // TRANSFER OPERATIONS // ============================================================= /** * @dev Transfers `tokenId` from `from` to `to`. * * 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 ) public payable virtual override { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); if (address(uint160(prevOwnershipPacked)) != from) revert TransferFromIncorrectOwner(); (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId); // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A())) if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved(); if (to == address(0)) revert TransferToZeroAddress(); _beforeTokenTransfers(from, to, tokenId, 1); // Clear approvals from the previous owner. assembly { if approvedAddress { // This is equivalent to `delete _tokenApprovals[tokenId]`. sstore(approvedAddressSlot, 0) } } // 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 { // We can directly increment and decrement the balances. --_packedAddressData[from]; // Updates: `balance -= 1`. ++_packedAddressData[to]; // Updates: `balance += 1`. // Updates: // - `address` to the next owner. // - `startTimestamp` to the timestamp of transfering. // - `burned` to `false`. // - `nextInitialized` to `true`. _packedOwnerships[tokenId] = _packOwnershipData( to, _BITMASK_NEXT_INITIALIZED | _nextExtraData(from, to, prevOwnershipPacked) ); // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (_packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != _currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. _packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, to, tokenId); _afterTokenTransfers(from, to, tokenId, 1); } /** * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public payable virtual override { safeTransferFrom(from, to, tokenId, ''); } /** * @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 memory _data ) public payable virtual override { transferFrom(from, to, tokenId); if (to.code.length != 0) if (!_checkContractOnERC721Received(from, to, tokenId, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } /** * @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 {} /** * @dev Private function to invoke {IERC721Receiver-onERC721Received} on a target contract. * * `from` - Previous owner of the given token ID. * `to` - Target address that will receive the token. * `tokenId` - Token ID to be transferred. * `_data` - Optional data to send along with the call. * * Returns whether the call correctly returned the expected magic value. */ function _checkContractOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { try ERC721A__IERC721Receiver(to).onERC721Received(_msgSenderERC721A(), from, tokenId, _data) returns ( bytes4 retval ) { return retval == ERC721A__IERC721Receiver(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert TransferToNonERC721ReceiverImplementer(); } else { assembly { revert(add(32, reason), mload(reason)) } } } } // ============================================================= // MINT OPERATIONS // ============================================================= /** * @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 for each mint. */ function _mint(address to, uint256 quantity) internal virtual { uint256 startTokenId = _currentIndex; if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // `balance` and `numberMinted` have a maximum limit of 2**64. // `tokenId` has a maximum limit of 2**256. unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the `balance` and `numberMinted`. _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. _packedOwnerships[startTokenId] = _packOwnershipData( to, _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0) ); uint256 toMasked; uint256 end = startTokenId + quantity; // Use assembly to loop and emit the `Transfer` event for gas savings. // The duplicated `log4` removes an extra check and reduces stack juggling. // The assembly, together with the surrounding Solidity code, have been // delicately arranged to nudge the compiler into producing optimized opcodes. assembly { // Mask `to` to the lower 160 bits, in case the upper bits somehow aren't clean. toMasked := and(to, _BITMASK_ADDRESS) // Emit the `Transfer` event. log4( 0, // Start of data (0, since no data). 0, // End of data (0, since no data). _TRANSFER_EVENT_SIGNATURE, // Signature. 0, // `address(0)`. toMasked, // `to`. startTokenId // `tokenId`. ) // The `iszero(eq(,))` check ensures that large values of `quantity` // that overflows uint256 will make the loop run out of gas. // The compiler will optimize the `iszero` away for performance. for { let tokenId := add(startTokenId, 1) } iszero(eq(tokenId, end)) { tokenId := add(tokenId, 1) } { // Emit the `Transfer` event. Similar to above. log4(0, 0, _TRANSFER_EVENT_SIGNATURE, 0, toMasked, tokenId) } } if (toMasked == 0) revert MintToZeroAddress(); _currentIndex = end; } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Mints `quantity` tokens and transfers them to `to`. * * This function is intended for efficient minting only during contract creation. * * It emits only one {ConsecutiveTransfer} as defined in * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309), * instead of a sequence of {Transfer} event(s). * * Calling this function outside of contract creation WILL make your contract * non-compliant with the ERC721 standard. * For full ERC721 compliance, substituting ERC721 {Transfer} event(s) with the ERC2309 * {ConsecutiveTransfer} event is only permissible during contract creation. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {ConsecutiveTransfer} event. */ function _mintERC2309(address to, uint256 quantity) internal virtual { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); if (quantity > _MAX_MINT_ERC2309_QUANTITY_LIMIT) revert MintERC2309QuantityExceedsLimit(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are unrealistic due to the above check for `quantity` to be below the limit. unchecked { // Updates: // - `balance += quantity`. // - `numberMinted += quantity`. // // We can directly add to the `balance` and `numberMinted`. _packedAddressData[to] += quantity * ((1 << _BITPOS_NUMBER_MINTED) | 1); // Updates: // - `address` to the owner. // - `startTimestamp` to the timestamp of minting. // - `burned` to `false`. // - `nextInitialized` to `quantity == 1`. _packedOwnerships[startTokenId] = _packOwnershipData( to, _nextInitializedFlag(quantity) | _nextExtraData(address(0), to, 0) ); emit ConsecutiveTransfer(startTokenId, startTokenId + quantity - 1, address(0), to); _currentIndex = startTokenId + quantity; } _afterTokenTransfers(address(0), to, startTokenId, 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. * * See {_mint}. * * Emits a {Transfer} event for each mint. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal virtual { _mint(to, quantity); unchecked { if (to.code.length != 0) { uint256 end = _currentIndex; uint256 index = end - quantity; do { if (!_checkContractOnERC721Received(address(0), to, index++, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } while (index < end); // Reentrancy protection. if (_currentIndex != end) revert(); } } } /** * @dev Equivalent to `_safeMint(to, quantity, '')`. */ function _safeMint(address to, uint256 quantity) internal virtual { _safeMint(to, quantity, ''); } // ============================================================= // BURN OPERATIONS // ============================================================= /** * @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 { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); address from = address(uint160(prevOwnershipPacked)); (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedSlotAndAddress(tokenId); if (approvalCheck) { // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isSenderApprovedOrOwner(approvedAddress, from, _msgSenderERC721A())) if (!isApprovedForAll(from, _msgSenderERC721A())) revert TransferCallerNotOwnerNorApproved(); } _beforeTokenTransfers(from, address(0), tokenId, 1); // Clear approvals from the previous owner. assembly { if approvedAddress { // This is equivalent to `delete _tokenApprovals[tokenId]`. sstore(approvedAddressSlot, 0) } } // 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 { // Updates: // - `balance -= 1`. // - `numberBurned += 1`. // // We can directly decrement the balance, and increment the number burned. // This is equivalent to `packed -= 1; packed += 1 << _BITPOS_NUMBER_BURNED;`. _packedAddressData[from] += (1 << _BITPOS_NUMBER_BURNED) - 1; // Updates: // - `address` to the last owner. // - `startTimestamp` to the timestamp of burning. // - `burned` to `true`. // - `nextInitialized` to `true`. _packedOwnerships[tokenId] = _packOwnershipData( from, (_BITMASK_BURNED | _BITMASK_NEXT_INITIALIZED) | _nextExtraData(from, address(0), prevOwnershipPacked) ); // If the next slot may not have been initialized (i.e. `nextInitialized == false`) . if (prevOwnershipPacked & _BITMASK_NEXT_INITIALIZED == 0) { uint256 nextTokenId = tokenId + 1; // If the next slot's address is zero and not burned (i.e. packed value is zero). if (_packedOwnerships[nextTokenId] == 0) { // If the next slot is within bounds. if (nextTokenId != _currentIndex) { // Initialize the next slot to maintain correctness for `ownerOf(tokenId + 1)`. _packedOwnerships[nextTokenId] = prevOwnershipPacked; } } } } emit Transfer(from, address(0), tokenId); _afterTokenTransfers(from, address(0), tokenId, 1); // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times. unchecked { _burnCounter++; } } // ============================================================= // EXTRA DATA OPERATIONS // ============================================================= /** * @dev Directly sets the extra data for the ownership data `index`. */ function _setExtraDataAt(uint256 index, uint24 extraData) internal virtual { uint256 packed = _packedOwnerships[index]; if (packed == 0) revert OwnershipNotInitializedForExtraData(); uint256 extraDataCasted; // Cast `extraData` with assembly to avoid redundant masking. assembly { extraDataCasted := extraData } packed = (packed & _BITMASK_EXTRA_DATA_COMPLEMENT) | (extraDataCasted << _BITPOS_EXTRA_DATA); _packedOwnerships[index] = packed; } /** * @dev Called during each token transfer to set the 24bit `extraData` field. * Intended to be overridden by the cosumer contract. * * `previousExtraData` - the value of `extraData` before transfer. * * 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 _extraData( address from, address to, uint24 previousExtraData ) internal view virtual returns (uint24) {} /** * @dev Returns the next extra data for the packed ownership data. * The returned result is shifted into position. */ function _nextExtraData( address from, address to, uint256 prevOwnershipPacked ) private view returns (uint256) { uint24 extraData = uint24(prevOwnershipPacked >> _BITPOS_EXTRA_DATA); return uint256(_extraData(from, to, extraData)) << _BITPOS_EXTRA_DATA; } // ============================================================= // OTHER OPERATIONS // ============================================================= /** * @dev Returns the message sender (defaults to `msg.sender`). * * If you are writing GSN compatible contracts, you need to override this function. */ function _msgSenderERC721A() internal view virtual returns (address) { return msg.sender; } /** * @dev Converts a uint256 to its ASCII string decimal representation. */ function _toString(uint256 value) internal pure virtual returns (string memory str) { assembly { // The maximum value of a uint256 contains 78 digits (1 byte per digit), but // we allocate 0xa0 bytes to keep the free memory pointer 32-byte word aligned. // We will need 1 word for the trailing zeros padding, 1 word for the length, // and 3 words for a maximum of 78 digits. Total: 5 * 0x20 = 0xa0. let m := add(mload(0x40), 0xa0) // Update the free memory pointer to allocate. mstore(0x40, m) // Assign the `str` to the end. str := sub(m, 0x20) // Zeroize the slot after the string. mstore(str, 0) // Cache the end of the memory to calculate the length later. let end := str // We write the string from rightmost digit to leftmost digit. // The following is essentially a do-while loop that also handles the zero case. // prettier-ignore for { let temp := value } 1 {} { str := sub(str, 1) // Write the character to the pointer. // The ASCII index of the '0' character is 48. mstore8(str, add(48, mod(temp, 10))) // Keep dividing `temp` until zero. temp := div(temp, 10) // prettier-ignore if iszero(temp) { break } } let length := sub(end, str) // Move the pointer 32 bytes leftwards to make room for the length. str := sub(str, 0x20) // Store the length. mstore(str, length) } } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721ABurnable.sol'; import '../ERC721A.sol'; /** * @title ERC721ABurnable. * * @dev ERC721A token that can be irreversibly burned (destroyed). */ abstract contract ERC721ABurnable is ERC721A, IERC721ABurnable { /** * @dev Burns `tokenId`. See {ERC721A-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) public virtual override { _burn(tokenId, true); } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721AQueryable.sol'; import '../ERC721A.sol'; /** * @title ERC721AQueryable. * * @dev ERC721A subclass with convenience query functions. */ abstract contract ERC721AQueryable is ERC721A, IERC721AQueryable { /** * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting. * * If the `tokenId` is out of bounds: * * - `addr = address(0)` * - `startTimestamp = 0` * - `burned = false` * - `extraData = 0` * * If the `tokenId` is burned: * * - `addr = <Address of owner before token was burned>` * - `startTimestamp = <Timestamp when token was burned>` * - `burned = true` * - `extraData = <Extra data when token was burned>` * * Otherwise: * * - `addr = <Address of owner>` * - `startTimestamp = <Timestamp of start of ownership>` * - `burned = false` * - `extraData = <Extra data at start of ownership>` */ function explicitOwnershipOf(uint256 tokenId) public view virtual override returns (TokenOwnership memory) { TokenOwnership memory ownership; if (tokenId < _startTokenId() || tokenId >= _nextTokenId()) { return ownership; } ownership = _ownershipAt(tokenId); if (ownership.burned) { return ownership; } return _ownershipOf(tokenId); } /** * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order. * See {ERC721AQueryable-explicitOwnershipOf} */ function explicitOwnershipsOf(uint256[] calldata tokenIds) external view virtual override returns (TokenOwnership[] memory) { unchecked { uint256 tokenIdsLength = tokenIds.length; TokenOwnership[] memory ownerships = new TokenOwnership[](tokenIdsLength); for (uint256 i; i != tokenIdsLength; ++i) { ownerships[i] = explicitOwnershipOf(tokenIds[i]); } return ownerships; } } /** * @dev Returns an array of token IDs owned by `owner`, * in the range [`start`, `stop`) * (i.e. `start <= tokenId < stop`). * * This function allows for tokens to be queried if the collection * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}. * * Requirements: * * - `start < stop` */ function tokensOfOwnerIn( address owner, uint256 start, uint256 stop ) external view virtual override returns (uint256[] memory) { unchecked { if (start >= stop) revert InvalidQueryRange(); uint256 tokenIdsIdx; uint256 stopLimit = _nextTokenId(); // Set `start = max(start, _startTokenId())`. if (start < _startTokenId()) { start = _startTokenId(); } // Set `stop = min(stop, stopLimit)`. if (stop > stopLimit) { stop = stopLimit; } uint256 tokenIdsMaxLength = balanceOf(owner); // Set `tokenIdsMaxLength = min(balanceOf(owner), stop - start)`, // to cater for cases where `balanceOf(owner)` is too big. if (start < stop) { uint256 rangeLength = stop - start; if (rangeLength < tokenIdsMaxLength) { tokenIdsMaxLength = rangeLength; } } else { tokenIdsMaxLength = 0; } uint256[] memory tokenIds = new uint256[](tokenIdsMaxLength); if (tokenIdsMaxLength == 0) { return tokenIds; } // We need to call `explicitOwnershipOf(start)`, // because the slot at `start` may not be initialized. TokenOwnership memory ownership = explicitOwnershipOf(start); address currOwnershipAddr; // If the starting slot exists (i.e. not burned), initialize `currOwnershipAddr`. // `ownership.address` will not be zero, as `start` is clamped to the valid token ID range. if (!ownership.burned) { currOwnershipAddr = ownership.addr; } for (uint256 i = start; i != stop && tokenIdsIdx != tokenIdsMaxLength; ++i) { ownership = _ownershipAt(i); if (ownership.burned) { continue; } if (ownership.addr != address(0)) { currOwnershipAddr = ownership.addr; } if (currOwnershipAddr == owner) { tokenIds[tokenIdsIdx++] = i; } } // Downsize the array to fit. assembly { mstore(tokenIds, tokenIdsIdx) } return tokenIds; } } /** * @dev Returns an array of token IDs owned by `owner`. * * This function scans the ownership mapping and is O(`totalSupply`) in complexity. * It is meant to be called off-chain. * * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into * multiple smaller scans if the collection is large enough to cause * an out-of-gas error (10K collections should be fine). */ function tokensOfOwner(address owner) external view virtual override returns (uint256[] memory) { unchecked { uint256 tokenIdsIdx; address currOwnershipAddr; uint256 tokenIdsLength = balanceOf(owner); uint256[] memory tokenIds = new uint256[](tokenIdsLength); TokenOwnership memory ownership; for (uint256 i = _startTokenId(); tokenIdsIdx != tokenIdsLength; ++i) { ownership = _ownershipAt(i); if (ownership.burned) { continue; } if (ownership.addr != address(0)) { currOwnershipAddr = ownership.addr; } if (currOwnershipAddr == owner) { tokenIds[tokenIdsIdx++] = i; } } return tokenIds; } } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import '../IERC721A.sol'; /** * @dev Interface of ERC721ABurnable. */ interface IERC721ABurnable is IERC721A { /** * @dev Burns `tokenId`. See {ERC721A-_burn}. * * Requirements: * * - The caller must own `tokenId` or be an approved operator. */ function burn(uint256 tokenId) external; }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; import '../IERC721A.sol'; /** * @dev Interface of ERC721AQueryable. */ interface IERC721AQueryable is IERC721A { /** * Invalid query range (`start` >= `stop`). */ error InvalidQueryRange(); /** * @dev Returns the `TokenOwnership` struct at `tokenId` without reverting. * * If the `tokenId` is out of bounds: * * - `addr = address(0)` * - `startTimestamp = 0` * - `burned = false` * - `extraData = 0` * * If the `tokenId` is burned: * * - `addr = <Address of owner before token was burned>` * - `startTimestamp = <Timestamp when token was burned>` * - `burned = true` * - `extraData = <Extra data when token was burned>` * * Otherwise: * * - `addr = <Address of owner>` * - `startTimestamp = <Timestamp of start of ownership>` * - `burned = false` * - `extraData = <Extra data at start of ownership>` */ function explicitOwnershipOf(uint256 tokenId) external view returns (TokenOwnership memory); /** * @dev Returns an array of `TokenOwnership` structs at `tokenIds` in order. * See {ERC721AQueryable-explicitOwnershipOf} */ function explicitOwnershipsOf(uint256[] memory tokenIds) external view returns (TokenOwnership[] memory); /** * @dev Returns an array of token IDs owned by `owner`, * in the range [`start`, `stop`) * (i.e. `start <= tokenId < stop`). * * This function allows for tokens to be queried if the collection * grows too big for a single call of {ERC721AQueryable-tokensOfOwner}. * * Requirements: * * - `start < stop` */ function tokensOfOwnerIn( address owner, uint256 start, uint256 stop ) external view returns (uint256[] memory); /** * @dev Returns an array of token IDs owned by `owner`. * * This function scans the ownership mapping and is O(`totalSupply`) in complexity. * It is meant to be called off-chain. * * See {ERC721AQueryable-tokensOfOwnerIn} for splitting the scan into * multiple smaller scans if the collection is large enough to cause * an out-of-gas error (10K collections should be fine). */ function tokensOfOwner(address owner) external view returns (uint256[] memory); }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.2.3 // Creator: Chiru Labs pragma solidity ^0.8.4; /** * @dev Interface of ERC721A. */ interface IERC721A { /** * The caller must own the token or be an approved operator. */ error ApprovalCallerNotOwnerNorApproved(); /** * The token does not exist. */ error ApprovalQueryForNonexistentToken(); /** * 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(); /** * The `quantity` minted with ERC2309 exceeds the safety limit. */ error MintERC2309QuantityExceedsLimit(); /** * The `extraData` cannot be set on an unintialized ownership slot. */ error OwnershipNotInitializedForExtraData(); // ============================================================= // STRUCTS // ============================================================= struct TokenOwnership { // The address of the owner. address addr; // Stores the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; // Arbitrary data similar to `startTimestamp` that can be set via {_extraData}. uint24 extraData; } // ============================================================= // TOKEN COUNTERS // ============================================================= /** * @dev Returns the total number of tokens in existence. * Burned tokens will reduce the count. * To get the total number of tokens minted, please see {_totalMinted}. */ function totalSupply() external view returns (uint256); // ============================================================= // IERC165 // ============================================================= /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * [EIP section](https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified) * to learn more about how these ids are created. * * This function call must use less than 30000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); // ============================================================= // IERC721 // ============================================================= /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables * (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in `owner`'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, * checking first that contract recipients are aware of the ERC721 protocol * to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move * this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement * {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external payable; /** * @dev Equivalent to `safeTransferFrom(from, to, tokenId, '')`. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external payable; /** * @dev Transfers `tokenId` 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 payable; /** * @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 payable; /** * @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); // ============================================================= // IERC721Metadata // ============================================================= /** * @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); // ============================================================= // IERC2309 // ============================================================= /** * @dev Emitted when tokens in `fromTokenId` to `toTokenId` * (inclusive) is transferred from `from` to `to`, as defined in the * [ERC2309](https://eips.ethereum.org/EIPS/eip-2309) standard. * * See {_mintERC2309} for more details. */ event ConsecutiveTransfer(uint256 indexed fromTokenId, uint256 toTokenId, address indexed from, address indexed to); }
{ "optimizer": { "enabled": true, "runs": 200 }, "viaIR": true, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"string","name":"__name","type":"string"},{"internalType":"string","name":"__symbol","type":"string"},{"internalType":"string","name":"_baseUri","type":"string"},{"internalType":"string","name":"_uri","type":"string"},{"internalType":"address","name":"_royaltyReceiver","type":"address"},{"internalType":"uint96","name":"_royaltyValue","type":"uint96"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"InvalidQueryRange","type":"error"},{"inputs":[],"name":"MintERC2309QuantityExceedsLimit","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"OwnershipNotInitializedForExtraData","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","type":"error"},{"inputs":[],"name":"URIQueryForNonexistentToken","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","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":"uint256","name":"fromTokenId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"toTokenId","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"ConsecutiveTransfer","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":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"MAX_SUPPLY","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseUri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"to","type":"address[]"}],"name":"batchMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"explicitOwnershipOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership","name":"","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"explicitOwnershipsOf","outputs":[{"components":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint64","name":"startTimestamp","type":"uint64"},{"internalType":"bool","name":"burned","type":"bool"},{"internalType":"uint24","name":"extraData","type":"uint24"}],"internalType":"struct IERC721A.TokenOwnership[]","name":"","type":"tuple[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_baseUri","type":"string"}],"name":"setBaseUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newContractURI","type":"string"}],"name":"setContractUri","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"newName","type":"string"},{"internalType":"string","name":"newSymbol","type":"string"}],"name":"setNameAndSymbol","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"receiver","type":"address"},{"internalType":"uint96","name":"value","type":"uint96"}],"name":"setRoyalties","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":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"tokensOfOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"start","type":"uint256"},{"internalType":"uint256","name":"stop","type":"uint256"}],"name":"tokensOfOwnerIn","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60406080815234620008f55762002bcf803803806200001e81620008f9565b92833981019060c081830312620008f55780516001600160401b0390818111620008f55783620000509184016200091f565b90602080840151828111620008f557856200006d9186016200091f565b9186850151818111620008f55786620000889187016200091f565b95606086015190828211620008f557620000a49187016200091f565b60808601516001600160a01b03808216989097909291899003620008f55760a00151956001600160601b03871695868803620008f5578151938585116200037157600254916001958684811c94168015620008ea575b89851014620004de57601f93848111620008a1575b5080898582116001146200083d575f9162000831575b505f19600383901b1c191690871b176002555b805193878511620003715760039485548881811c9116801562000826575b8b821014620004de57858111620007de575b50808a8682116001146200077b575f916200076f575b505f1982881b1c191690881b1785555b865f55600a5460018060a01b03199c8d3390831617600a553391167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a38051908882116200037157600c54908882811c9216801562000764575b8b831014620004de57818684931162000710575b508a90868311600114620006a9575f926200069d575b50505f1982871b1c191690871b17600c555b8051908782116200037157600d54908782811c9216801562000692575b8a831014620004de5781858493116200063e575b508990858311600114620005d9575f92620005cd575b50505f1982861b1c191690861b17600d555b8051908682116200037157600b54908682811c92168015620005c2575b89831014620004de5781848493116200056e575b50889084831160011462000509575f92620004fd575b50505f1982851b1c191690851b17600b555b8251928584116200037157600e548581811c91168015620004f2575b88821014620004de5782811162000495575b50869184116001146200042c579383949184925f9562000420575b50501b925f19911b1c191617600e555b6127108311620003c957851562000385578651908188019081118282101762000371578752858152015260a01b16176008555161223f9081620009908239f35b634e487b7160e01b5f52604160045260245ffd5b865162461bcd60e51b815260048101839052601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606490fd5b865162461bcd60e51b815260048101839052602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608490fd5b015193505f8062000321565b9190601f19841692600e5f5284885f20945f5b8a898383106200047d575050501062000463575b50505050811b01600e5562000331565b01519060f8845f19921b161c191690555f80808062000453565b8686015189559097019694850194889350016200043f565b600e5f52875f208380870160051c8201928a8810620004d4575b0160051c019086905b828110620004c857505062000306565b5f8155018690620004b8565b92508192620004af565b634e487b7160e01b5f52602260045260245ffd5b90607f1690620002f4565b015190505f80620002c6565b90879350601f19831691600b5f528a5f20925f5b8c8282106200055757505084116200053f575b505050811b01600b55620002d8565b01515f1983871b60f8161c191690555f808062000530565b8385015186558b979095019493840193016200051d565b909150600b5f52885f208480850160051c8201928b8610620005b8575b918991869594930160051c01915b828110620005a9575050620002b0565b5f815585945089910162000599565b925081926200058b565b91607f16916200029c565b015190505f806200026d565b90889350601f19831691600d5f528b5f20925f5b8d8282106200062757505084116200060f575b505050811b01600d556200027f565b01515f1983881b60f8161c191690555f808062000600565b8385015186558c97909501949384019301620005ed565b909150600d5f52895f208580850160051c8201928c861062000688575b918a91869594930160051c01915b8281106200067957505062000257565b5f81558594508a910162000669565b925081926200065b565b91607f169162000243565b015190505f8062000214565b90899350601f19831691600c5f528c5f20928d5f905b828210620006f85750508411620006e0575b505050811b01600c5562000226565b01515f1983891b60f8161c191690555f8080620006d1565b8385015186558d979095019493840193018e620006bf565b909150600c5f528a5f208680850160051c8201928d86106200075a575b918b91869594930160051c01915b8281106200074b575050620001fe565b5f81558594508b91016200073b565b925081926200072d565b91607f1691620001ea565b90508301515f6200017e565b5f8881528c81208b94509190601f198416908e5b828210620007c65750508311620007ae575b5050811b0185556200018e565b8501515f19838a1b60f8161c191690555f80620007a1565b8389015185558d969094019392830192018e6200078f565b865f528a5f208680840160051c8201928d85106200081c575b0160051c019089905b8281106200081057505062000168565b5f815501899062000800565b92508192620007f7565b90607f169062000156565b90508501515f62000125565b889250601f1982169060025f528b5f20915f5b8d8282106200088a575050831162000871575b5050811b0160025562000138565b8701515f1960f88460031b161c191690555f8062000863565b838b015185558c9690940193928301920162000850565b60025f52895f208580840160051c8201928c8510620008e0575b0160051c019088905b828110620008d45750506200010f565b5f8155018890620008c4565b92508192620008bb565b93607f1693620000fa565b5f80fd5b6040519190601f01601f191682016001600160401b038111838210176200037157604052565b919080601f84011215620008f55782516001600160401b038111620003715760209062000955601f8201601f19168301620008f9565b92818452828287010111620008f5575f5b8181106200097b5750825f9394955001015290565b85810183015184820184015282016200096656fe60806040526004361015610011575f80fd5b5f3560e01c806301ffc9a71461020457806306fdde03146101ff578063081812fc146101fa578063095ea7b3146101f557806318160ddd146101f057806323b872dd146101eb5780632a55205a146101e657806332cb6b0c146101e157806342842e0e146101dc57806342966c68146101d75780635a446215146101d25780635bbb2177146101cd5780636352211e146101c857806370a08231146101c3578063715018a6146101be5780638462151c146101b95780638da5cb5b146101b457806395d89b41146101af57806399a2557a146101aa5780639abc8320146101a5578063a0bcfc7f146101a0578063a22cb4651461019b578063b88d4fde14610196578063c21b471b14610191578063c23dc68f1461018c578063c87b56dd14610187578063ccb4807b14610182578063d67b06c11461017d578063e8a3d48514610178578063e985e9c5146101735763f2fde38b1461016e575f80fd5b611619565b6115b5565b61150e565b611462565b61137d565b6112b3565b611250565b611148565b6110be565b611005565b610f20565b610ec3565b610d28565b610c81565b610c59565b610ba2565b610b0b565b610adc565b610aad565b610a0b565b610804565b610640565b61061e565b610602565b610570565b61055c565b61050c565b610453565b6103f0565b610313565b61021f565b6001600160e01b031981160361021b57565b5f80fd5b3461021b57602036600319011261021b57602060043561023e81610209565b63ffffffff60e01b166301ffc9a760e01b811490819082156102a8575b8215610297575b8215610275575b50506040519015158152f35b63152a902d60e11b149150811561028f575b505f80610269565b90505f610287565b635b5e139f60e01b81149250610262565b6380ac58cd60e01b8114925061025b565b5f5b8381106102ca5750505f910152565b81810151838201526020016102bb565b906020916102f3815180928185528580860191016102b9565b601f01601f1916010190565b9060206103109281815201906102da565b90565b3461021b575f806003193601126103ed5760405181600c5461033481610d64565b9081845260209260019182811690815f146103cb5750600114610372575b61036e8561036281890382610de6565b604051918291826102ff565b0390f35b929450600c83527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c75b8284106103b8575050508161036e9361036292820101935f610352565b805485850187015292850192810161039b565b60ff191686860152505050151560051b82010191506103628161036e5f610352565b80fd5b3461021b57602036600319011261021b5760043561040d81611b76565b15610430575f526006602052602060018060a01b0360405f205416604051908152f35b6040516333d1c03960e21b8152600490fd5b6001600160a01b0381160361021b57565b604036600319011261021b5760043561046b81610442565b6024356001600160a01b038061048083611af9565b16908133036104da575b5f83815260066020526040812080546001600160a01b0319166001600160a01b0387161790559316907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258480a480f35b5f82815260076020908152604080832033845290915290205460ff1661048a576040516367d9dca160e11b8152600490fd5b3461021b575f36600319011261021b575f5460015460405191035f19018152602090f35b606090600319011261021b5760043561054881610442565b9060243561055581610442565b9060443590565b61056e61056836610530565b91611bae565b005b3461021b57604036600319011261021b576024356004355f52600960205261059a60405f2061175e565b80519091906001600160a01b0316156105f2575b6001600160601b03602083015116908181029181830414901517156105ed579051604080516001600160a01b0390921682526127109092046020820152f35b611783565b90506105fc611738565b906105ae565b3461021b575f36600319011261021b576020604051610bb88152f35b61056e61062a36610530565b906040519261063884610dcb565b5f8452611d52565b3461021b57602036600319011261021b5760043561065d81611af9565b5f8281526006602052604090208054916001600160a01b0381169133808514908414171561068a565b1590565b610780575b5f93610777575b506001600160a01b0382165f90815260056020526040902080546fffffffffffffffffffffffffffffffff0190556001600160a01b0382164260a01b17600360e01b176106eb855f52600460205260405f2090565b55600160e11b811615610732575b507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8280a461056e61072d60015460010190565b600155565b60018401610748815f52600460205260405f2090565b5415610755575b506106f9565b8354811461074f5761076f905f52600460205260405f2090565b555f8061074f565b8390555f610696565b6107c06106866107b9336107a48760018060a01b03165f52600760205260405f2090565b9060018060a01b03165f5260205260405f2090565b5460ff1690565b1561068f57604051632ce44b5f60e11b8152600490fd5b9181601f8401121561021b578235916001600160401b03831161021b576020838186019501011161021b57565b3461021b57604036600319011261021b576001600160401b0360043581811161021b576108359036906004016107d7565b9160243581811161021b5761084e9036906004016107d7565b9290916108596116e0565b841161093d576108738461086e600c54610d64565b611797565b5f90601f85116001146108b85793806108a59261056e965f926108ad575b50508160011b915f199060031b1c19161790565b600c55611957565b013590505f80610891565b600c5f527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c791601f198616815b818110610925575091600193918761056e98941061090c575b505050811b01600c55611957565b01355f19600384901b60f8161c191690555f80806108fe565b919360206001819287870135815501950192016108e5565b610d9c565b90602060031983011261021b576004356001600160401b039283821161021b578060238301121561021b57816004013593841161021b5760248460051b8301011161021b576024019190565b602090816040818301928281528551809452019301915f5b8281106109b4575050505090565b90919293826080826109ff600194895162ffffff6060809260018060a01b0381511685526001600160401b036020820151166020860152604081015115156040860152015116910152565b019501939291016109a6565b3461021b57610a1936610942565b90610a238261205b565b91610a316040519384610de6565b808352601f19610a408261205b565b015f5b818110610a965750505f5b818103610a63576040518061036e868261098e565b80610a7a610a746001938587611a8a565b35611fa1565b610a848287612072565b52610a8f8186612072565b5001610a4e565b602090610aa1611f6d565b82828801015201610a43565b3461021b57602036600319011261021b5760206001600160a01b03610ad3600435611af9565b16604051908152f35b3461021b57602036600319011261021b576020610b03600435610afe81610442565b611aa9565b604051908152f35b3461021b575f806003193601126103ed57610b246116e0565b600a80546001600160a01b0319811690915581906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b602090816040818301928281528551809452019301915f5b828110610b8e575050505090565b835185529381019392810192600101610b80565b3461021b57602036600319011261021b57600435610bbf81610442565b5f8091610bcb81611aa9565b610bd481612086565b92610bdd611f6d565b506001926001600160a01b0390811690845b848403610c04576040518061036e8982610b68565b81610c0e82611fff565b876040820151610c505750511680610c48575b50859083838a1614610c34575b01610bef565b80610c42838701968a612072565b52610c2e565b975085610c21565b92915050610c2e565b3461021b575f36600319011261021b57600a546040516001600160a01b039091168152602090f35b3461021b575f806003193601126103ed5760405181600d54610ca281610d64565b9081845260209260019182811690815f146103cb5750600114610ccf5761036e8561036281890382610de6565b929450600d83527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb55b828410610d15575050508161036e9361036292820101935f610352565b8054858501870152928501928101610cf8565b3461021b57606036600319011261021b5761036e610d58600435610d4b81610442565b60443590602435906120b8565b60405191829182610b68565b90600182811c92168015610d92575b6020831014610d7e57565b634e487b7160e01b5f52602260045260245ffd5b91607f1691610d73565b634e487b7160e01b5f52604160045260245ffd5b604081019081106001600160401b0382111761093d57604052565b602081019081106001600160401b0382111761093d57604052565b90601f801991011681019081106001600160401b0382111761093d57604052565b604051905f82600b5491610e1a83610d64565b808352602093600190818116908115610ea35750600114610e46575b5050610e4492500383610de6565b565b90939150600b5f527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9935f915b818310610e8b575050610e4493508201015f80610e36565b85548884018501529485019487945091830191610e73565b915050610e4494925060ff191682840152151560051b8201015f80610e36565b3461021b575f36600319011261021b5761036e610ede610e07565b6040519182916020835260208301906102da565b602060031982011261021b57600435906001600160401b03821161021b57610f1c916004016107d7565b9091565b3461021b57610f2e36610ef2565b610f366116e0565b6001600160401b03811161093d57610f5881610f53600b54610d64565b611807565b5f601f8211600114610f89578190610f84935f926108ad5750508160011b915f199060031b1c19161790565b600b55005b600b5f52601f198216927f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db991805b858110610fed57508360019510610fd4575b505050811b01600b55005b01355f19600384901b60f8161c191690555f8080610fc9565b90926020600181928686013581550194019101610fb7565b3461021b57604036600319011261021b5760043561102281610442565b6024359081151580920361021b57335f9081526007602090815260408083206001600160a01b0385168452909152902060ff1981541660ff841617905560405191825260018060a01b0316907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a3005b60405190610e4482610db0565b6001600160401b03811161093d57601f01601f191660200190565b608036600319011261021b576004356110d681610442565b6024356110e281610442565b606435916001600160401b03831161021b573660238401121561021b5782600401359161110e836110a3565b9261111c6040519485610de6565b808452366024828701011161021b576020815f92602461056e9801838801378501015260443591611d52565b3461021b57604036600319011261021b5760043561116581610442565b602435906001600160601b03821680830361021b57612710906111866116e0565b116111f85761056e916111d1906111a76001600160a01b0384161515611a2a565b6111c16111b2611096565b6001600160a01b039094168452565b6001600160601b03166020830152565b805160209091015160a01b6001600160a01b0319166001600160a01b039190911617600855565b60405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608490fd5b3461021b57602036600319011261021b57608061126e600435611fa1565b6112b1604051809262ffffff6060809260018060a01b0381511685526001600160401b036020820151166020860152604081015115156040860152015116910152565bf35b3461021b57602036600319011261021b576004356112d081611b76565b1561136b576112dd610e07565b80515f9015611351575060405160a0810160405260808101925f8452925b5f190192600a9060308282060185530492836112fb5761036e935061133f92611345610362936080601f199485810192030181526040519586936020850190611ae2565b90611ae2565b03908101835282610de6565b60405161036e9350915061136482610dcb565b8152610362565b604051630a14c4b560e41b8152600490fd5b3461021b5761138b36610ef2565b6113936116e0565b6001600160401b03811161093d576113b5816113b0600e54610d64565b611877565b5f601f82116001146113e65781906113e1935f926108ad5750508160011b915f199060031b1c19161790565b600e55005b600e5f52601f198216927fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd91805b85811061144a57508360019510611431575b505050811b01600e55005b01355f19600384901b60f8161c191690555f8080611426565b90926020600181928686013581550194019101611414565b3461021b5761147036610942565b906114796116e0565b5f5460018054909391038082015f19908101910181106105ed57610bb8106114c9575f5b8181106114a657005b806114c36114be6114b987948688611a8a565b611a9f565b611eb2565b0161149d565b60405162461bcd60e51b815260206004820152601c60248201527f4d696e7420776f756c6420657863656564206d617820737570706c79000000006044820152606490fd5b3461021b575f806003193601126103ed5760405181600e5461152f81610d64565b9081845260209260019182811690815f146103cb575060011461155c5761036e8561036281890382610de6565b929450600e83527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd5b8284106115a2575050508161036e9361036292820101935f610352565b8054858501870152928501928101611585565b3461021b57604036600319011261021b57602060ff61160d6004356115d981610442565b602435906115e682610442565b60018060a01b03165f526007845260405f209060018060a01b03165f5260205260405f2090565b54166040519015158152f35b3461021b57602036600319011261021b5760043561163681610442565b61163e6116e0565b6001600160a01b0390811690811561168c57600a54826001600160601b0360a01b821617600a55167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a3005b60405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608490fd5b600a546001600160a01b031633036116f457565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b6040519061174582610db0565b6008546001600160a01b038116835260a01c6020830152565b9060405161176b81610db0565b91546001600160a01b038116835260a01c6020830152565b634e487b7160e01b5f52601160045260245ffd5b601f81116117a3575050565b5f90600c82527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7906020601f850160051c830194106117fd575b601f0160051c01915b8281106117f257505050565b8181556001016117e6565b90925082906117dd565b601f8111611813575050565b5f90600b82527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9906020601f850160051c8301941061186d575b601f0160051c01915b82811061186257505050565b818155600101611856565b909250829061184d565b601f8111611883575050565b5f90600e82527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd906020601f850160051c830194106118dd575b601f0160051c01915b8281106118d257505050565b8181556001016118c6565b90925082906118bd565b601f81116118f3575050565b5f90600d82527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb5906020601f850160051c8301941061194d575b601f0160051c01915b82811061194257505050565b818155600101611936565b909250829061192d565b91906001600160401b03811161093d5761197b81611976600d54610d64565b6118e7565b5f601f82116001146119ad5781906119a893945f926108ad5750508160011b915f199060031b1c19161790565b600d55565b600d5f52601f198216937fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb591805b868110611a1257508360019596106119f9575b505050811b01600d55565b01355f19600384901b60f8161c191690555f80806119ee565b909260206001819286860135815501940191016119db565b15611a3157565b60405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606490fd5b634e487b7160e01b5f52603260045260245ffd5b9190811015611a9a5760051b0190565b611a76565b3561031081610442565b6001600160a01b03168015611ad0575f5260056020526001600160401b0360405f20541690565b6040516323d3ad8160e21b8152600490fd5b90611af5602092828151948592016102b9565b0190565b808060011115611b16575b604051636f96cda160e11b8152600490fd5b5f9081548110611b27575b50611b04565b81526004906020918083526040928383205494600160e01b861615611b4e57505050611b21565b93929190935b8515611b6257505050505090565b5f1901808352818552838320549550611b54565b80600111159081611ba3575b81611b8b575090565b90505f526004602052600160e01b60405f2054161590565b5f5481109150611b82565b90611bb883611af9565b6001600160a01b0383811692828216849003611d41575f86815260066020526040902080549092611bf86001600160a01b03881633908114908414171590565b611d06575b8216958615611cf457611c5f93611c2d92611ceb575b506001600160a01b03165f90815260056020526040902090565b80545f190190556001600160a01b03165f818152600560205260409020805460010190554260a01b17600160e11b1790565b611c71855f52600460205260405f2090565b55600160e11b811615611ca6575b507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef5f80a4565b60018401611cbc815f52600460205260405f2090565b5415611cc9575b50611c7f565b5f548114611cc357611ce3905f52600460205260405f2090565b555f80611cc3565b5f90555f611c13565b604051633a954ecd60e21b8152600490fd5b611d2a6106866107b9336107a48b60018060a01b03165f52600760205260405f2090565b15611bfd57604051632ce44b5f60e11b8152600490fd5b60405162a1148160e81b8152600490fd5b929190611d60828286611bae565b803b611d6d575b50505050565b611d7693611e0b565b15611d84575f808080611d67565b6040516368d2bf6b60e11b8152600490fd5b9081602091031261021b575161031081610209565b6001600160a01b039182168152911660208201526040810191909152608060608201819052610310929101906102da565b3d15611e06573d90611ded826110a3565b91611dfb6040519384610de6565b82523d5f602084013e565b606090565b92602091611e33935f604051809681958294630a85bd0160e11b9a8b85523360048601611dab565b03926001600160a01b03165af15f9181611e82575b50611e7457611e55611ddc565b80519081611e6f576040516368d2bf6b60e11b8152600490fd5b602001fd5b6001600160e01b0319161490565b611ea491925060203d8111611eab575b611e9c8183610de6565b810190611d96565b905f611e48565b503d611e92565b5f80546001600160a01b03831682526005602052604082208054680100000000000000010190556001600160a01b0383164260a01b17600160e11b17611f00825f52600460205260405f2090565b556001818101936001600160a01b0316917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908385838180a4845b858103611f5e5750505015611f4d5755565b604051622e076360e81b8152600490fd5b8083918587858180a401611f3b565b60405190608082018281106001600160401b0382111761093d576040525f6060838281528260208201528260408201520152565b611fa9611f6d565b50611fb2611f6d565b600182108015611ff4575b611fef5750611fcb81611fff565b6040810151611fef5750611fea61031091611fe4611f6d565b50611af9565b612018565b905090565b505f54821015611fbd565b612007611f6d565b505f52600460205261031060405f20545b90612021611f6d565b6001600160a01b038316815260a083901c6001600160401b03166020820152600160e01b83161515604082015260e89290921c6060830152565b6001600160401b03811161093d5760051b60200190565b8051821015611a9a5760209160051b010190565b906120908261205b565b61209d6040519182610de6565b82815280926120ae601f199161205b565b0190602036910137565b90828110156121f7575f918254916001928382106121ef575b8086116121e7575b506120e382611aa9565b91858210156121df578186038381106121d7575b505b61210283612086565b9583156121ce57849361211484611fa1565b91879460409361212961068686830151151590565b6121bc575b50955b612142575b50505050505050815290565b80861415806121b2575b156121ad57868661215d8298611fff565b808601516121a757516001600160a01b039081168061219f575b508087169088161461218b575b0195612131565b80612199838c019b8d612072565b52612184565b97505f612177565b50612184565b612136565b508188141561214c565b516001600160a01b031695505f61212e565b50505050505090565b92505f6120f7565b8492506120f9565b94505f6120d9565b8391506120d1565b604051631960ccad60e11b8152600490fdfea2646970667358221220fecf4f3d303968cedea1bcd56acc3aea9a21ee2936ecdc1f61b8de59d2a9b3aa64736f6c6343000815003300000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000734dabe2171dfa9689e94675cc279aa0d3ce703300000000000000000000000000000000000000000000000000000000000003e800000000000000000000000000000000000000000000000000000000000000284d6f6e636c6572207820616469646173204f726967696e616c733a20546865204578706c6f726572000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000541444d4e430000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000043697066733a2f2f62616679626569637733346e35717a7077643736647a7365626d336e787767783472366c68336d6e6268736b736170797036756a69616f676271612f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000042697066733a2f2f6261666b72656968616f6a346b6a7a34616263766d366673666b66327332686a77616e6761613779703566637279746f3477677733677269766c6d000000000000000000000000000000000000000000000000000000000000
Deployed Bytecode
0x60806040526004361015610011575f80fd5b5f3560e01c806301ffc9a71461020457806306fdde03146101ff578063081812fc146101fa578063095ea7b3146101f557806318160ddd146101f057806323b872dd146101eb5780632a55205a146101e657806332cb6b0c146101e157806342842e0e146101dc57806342966c68146101d75780635a446215146101d25780635bbb2177146101cd5780636352211e146101c857806370a08231146101c3578063715018a6146101be5780638462151c146101b95780638da5cb5b146101b457806395d89b41146101af57806399a2557a146101aa5780639abc8320146101a5578063a0bcfc7f146101a0578063a22cb4651461019b578063b88d4fde14610196578063c21b471b14610191578063c23dc68f1461018c578063c87b56dd14610187578063ccb4807b14610182578063d67b06c11461017d578063e8a3d48514610178578063e985e9c5146101735763f2fde38b1461016e575f80fd5b611619565b6115b5565b61150e565b611462565b61137d565b6112b3565b611250565b611148565b6110be565b611005565b610f20565b610ec3565b610d28565b610c81565b610c59565b610ba2565b610b0b565b610adc565b610aad565b610a0b565b610804565b610640565b61061e565b610602565b610570565b61055c565b61050c565b610453565b6103f0565b610313565b61021f565b6001600160e01b031981160361021b57565b5f80fd5b3461021b57602036600319011261021b57602060043561023e81610209565b63ffffffff60e01b166301ffc9a760e01b811490819082156102a8575b8215610297575b8215610275575b50506040519015158152f35b63152a902d60e11b149150811561028f575b505f80610269565b90505f610287565b635b5e139f60e01b81149250610262565b6380ac58cd60e01b8114925061025b565b5f5b8381106102ca5750505f910152565b81810151838201526020016102bb565b906020916102f3815180928185528580860191016102b9565b601f01601f1916010190565b9060206103109281815201906102da565b90565b3461021b575f806003193601126103ed5760405181600c5461033481610d64565b9081845260209260019182811690815f146103cb5750600114610372575b61036e8561036281890382610de6565b604051918291826102ff565b0390f35b929450600c83527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c75b8284106103b8575050508161036e9361036292820101935f610352565b805485850187015292850192810161039b565b60ff191686860152505050151560051b82010191506103628161036e5f610352565b80fd5b3461021b57602036600319011261021b5760043561040d81611b76565b15610430575f526006602052602060018060a01b0360405f205416604051908152f35b6040516333d1c03960e21b8152600490fd5b6001600160a01b0381160361021b57565b604036600319011261021b5760043561046b81610442565b6024356001600160a01b038061048083611af9565b16908133036104da575b5f83815260066020526040812080546001600160a01b0319166001600160a01b0387161790559316907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258480a480f35b5f82815260076020908152604080832033845290915290205460ff1661048a576040516367d9dca160e11b8152600490fd5b3461021b575f36600319011261021b575f5460015460405191035f19018152602090f35b606090600319011261021b5760043561054881610442565b9060243561055581610442565b9060443590565b61056e61056836610530565b91611bae565b005b3461021b57604036600319011261021b576024356004355f52600960205261059a60405f2061175e565b80519091906001600160a01b0316156105f2575b6001600160601b03602083015116908181029181830414901517156105ed579051604080516001600160a01b0390921682526127109092046020820152f35b611783565b90506105fc611738565b906105ae565b3461021b575f36600319011261021b576020604051610bb88152f35b61056e61062a36610530565b906040519261063884610dcb565b5f8452611d52565b3461021b57602036600319011261021b5760043561065d81611af9565b5f8281526006602052604090208054916001600160a01b0381169133808514908414171561068a565b1590565b610780575b5f93610777575b506001600160a01b0382165f90815260056020526040902080546fffffffffffffffffffffffffffffffff0190556001600160a01b0382164260a01b17600360e01b176106eb855f52600460205260405f2090565b55600160e11b811615610732575b507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef8280a461056e61072d60015460010190565b600155565b60018401610748815f52600460205260405f2090565b5415610755575b506106f9565b8354811461074f5761076f905f52600460205260405f2090565b555f8061074f565b8390555f610696565b6107c06106866107b9336107a48760018060a01b03165f52600760205260405f2090565b9060018060a01b03165f5260205260405f2090565b5460ff1690565b1561068f57604051632ce44b5f60e11b8152600490fd5b9181601f8401121561021b578235916001600160401b03831161021b576020838186019501011161021b57565b3461021b57604036600319011261021b576001600160401b0360043581811161021b576108359036906004016107d7565b9160243581811161021b5761084e9036906004016107d7565b9290916108596116e0565b841161093d576108738461086e600c54610d64565b611797565b5f90601f85116001146108b85793806108a59261056e965f926108ad575b50508160011b915f199060031b1c19161790565b600c55611957565b013590505f80610891565b600c5f527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c791601f198616815b818110610925575091600193918761056e98941061090c575b505050811b01600c55611957565b01355f19600384901b60f8161c191690555f80806108fe565b919360206001819287870135815501950192016108e5565b610d9c565b90602060031983011261021b576004356001600160401b039283821161021b578060238301121561021b57816004013593841161021b5760248460051b8301011161021b576024019190565b602090816040818301928281528551809452019301915f5b8281106109b4575050505090565b90919293826080826109ff600194895162ffffff6060809260018060a01b0381511685526001600160401b036020820151166020860152604081015115156040860152015116910152565b019501939291016109a6565b3461021b57610a1936610942565b90610a238261205b565b91610a316040519384610de6565b808352601f19610a408261205b565b015f5b818110610a965750505f5b818103610a63576040518061036e868261098e565b80610a7a610a746001938587611a8a565b35611fa1565b610a848287612072565b52610a8f8186612072565b5001610a4e565b602090610aa1611f6d565b82828801015201610a43565b3461021b57602036600319011261021b5760206001600160a01b03610ad3600435611af9565b16604051908152f35b3461021b57602036600319011261021b576020610b03600435610afe81610442565b611aa9565b604051908152f35b3461021b575f806003193601126103ed57610b246116e0565b600a80546001600160a01b0319811690915581906001600160a01b03167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e08280a380f35b602090816040818301928281528551809452019301915f5b828110610b8e575050505090565b835185529381019392810192600101610b80565b3461021b57602036600319011261021b57600435610bbf81610442565b5f8091610bcb81611aa9565b610bd481612086565b92610bdd611f6d565b506001926001600160a01b0390811690845b848403610c04576040518061036e8982610b68565b81610c0e82611fff565b876040820151610c505750511680610c48575b50859083838a1614610c34575b01610bef565b80610c42838701968a612072565b52610c2e565b975085610c21565b92915050610c2e565b3461021b575f36600319011261021b57600a546040516001600160a01b039091168152602090f35b3461021b575f806003193601126103ed5760405181600d54610ca281610d64565b9081845260209260019182811690815f146103cb5750600114610ccf5761036e8561036281890382610de6565b929450600d83527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb55b828410610d15575050508161036e9361036292820101935f610352565b8054858501870152928501928101610cf8565b3461021b57606036600319011261021b5761036e610d58600435610d4b81610442565b60443590602435906120b8565b60405191829182610b68565b90600182811c92168015610d92575b6020831014610d7e57565b634e487b7160e01b5f52602260045260245ffd5b91607f1691610d73565b634e487b7160e01b5f52604160045260245ffd5b604081019081106001600160401b0382111761093d57604052565b602081019081106001600160401b0382111761093d57604052565b90601f801991011681019081106001600160401b0382111761093d57604052565b604051905f82600b5491610e1a83610d64565b808352602093600190818116908115610ea35750600114610e46575b5050610e4492500383610de6565b565b90939150600b5f527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9935f915b818310610e8b575050610e4493508201015f80610e36565b85548884018501529485019487945091830191610e73565b915050610e4494925060ff191682840152151560051b8201015f80610e36565b3461021b575f36600319011261021b5761036e610ede610e07565b6040519182916020835260208301906102da565b602060031982011261021b57600435906001600160401b03821161021b57610f1c916004016107d7565b9091565b3461021b57610f2e36610ef2565b610f366116e0565b6001600160401b03811161093d57610f5881610f53600b54610d64565b611807565b5f601f8211600114610f89578190610f84935f926108ad5750508160011b915f199060031b1c19161790565b600b55005b600b5f52601f198216927f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db991805b858110610fed57508360019510610fd4575b505050811b01600b55005b01355f19600384901b60f8161c191690555f8080610fc9565b90926020600181928686013581550194019101610fb7565b3461021b57604036600319011261021b5760043561102281610442565b6024359081151580920361021b57335f9081526007602090815260408083206001600160a01b0385168452909152902060ff1981541660ff841617905560405191825260018060a01b0316907f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c3160203392a3005b60405190610e4482610db0565b6001600160401b03811161093d57601f01601f191660200190565b608036600319011261021b576004356110d681610442565b6024356110e281610442565b606435916001600160401b03831161021b573660238401121561021b5782600401359161110e836110a3565b9261111c6040519485610de6565b808452366024828701011161021b576020815f92602461056e9801838801378501015260443591611d52565b3461021b57604036600319011261021b5760043561116581610442565b602435906001600160601b03821680830361021b57612710906111866116e0565b116111f85761056e916111d1906111a76001600160a01b0384161515611a2a565b6111c16111b2611096565b6001600160a01b039094168452565b6001600160601b03166020830152565b805160209091015160a01b6001600160a01b0319166001600160a01b039190911617600855565b60405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b6064820152608490fd5b3461021b57602036600319011261021b57608061126e600435611fa1565b6112b1604051809262ffffff6060809260018060a01b0381511685526001600160401b036020820151166020860152604081015115156040860152015116910152565bf35b3461021b57602036600319011261021b576004356112d081611b76565b1561136b576112dd610e07565b80515f9015611351575060405160a0810160405260808101925f8452925b5f190192600a9060308282060185530492836112fb5761036e935061133f92611345610362936080601f199485810192030181526040519586936020850190611ae2565b90611ae2565b03908101835282610de6565b60405161036e9350915061136482610dcb565b8152610362565b604051630a14c4b560e41b8152600490fd5b3461021b5761138b36610ef2565b6113936116e0565b6001600160401b03811161093d576113b5816113b0600e54610d64565b611877565b5f601f82116001146113e65781906113e1935f926108ad5750508160011b915f199060031b1c19161790565b600e55005b600e5f52601f198216927fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd91805b85811061144a57508360019510611431575b505050811b01600e55005b01355f19600384901b60f8161c191690555f8080611426565b90926020600181928686013581550194019101611414565b3461021b5761147036610942565b906114796116e0565b5f5460018054909391038082015f19908101910181106105ed57610bb8106114c9575f5b8181106114a657005b806114c36114be6114b987948688611a8a565b611a9f565b611eb2565b0161149d565b60405162461bcd60e51b815260206004820152601c60248201527f4d696e7420776f756c6420657863656564206d617820737570706c79000000006044820152606490fd5b3461021b575f806003193601126103ed5760405181600e5461152f81610d64565b9081845260209260019182811690815f146103cb575060011461155c5761036e8561036281890382610de6565b929450600e83527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd5b8284106115a2575050508161036e9361036292820101935f610352565b8054858501870152928501928101611585565b3461021b57604036600319011261021b57602060ff61160d6004356115d981610442565b602435906115e682610442565b60018060a01b03165f526007845260405f209060018060a01b03165f5260205260405f2090565b54166040519015158152f35b3461021b57602036600319011261021b5760043561163681610442565b61163e6116e0565b6001600160a01b0390811690811561168c57600a54826001600160601b0360a01b821617600a55167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e05f80a3005b60405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608490fd5b600a546001600160a01b031633036116f457565b606460405162461bcd60e51b815260206004820152602060248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152fd5b6040519061174582610db0565b6008546001600160a01b038116835260a01c6020830152565b9060405161176b81610db0565b91546001600160a01b038116835260a01c6020830152565b634e487b7160e01b5f52601160045260245ffd5b601f81116117a3575050565b5f90600c82527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7906020601f850160051c830194106117fd575b601f0160051c01915b8281106117f257505050565b8181556001016117e6565b90925082906117dd565b601f8111611813575050565b5f90600b82527f0175b7a638427703f0dbe7bb9bbf987a2551717b34e79f33b5b1008d1fa01db9906020601f850160051c8301941061186d575b601f0160051c01915b82811061186257505050565b818155600101611856565b909250829061184d565b601f8111611883575050565b5f90600e82527fbb7b4a454dc3493923482f07822329ed19e8244eff582cc204f8554c3620c3fd906020601f850160051c830194106118dd575b601f0160051c01915b8281106118d257505050565b8181556001016118c6565b90925082906118bd565b601f81116118f3575050565b5f90600d82527fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb5906020601f850160051c8301941061194d575b601f0160051c01915b82811061194257505050565b818155600101611936565b909250829061192d565b91906001600160401b03811161093d5761197b81611976600d54610d64565b6118e7565b5f601f82116001146119ad5781906119a893945f926108ad5750508160011b915f199060031b1c19161790565b600d55565b600d5f52601f198216937fd7b6990105719101dabeb77144f2a3385c8033acd3af97e9423a695e81ad1eb591805b868110611a1257508360019596106119f9575b505050811b01600d55565b01355f19600384901b60f8161c191690555f80806119ee565b909260206001819286860135815501940191016119db565b15611a3157565b60405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c6964207265636569766572000000000000006044820152606490fd5b634e487b7160e01b5f52603260045260245ffd5b9190811015611a9a5760051b0190565b611a76565b3561031081610442565b6001600160a01b03168015611ad0575f5260056020526001600160401b0360405f20541690565b6040516323d3ad8160e21b8152600490fd5b90611af5602092828151948592016102b9565b0190565b808060011115611b16575b604051636f96cda160e11b8152600490fd5b5f9081548110611b27575b50611b04565b81526004906020918083526040928383205494600160e01b861615611b4e57505050611b21565b93929190935b8515611b6257505050505090565b5f1901808352818552838320549550611b54565b80600111159081611ba3575b81611b8b575090565b90505f526004602052600160e01b60405f2054161590565b5f5481109150611b82565b90611bb883611af9565b6001600160a01b0383811692828216849003611d41575f86815260066020526040902080549092611bf86001600160a01b03881633908114908414171590565b611d06575b8216958615611cf457611c5f93611c2d92611ceb575b506001600160a01b03165f90815260056020526040902090565b80545f190190556001600160a01b03165f818152600560205260409020805460010190554260a01b17600160e11b1790565b611c71855f52600460205260405f2090565b55600160e11b811615611ca6575b507fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef5f80a4565b60018401611cbc815f52600460205260405f2090565b5415611cc9575b50611c7f565b5f548114611cc357611ce3905f52600460205260405f2090565b555f80611cc3565b5f90555f611c13565b604051633a954ecd60e21b8152600490fd5b611d2a6106866107b9336107a48b60018060a01b03165f52600760205260405f2090565b15611bfd57604051632ce44b5f60e11b8152600490fd5b60405162a1148160e81b8152600490fd5b929190611d60828286611bae565b803b611d6d575b50505050565b611d7693611e0b565b15611d84575f808080611d67565b6040516368d2bf6b60e11b8152600490fd5b9081602091031261021b575161031081610209565b6001600160a01b039182168152911660208201526040810191909152608060608201819052610310929101906102da565b3d15611e06573d90611ded826110a3565b91611dfb6040519384610de6565b82523d5f602084013e565b606090565b92602091611e33935f604051809681958294630a85bd0160e11b9a8b85523360048601611dab565b03926001600160a01b03165af15f9181611e82575b50611e7457611e55611ddc565b80519081611e6f576040516368d2bf6b60e11b8152600490fd5b602001fd5b6001600160e01b0319161490565b611ea491925060203d8111611eab575b611e9c8183610de6565b810190611d96565b905f611e48565b503d611e92565b5f80546001600160a01b03831682526005602052604082208054680100000000000000010190556001600160a01b0383164260a01b17600160e11b17611f00825f52600460205260405f2090565b556001818101936001600160a01b0316917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908385838180a4845b858103611f5e5750505015611f4d5755565b604051622e076360e81b8152600490fd5b8083918587858180a401611f3b565b60405190608082018281106001600160401b0382111761093d576040525f6060838281528260208201528260408201520152565b611fa9611f6d565b50611fb2611f6d565b600182108015611ff4575b611fef5750611fcb81611fff565b6040810151611fef5750611fea61031091611fe4611f6d565b50611af9565b612018565b905090565b505f54821015611fbd565b612007611f6d565b505f52600460205261031060405f20545b90612021611f6d565b6001600160a01b038316815260a083901c6001600160401b03166020820152600160e01b83161515604082015260e89290921c6060830152565b6001600160401b03811161093d5760051b60200190565b8051821015611a9a5760209160051b010190565b906120908261205b565b61209d6040519182610de6565b82815280926120ae601f199161205b565b0190602036910137565b90828110156121f7575f918254916001928382106121ef575b8086116121e7575b506120e382611aa9565b91858210156121df578186038381106121d7575b505b61210283612086565b9583156121ce57849361211484611fa1565b91879460409361212961068686830151151590565b6121bc575b50955b612142575b50505050505050815290565b80861415806121b2575b156121ad57868661215d8298611fff565b808601516121a757516001600160a01b039081168061219f575b508087169088161461218b575b0195612131565b80612199838c019b8d612072565b52612184565b97505f612177565b50612184565b612136565b508188141561214c565b516001600160a01b031695505f61212e565b50505050505090565b92505f6120f7565b8492506120f9565b94505f6120d9565b8391506120d1565b604051631960ccad60e11b8152600490fdfea2646970667358221220fecf4f3d303968cedea1bcd56acc3aea9a21ee2936ecdc1f61b8de59d2a9b3aa64736f6c63430008150033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000734dabe2171dfa9689e94675cc279aa0d3ce703300000000000000000000000000000000000000000000000000000000000003e800000000000000000000000000000000000000000000000000000000000000284d6f6e636c6572207820616469646173204f726967696e616c733a20546865204578706c6f726572000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000541444d4e430000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000043697066733a2f2f62616679626569637733346e35717a7077643736647a7365626d336e787767783472366c68336d6e6268736b736170797036756a69616f676271612f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000042697066733a2f2f6261666b72656968616f6a346b6a7a34616263766d366673666b66327332686a77616e6761613779703566637279746f3477677733677269766c6d000000000000000000000000000000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : __name (string): Moncler x adidas Originals: The Explorer
Arg [1] : __symbol (string): ADMNC
Arg [2] : _baseUri (string): ipfs://bafybeicw34n5qzpwd76dzsebm3nxwgx4r6lh3mnbhsksapyp6ujiaogbqa/
Arg [3] : _uri (string): ipfs://bafkreihaoj4kjz4abcvm6fsfkf2s2hjwangaa7yp5fcryto4wgw3grivlm
Arg [4] : _royaltyReceiver (address): 0x734dABe2171Dfa9689E94675Cc279aA0d3Ce7033
Arg [5] : _royaltyValue (uint96): 1000
-----Encoded View---------------
19 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000000c0
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000160
Arg [3] : 00000000000000000000000000000000000000000000000000000000000001e0
Arg [4] : 000000000000000000000000734dabe2171dfa9689e94675cc279aa0d3ce7033
Arg [5] : 00000000000000000000000000000000000000000000000000000000000003e8
Arg [6] : 0000000000000000000000000000000000000000000000000000000000000028
Arg [7] : 4d6f6e636c6572207820616469646173204f726967696e616c733a2054686520
Arg [8] : 4578706c6f726572000000000000000000000000000000000000000000000000
Arg [9] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [10] : 41444d4e43000000000000000000000000000000000000000000000000000000
Arg [11] : 0000000000000000000000000000000000000000000000000000000000000043
Arg [12] : 697066733a2f2f62616679626569637733346e35717a7077643736647a736562
Arg [13] : 6d336e787767783472366c68336d6e6268736b736170797036756a69616f6762
Arg [14] : 71612f0000000000000000000000000000000000000000000000000000000000
Arg [15] : 0000000000000000000000000000000000000000000000000000000000000042
Arg [16] : 697066733a2f2f6261666b72656968616f6a346b6a7a34616263766d36667366
Arg [17] : 6b66327332686a77616e6761613779703566637279746f347767773367726976
Arg [18] : 6c6d000000000000000000000000000000000000000000000000000000000000
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.