Feature Tip: Add private address tag to any address under My Name Tag !
ERC-721
Overview
Max Total Supply
2,106 KJC
Holders
692
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
1 KJCLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
KemigawaJinjaCollection
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 800 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.4; import { Base64 } from 'base64-sol/base64.sol'; import "erc721a/contracts/ERC721A.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import './BokkyPooBahsDateTimeLibrary.sol'; contract KemigawaJinjaCollection is ERC721A, Ownable, Pausable { struct Claim { uint64 amuletType; uint64 count; } struct TokenMetaInfo { uint64 amuletType; uint256 mintTimestamp; } address public constant withdrawAddress = 0x2eC92DB165fa3Df089EC1Ae997bFE692ea095EcC; uint256 public mintCost = 0.005 ether; string public imageURI = 'https://kemigawa.nft-kojiki-project.com/images/'; string public animationURI = 'https://kemigawa.nft-kojiki-project.com/animations/'; string public imageExtension = '.png'; string public animationExtension = '.mp4'; uint256 public blessingTimeSec = 60 * 60 * 24 * 365; uint256 public baseTimestampSecDiff = 60 * 60 * 9; uint256 public amuletTypeNum = 10; mapping(uint64 => string) public amuletNames; mapping(uint64 => string) public amuletDescriptions; mapping(uint64 => string) public amuletNamesExpired; mapping(uint64 => string) public amuletDescriptionsExpired; mapping(uint256 => TokenMetaInfo) private _tokenMetaInfos; modifier enoughEth(uint256 quantity) { require(msg.value >= mintCost * quantity, "not enough eth"); _; } modifier correctAmuletTypes(Claim[] memory claims) { for (uint64 index = 0 ; index < claims.length; index++) { require(1 <= claims[index].amuletType && claims[index].amuletType <= amuletTypeNum, "incorrect amulet type"); } _; } modifier existsToken(uint256 tokenId) { require(exists(tokenId), "token is not exist"); _; } constructor() ERC721A("KemigawaJinjaCollection", "KJC") { Claim[] memory claims = new Claim[](amuletTypeNum); for (uint64 amuletType = 1; amuletType <= amuletTypeNum; amuletType++) { if (amuletType == 6) { claims[amuletType - 1] = Claim(amuletType, 280); } else { claims[amuletType - 1] = Claim(amuletType, 30); } } mintCommon(withdrawAddress, claims); _pause(); } function mint(Claim[] memory claims) external payable whenNotPaused enoughEth(getTotalClaimCount(claims)) { mintCommon(msg.sender, claims); } function mintCommon(address mintAddress, Claim[] memory claims) private correctAmuletTypes(claims) { uint64 totalClaimCount = getTotalClaimCount(claims); _safeMint(mintAddress, totalClaimCount); uint64 sum = 0; for (uint64 i = 0; i < claims.length; i++) { for (uint64 j = 0; j < claims[i].count; j++){ sum++; uint256 tokenId = totalSupply() - totalClaimCount + sum; _tokenMetaInfos[tokenId] = TokenMetaInfo(claims[i].amuletType, block.timestamp); } } } function getTotalClaimCount(Claim[] memory claims) private pure returns (uint64) { uint64 totalClaimCount = 0; for (uint64 index = 0; index < claims.length; index++){ totalClaimCount += claims[index].count; } return totalClaimCount; } function encodePackedJson(uint256 tokenId) private view existsToken(tokenId) returns (bytes memory) { uint64 amuletType = _tokenMetaInfos[tokenId].amuletType; uint256 mintTimestamp = _tokenMetaInfos[tokenId].mintTimestamp; if (block.timestamp > mintTimestamp + blessingTimeSec) { string memory name = amuletNamesExpired[amuletType]; string memory description = amuletDescriptionsExpired[amuletType]; return abi.encodePacked('{"name":"', name, '", "description":"', description, '", "image": "', imageURI, Strings.toString(amuletType), '_expired', imageExtension, '"}'); } else { uint256 baseTimestamp = mintTimestamp + baseTimestampSecDiff; string memory name = string(abi.encodePacked(amuletNames[amuletType], ' Minted at ', Strings.toString(BokkyPooBahsDateTimeLibrary.getYear(baseTimestamp)), '/', Strings.toString(BokkyPooBahsDateTimeLibrary.getMonth(baseTimestamp)), '/', Strings.toString(BokkyPooBahsDateTimeLibrary.getDay(baseTimestamp)))); string memory description = amuletDescriptions[amuletType]; return abi.encodePacked('{"name":"', name, '", "description":"', description, '", "image": "', imageURI, Strings.toString(amuletType), imageExtension, '", "animation_url": "', animationURI, Strings.toString(amuletType), animationExtension, '"}'); } } function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { return string(abi.encodePacked('data:application/json;base64,', Base64.encode(bytes(encodePackedJson(tokenId))))); } function getJsonText(uint256 tokenId) public view returns (string memory) { return string(encodePackedJson(tokenId)); } function getMintTimestamp(uint256 tokenId) public view virtual existsToken(tokenId) returns (uint256) { return _tokenMetaInfos[tokenId].mintTimestamp; } function getExpireTimestamp(uint256 tokenId) public view virtual existsToken(tokenId) returns (uint256) { return _tokenMetaInfos[tokenId].mintTimestamp + blessingTimeSec; } function pause() public onlyOwner { _pause(); } function unpause() public onlyOwner { _unpause(); } function setImageURI(string memory _value) public onlyOwner { imageURI = _value; } function setAnimationURI(string memory _value) public onlyOwner { animationURI = _value; } function setImageExtension(string memory _value) public onlyOwner { imageExtension = _value; } function setAnimationExtension(string memory _value) public onlyOwner { animationExtension = _value; } function setBlessingTimeSec(uint256 _value) public onlyOwner { blessingTimeSec = _value; } function setBaseTimestampSecDiff(uint256 _value) public onlyOwner { baseTimestampSecDiff = _value; } function setAmuletTypeNum(uint256 _value) public onlyOwner { amuletTypeNum = _value; } function setAmuletName(uint64 _type, string memory _value) public onlyOwner { amuletNames[_type] = _value; } function setAmuletDescription(uint64 _type, string memory _value) public onlyOwner { amuletDescriptions[_type] = _value; } function setAmuletNameExpired(uint64 _type, string memory _value) public onlyOwner { amuletNamesExpired[_type] = _value; } function setAmuletDescriptionExpired(uint64 _type, string memory _value) public onlyOwner { amuletDescriptionsExpired[_type] = _value; } function exists(uint256 tokenId) public view virtual returns (bool) { return _exists(tokenId); } function withdraw() public payable onlyOwner { (bool os, ) = payable(withdrawAddress).call{value: address(this).balance}(""); require(os); } function _startTokenId() internal view virtual override returns (uint256) { return 1; } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0; /// @title Base64 /// @author Brecht Devos - <[email protected]> /// @notice Provides functions for encoding/decoding base64 library Base64 { string internal constant TABLE_ENCODE = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'; bytes internal constant TABLE_DECODE = hex"0000000000000000000000000000000000000000000000000000000000000000" hex"00000000000000000000003e0000003f3435363738393a3b3c3d000000000000" hex"00000102030405060708090a0b0c0d0e0f101112131415161718190000000000" hex"001a1b1c1d1e1f202122232425262728292a2b2c2d2e2f303132330000000000"; function encode(bytes memory data) internal pure returns (string memory) { if (data.length == 0) return ''; // load the table into memory string memory table = TABLE_ENCODE; // multiply by 4/3 rounded up uint256 encodedLen = 4 * ((data.length + 2) / 3); // add some extra buffer at the end required for the writing string memory result = new string(encodedLen + 32); assembly { // set the actual output length mstore(result, encodedLen) // prepare the lookup table let tablePtr := add(table, 1) // input ptr let dataPtr := data let endPtr := add(dataPtr, mload(data)) // result ptr, jump over length let resultPtr := add(result, 32) // run over the input, 3 bytes at a time for {} lt(dataPtr, endPtr) {} { // read 3 bytes dataPtr := add(dataPtr, 3) let input := mload(dataPtr) // write 4 characters mstore8(resultPtr, mload(add(tablePtr, and(shr(18, input), 0x3F)))) resultPtr := add(resultPtr, 1) mstore8(resultPtr, mload(add(tablePtr, and(shr(12, input), 0x3F)))) resultPtr := add(resultPtr, 1) mstore8(resultPtr, mload(add(tablePtr, and(shr( 6, input), 0x3F)))) resultPtr := add(resultPtr, 1) mstore8(resultPtr, mload(add(tablePtr, and( input, 0x3F)))) resultPtr := add(resultPtr, 1) } // padding with '=' switch mod(mload(data), 3) case 1 { mstore(sub(resultPtr, 2), shl(240, 0x3d3d)) } case 2 { mstore(sub(resultPtr, 1), shl(248, 0x3d)) } } return result; } function decode(string memory _data) internal pure returns (bytes memory) { bytes memory data = bytes(_data); if (data.length == 0) return new bytes(0); require(data.length % 4 == 0, "invalid base64 decoder input"); // load the table into memory bytes memory table = TABLE_DECODE; // every 4 characters represent 3 bytes uint256 decodedLen = (data.length / 4) * 3; // add some extra buffer at the end required for the writing bytes memory result = new bytes(decodedLen + 32); assembly { // padding with '=' let lastBytes := mload(add(data, mload(data))) if eq(and(lastBytes, 0xFF), 0x3d) { decodedLen := sub(decodedLen, 1) if eq(and(lastBytes, 0xFFFF), 0x3d3d) { decodedLen := sub(decodedLen, 1) } } // set the actual output length mstore(result, decodedLen) // prepare the lookup table let tablePtr := add(table, 1) // input ptr let dataPtr := data let endPtr := add(dataPtr, mload(data)) // result ptr, jump over length let resultPtr := add(result, 32) // run over the input, 4 characters at a time for {} lt(dataPtr, endPtr) {} { // read 4 characters dataPtr := add(dataPtr, 4) let input := mload(dataPtr) // write 3 bytes let output := add( add( shl(18, and(mload(add(tablePtr, and(shr(24, input), 0xFF))), 0xFF)), shl(12, and(mload(add(tablePtr, and(shr(16, input), 0xFF))), 0xFF))), add( shl( 6, and(mload(add(tablePtr, and(shr( 8, input), 0xFF))), 0xFF)), and(mload(add(tablePtr, and( input , 0xFF))), 0xFF) ) ) mstore(resultPtr, shl(232, output)) resultPtr := add(resultPtr, 3) } } return result; } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.1.0 // Creator: Chiru Labs pragma solidity ^0.8.4; import './IERC721A.sol'; /** * @dev ERC721 token receiver interface. */ interface ERC721A__IERC721Receiver { function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); } /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, * including the Metadata extension. Built to optimize for lower gas during batch mints. * * Assumes serials are sequentially minted starting at `_startTokenId()` * (defaults to 0, e.g. 0, 1, 2, 3..). * * Assumes that an owner cannot have more than 2**64 - 1 (max value of uint64) of supply. * * Assumes that the maximum token id cannot exceed 2**256 - 1 (max value of uint256). */ contract ERC721A is IERC721A { // 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 tokenId of the next token 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 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; _currentIndex = _startTokenId(); } /** * @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 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 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 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 returns (uint256) { return _burnCounter; } /** * @dev See {IERC165-supportsInterface}. */ 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: 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. } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view 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 { 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; } /** * 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 ownership that has an address and is not burned // before an ownership that does not have an address and is not burned. // Hence, curr will not underflow. // // We can directly compare the packed value. // If the address is zero, packed is zero. while (packed == 0) { packed = _packedOwnerships[--curr]; } return packed; } } } revert OwnerQueryForNonexistentToken(); } /** * 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); } /** * Returns the unpacked `TokenOwnership` struct at `index`. */ function _ownershipAt(uint256 index) internal view returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnerships[index]); } /** * @dev Initializes the ownership slot minted at `index` for efficiency purposes. */ function _initializeOwnershipAt(uint256 index) internal { if (_packedOwnerships[index] == 0) { _packedOwnerships[index] = _packedOwnershipOf(index); } } /** * Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around in the collection over time. */ function _ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) { return _unpackedOwnership(_packedOwnershipOf(tokenId)); } /** * @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 See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view override returns (address) { return address(uint160(_packedOwnershipOf(tokenId))); } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { if (!_exists(tokenId)) revert URIQueryForNonexistentToken(); string memory baseURI = _baseURI(); return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, _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 ''; } /** * @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)) } } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public override { address owner = ownerOf(tokenId); if (_msgSenderERC721A() != owner) if (!isApprovedForAll(owner, _msgSenderERC721A())) { revert ApprovalCallerNotOwnerNorApproved(); } _tokenApprovals[tokenId] = to; emit Approval(owner, to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { if (operator == _msgSenderERC721A()) revert ApproveToCaller(); _operatorApprovals[_msgSenderERC721A()][operator] = approved; emit ApprovalForAll(_msgSenderERC721A(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ''); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { transferFrom(from, to, tokenId); if (to.code.length != 0) if (!_checkContractOnERC721Received(from, to, tokenId, _data)) { revert TransferToNonERC721ReceiverImplementer(); } } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), */ function _exists(uint256 tokenId) internal view returns (bool) { return _startTokenId() <= tokenId && tokenId < _currentIndex && // If within bounds, _packedOwnerships[tokenId] & BITMASK_BURNED == 0; // and not burned. } /** * @dev Equivalent to `_safeMint(to, quantity, '')`. */ function _safeMint(address to, uint256 quantity) internal { _safeMint(to, quantity, ''); } /** * @dev Safely mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - If `to` refers to a smart contract, it must implement * {IERC721Receiver-onERC721Received}, which is called for each safe transfer. * - `quantity` must be greater than 0. * * See {_mint}. * * Emits a {Transfer} event for each mint. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal { _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 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 { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // `balance` 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 tokenId = startTokenId; uint256 end = startTokenId + quantity; do { emit Transfer(address(0), to, tokenId++); } while (tokenId < end); _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 { 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 Returns the storage slot and value for the approved address of `tokenId`. */ function _getApprovedAddress(uint256 tokenId) private view returns (uint256 approvedAddressSlot, address approvedAddress) { mapping(uint256 => address) storage tokenApprovalsPtr = _tokenApprovals; // The following is equivalent to `approvedAddress = _tokenApprovals[tokenId]`. assembly { // Compute the slot. mstore(0x00, tokenId) mstore(0x20, tokenApprovalsPtr.slot) approvedAddressSlot := keccak256(0x00, 0x40) // Load the slot's value from storage. approvedAddress := sload(approvedAddressSlot) } } /** * @dev Returns whether the `approvedAddress` is equals to `from` or `msgSender`. */ function _isOwnerOrApproved( address approvedAddress, address from, address msgSender ) private pure returns (bool result) { assembly { // Mask `from` to the lower 160 bits, in case the upper bits somehow aren't clean. from := and(from, BITMASK_ADDRESS) // Mask `msgSender` to the lower 160 bits, in case the upper bits somehow aren't clean. msgSender := and(msgSender, BITMASK_ADDRESS) // `msgSender == from || msgSender == approvedAddress`. result := or(eq(msgSender, from), eq(msgSender, approvedAddress)) } } /** * @dev Transfers `tokenId` from `from` to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { uint256 prevOwnershipPacked = _packedOwnershipOf(tokenId); if (address(uint160(prevOwnershipPacked)) != from) revert TransferFromIncorrectOwner(); (uint256 approvedAddressSlot, address approvedAddress) = _getApprovedAddress(tokenId); // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isOwnerOrApproved(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 `_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) = _getApprovedAddress(tokenId); if (approvalCheck) { // The nested ifs save around 20+ gas over a compound boolean condition. if (!_isOwnerOrApproved(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++; } } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkContractOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { try 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)) } } } } /** * @dev Directly sets the extra data for the ownership data `index`. */ function _setExtraDataAt(uint256 index, uint24 extraData) internal { 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 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; } /** * @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 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 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 returns (string memory ptr) { assembly { // The maximum value of a uint256 contains 78 digits (1 byte per digit), // but we allocate 128 bytes to keep the free memory pointer 32-byte word aliged. // We will need 1 32-byte word to store the length, // and 3 32-byte words to store a maximum of 78 digits. Total: 32 + 3 * 32 = 128. ptr := add(mload(0x40), 128) // Update the free memory pointer to allocate. mstore(0x40, ptr) // Cache the end of the memory to calculate the length later. let end := ptr // We write the string from the rightmost digit to the leftmost digit. // The following is essentially a do-while loop that also handles the zero case. // Costs a bit more than early returning for the zero case, // but cheaper in terms of deployment and overall runtime costs. for { // Initialize and perform the first pass without check. let temp := value // Move the pointer 1 byte leftwards to point to an empty character slot. ptr := sub(ptr, 1) // Write the character to the pointer. 48 is the ASCII index of '0'. mstore8(ptr, add(48, mod(temp, 10))) temp := div(temp, 10) } temp { // Keep dividing `temp` until zero. temp := div(temp, 10) } { // Body of the for loop. ptr := sub(ptr, 1) mstore8(ptr, add(48, mod(temp, 10))) } let length := sub(end, ptr) // Move the pointer 32 bytes leftwards to make room for the length. ptr := sub(ptr, 32) // Store the length. mstore(ptr, length) } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.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 anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (security/Pausable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { _requireNotPaused(); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { _requirePaused(); _; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Throws if the contract is paused. */ function _requireNotPaused() internal view virtual { require(!paused(), "Pausable: paused"); } /** * @dev Throws if the contract is not paused. */ function _requirePaused() internal view virtual { require(paused(), "Pausable: not paused"); } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.7.0) (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } /** * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. */ function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } }
// SPDX-License-Identifier: MIT pragma solidity >=0.6.0 <0.9.0; // ---------------------------------------------------------------------------- // BokkyPooBah's DateTime Library v1.01 // // A gas-efficient Solidity date and time library // // https://github.com/bokkypoobah/BokkyPooBahsDateTimeLibrary // // Tested date range 1970/01/01 to 2345/12/31 // // Conventions: // Unit | Range | Notes // :-------- |:-------------:|:----- // timestamp | >= 0 | Unix timestamp, number of seconds since 1970/01/01 00:00:00 UTC // year | 1970 ... 2345 | // month | 1 ... 12 | // day | 1 ... 31 | // hour | 0 ... 23 | // minute | 0 ... 59 | // second | 0 ... 59 | // dayOfWeek | 1 ... 7 | 1 = Monday, ..., 7 = Sunday // // // Enjoy. (c) BokkyPooBah / Bok Consulting Pty Ltd 2018-2019. The MIT Licence. // ---------------------------------------------------------------------------- library BokkyPooBahsDateTimeLibrary { uint constant SECONDS_PER_DAY = 24 * 60 * 60; uint constant SECONDS_PER_HOUR = 60 * 60; uint constant SECONDS_PER_MINUTE = 60; int constant OFFSET19700101 = 2440588; uint constant DOW_MON = 1; uint constant DOW_TUE = 2; uint constant DOW_WED = 3; uint constant DOW_THU = 4; uint constant DOW_FRI = 5; uint constant DOW_SAT = 6; uint constant DOW_SUN = 7; // ------------------------------------------------------------------------ // Calculate the number of days from 1970/01/01 to year/month/day using // the date conversion algorithm from // https://aa.usno.navy.mil/faq/JD_formula.html // and subtracting the offset 2440588 so that 1970/01/01 is day 0 // // days = day // - 32075 // + 1461 * (year + 4800 + (month - 14) / 12) / 4 // + 367 * (month - 2 - (month - 14) / 12 * 12) / 12 // - 3 * ((year + 4900 + (month - 14) / 12) / 100) / 4 // - offset // ------------------------------------------------------------------------ function _daysFromDate(uint year, uint month, uint day) internal pure returns (uint _days) { require(year >= 1970); int _year = int(year); int _month = int(month); int _day = int(day); int __days = _day - 32075 + 1461 * (_year + 4800 + (_month - 14) / 12) / 4 + 367 * (_month - 2 - (_month - 14) / 12 * 12) / 12 - 3 * ((_year + 4900 + (_month - 14) / 12) / 100) / 4 - OFFSET19700101; _days = uint(__days); } // ------------------------------------------------------------------------ // Calculate year/month/day from the number of days since 1970/01/01 using // the date conversion algorithm from // http://aa.usno.navy.mil/faq/docs/JD_Formula.php // and adding the offset 2440588 so that 1970/01/01 is day 0 // // int L = days + 68569 + offset // int N = 4 * L / 146097 // L = L - (146097 * N + 3) / 4 // year = 4000 * (L + 1) / 1461001 // L = L - 1461 * year / 4 + 31 // month = 80 * L / 2447 // dd = L - 2447 * month / 80 // L = month / 11 // month = month + 2 - 12 * L // year = 100 * (N - 49) + year + L // ------------------------------------------------------------------------ function _daysToDate(uint _days) internal pure returns (uint year, uint month, uint day) { int __days = int(_days); int L = __days + 68569 + OFFSET19700101; int N = 4 * L / 146097; L = L - (146097 * N + 3) / 4; int _year = 4000 * (L + 1) / 1461001; L = L - 1461 * _year / 4 + 31; int _month = 80 * L / 2447; int _day = L - 2447 * _month / 80; L = _month / 11; _month = _month + 2 - 12 * L; _year = 100 * (N - 49) + _year + L; year = uint(_year); month = uint(_month); day = uint(_day); } function timestampFromDate(uint year, uint month, uint day) internal pure returns (uint timestamp) { timestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY; } function timestampFromDateTime(uint year, uint month, uint day, uint hour, uint minute, uint second) internal pure returns (uint timestamp) { timestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + hour * SECONDS_PER_HOUR + minute * SECONDS_PER_MINUTE + second; } function timestampToDate(uint timestamp) internal pure returns (uint year, uint month, uint day) { (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function timestampToDateTime(uint timestamp) internal pure returns (uint year, uint month, uint day, uint hour, uint minute, uint second) { (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); uint secs = timestamp % SECONDS_PER_DAY; hour = secs / SECONDS_PER_HOUR; secs = secs % SECONDS_PER_HOUR; minute = secs / SECONDS_PER_MINUTE; second = secs % SECONDS_PER_MINUTE; } function isValidDate(uint year, uint month, uint day) internal pure returns (bool valid) { if (year >= 1970 && month > 0 && month <= 12) { uint daysInMonth = _getDaysInMonth(year, month); if (day > 0 && day <= daysInMonth) { valid = true; } } } function isValidDateTime(uint year, uint month, uint day, uint hour, uint minute, uint second) internal pure returns (bool valid) { if (isValidDate(year, month, day)) { if (hour < 24 && minute < 60 && second < 60) { valid = true; } } } function isLeapYear(uint timestamp) internal pure returns (bool leapYear) { (uint year,,) = _daysToDate(timestamp / SECONDS_PER_DAY); leapYear = _isLeapYear(year); } function _isLeapYear(uint year) internal pure returns (bool leapYear) { leapYear = ((year % 4 == 0) && (year % 100 != 0)) || (year % 400 == 0); } function isWeekDay(uint timestamp) internal pure returns (bool weekDay) { weekDay = getDayOfWeek(timestamp) <= DOW_FRI; } function isWeekEnd(uint timestamp) internal pure returns (bool weekEnd) { weekEnd = getDayOfWeek(timestamp) >= DOW_SAT; } function getDaysInMonth(uint timestamp) internal pure returns (uint daysInMonth) { (uint year, uint month,) = _daysToDate(timestamp / SECONDS_PER_DAY); daysInMonth = _getDaysInMonth(year, month); } function _getDaysInMonth(uint year, uint month) internal pure returns (uint daysInMonth) { if (month == 1 || month == 3 || month == 5 || month == 7 || month == 8 || month == 10 || month == 12) { daysInMonth = 31; } else if (month != 2) { daysInMonth = 30; } else { daysInMonth = _isLeapYear(year) ? 29 : 28; } } // 1 = Monday, 7 = Sunday function getDayOfWeek(uint timestamp) internal pure returns (uint dayOfWeek) { uint _days = timestamp / SECONDS_PER_DAY; dayOfWeek = (_days + 3) % 7 + 1; } function getYear(uint timestamp) internal pure returns (uint year) { (year,,) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getMonth(uint timestamp) internal pure returns (uint month) { (,month,) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getDay(uint timestamp) internal pure returns (uint day) { (,,day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getHour(uint timestamp) internal pure returns (uint hour) { uint secs = timestamp % SECONDS_PER_DAY; hour = secs / SECONDS_PER_HOUR; } function getMinute(uint timestamp) internal pure returns (uint minute) { uint secs = timestamp % SECONDS_PER_HOUR; minute = secs / SECONDS_PER_MINUTE; } function getSecond(uint timestamp) internal pure returns (uint second) { second = timestamp % SECONDS_PER_MINUTE; } function addYears(uint timestamp, uint _years) internal pure returns (uint newTimestamp) { (uint year, uint month, uint day) = _daysToDate(timestamp / SECONDS_PER_DAY); year += _years; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addMonths(uint timestamp, uint _months) internal pure returns (uint newTimestamp) { (uint year, uint month, uint day) = _daysToDate(timestamp / SECONDS_PER_DAY); month += _months; year += (month - 1) / 12; month = (month - 1) % 12 + 1; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addDays(uint timestamp, uint _days) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _days * SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addHours(uint timestamp, uint _hours) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _hours * SECONDS_PER_HOUR; require(newTimestamp >= timestamp); } function addMinutes(uint timestamp, uint _minutes) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _minutes * SECONDS_PER_MINUTE; require(newTimestamp >= timestamp); } function addSeconds(uint timestamp, uint _seconds) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _seconds; require(newTimestamp >= timestamp); } function subYears(uint timestamp, uint _years) internal pure returns (uint newTimestamp) { (uint year, uint month, uint day) = _daysToDate(timestamp / SECONDS_PER_DAY); year -= _years; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subMonths(uint timestamp, uint _months) internal pure returns (uint newTimestamp) { (uint year, uint month, uint day) = _daysToDate(timestamp / SECONDS_PER_DAY); uint yearMonth = year * 12 + (month - 1) - _months; year = yearMonth / 12; month = yearMonth % 12 + 1; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subDays(uint timestamp, uint _days) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _days * SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subHours(uint timestamp, uint _hours) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _hours * SECONDS_PER_HOUR; require(newTimestamp <= timestamp); } function subMinutes(uint timestamp, uint _minutes) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _minutes * SECONDS_PER_MINUTE; require(newTimestamp <= timestamp); } function subSeconds(uint timestamp, uint _seconds) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _seconds; require(newTimestamp <= timestamp); } function diffYears(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _years) { require(fromTimestamp <= toTimestamp); (uint fromYear,,) = _daysToDate(fromTimestamp / SECONDS_PER_DAY); (uint toYear,,) = _daysToDate(toTimestamp / SECONDS_PER_DAY); _years = toYear - fromYear; } function diffMonths(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _months) { require(fromTimestamp <= toTimestamp); (uint fromYear, uint fromMonth,) = _daysToDate(fromTimestamp / SECONDS_PER_DAY); (uint toYear, uint toMonth,) = _daysToDate(toTimestamp / SECONDS_PER_DAY); _months = toYear * 12 + toMonth - fromYear * 12 - fromMonth; } function diffDays(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _days) { require(fromTimestamp <= toTimestamp); _days = (toTimestamp - fromTimestamp) / SECONDS_PER_DAY; } function diffHours(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _hours) { require(fromTimestamp <= toTimestamp); _hours = (toTimestamp - fromTimestamp) / SECONDS_PER_HOUR; } function diffMinutes(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _minutes) { require(fromTimestamp <= toTimestamp); _minutes = (toTimestamp - fromTimestamp) / SECONDS_PER_MINUTE; } function diffSeconds(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _seconds) { require(fromTimestamp <= toTimestamp); _seconds = toTimestamp - fromTimestamp; } }
// SPDX-License-Identifier: MIT // ERC721A Contracts v4.1.0 // Creator: Chiru Labs pragma solidity ^0.8.4; /** * @dev Interface of an ERC721A compliant contract. */ interface IERC721A { /** * The caller must own the token or be an approved operator. */ error ApprovalCallerNotOwnerNorApproved(); /** * The token does not exist. */ error ApprovalQueryForNonexistentToken(); /** * The caller cannot approve to their own address. */ error ApproveToCaller(); /** * 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(); struct TokenOwnership { // The address of the owner. address addr; // Keeps track of the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; // Arbitrary data similar to `startTimestamp` that can be set through `_extraData`. uint24 extraData; } /** * @dev Returns the total amount of tokens stored by the contract. * * Burned tokens are calculated here, use `_totalMinted()` if you want to count just minted tokens. */ function totalSupply() external view returns (uint256); // ============================== // 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); // ============================== // 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`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); // ============================== // 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 standard. See `_mintERC2309` for more details. */ event ConsecutiveTransfer(uint256 indexed fromTokenId, uint256 toTokenId, address indexed from, address indexed to); }
// 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; } }
{ "optimizer": { "enabled": true, "runs": 800 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","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"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"amuletDescriptions","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"amuletDescriptionsExpired","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"amuletNames","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint64","name":"","type":"uint64"}],"name":"amuletNamesExpired","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"amuletTypeNum","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"animationExtension","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"animationURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseTimestampSecDiff","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"blessingTimeSec","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":"uint256","name":"tokenId","type":"uint256"}],"name":"getExpireTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getJsonText","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getMintTimestamp","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"imageExtension","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"imageURI","outputs":[{"internalType":"string","name":"","type":"string"}],"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":[{"components":[{"internalType":"uint64","name":"amuletType","type":"uint64"},{"internalType":"uint64","name":"count","type":"uint64"}],"internalType":"struct KemigawaJinjaCollection.Claim[]","name":"claims","type":"tuple[]"}],"name":"mint","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"mintCost","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","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":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_type","type":"uint64"},{"internalType":"string","name":"_value","type":"string"}],"name":"setAmuletDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_type","type":"uint64"},{"internalType":"string","name":"_value","type":"string"}],"name":"setAmuletDescriptionExpired","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_type","type":"uint64"},{"internalType":"string","name":"_value","type":"string"}],"name":"setAmuletName","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint64","name":"_type","type":"uint64"},{"internalType":"string","name":"_value","type":"string"}],"name":"setAmuletNameExpired","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"setAmuletTypeNum","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_value","type":"string"}],"name":"setAnimationExtension","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_value","type":"string"}],"name":"setAnimationURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"setBaseTimestampSecDiff","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"setBlessingTimeSec","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_value","type":"string"}],"name":"setImageExtension","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_value","type":"string"}],"name":"setImageURI","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":[],"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":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"withdrawAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
6611c37937e0800060095560e0604052602f60808181529062003b1660a03980516200003491600a9160209091019062000978565b5060405180606001604052806033815260200162003b456033913980516200006591600b9160209091019062000978565b50604080518082019091526004808252632e706e6760e01b60209092019182526200009391600c9162000978565b50604080518082019091526004808252630b9b5c0d60e21b6020909201918252620000c191600d9162000978565b506301e13380600e55617e90600f55600a601055348015620000e257600080fd5b50604080518082018252601781527f4b656d69676177614a696e6a61436f6c6c656374696f6e0000000000000000006020808301918252835180850190945260038452624b4a4360e81b908401528151919291620001439160029162000978565b5080516200015990600390602084019062000978565b50506001600055506200016c33620002ff565b6008805460ff60a01b191690556010546000906001600160401b0381111562000199576200019962000a1e565b604051908082528060200260200182016040528015620001e057816020015b6040805180820190915260008082526020820152815260200190600190039081620001b85790505b50905060015b601054816001600160401b031611620002cd57806001600160401b0316600614156200026557604080518082019091526001600160401b03821681526101186020820152826200023860018462000a4a565b6001600160401b03168151811062000254576200025462000a75565b6020026020010181905250620002b8565b604080518082019091526001600160401b0382168152601e6020820152826200029060018462000a4a565b6001600160401b031681518110620002ac57620002ac62000a75565b60200260200101819052505b80620002c48162000a8b565b915050620001e6565b50620002ee732ec92db165fa3df089ec1ae997bfe692ea095ecc8262000351565b620002f8620005c4565b5062000c03565b600880546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8060005b8151816001600160401b03161015620004475781816001600160401b03168151811062000386576200038662000a75565b6020026020010151600001516001600160401b0316600111158015620003e0575060105482826001600160401b031681518110620003c857620003c862000a75565b6020026020010151600001516001600160401b031611155b620004325760405162461bcd60e51b815260206004820152601560248201527f696e636f727265637420616d756c65742074797065000000000000000000000060448201526064015b60405180910390fd5b806200043e8162000a8b565b91505062000355565b506000620004558362000627565b90506200046c846001600160401b03831662000694565b6000805b8451816001600160401b03161015620005bc5760005b85826001600160401b031681518110620004a457620004a462000a75565b6020026020010151602001516001600160401b0316816001600160401b03161015620005a65782620004d68162000a8b565b9350506000836001600160401b0316856001600160401b0316620004ff620006ba60201b60201c565b6200050b919062000ab5565b62000517919062000acf565b9050604051806040016040528088856001600160401b03168151811062000542576200054262000a75565b602090810291909101810151516001600160401b03908116835242928201929092526000938452601581526040909320825181546001600160401b0319169216919091178155910151600190910155806200059d8162000a8b565b91505062000486565b5080620005b38162000a8b565b91505062000470565b505050505050565b620005ce620006c8565b6008805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586200060a3390565b6040516001600160a01b03909116815260200160405180910390a1565b600080805b8351816001600160401b031610156200068d5783816001600160401b0316815181106200065d576200065d62000a75565b6020026020010151602001518262000676919062000aea565b915080620006848162000a8b565b9150506200062c565b5092915050565b620006b68282604051806020016040528060008152506200072060201b60201c565b5050565b600154600054036000190190565b620006dc600854600160a01b900460ff1690565b156200071e5760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b604482015260640162000429565b565b6200072c838362000797565b6001600160a01b0383163b1562000792576000548281035b60018101906200075a9060009087908662000877565b62000778576040516368d2bf6b60e11b815260040160405180910390fd5b818110620007445781600054146200078f57600080fd5b50505b505050565b6000546001600160a01b038316620007c157604051622e076360e81b815260040160405180910390fd5b81620007e05760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038316600081815260056020526040902080546801000000000000000185020190554260a01b6001841460e11b1717600082815260046020526040902055808281015b6040516001830192906001600160a01b038716906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082106200082a5760005550505050565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a0290620008ae90339089908890889060040162000b18565b602060405180830381600087803b158015620008c957600080fd5b505af1925050508015620008fc575060408051601f3d908101601f19168201909252620008f99181019062000b93565b60015b6200095b573d8080156200092d576040519150601f19603f3d011682016040523d82523d6000602084013e62000932565b606091505b50805162000953576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050949350505050565b828054620009869062000bc6565b90600052602060002090601f016020900481019282620009aa5760008555620009f5565b82601f10620009c557805160ff1916838001178555620009f5565b82800160010185558215620009f5579182015b82811115620009f5578251825591602001919060010190620009d8565b5062000a0392915062000a07565b5090565b5b8082111562000a03576000815560010162000a08565b634e487b7160e01b600052604160045260246000fd5b634e487b7160e01b600052601160045260246000fd5b60006001600160401b038381169083168181101562000a6d5762000a6d62000a34565b039392505050565b634e487b7160e01b600052603260045260246000fd5b60006001600160401b038281168082141562000aab5762000aab62000a34565b6001019392505050565b60008282101562000aca5762000aca62000a34565b500390565b6000821982111562000ae55762000ae562000a34565b500190565b60006001600160401b0382811684821680830382111562000b0f5762000b0f62000a34565b01949350505050565b600060018060a01b038087168352602081871681850152856040850152608060608501528451915081608085015260005b8281101562000b675785810182015185820160a00152810162000b49565b8281111562000b7a57600060a084870101525b5050601f01601f19169190910160a00195945050505050565b60006020828403121562000ba657600080fd5b81516001600160e01b03198116811462000bbf57600080fd5b9392505050565b600181811c9082168062000bdb57607f821691505b6020821081141562000bfd57634e487b7160e01b600052602260045260246000fd5b50919050565b612f038062000c136000396000f3fe6080604052600436106103295760003560e01c806373a421c1116101a5578063b51bbbdf116100ec578063c87b56dd11610095578063e985e9c51161006f578063e985e9c514610886578063f2fde38b146108cf578063ff34e05d146108ef578063ffd49ac21461090f57600080fd5b8063c87b56dd14610826578063d83b5fde14610846578063dced59e11461086657600080fd5b8063be24aebd116100c6578063be24aebd146107dd578063c5ac58e1146107f0578063c6ec944e1461081057600080fd5b8063b51bbbdf14610792578063b88d4fde146107a7578063bdb4b848146107c757600080fd5b80639422ba3b1161014e5780639b0f78f0116101285780639b0f78f01461073d578063a22cb4651461075d578063a9ef3aeb1461077d57600080fd5b80639422ba3b146106f257806395d89b411461070857806396492fad1461071d57600080fd5b8063851aaf861161017f578063851aaf86146106945780638b9ae041146106b45780638da5cb5b146106d457600080fd5b806373a421c11461063f5780638114632b1461065f5780638456cb591461067f57600080fd5b80633bb3af77116102745780636203982c1161021d5780636c360923116101f75780636c360923146105ca57806370a08231146105ea578063715018a61461060a57806372866c291461061f57600080fd5b80636203982c146105755780636352211e1461059557806364548d2e146105b557600080fd5b806342842e0e1161024e57806342842e0e146105165780634f558e79146105365780635c975abb1461055657600080fd5b80633bb3af77146104d95780633ccfd60b146104f95780633f4ba83a1461050157600080fd5b8063135d088d116102d657806323b872dd116102b057806323b872dd146104835780633693774d146104a357806339e3aa7e146104b957600080fd5b8063135d088d1461041f5780631581b6001461043457806318160ddd1461045c57600080fd5b8063081812fc11610307578063081812fc146103a7578063095ea7b3146103df5780630e2df75c146103ff57600080fd5b806301ffc9a71461032e57806304787ca21461036357806306fdde0314610385575b600080fd5b34801561033a57600080fd5b5061034e61034936600461239b565b61092f565b60405190151581526020015b60405180910390f35b34801561036f57600080fd5b5061038361037e3660046124a0565b610981565b005b34801561039157600080fd5b5061039a6109a0565b60405161035a919061252d565b3480156103b357600080fd5b506103c76103c2366004612540565b610a32565b6040516001600160a01b03909116815260200161035a565b3480156103eb57600080fd5b506103836103fa366004612575565b610a76565b34801561040b57600080fd5b5061038361041a3660046125b7565b610b23565b34801561042b57600080fd5b5061039a610b5a565b34801561044057600080fd5b506103c7732ec92db165fa3df089ec1ae997bfe692ea095ecc81565b34801561046857600080fd5b5060015460005403600019015b60405190815260200161035a565b34801561048f57600080fd5b5061038361049e366004612605565b610be8565b3480156104af57600080fd5b5061047560105481565b3480156104c557600080fd5b506103836104d43660046124a0565b610d7a565b3480156104e557600080fd5b5061039a6104f4366004612641565b610d95565b610383610dae565b34801561050d57600080fd5b50610383610e22565b34801561052257600080fd5b50610383610531366004612605565b610e34565b34801561054257600080fd5b5061034e610551366004612540565b610e4f565b34801561056257600080fd5b50600854600160a01b900460ff1661034e565b34801561058157600080fd5b5061039a610590366004612540565b610e5a565b3480156105a157600080fd5b506103c76105b0366004612540565b610e65565b3480156105c157600080fd5b5061039a610e70565b3480156105d657600080fd5b506104756105e5366004612540565b610e7d565b3480156105f657600080fd5b5061047561060536600461265c565b610eea565b34801561061657600080fd5b50610383610f39565b34801561062b57600080fd5b5061038361063a3660046124a0565b610f4b565b34801561064b57600080fd5b5061047561065a366004612540565b610f66565b34801561066b57600080fd5b5061039a61067a366004612641565b610fd9565b34801561068b57600080fd5b50610383610ff2565b3480156106a057600080fd5b506103836106af3660046125b7565b611002565b3480156106c057600080fd5b506103836106cf3660046125b7565b611034565b3480156106e057600080fd5b506008546001600160a01b03166103c7565b3480156106fe57600080fd5b50610475600f5481565b34801561071457600080fd5b5061039a611066565b34801561072957600080fd5b50610383610738366004612540565b611075565b34801561074957600080fd5b506103836107583660046125b7565b611082565b34801561076957600080fd5b50610383610778366004612677565b6110b4565b34801561078957600080fd5b5061039a61114a565b34801561079e57600080fd5b5061039a611157565b3480156107b357600080fd5b506103836107c23660046126b3565b611164565b3480156107d357600080fd5b5061047560095481565b6103836107eb36600461272f565b6111ae565b3480156107fc57600080fd5b5061038361080b3660046124a0565b611230565b34801561081c57600080fd5b50610475600e5481565b34801561083257600080fd5b5061039a610841366004612540565b61124b565b34801561085257600080fd5b50610383610861366004612540565b611284565b34801561087257600080fd5b5061039a610881366004612641565b611291565b34801561089257600080fd5b5061034e6108a136600461280b565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b3480156108db57600080fd5b506103836108ea36600461265c565b6112aa565b3480156108fb57600080fd5b5061038361090a366004612540565b611337565b34801561091b57600080fd5b5061039a61092a366004612641565b611344565b60006301ffc9a760e01b6001600160e01b03198316148061096057506380ac58cd60e01b6001600160e01b03198316145b8061097b5750635b5e139f60e01b6001600160e01b03198316145b92915050565b61098961135d565b805161099c90600a9060208401906122ec565b5050565b6060600280546109af9061283e565b80601f01602080910402602001604051908101604052809291908181526020018280546109db9061283e565b8015610a285780601f106109fd57610100808354040283529160200191610a28565b820191906000526020600020905b815481529060010190602001808311610a0b57829003601f168201915b5050505050905090565b6000610a3d826113b7565b610a5a576040516333d1c03960e21b815260040160405180910390fd5b506000908152600660205260409020546001600160a01b031690565b6000610a8182610e65565b9050336001600160a01b03821614610aba57610a9d81336108a1565b610aba576040516367d9dca160e11b815260040160405180910390fd5b600082815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b610b2b61135d565b67ffffffffffffffff821660009081526011602090815260409091208251610b55928401906122ec565b505050565b600a8054610b679061283e565b80601f0160208091040260200160405190810160405280929190818152602001828054610b939061283e565b8015610be05780601f10610bb557610100808354040283529160200191610be0565b820191906000526020600020905b815481529060010190602001808311610bc357829003601f168201915b505050505081565b6000610bf3826113ec565b9050836001600160a01b0316816001600160a01b031614610c265760405162a1148160e81b815260040160405180910390fd5b60008281526006602052604090208054338082146001600160a01b03881690911417610c7357610c5686336108a1565b610c7357604051632ce44b5f60e11b815260040160405180910390fd5b6001600160a01b038516610c9a57604051633a954ecd60e21b815260040160405180910390fd5b8015610ca557600082555b6001600160a01b038681166000908152600560205260408082208054600019019055918716808252919020805460010190554260a01b17600160e11b17600085815260046020526040902055600160e11b8316610d305760018401600081815260046020526040902054610d2e576000548114610d2e5760008181526004602052604090208490555b505b83856001600160a01b0316876001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b505050505050565b610d8261135d565b805161099c90600c9060208401906122ec565b60126020526000908152604090208054610b679061283e565b610db661135d565b604051600090732ec92db165fa3df089ec1ae997bfe692ea095ecc9047908381818185875af1925050503d8060008114610e0c576040519150601f19603f3d011682016040523d82523d6000602084013e610e11565b606091505b5050905080610e1f57600080fd5b50565b610e2a61135d565b610e32611455565b565b610b5583838360405180602001604052806000815250611164565b600061097b826113b7565b606061097b826114aa565b600061097b826113ec565b600d8054610b679061283e565b600081610e8981610e4f565b610ecf5760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b60448201526064015b60405180910390fd5b60008381526015602052604090206001015491505b50919050565b60006001600160a01b038216610f13576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b031660009081526005602052604090205467ffffffffffffffff1690565b610f4161135d565b610e326000611845565b610f5361135d565b805161099c90600d9060208401906122ec565b600081610f7281610e4f565b610fb35760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b6044820152606401610ec6565b600e54600084815260156020526040902060010154610fd29190612889565b9392505050565b60116020526000908152604090208054610b679061283e565b610ffa61135d565b610e326118a4565b61100a61135d565b67ffffffffffffffff821660009081526012602090815260409091208251610b55928401906122ec565b61103c61135d565b67ffffffffffffffff821660009081526013602090815260409091208251610b55928401906122ec565b6060600380546109af9061283e565b61107d61135d565b601055565b61108a61135d565b67ffffffffffffffff821660009081526014602090815260409091208251610b55928401906122ec565b6001600160a01b0382163314156110de5760405163b06307db60e01b815260040160405180910390fd5b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b600c8054610b679061283e565b600b8054610b679061283e565b61116f848484610be8565b6001600160a01b0383163b156111a85761118b848484846118e7565b6111a8576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6111b66119df565b6111bf81611a39565b67ffffffffffffffff16806009546111d791906128a1565b3410156112265760405162461bcd60e51b815260206004820152600e60248201527f6e6f7420656e6f756768206574680000000000000000000000000000000000006044820152606401610ec6565b61099c3383611a9f565b61123861135d565b805161099c90600b9060208401906122ec565b606061125e611259836114aa565b611cf3565b60405160200161126e91906128c0565b6040516020818303038152906040529050919050565b61128c61135d565b600e55565b60136020526000908152604090208054610b679061283e565b6112b261135d565b6001600160a01b03811661132e5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610ec6565b610e1f81611845565b61133f61135d565b600f55565b60146020526000908152604090208054610b679061283e565b6008546001600160a01b03163314610e325760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ec6565b6000816001111580156113cb575060005482105b801561097b575050600090815260046020526040902054600160e01b161590565b6000818060011161143c5760005481101561143c57600081815260046020526040902054600160e01b811661143a575b80610fd257506000190160008181526004602052604090205461141c565b505b604051636f96cda160e11b815260040160405180910390fd5b61145d611e59565b6008805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6060816114b681610e4f565b6114f75760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b6044820152606401610ec6565b60008381526015602052604090208054600190910154600e5467ffffffffffffffff909216916115279082612889565b4211156116c25767ffffffffffffffff8216600090815260136020526040812080546115529061283e565b80601f016020809104026020016040519081016040528092919081815260200182805461157e9061283e565b80156115cb5780601f106115a0576101008083540402835291602001916115cb565b820191906000526020600020905b8154815290600101906020018083116115ae57829003601f168201915b50505067ffffffffffffffff86166000908152601460205260408120805494955090939092506115fb915061283e565b80601f01602080910402602001604051908101604052809291908181526020018280546116279061283e565b80156116745780601f1061164957610100808354040283529160200191611674565b820191906000526020600020905b81548152906001019060200180831161165757829003601f168201915b505050505090508181600a6116928767ffffffffffffffff16611eb2565b600c6040516020016116a895949392919061299f565b604051602081830303815290604052955050505050610ee4565b6000600f54826116d29190612889565b67ffffffffffffffff84166000908152601160205260408120919250906117006116fb84611fc8565b611eb2565b61170c6116fb85611fe8565b6117186116fb86612002565b60405160200161172b9493929190612a84565b60408051601f1981840301815291815267ffffffffffffffff861660009081526012602052908120805492935090916117639061283e565b80601f016020809104026020016040519081016040528092919081815260200182805461178f9061283e565b80156117dc5780601f106117b1576101008083540402835291602001916117dc565b820191906000526020600020905b8154815290600101906020018083116117bf57829003601f168201915b505050505090508181600a6117fa8867ffffffffffffffff16611eb2565b600c600b6118118b67ffffffffffffffff16611eb2565b600d60405160200161182a989796959493929190612b13565b60405160208183030381529060405296505050505050610ee4565b600880546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6118ac6119df565b6008805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861148d3390565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a029061191c903390899088908890600401612c26565b602060405180830381600087803b15801561193657600080fd5b505af1925050508015611966575060408051601f3d908101601f1916820190925261196391810190612c62565b60015b6119c1573d808015611994576040519150601f19603f3d011682016040523d82523d6000602084013e611999565b606091505b5080516119b9576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490505b949350505050565b600854600160a01b900460ff1615610e325760405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610ec6565b600080805b83518167ffffffffffffffff161015611a9857838167ffffffffffffffff1681518110611a6d57611a6d612c7f565b60200260200101516020015182611a849190612c95565b915080611a9081612cc1565b915050611a3e565b5092915050565b8060005b81518167ffffffffffffffff161015611b8957818167ffffffffffffffff1681518110611ad257611ad2612c7f565b60200260200101516000015167ffffffffffffffff16600111158015611b2b5750601054828267ffffffffffffffff1681518110611b1257611b12612c7f565b60200260200101516000015167ffffffffffffffff1611155b611b775760405162461bcd60e51b815260206004820152601560248201527f696e636f727265637420616d756c6574207479706500000000000000000000006044820152606401610ec6565b80611b8181612cc1565b915050611aa3565b506000611b9583611a39565b9050611bab848267ffffffffffffffff16612014565b6000805b84518167ffffffffffffffff161015610d725760005b858267ffffffffffffffff1681518110611be157611be1612c7f565b60200260200101516020015167ffffffffffffffff168167ffffffffffffffff161015611ce05782611c1281612cc1565b93505060008367ffffffffffffffff168567ffffffffffffffff16611c406001546000546000199190030190565b611c4a9190612ce9565b611c549190612889565b90506040518060400160405280888567ffffffffffffffff1681518110611c7d57611c7d612c7f565b6020908102919091018101515167ffffffffffffffff9081168352429282019290925260009384526015815260409093208251815467ffffffffffffffff1916921691909117815591015160019091015580611cd881612cc1565b915050611bc5565b5080611ceb81612cc1565b915050611baf565b6060815160001415611d1357505060408051602081019091526000815290565b6000604051806060016040528060408152602001612e8e6040913990506000600384516002611d429190612889565b611d4c9190612d16565b611d579060046128a1565b90506000611d66826020612889565b67ffffffffffffffff811115611d7e57611d7e6123b8565b6040519080825280601f01601f191660200182016040528015611da8576020820181803683370190505b509050818152600183018586518101602084015b81831015611e14576003830192508251603f8160121c168501518253600182019150603f81600c1c168501518253600182019150603f8160061c168501518253600182019150603f8116850151825350600101611dbc565b600389510660018114611e2e5760028114611e3f57611e4b565b613d3d60f01b600119830152611e4b565b603d60f81b6000198301525b509398975050505050505050565b600854600160a01b900460ff16610e325760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610ec6565b606081611ed65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611f005780611eea81612d2a565b9150611ef99050600a83612d16565b9150611eda565b60008167ffffffffffffffff811115611f1b57611f1b6123b8565b6040519080825280601f01601f191660200182016040528015611f45576020820181803683370190505b5090505b84156119d757611f5a600183612ce9565b9150611f67600a86612d45565b611f72906030612889565b60f81b818381518110611f8757611f87612c7f565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611fc1600a86612d16565b9450611f49565b6000611fdf611fda6201518084612d16565b61202e565b50909392505050565b6000611ffa611fda6201518084612d16565b509392505050565b60006119d7611fda6201518084612d16565b61099c8282604051806020016040528060008152506121a2565b60008080838162253d8c6120458362010bd9612d59565b61204f9190612d59565b9050600062023ab1612062836004612d99565b61206c9190612e20565b9050600461207d8262023ab1612d99565b612088906003612d59565b6120929190612e20565b61209c9083612e4e565b9150600062164b096120af846001612d59565b6120bb90610fa0612d99565b6120c59190612e20565b905060046120d5826105b5612d99565b6120df9190612e20565b6120e99084612e4e565b6120f490601f612d59565b9250600061098f612106856050612d99565b6121109190612e20565b9050600060506121228361098f612d99565b61212c9190612e20565b6121369086612e4e565b9050612143600b83612e20565b945061215085600c612d99565b61215b836002612d59565b6121659190612e4e565b91508483612174603187612e4e565b61217f906064612d99565b6121899190612d59565b6121939190612d59565b9a919950975095505050505050565b6121ac838361220f565b6001600160a01b0383163b15610b55576000548281035b6121d660008683806001019450866118e7565b6121f3576040516368d2bf6b60e11b815260040160405180910390fd5b8181106121c357816000541461220857600080fd5b5050505050565b6000546001600160a01b03831661223857604051622e076360e81b815260040160405180910390fd5b816122565760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038316600081815260056020526040902080546801000000000000000185020190554260a01b6001841460e11b1717600082815260046020526040902055808281015b6040516001830192906001600160a01b038716906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082106122a05760005550505050565b8280546122f89061283e565b90600052602060002090601f01602090048101928261231a5760008555612360565b82601f1061233357805160ff1916838001178555612360565b82800160010185558215612360579182015b82811115612360578251825591602001919060010190612345565b5061236c929150612370565b5090565b5b8082111561236c5760008155600101612371565b6001600160e01b031981168114610e1f57600080fd5b6000602082840312156123ad57600080fd5b8135610fd281612385565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff811182821017156123f1576123f16123b8565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715612420576124206123b8565b604052919050565b600067ffffffffffffffff831115612442576124426123b8565b612455601f8401601f19166020016123f7565b905082815283838301111561246957600080fd5b828260208301376000602084830101529392505050565b600082601f83011261249157600080fd5b610fd283833560208501612428565b6000602082840312156124b257600080fd5b813567ffffffffffffffff8111156124c957600080fd5b6119d784828501612480565b60005b838110156124f05781810151838201526020016124d8565b838111156111a85750506000910152565b600081518084526125198160208601602086016124d5565b601f01601f19169290920160200192915050565b602081526000610fd26020830184612501565b60006020828403121561255257600080fd5b5035919050565b80356001600160a01b038116811461257057600080fd5b919050565b6000806040838503121561258857600080fd5b61259183612559565b946020939093013593505050565b803567ffffffffffffffff8116811461257057600080fd5b600080604083850312156125ca57600080fd5b6125d38361259f565b9150602083013567ffffffffffffffff8111156125ef57600080fd5b6125fb85828601612480565b9150509250929050565b60008060006060848603121561261a57600080fd5b61262384612559565b925061263160208501612559565b9150604084013590509250925092565b60006020828403121561265357600080fd5b610fd28261259f565b60006020828403121561266e57600080fd5b610fd282612559565b6000806040838503121561268a57600080fd5b61269383612559565b9150602083013580151581146126a857600080fd5b809150509250929050565b600080600080608085870312156126c957600080fd5b6126d285612559565b93506126e060208601612559565b925060408501359150606085013567ffffffffffffffff81111561270357600080fd5b8501601f8101871361271457600080fd5b61272387823560208401612428565b91505092959194509250565b6000602080838503121561274257600080fd5b823567ffffffffffffffff8082111561275a57600080fd5b818501915085601f83011261276e57600080fd5b813581811115612780576127806123b8565b61278e848260051b016123f7565b818152848101925060069190911b8301840190878211156127ae57600080fd5b928401925b8184101561280057604084890312156127cc5760008081fd5b6127d46123ce565b6127dd8561259f565b81526127ea86860161259f565b81870152835260409390930192918401916127b3565b979650505050505050565b6000806040838503121561281e57600080fd5b61282783612559565b915061283560208401612559565b90509250929050565b600181811c9082168061285257607f821691505b60208210811415610ee457634e487b7160e01b600052602260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000821982111561289c5761289c612873565b500190565b60008160001904831182151516156128bb576128bb612873565b500290565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008152600082516128f881601d8501602087016124d5565b91909101601d0192915050565b8054600090600181811c908083168061291f57607f831692505b602080841082141561294157634e487b7160e01b600052602260045260246000fd5b818015612955576001811461296657612993565b60ff19861689528489019650612993565b60008881526020902060005b8681101561298b5781548b820152908501908301612972565b505084890196505b50505050505092915050565b683d913730b6b2911d1160b91b8152600086516129c3816009850160208b016124d5565b7f222c20226465736372697074696f6e223a2200000000000000000000000000006009918401918201528651612a0081601b840160208b016124d5565b6c1116101134b6b0b3b2911d101160991b601b9290910191820152612a286028820187612905565b90508451612a3a8183602089016124d5565b7f5f657870697265640000000000000000000000000000000000000000000000009101908152612a6d6008820185612905565b61227d60f01b815260020198975050505050505050565b6000612a908287612905565b7f204d696e7465642061742000000000000000000000000000000000000000000081528551612ac681600b840160208a016124d5565b808201915050602f60f81b80600b8301528551612aea81600c850160208a016124d5565b600c9201918201528351612b0581600d8401602088016124d5565b01600d019695505050505050565b683d913730b6b2911d1160b91b815260008951612b37816009850160208e016124d5565b7f222c20226465736372697074696f6e223a2200000000000000000000000000006009918401918201528951612b7481601b840160208e016124d5565b6c1116101134b6b0b3b2911d101160991b601b9290910191820152612b9c602882018a612905565b90508751612bae818360208c016124d5565b612bba81830189612905565b9150507f222c2022616e696d6174696f6e5f75726c223a202200000000000000000000008152612bed6015820187612905565b90508451612bff8183602089016124d5565b612c0b81830186612905565b61227d60f01b81526002019c9b505050505050505050505050565b60006001600160a01b03808716835280861660208401525083604083015260806060830152612c586080830184612501565b9695505050505050565b600060208284031215612c7457600080fd5b8151610fd281612385565b634e487b7160e01b600052603260045260246000fd5b600067ffffffffffffffff808316818516808303821115612cb857612cb8612873565b01949350505050565b600067ffffffffffffffff80831681811415612cdf57612cdf612873565b6001019392505050565b600082821015612cfb57612cfb612873565b500390565b634e487b7160e01b600052601260045260246000fd5b600082612d2557612d25612d00565b500490565b6000600019821415612d3e57612d3e612873565b5060010190565b600082612d5457612d54612d00565b500690565b6000808212826001600160ff1b0303841381151615612d7a57612d7a612873565b600160ff1b8390038412811615612d9357612d93612873565b50500190565b60006001600160ff1b03600084136000841385830485118282161615612dc157612dc1612873565b600160ff1b6000871282811687830589121615612de057612de0612873565b60008712925087820587128484161615612dfc57612dfc612873565b87850587128184161615612e1257612e12612873565b505050929093029392505050565b600082612e2f57612e2f612d00565b600160ff1b821460001984141615612e4957612e49612873565b500590565b60008083128015600160ff1b850184121615612e6c57612e6c612873565b836001600160ff1b03018313811615612e8757612e87612873565b5050039056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220c1554453f50bc8c09c5c6292593724fbbc19d87bd22006c50b0b5545578181f664736f6c6343000809003368747470733a2f2f6b656d69676177612e6e66742d6b6f6a696b692d70726f6a6563742e636f6d2f696d616765732f68747470733a2f2f6b656d69676177612e6e66742d6b6f6a696b692d70726f6a6563742e636f6d2f616e696d6174696f6e732f
Deployed Bytecode
0x6080604052600436106103295760003560e01c806373a421c1116101a5578063b51bbbdf116100ec578063c87b56dd11610095578063e985e9c51161006f578063e985e9c514610886578063f2fde38b146108cf578063ff34e05d146108ef578063ffd49ac21461090f57600080fd5b8063c87b56dd14610826578063d83b5fde14610846578063dced59e11461086657600080fd5b8063be24aebd116100c6578063be24aebd146107dd578063c5ac58e1146107f0578063c6ec944e1461081057600080fd5b8063b51bbbdf14610792578063b88d4fde146107a7578063bdb4b848146107c757600080fd5b80639422ba3b1161014e5780639b0f78f0116101285780639b0f78f01461073d578063a22cb4651461075d578063a9ef3aeb1461077d57600080fd5b80639422ba3b146106f257806395d89b411461070857806396492fad1461071d57600080fd5b8063851aaf861161017f578063851aaf86146106945780638b9ae041146106b45780638da5cb5b146106d457600080fd5b806373a421c11461063f5780638114632b1461065f5780638456cb591461067f57600080fd5b80633bb3af77116102745780636203982c1161021d5780636c360923116101f75780636c360923146105ca57806370a08231146105ea578063715018a61461060a57806372866c291461061f57600080fd5b80636203982c146105755780636352211e1461059557806364548d2e146105b557600080fd5b806342842e0e1161024e57806342842e0e146105165780634f558e79146105365780635c975abb1461055657600080fd5b80633bb3af77146104d95780633ccfd60b146104f95780633f4ba83a1461050157600080fd5b8063135d088d116102d657806323b872dd116102b057806323b872dd146104835780633693774d146104a357806339e3aa7e146104b957600080fd5b8063135d088d1461041f5780631581b6001461043457806318160ddd1461045c57600080fd5b8063081812fc11610307578063081812fc146103a7578063095ea7b3146103df5780630e2df75c146103ff57600080fd5b806301ffc9a71461032e57806304787ca21461036357806306fdde0314610385575b600080fd5b34801561033a57600080fd5b5061034e61034936600461239b565b61092f565b60405190151581526020015b60405180910390f35b34801561036f57600080fd5b5061038361037e3660046124a0565b610981565b005b34801561039157600080fd5b5061039a6109a0565b60405161035a919061252d565b3480156103b357600080fd5b506103c76103c2366004612540565b610a32565b6040516001600160a01b03909116815260200161035a565b3480156103eb57600080fd5b506103836103fa366004612575565b610a76565b34801561040b57600080fd5b5061038361041a3660046125b7565b610b23565b34801561042b57600080fd5b5061039a610b5a565b34801561044057600080fd5b506103c7732ec92db165fa3df089ec1ae997bfe692ea095ecc81565b34801561046857600080fd5b5060015460005403600019015b60405190815260200161035a565b34801561048f57600080fd5b5061038361049e366004612605565b610be8565b3480156104af57600080fd5b5061047560105481565b3480156104c557600080fd5b506103836104d43660046124a0565b610d7a565b3480156104e557600080fd5b5061039a6104f4366004612641565b610d95565b610383610dae565b34801561050d57600080fd5b50610383610e22565b34801561052257600080fd5b50610383610531366004612605565b610e34565b34801561054257600080fd5b5061034e610551366004612540565b610e4f565b34801561056257600080fd5b50600854600160a01b900460ff1661034e565b34801561058157600080fd5b5061039a610590366004612540565b610e5a565b3480156105a157600080fd5b506103c76105b0366004612540565b610e65565b3480156105c157600080fd5b5061039a610e70565b3480156105d657600080fd5b506104756105e5366004612540565b610e7d565b3480156105f657600080fd5b5061047561060536600461265c565b610eea565b34801561061657600080fd5b50610383610f39565b34801561062b57600080fd5b5061038361063a3660046124a0565b610f4b565b34801561064b57600080fd5b5061047561065a366004612540565b610f66565b34801561066b57600080fd5b5061039a61067a366004612641565b610fd9565b34801561068b57600080fd5b50610383610ff2565b3480156106a057600080fd5b506103836106af3660046125b7565b611002565b3480156106c057600080fd5b506103836106cf3660046125b7565b611034565b3480156106e057600080fd5b506008546001600160a01b03166103c7565b3480156106fe57600080fd5b50610475600f5481565b34801561071457600080fd5b5061039a611066565b34801561072957600080fd5b50610383610738366004612540565b611075565b34801561074957600080fd5b506103836107583660046125b7565b611082565b34801561076957600080fd5b50610383610778366004612677565b6110b4565b34801561078957600080fd5b5061039a61114a565b34801561079e57600080fd5b5061039a611157565b3480156107b357600080fd5b506103836107c23660046126b3565b611164565b3480156107d357600080fd5b5061047560095481565b6103836107eb36600461272f565b6111ae565b3480156107fc57600080fd5b5061038361080b3660046124a0565b611230565b34801561081c57600080fd5b50610475600e5481565b34801561083257600080fd5b5061039a610841366004612540565b61124b565b34801561085257600080fd5b50610383610861366004612540565b611284565b34801561087257600080fd5b5061039a610881366004612641565b611291565b34801561089257600080fd5b5061034e6108a136600461280b565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b3480156108db57600080fd5b506103836108ea36600461265c565b6112aa565b3480156108fb57600080fd5b5061038361090a366004612540565b611337565b34801561091b57600080fd5b5061039a61092a366004612641565b611344565b60006301ffc9a760e01b6001600160e01b03198316148061096057506380ac58cd60e01b6001600160e01b03198316145b8061097b5750635b5e139f60e01b6001600160e01b03198316145b92915050565b61098961135d565b805161099c90600a9060208401906122ec565b5050565b6060600280546109af9061283e565b80601f01602080910402602001604051908101604052809291908181526020018280546109db9061283e565b8015610a285780601f106109fd57610100808354040283529160200191610a28565b820191906000526020600020905b815481529060010190602001808311610a0b57829003601f168201915b5050505050905090565b6000610a3d826113b7565b610a5a576040516333d1c03960e21b815260040160405180910390fd5b506000908152600660205260409020546001600160a01b031690565b6000610a8182610e65565b9050336001600160a01b03821614610aba57610a9d81336108a1565b610aba576040516367d9dca160e11b815260040160405180910390fd5b600082815260066020526040808220805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b610b2b61135d565b67ffffffffffffffff821660009081526011602090815260409091208251610b55928401906122ec565b505050565b600a8054610b679061283e565b80601f0160208091040260200160405190810160405280929190818152602001828054610b939061283e565b8015610be05780601f10610bb557610100808354040283529160200191610be0565b820191906000526020600020905b815481529060010190602001808311610bc357829003601f168201915b505050505081565b6000610bf3826113ec565b9050836001600160a01b0316816001600160a01b031614610c265760405162a1148160e81b815260040160405180910390fd5b60008281526006602052604090208054338082146001600160a01b03881690911417610c7357610c5686336108a1565b610c7357604051632ce44b5f60e11b815260040160405180910390fd5b6001600160a01b038516610c9a57604051633a954ecd60e21b815260040160405180910390fd5b8015610ca557600082555b6001600160a01b038681166000908152600560205260408082208054600019019055918716808252919020805460010190554260a01b17600160e11b17600085815260046020526040902055600160e11b8316610d305760018401600081815260046020526040902054610d2e576000548114610d2e5760008181526004602052604090208490555b505b83856001600160a01b0316876001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45b505050505050565b610d8261135d565b805161099c90600c9060208401906122ec565b60126020526000908152604090208054610b679061283e565b610db661135d565b604051600090732ec92db165fa3df089ec1ae997bfe692ea095ecc9047908381818185875af1925050503d8060008114610e0c576040519150601f19603f3d011682016040523d82523d6000602084013e610e11565b606091505b5050905080610e1f57600080fd5b50565b610e2a61135d565b610e32611455565b565b610b5583838360405180602001604052806000815250611164565b600061097b826113b7565b606061097b826114aa565b600061097b826113ec565b600d8054610b679061283e565b600081610e8981610e4f565b610ecf5760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b60448201526064015b60405180910390fd5b60008381526015602052604090206001015491505b50919050565b60006001600160a01b038216610f13576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b031660009081526005602052604090205467ffffffffffffffff1690565b610f4161135d565b610e326000611845565b610f5361135d565b805161099c90600d9060208401906122ec565b600081610f7281610e4f565b610fb35760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b6044820152606401610ec6565b600e54600084815260156020526040902060010154610fd29190612889565b9392505050565b60116020526000908152604090208054610b679061283e565b610ffa61135d565b610e326118a4565b61100a61135d565b67ffffffffffffffff821660009081526012602090815260409091208251610b55928401906122ec565b61103c61135d565b67ffffffffffffffff821660009081526013602090815260409091208251610b55928401906122ec565b6060600380546109af9061283e565b61107d61135d565b601055565b61108a61135d565b67ffffffffffffffff821660009081526014602090815260409091208251610b55928401906122ec565b6001600160a01b0382163314156110de5760405163b06307db60e01b815260040160405180910390fd5b3360008181526007602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b600c8054610b679061283e565b600b8054610b679061283e565b61116f848484610be8565b6001600160a01b0383163b156111a85761118b848484846118e7565b6111a8576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6111b66119df565b6111bf81611a39565b67ffffffffffffffff16806009546111d791906128a1565b3410156112265760405162461bcd60e51b815260206004820152600e60248201527f6e6f7420656e6f756768206574680000000000000000000000000000000000006044820152606401610ec6565b61099c3383611a9f565b61123861135d565b805161099c90600b9060208401906122ec565b606061125e611259836114aa565b611cf3565b60405160200161126e91906128c0565b6040516020818303038152906040529050919050565b61128c61135d565b600e55565b60136020526000908152604090208054610b679061283e565b6112b261135d565b6001600160a01b03811661132e5760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610ec6565b610e1f81611845565b61133f61135d565b600f55565b60146020526000908152604090208054610b679061283e565b6008546001600160a01b03163314610e325760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610ec6565b6000816001111580156113cb575060005482105b801561097b575050600090815260046020526040902054600160e01b161590565b6000818060011161143c5760005481101561143c57600081815260046020526040902054600160e01b811661143a575b80610fd257506000190160008181526004602052604090205461141c565b505b604051636f96cda160e11b815260040160405180910390fd5b61145d611e59565b6008805460ff60a01b191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b6060816114b681610e4f565b6114f75760405162461bcd60e51b81526020600482015260126024820152711d1bdad95b881a5cc81b9bdd08195e1a5cdd60721b6044820152606401610ec6565b60008381526015602052604090208054600190910154600e5467ffffffffffffffff909216916115279082612889565b4211156116c25767ffffffffffffffff8216600090815260136020526040812080546115529061283e565b80601f016020809104026020016040519081016040528092919081815260200182805461157e9061283e565b80156115cb5780601f106115a0576101008083540402835291602001916115cb565b820191906000526020600020905b8154815290600101906020018083116115ae57829003601f168201915b50505067ffffffffffffffff86166000908152601460205260408120805494955090939092506115fb915061283e565b80601f01602080910402602001604051908101604052809291908181526020018280546116279061283e565b80156116745780601f1061164957610100808354040283529160200191611674565b820191906000526020600020905b81548152906001019060200180831161165757829003601f168201915b505050505090508181600a6116928767ffffffffffffffff16611eb2565b600c6040516020016116a895949392919061299f565b604051602081830303815290604052955050505050610ee4565b6000600f54826116d29190612889565b67ffffffffffffffff84166000908152601160205260408120919250906117006116fb84611fc8565b611eb2565b61170c6116fb85611fe8565b6117186116fb86612002565b60405160200161172b9493929190612a84565b60408051601f1981840301815291815267ffffffffffffffff861660009081526012602052908120805492935090916117639061283e565b80601f016020809104026020016040519081016040528092919081815260200182805461178f9061283e565b80156117dc5780601f106117b1576101008083540402835291602001916117dc565b820191906000526020600020905b8154815290600101906020018083116117bf57829003601f168201915b505050505090508181600a6117fa8867ffffffffffffffff16611eb2565b600c600b6118118b67ffffffffffffffff16611eb2565b600d60405160200161182a989796959493929190612b13565b60405160208183030381529060405296505050505050610ee4565b600880546001600160a01b0383811673ffffffffffffffffffffffffffffffffffffffff19831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6118ac6119df565b6008805460ff60a01b1916600160a01b1790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861148d3390565b604051630a85bd0160e11b81526000906001600160a01b0385169063150b7a029061191c903390899088908890600401612c26565b602060405180830381600087803b15801561193657600080fd5b505af1925050508015611966575060408051601f3d908101601f1916820190925261196391810190612c62565b60015b6119c1573d808015611994576040519150601f19603f3d011682016040523d82523d6000602084013e611999565b606091505b5080516119b9576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b1490505b949350505050565b600854600160a01b900460ff1615610e325760405162461bcd60e51b815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610ec6565b600080805b83518167ffffffffffffffff161015611a9857838167ffffffffffffffff1681518110611a6d57611a6d612c7f565b60200260200101516020015182611a849190612c95565b915080611a9081612cc1565b915050611a3e565b5092915050565b8060005b81518167ffffffffffffffff161015611b8957818167ffffffffffffffff1681518110611ad257611ad2612c7f565b60200260200101516000015167ffffffffffffffff16600111158015611b2b5750601054828267ffffffffffffffff1681518110611b1257611b12612c7f565b60200260200101516000015167ffffffffffffffff1611155b611b775760405162461bcd60e51b815260206004820152601560248201527f696e636f727265637420616d756c6574207479706500000000000000000000006044820152606401610ec6565b80611b8181612cc1565b915050611aa3565b506000611b9583611a39565b9050611bab848267ffffffffffffffff16612014565b6000805b84518167ffffffffffffffff161015610d725760005b858267ffffffffffffffff1681518110611be157611be1612c7f565b60200260200101516020015167ffffffffffffffff168167ffffffffffffffff161015611ce05782611c1281612cc1565b93505060008367ffffffffffffffff168567ffffffffffffffff16611c406001546000546000199190030190565b611c4a9190612ce9565b611c549190612889565b90506040518060400160405280888567ffffffffffffffff1681518110611c7d57611c7d612c7f565b6020908102919091018101515167ffffffffffffffff9081168352429282019290925260009384526015815260409093208251815467ffffffffffffffff1916921691909117815591015160019091015580611cd881612cc1565b915050611bc5565b5080611ceb81612cc1565b915050611baf565b6060815160001415611d1357505060408051602081019091526000815290565b6000604051806060016040528060408152602001612e8e6040913990506000600384516002611d429190612889565b611d4c9190612d16565b611d579060046128a1565b90506000611d66826020612889565b67ffffffffffffffff811115611d7e57611d7e6123b8565b6040519080825280601f01601f191660200182016040528015611da8576020820181803683370190505b509050818152600183018586518101602084015b81831015611e14576003830192508251603f8160121c168501518253600182019150603f81600c1c168501518253600182019150603f8160061c168501518253600182019150603f8116850151825350600101611dbc565b600389510660018114611e2e5760028114611e3f57611e4b565b613d3d60f01b600119830152611e4b565b603d60f81b6000198301525b509398975050505050505050565b600854600160a01b900460ff16610e325760405162461bcd60e51b815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610ec6565b606081611ed65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115611f005780611eea81612d2a565b9150611ef99050600a83612d16565b9150611eda565b60008167ffffffffffffffff811115611f1b57611f1b6123b8565b6040519080825280601f01601f191660200182016040528015611f45576020820181803683370190505b5090505b84156119d757611f5a600183612ce9565b9150611f67600a86612d45565b611f72906030612889565b60f81b818381518110611f8757611f87612c7f565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611fc1600a86612d16565b9450611f49565b6000611fdf611fda6201518084612d16565b61202e565b50909392505050565b6000611ffa611fda6201518084612d16565b509392505050565b60006119d7611fda6201518084612d16565b61099c8282604051806020016040528060008152506121a2565b60008080838162253d8c6120458362010bd9612d59565b61204f9190612d59565b9050600062023ab1612062836004612d99565b61206c9190612e20565b9050600461207d8262023ab1612d99565b612088906003612d59565b6120929190612e20565b61209c9083612e4e565b9150600062164b096120af846001612d59565b6120bb90610fa0612d99565b6120c59190612e20565b905060046120d5826105b5612d99565b6120df9190612e20565b6120e99084612e4e565b6120f490601f612d59565b9250600061098f612106856050612d99565b6121109190612e20565b9050600060506121228361098f612d99565b61212c9190612e20565b6121369086612e4e565b9050612143600b83612e20565b945061215085600c612d99565b61215b836002612d59565b6121659190612e4e565b91508483612174603187612e4e565b61217f906064612d99565b6121899190612d59565b6121939190612d59565b9a919950975095505050505050565b6121ac838361220f565b6001600160a01b0383163b15610b55576000548281035b6121d660008683806001019450866118e7565b6121f3576040516368d2bf6b60e11b815260040160405180910390fd5b8181106121c357816000541461220857600080fd5b5050505050565b6000546001600160a01b03831661223857604051622e076360e81b815260040160405180910390fd5b816122565760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038316600081815260056020526040902080546801000000000000000185020190554260a01b6001841460e11b1717600082815260046020526040902055808281015b6040516001830192906001600160a01b038716906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a48082106122a05760005550505050565b8280546122f89061283e565b90600052602060002090601f01602090048101928261231a5760008555612360565b82601f1061233357805160ff1916838001178555612360565b82800160010185558215612360579182015b82811115612360578251825591602001919060010190612345565b5061236c929150612370565b5090565b5b8082111561236c5760008155600101612371565b6001600160e01b031981168114610e1f57600080fd5b6000602082840312156123ad57600080fd5b8135610fd281612385565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff811182821017156123f1576123f16123b8565b60405290565b604051601f8201601f1916810167ffffffffffffffff81118282101715612420576124206123b8565b604052919050565b600067ffffffffffffffff831115612442576124426123b8565b612455601f8401601f19166020016123f7565b905082815283838301111561246957600080fd5b828260208301376000602084830101529392505050565b600082601f83011261249157600080fd5b610fd283833560208501612428565b6000602082840312156124b257600080fd5b813567ffffffffffffffff8111156124c957600080fd5b6119d784828501612480565b60005b838110156124f05781810151838201526020016124d8565b838111156111a85750506000910152565b600081518084526125198160208601602086016124d5565b601f01601f19169290920160200192915050565b602081526000610fd26020830184612501565b60006020828403121561255257600080fd5b5035919050565b80356001600160a01b038116811461257057600080fd5b919050565b6000806040838503121561258857600080fd5b61259183612559565b946020939093013593505050565b803567ffffffffffffffff8116811461257057600080fd5b600080604083850312156125ca57600080fd5b6125d38361259f565b9150602083013567ffffffffffffffff8111156125ef57600080fd5b6125fb85828601612480565b9150509250929050565b60008060006060848603121561261a57600080fd5b61262384612559565b925061263160208501612559565b9150604084013590509250925092565b60006020828403121561265357600080fd5b610fd28261259f565b60006020828403121561266e57600080fd5b610fd282612559565b6000806040838503121561268a57600080fd5b61269383612559565b9150602083013580151581146126a857600080fd5b809150509250929050565b600080600080608085870312156126c957600080fd5b6126d285612559565b93506126e060208601612559565b925060408501359150606085013567ffffffffffffffff81111561270357600080fd5b8501601f8101871361271457600080fd5b61272387823560208401612428565b91505092959194509250565b6000602080838503121561274257600080fd5b823567ffffffffffffffff8082111561275a57600080fd5b818501915085601f83011261276e57600080fd5b813581811115612780576127806123b8565b61278e848260051b016123f7565b818152848101925060069190911b8301840190878211156127ae57600080fd5b928401925b8184101561280057604084890312156127cc5760008081fd5b6127d46123ce565b6127dd8561259f565b81526127ea86860161259f565b81870152835260409390930192918401916127b3565b979650505050505050565b6000806040838503121561281e57600080fd5b61282783612559565b915061283560208401612559565b90509250929050565b600181811c9082168061285257607f821691505b60208210811415610ee457634e487b7160e01b600052602260045260246000fd5b634e487b7160e01b600052601160045260246000fd5b6000821982111561289c5761289c612873565b500190565b60008160001904831182151516156128bb576128bb612873565b500290565b7f646174613a6170706c69636174696f6e2f6a736f6e3b6261736536342c0000008152600082516128f881601d8501602087016124d5565b91909101601d0192915050565b8054600090600181811c908083168061291f57607f831692505b602080841082141561294157634e487b7160e01b600052602260045260246000fd5b818015612955576001811461296657612993565b60ff19861689528489019650612993565b60008881526020902060005b8681101561298b5781548b820152908501908301612972565b505084890196505b50505050505092915050565b683d913730b6b2911d1160b91b8152600086516129c3816009850160208b016124d5565b7f222c20226465736372697074696f6e223a2200000000000000000000000000006009918401918201528651612a0081601b840160208b016124d5565b6c1116101134b6b0b3b2911d101160991b601b9290910191820152612a286028820187612905565b90508451612a3a8183602089016124d5565b7f5f657870697265640000000000000000000000000000000000000000000000009101908152612a6d6008820185612905565b61227d60f01b815260020198975050505050505050565b6000612a908287612905565b7f204d696e7465642061742000000000000000000000000000000000000000000081528551612ac681600b840160208a016124d5565b808201915050602f60f81b80600b8301528551612aea81600c850160208a016124d5565b600c9201918201528351612b0581600d8401602088016124d5565b01600d019695505050505050565b683d913730b6b2911d1160b91b815260008951612b37816009850160208e016124d5565b7f222c20226465736372697074696f6e223a2200000000000000000000000000006009918401918201528951612b7481601b840160208e016124d5565b6c1116101134b6b0b3b2911d101160991b601b9290910191820152612b9c602882018a612905565b90508751612bae818360208c016124d5565b612bba81830189612905565b9150507f222c2022616e696d6174696f6e5f75726c223a202200000000000000000000008152612bed6015820187612905565b90508451612bff8183602089016124d5565b612c0b81830186612905565b61227d60f01b81526002019c9b505050505050505050505050565b60006001600160a01b03808716835280861660208401525083604083015260806060830152612c586080830184612501565b9695505050505050565b600060208284031215612c7457600080fd5b8151610fd281612385565b634e487b7160e01b600052603260045260246000fd5b600067ffffffffffffffff808316818516808303821115612cb857612cb8612873565b01949350505050565b600067ffffffffffffffff80831681811415612cdf57612cdf612873565b6001019392505050565b600082821015612cfb57612cfb612873565b500390565b634e487b7160e01b600052601260045260246000fd5b600082612d2557612d25612d00565b500490565b6000600019821415612d3e57612d3e612873565b5060010190565b600082612d5457612d54612d00565b500690565b6000808212826001600160ff1b0303841381151615612d7a57612d7a612873565b600160ff1b8390038412811615612d9357612d93612873565b50500190565b60006001600160ff1b03600084136000841385830485118282161615612dc157612dc1612873565b600160ff1b6000871282811687830589121615612de057612de0612873565b60008712925087820587128484161615612dfc57612dfc612873565b87850587128184161615612e1257612e12612873565b505050929093029392505050565b600082612e2f57612e2f612d00565b600160ff1b821460001984141615612e4957612e49612873565b500590565b60008083128015600160ff1b850184121615612e6c57612e6c612873565b836001600160ff1b03018313811615612e8757612e87612873565b5050039056fe4142434445464748494a4b4c4d4e4f505152535455565758595a6162636465666768696a6b6c6d6e6f707172737475767778797a303132333435363738392b2fa2646970667358221220c1554453f50bc8c09c5c6292593724fbbc19d87bd22006c50b0b5545578181f664736f6c63430008090033
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.