Feature Tip: Add private address tag to any address under My Name Tag !
ERC-721
NFT
Overview
Max Total Supply
13,961 WAWTWO
Holders
6,813
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Balance
2 WAWTWOLoading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
DropspaceSale
Compiler Version
v0.8.4+commit.c7e474f2
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: Unlicense pragma solidity ^0.8.4; import "./IDropspaceSale.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/utils/Strings.sol"; import "@openzeppelin/contracts/utils/cryptography/MerkleProof.sol"; import "erc721a/contracts/ERC721A.sol"; contract DropspaceSale is IDropspaceSale, ERC721A, Ownable { using SafeMath for uint256; using Strings for uint256; uint256 MAX = 2**256 - 1; uint256 public override mintLimit; uint256 public override mintPrice; uint256 public override supplyLimit; string public override baseURI; bool public override smartContractAllowance = false; bool public override saleActive; bool public override presaleActive; bool public override whitelistSaleActive; address payable public override withdrawalWallet; address payable public override devWallet; address public override ticketAddress; bool public override whitelistBuyOnce; uint256 devSaleShare; uint256 ownerSaleShare; mapping(uint256 => bool) public override usedTickets; bytes32 public override whitelistRoot; mapping(address => bool) public override whitelistClaimed; constructor( uint256 _supplyLimit, uint256 _mintLimit, uint256 _mintPrice, uint256 _devSaleShare, address payable _withdrawalWallet, address payable _devWallet, address _ticketAddress, string memory _name, string memory _ticker, string memory _baseURI ) ERC721A(_name, _ticker) { supplyLimit = _supplyLimit; mintLimit = _mintLimit; mintPrice = _mintPrice; withdrawalWallet = _withdrawalWallet; devWallet = _devWallet; ticketAddress = _ticketAddress; baseURI = _baseURI; devSaleShare = _devSaleShare; ownerSaleShare = uint256(10000).sub(devSaleShare); } modifier onlyWithdrawalWallet() { require(address(withdrawalWallet) == _msgSender(), "DropspaceSale: caller is not the withdrawal wallet"); _; } function setWhitelistBuyOnce(bool _whitelistBuyOnce) external onlyOwner override { whitelistBuyOnce = _whitelistBuyOnce; emit WhitelistBuyOnceChanged(whitelistBuyOnce); } function emergencyWithdraw() external onlyOwner override { payable(owner()).transfer(address(this).balance); } function changeSupplyLimit(uint256 _supplyLimit) external onlyOwner override { require(supplyLimit >= totalSupply(), "DropspaceSale::changeSupplyLimit: Supply Limit can't be reduced below total supply"); supplyLimit = _supplyLimit; emit SupplyLimitChanged(_supplyLimit); } function setMintPrice(uint256 _mintPrice) external onlyOwner override { mintPrice = _mintPrice; emit MintPriceChanged(_mintPrice); } function setWhitelistClaimStatus(address _user, bool _status) public onlyOwner override { _setWhitelistClaimStatus(_user, _status); } function _setWhitelistClaimStatus(address _user, bool _status) internal { whitelistClaimed[_user] = _status; emit WhitelistClaimStatusChanged(_user, _status); } function setWhitelistRoot(bytes32 _whitelistRoot) external onlyOwner override { whitelistRoot = _whitelistRoot; emit WhitelistRootChanged(whitelistRoot); } function setDevSaleShare(uint256 _devSaleShare) external override onlyOwner { devSaleShare = _devSaleShare; ownerSaleShare = uint256(10000).sub(devSaleShare); emit DevShareSaleChanged(devSaleShare); } function toggleSaleActive() external onlyOwner override { saleActive = !saleActive; emit ToggleSaleState(saleActive); } function toggleWhitelistSaleActive() external onlyOwner override { whitelistSaleActive = !whitelistSaleActive; emit ToggleWhitelistSaleState(whitelistSaleActive); } function setBaseURI(string memory _baseURI) external onlyOwner override { baseURI = _baseURI; emit BaseURIChanged(baseURI); } function setSmartContractAllowance(bool _smartContractAllowance) external onlyOwner override { smartContractAllowance = _smartContractAllowance; emit SmartContractAllowanceChanged(smartContractAllowance); } function setWithdrawalWallet(address payable _withdrawalWallet) external onlyOwner override { withdrawalWallet = _withdrawalWallet; emit WithdrawalWalletChanged(withdrawalWallet); } function setDevWallet(address payable _devWallet) external onlyOwner override { devWallet = _devWallet; emit DevWalletChanged(devWallet); } function setMintLimit(uint256 _mintLimit) external onlyOwner override { mintLimit = _mintLimit; emit MintLimitChanged(mintLimit); } function withdraw() external onlyOwner override { uint256 contractBalance = address(this).balance; devWallet.transfer(contractBalance.mul(devSaleShare).div(10000)); withdrawalWallet.transfer(contractBalance.mul(ownerSaleShare).div(10000)); } function reserve(uint256 _amount) external onlyOwner override { _mint(_amount); emit Reserve(_amount); } function buy(uint256 _amount) external override payable { require(saleActive, "Dropspace::buy: Sale is not active."); require(_amount <= mintLimit, "Dropspace::buy: Too many tokens for one transaction."); require(msg.value >= mintPrice.mul(_amount), "Dropspace::buy: Insufficient payment."); if (!smartContractAllowance) { require(tx.origin == _msgSender(), "Dropspace::buy: Smart contracts are not allowed to buy."); } _mint(_amount); emit Buy(_msgSender(), _amount); } function _mint(uint256 _amount) internal { require(totalSupply().add(_amount) <= supplyLimit, "Not enough tokens left."); _safeMint(_msgSender(), _amount); } function airdrop( address[] calldata _receivers, uint256[] calldata _numTokens ) external onlyOwner { require(_receivers.length == _numTokens.length, "Airdrop lengths must match"); for (uint256 i = 0; i < _receivers.length; i++) { _safeMint(_receivers[i], _numTokens[i]); } } function viewOwner(address _collection, uint256 _tokenId) public view returns(address) { return IERC721(_collection).ownerOf(_tokenId); } function tokenURI(uint256 _tokenId) public view override returns(string memory) { require(_exists(_tokenId), "ERC721Metadata: URI query for nonexistent token"); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, _tokenId.toString())) : ""; } function togglePresaleActive() external onlyOwner override { presaleActive = !presaleActive; emit TogglePresaleState(presaleActive); } function setTicketAddress(address _ticketAddress) external onlyOwner override { require(_ticketAddress != address(0), "DropSpaceSale::setTicketAddress: Invalid address."); ticketAddress = _ticketAddress; emit TicketAddressChanged(_ticketAddress); } function presaleBuy(uint256 _ticketId, uint _amount) external payable override { require(presaleActive, "Dropspace::presaleBuy: Presale is not Active."); require(IERC721(ticketAddress).ownerOf(_ticketId) == _msgSender(), "Dropspace::presaleBuy: invalid ticket."); require(!usedTickets[_ticketId], "Dropspace::presaleBuy: Ticket already used."); require(_amount <= mintLimit, "Dropspace::presaleBuy: Too many tokens for one transaction."); require(msg.value >= mintPrice.mul(_amount), "Dropspace::presaleBuy: Insufficient payment."); usedTickets[_ticketId] = true; _mint(_amount); emit PresaleBuy(_msgSender(), _ticketId, _amount); } function _verifyWhitelist(address _user, bytes32[] calldata _merkleProof) internal view returns(bool) { bytes32 leaf = keccak256(abi.encodePacked(_user)); return MerkleProof.verify(_merkleProof, whitelistRoot, leaf); } function whitelistBuy(uint256 _amount, bytes32[] calldata _merkleProof) external payable override { require(whitelistSaleActive, "DropSpaceSale::whitelistBuy: Whitelist Buy is not Active."); require(_amount <= mintLimit, "Dropspace::presaleBuy: Too many tokens for one transaction."); require(msg.value >= mintPrice.mul(_amount), "Dropspace::presaleBuy: Insufficient payment."); require(_verifyWhitelist(_msgSender(), _merkleProof), "Dropspace::whitelistBuy: User is not whitelisted"); if (whitelistBuyOnce) { require(!whitelistClaimed[_msgSender()], "Dropspace::whitelistBuy: Already claimed"); _setWhitelistClaimStatus(_msgSender(), true); } _mint(_amount); emit WhitelistBuy(_msgSender(), _amount); } function clearTicket(uint256 _ticketId) external override onlyOwner{ require(usedTickets[_ticketId], "Dropspace::clearTicket: Ticket is not used"); usedTickets[_ticketId] = false; emit TicketCleared(_ticketId); } receive() external override payable {} }
// SPDX-License-Identifier: Unlicense pragma solidity ^0.8.4; interface IDropspaceSale { // OWNER ONLY function togglePresaleActive() external; function toggleWhitelistSaleActive() external; function toggleSaleActive() external; function setBaseURI(string memory _baseURI) external; function setWithdrawalWallet(address payable _withdrawalWallet) external; function setDevWallet(address payable _devWallet) external; function setDevSaleShare(uint256 _devSaleShare) external; function setMintLimit(uint256 _mintLimit) external; function setSmartContractAllowance(bool _smartContractAllowance) external; function setTicketAddress(address _ticketAddress) external; function setWhitelistClaimStatus(address _user, bool _status) external; function changeSupplyLimit(uint256 _supplyLimit) external; function emergencyWithdraw() external; function setMintPrice(uint256 _mintPrice) external; function setWhitelistBuyOnce(bool _whitelistBuyOnce) external; function setWhitelistRoot(bytes32 _whitelistRoot) external; function reserve(uint256 _amount) external; function withdraw() external; function clearTicket(uint256 _ticketId) external; // EXTERNAL function buy(uint256 _amount) external payable; function presaleBuy(uint256 _ticketId, uint256 _amount) external payable; function whitelistBuy(uint256 _amount, bytes32[] calldata _merkleProof) external payable; // VIEW function supplyLimit() view external returns(uint256); function mintPrice() view external returns(uint256); function mintLimit() view external returns(uint256); function baseURI() view external returns(string memory); function saleActive() view external returns(bool); function presaleActive() view external returns(bool); function whitelistSaleActive() view external returns(bool); function smartContractAllowance() view external returns(bool); function devWallet() view external returns(address payable); function withdrawalWallet() view external returns(address payable); function ticketAddress() view external returns(address); function whitelistRoot() view external returns (bytes32); function usedTickets(uint256 _ticketId) view external returns(bool); function whitelistClaimed(address _user) view external returns(bool); function whitelistBuyOnce() view external returns(bool); // EVENTS event Reserve(uint256 _amount); event Mint(address indexed _user, uint256 indexed _tokenId, string _tokenURI); event ToggleSaleState(bool _state); event BaseURIChanged(string _baseURI); event WithdrawalWalletChanged(address payable _newWithdrawalWallet); event DevWalletChanged(address payable _newDevWallet); event DevShareSaleChanged(uint256 _devSaleShare); event MintLimitChanged(uint256 _newMintLimit); event MintPriceChanged(uint256 _mintPrice); event SmartContractAllowanceChanged(bool _newSmartContractAllowance); event TogglePresaleState(bool _preSaleState); event TicketAddressChanged(address _ticketAddress); event PresaleBuy(address _user, uint256 _ticketId, uint256 _amount); event WhitelistBuy(address _user, uint256 _amount); event Buy(address _user, uint256 _amount); event WhitelistClaimStatusChanged(address _user, bool _status); event ToggleWhitelistSaleState(bool _whitelistSaleActive); event SupplyLimitChanged(uint256 _supplyLimit); event TicketCleared(uint256 _ticketId); event WhitelistRootChanged(bytes32 _whitelistRoot); event WhitelistBuyOnceChanged(bool _whitelistBuyOnce); receive() external payable; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (access/Ownable.sol) pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _transferOwnership(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _transferOwnership(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _transferOwnership(newOwner); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Internal function without access restriction. */ function _transferOwnership(address newOwner) internal virtual { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/math/SafeMath.sol) pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is generally not needed starting with Solidity 0.8, since the compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Strings.sol) pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/cryptography/MerkleProof.sol) pragma solidity ^0.8.0; /** * @dev These functions deal with verification of Merkle Trees proofs. * * The proofs can be generated using the JavaScript library * https://github.com/miguelmota/merkletreejs[merkletreejs]. * Note: the hashing algorithm should be keccak256 and pair sorting should be enabled. * * See `test/utils/cryptography/MerkleProof.test.js` for some examples. */ library MerkleProof { /** * @dev Returns true if a `leaf` can be proved to be a part of a Merkle tree * defined by `root`. For this, a `proof` must be provided, containing * sibling hashes on the branch from the leaf to the root of the tree. Each * pair of leaves and each pair of pre-images are assumed to be sorted. */ function verify( bytes32[] memory proof, bytes32 root, bytes32 leaf ) internal pure returns (bool) { return processProof(proof, leaf) == root; } /** * @dev Returns the rebuilt hash obtained by traversing a Merklee tree up * from `leaf` using `proof`. A `proof` is valid if and only if the rebuilt * hash matches the root of the tree. When processing the proof, the pairs * of leafs & pre-images are assumed to be sorted. * * _Available since v4.4._ */ function processProof(bytes32[] memory proof, bytes32 leaf) internal pure returns (bytes32) { bytes32 computedHash = leaf; for (uint256 i = 0; i < proof.length; i++) { bytes32 proofElement = proof[i]; if (computedHash <= proofElement) { // Hash(current computed hash + current element of the proof) computedHash = _efficientHash(computedHash, proofElement); } else { // Hash(current element of the proof + current computed hash) computedHash = _efficientHash(proofElement, computedHash); } } return computedHash; } function _efficientHash(bytes32 a, bytes32 b) private pure returns (bytes32 value) { assembly { mstore(0x00, a) mstore(0x20, b) value := keccak256(0x00, 0x40) } } }
// SPDX-License-Identifier: MIT // Creator: Chiru Labs pragma solidity ^0.8.4; import '@openzeppelin/contracts/token/ERC721/IERC721.sol'; import '@openzeppelin/contracts/token/ERC721/IERC721Receiver.sol'; import '@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol'; import '@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol'; import '@openzeppelin/contracts/utils/Address.sol'; import '@openzeppelin/contracts/utils/Context.sol'; import '@openzeppelin/contracts/utils/Strings.sol'; import '@openzeppelin/contracts/utils/introspection/ERC165.sol'; error ApprovalCallerNotOwnerNorApproved(); error ApprovalQueryForNonexistentToken(); error ApproveToCaller(); error ApprovalToCurrentOwner(); error BalanceQueryForZeroAddress(); error MintedQueryForZeroAddress(); error BurnedQueryForZeroAddress(); error MintToZeroAddress(); error MintZeroQuantity(); error OwnerIndexOutOfBounds(); error OwnerQueryForNonexistentToken(); error TokenIndexOutOfBounds(); error TransferCallerNotOwnerNorApproved(); error TransferFromIncorrectOwner(); error TransferToNonERC721ReceiverImplementer(); error TransferToZeroAddress(); error URIQueryForNonexistentToken(); /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata and Enumerable extension. Built to optimize for lower gas during batch mints. * * Assumes serials are sequentially minted starting at 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**128 - 1 (max value of uint128). */ contract ERC721A is Context, ERC165, IERC721, IERC721Metadata, IERC721Enumerable { using Address for address; using Strings for uint256; // Compiler will pack this into a single 256bit word. struct TokenOwnership { // The address of the owner. address addr; // Keeps track of the start time of ownership with minimal overhead for tokenomics. uint64 startTimestamp; // Whether the token has been burned. bool burned; } // Compiler will pack this into a single 256bit word. struct AddressData { // Realistically, 2**64-1 is more than enough. uint64 balance; // Keeps track of mint count with minimal overhead for tokenomics. uint64 numberMinted; // Keeps track of burn count with minimal overhead for tokenomics. uint64 numberBurned; } // Compiler will pack the following // _currentIndex and _burnCounter into a single 256bit word. // The tokenId of the next token to be minted. uint128 internal _currentIndex; // The number of tokens burned. uint128 internal _burnCounter; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to ownership details // An empty struct value does not necessarily mean the token is unowned. See ownershipOf implementation for details. mapping(uint256 => TokenOwnership) internal _ownerships; // Mapping owner address to address data mapping(address => AddressData) private _addressData; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view override returns (uint256) { // Counter underflow is impossible as _burnCounter cannot be incremented // more than _currentIndex times unchecked { return _currentIndex - _burnCounter; } } /** * @dev See {IERC721Enumerable-tokenByIndex}. * This read function is O(totalSupply). If calling from a separate contract, be sure to test gas first. * It may also degrade with extremely large collection sizes (e.g >> 10000), test for your use case. */ function tokenByIndex(uint256 index) public view override returns (uint256) { uint256 numMintedSoFar = _currentIndex; uint256 tokenIdsIdx; // Counter overflow is impossible as the loop breaks when // uint256 i is equal to another uint256 numMintedSoFar. unchecked { for (uint256 i; i < numMintedSoFar; i++) { TokenOwnership memory ownership = _ownerships[i]; if (!ownership.burned) { if (tokenIdsIdx == index) { return i; } tokenIdsIdx++; } } } revert TokenIndexOutOfBounds(); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. * This read function is O(totalSupply). If calling from a separate contract, be sure to test gas first. * It may also degrade with extremely large collection sizes (e.g >> 10000), test for your use case. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view override returns (uint256) { if (index >= balanceOf(owner)) revert OwnerIndexOutOfBounds(); uint256 numMintedSoFar = _currentIndex; uint256 tokenIdsIdx; address currOwnershipAddr; // Counter overflow is impossible as the loop breaks when // uint256 i is equal to another uint256 numMintedSoFar. unchecked { for (uint256 i; i < numMintedSoFar; i++) { TokenOwnership memory ownership = _ownerships[i]; if (ownership.burned) { continue; } if (ownership.addr != address(0)) { currOwnershipAddr = ownership.addr; } if (currOwnershipAddr == owner) { if (tokenIdsIdx == index) { return i; } tokenIdsIdx++; } } } // Execution should never reach this point. revert(); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view override returns (uint256) { if (owner == address(0)) revert BalanceQueryForZeroAddress(); return uint256(_addressData[owner].balance); } function _numberMinted(address owner) internal view returns (uint256) { if (owner == address(0)) revert MintedQueryForZeroAddress(); return uint256(_addressData[owner].numberMinted); } function _numberBurned(address owner) internal view returns (uint256) { if (owner == address(0)) revert BurnedQueryForZeroAddress(); return uint256(_addressData[owner].numberBurned); } /** * Gas spent here starts off proportional to the maximum mint batch size. * It gradually moves to O(1) as tokens get transferred around in the collection over time. */ function ownershipOf(uint256 tokenId) internal view returns (TokenOwnership memory) { uint256 curr = tokenId; unchecked { if (curr < _currentIndex) { TokenOwnership memory ownership = _ownerships[curr]; if (!ownership.burned) { if (ownership.addr != address(0)) { return ownership; } // Invariant: // There will always be an ownership that has an address and is not burned // before an ownership that does not have an address and is not burned. // Hence, curr will not underflow. while (true) { curr--; ownership = _ownerships[curr]; if (ownership.addr != address(0)) { return ownership; } } } } } revert OwnerQueryForNonexistentToken(); } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view override returns (address) { return ownershipOf(tokenId).addr; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { if (!_exists(tokenId)) revert URIQueryForNonexistentToken(); string memory baseURI = _baseURI(); return bytes(baseURI).length != 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ''; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ''; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public override { address owner = ERC721A.ownerOf(tokenId); if (to == owner) revert ApprovalToCurrentOwner(); if (_msgSender() != owner && !isApprovedForAll(owner, _msgSender())) { revert ApprovalCallerNotOwnerNorApproved(); } _approve(to, tokenId, owner); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view override returns (address) { if (!_exists(tokenId)) revert ApprovalQueryForNonexistentToken(); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public override { if (operator == _msgSender()) revert ApproveToCaller(); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ''); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { _transfer(from, to, tokenId); if (!_checkOnERC721Received(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 tokenId < _currentIndex && !_ownerships[tokenId].burned; } function _safeMint(address to, uint256 quantity) internal { _safeMint(to, quantity, ''); } /** * @dev Safely mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called for each safe transfer. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _safeMint( address to, uint256 quantity, bytes memory _data ) internal { _mint(to, quantity, _data, true); } /** * @dev Mints `quantity` tokens and transfers them to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `quantity` must be greater than 0. * * Emits a {Transfer} event. */ function _mint( address to, uint256 quantity, bytes memory _data, bool safe ) internal { uint256 startTokenId = _currentIndex; if (to == address(0)) revert MintToZeroAddress(); if (quantity == 0) revert MintZeroQuantity(); _beforeTokenTransfers(address(0), to, startTokenId, quantity); // Overflows are incredibly unrealistic. // balance or numberMinted overflow if current value of either + quantity > 3.4e38 (2**128) - 1 // updatedIndex overflows if _currentIndex + quantity > 3.4e38 (2**128) - 1 unchecked { _addressData[to].balance += uint64(quantity); _addressData[to].numberMinted += uint64(quantity); _ownerships[startTokenId].addr = to; _ownerships[startTokenId].startTimestamp = uint64(block.timestamp); uint256 updatedIndex = startTokenId; for (uint256 i; i < quantity; i++) { emit Transfer(address(0), to, updatedIndex); if (safe && !_checkOnERC721Received(address(0), to, updatedIndex, _data)) { revert TransferToNonERC721ReceiverImplementer(); } updatedIndex++; } _currentIndex = uint128(updatedIndex); } _afterTokenTransfers(address(0), to, startTokenId, quantity); } /** * @dev Transfers `tokenId` from `from` to `to`. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) private { TokenOwnership memory prevOwnership = ownershipOf(tokenId); bool isApprovedOrOwner = (_msgSender() == prevOwnership.addr || isApprovedForAll(prevOwnership.addr, _msgSender()) || getApproved(tokenId) == _msgSender()); if (!isApprovedOrOwner) revert TransferCallerNotOwnerNorApproved(); if (prevOwnership.addr != from) revert TransferFromIncorrectOwner(); if (to == address(0)) revert TransferToZeroAddress(); _beforeTokenTransfers(from, to, tokenId, 1); // Clear approvals from the previous owner _approve(address(0), tokenId, prevOwnership.addr); // 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**128. unchecked { _addressData[from].balance -= 1; _addressData[to].balance += 1; _ownerships[tokenId].addr = to; _ownerships[tokenId].startTimestamp = uint64(block.timestamp); // If the ownership slot of tokenId+1 is not explicitly set, that means the transfer initiator owns it. // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls. uint256 nextTokenId = tokenId + 1; if (_ownerships[nextTokenId].addr == address(0)) { // This will suffice for checking _exists(nextTokenId), // as a burned slot cannot contain the zero address. if (nextTokenId < _currentIndex) { _ownerships[nextTokenId].addr = prevOwnership.addr; _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp; } } } emit Transfer(from, to, tokenId); _afterTokenTransfers(from, to, tokenId, 1); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { TokenOwnership memory prevOwnership = ownershipOf(tokenId); _beforeTokenTransfers(prevOwnership.addr, address(0), tokenId, 1); // Clear approvals from the previous owner _approve(address(0), tokenId, prevOwnership.addr); // 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**128. unchecked { _addressData[prevOwnership.addr].balance -= 1; _addressData[prevOwnership.addr].numberBurned += 1; // Keep track of who burned the token, and the timestamp of burning. _ownerships[tokenId].addr = prevOwnership.addr; _ownerships[tokenId].startTimestamp = uint64(block.timestamp); _ownerships[tokenId].burned = true; // If the ownership slot of tokenId+1 is not explicitly set, that means the burn initiator owns it. // Set the slot of tokenId+1 explicitly in storage to maintain correctness for ownerOf(tokenId+1) calls. uint256 nextTokenId = tokenId + 1; if (_ownerships[nextTokenId].addr == address(0)) { // This will suffice for checking _exists(nextTokenId), // as a burned slot cannot contain the zero address. if (nextTokenId < _currentIndex) { _ownerships[nextTokenId].addr = prevOwnership.addr; _ownerships[nextTokenId].startTimestamp = prevOwnership.startTimestamp; } } } emit Transfer(prevOwnership.addr, address(0), tokenId); _afterTokenTransfers(prevOwnership.addr, address(0), tokenId, 1); // Overflow not possible, as _burnCounter cannot be exceed _currentIndex times. unchecked { _burnCounter++; } } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve( address to, uint256 tokenId, address owner ) private { _tokenApprovals[tokenId] = to; emit Approval(owner, to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver(to).onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert TransferToNonERC721ReceiverImplementer(); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before a set of serially-ordered token ids are about to be transferred. This includes minting. * And also called before burning one token. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * Calling conditions: * * - When `from` and `to` are both non-zero, `from`'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, `tokenId` will be burned by `from`. * - `from` and `to` are never both zero. */ function _beforeTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} /** * @dev Hook that is called after a set of serially-ordered token ids have been transferred. This includes * minting. * And also called after one token has been burned. * * startTokenId - the first token id to be transferred * quantity - the amount to be transferred * * Calling conditions: * * - When `from` and `to` are both non-zero, `from`'s `tokenId` has been * transferred to `to`. * - When `from` is zero, `tokenId` has been minted for `to`. * - When `to` is zero, `tokenId` has been burned by `from`. * - `from` and `to` are never both zero. */ function _afterTokenTransfers( address from, address to, uint256 startTokenId, uint256 quantity ) internal virtual {} }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/Context.sol) pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721.sol) pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721Receiver.sol) pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol) pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol) pragma solidity ^0.8.1; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== * * [IMPORTANT] * ==== * You shouldn't rely on `isContract` to protect against flash loan attacks! * * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract * constructor. * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize/address.code.length, which returns 0 // for contracts in construction, since the code is only stored at the end // of the constructor execution. return account.code.length > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol) pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT // OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"uint256","name":"_supplyLimit","type":"uint256"},{"internalType":"uint256","name":"_mintLimit","type":"uint256"},{"internalType":"uint256","name":"_mintPrice","type":"uint256"},{"internalType":"uint256","name":"_devSaleShare","type":"uint256"},{"internalType":"address payable","name":"_withdrawalWallet","type":"address"},{"internalType":"address payable","name":"_devWallet","type":"address"},{"internalType":"address","name":"_ticketAddress","type":"address"},{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_ticker","type":"string"},{"internalType":"string","name":"_baseURI","type":"string"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ApprovalCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"ApprovalQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"ApprovalToCurrentOwner","type":"error"},{"inputs":[],"name":"ApproveToCaller","type":"error"},{"inputs":[],"name":"BalanceQueryForZeroAddress","type":"error"},{"inputs":[],"name":"MintToZeroAddress","type":"error"},{"inputs":[],"name":"MintZeroQuantity","type":"error"},{"inputs":[],"name":"OwnerIndexOutOfBounds","type":"error"},{"inputs":[],"name":"OwnerQueryForNonexistentToken","type":"error"},{"inputs":[],"name":"TokenIndexOutOfBounds","type":"error"},{"inputs":[],"name":"TransferCallerNotOwnerNorApproved","type":"error"},{"inputs":[],"name":"TransferFromIncorrectOwner","type":"error"},{"inputs":[],"name":"TransferToNonERC721ReceiverImplementer","type":"error"},{"inputs":[],"name":"TransferToZeroAddress","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":false,"internalType":"string","name":"_baseURI","type":"string"}],"name":"BaseURIChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"Buy","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_devSaleShare","type":"uint256"}],"name":"DevShareSaleChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address payable","name":"_newDevWallet","type":"address"}],"name":"DevWalletChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_user","type":"address"},{"indexed":true,"internalType":"uint256","name":"_tokenId","type":"uint256"},{"indexed":false,"internalType":"string","name":"_tokenURI","type":"string"}],"name":"Mint","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_newMintLimit","type":"uint256"}],"name":"MintLimitChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_mintPrice","type":"uint256"}],"name":"MintPriceChanged","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":"_user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_ticketId","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"PresaleBuy","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"Reserve","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_newSmartContractAllowance","type":"bool"}],"name":"SmartContractAllowanceChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_supplyLimit","type":"uint256"}],"name":"SupplyLimitChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_ticketAddress","type":"address"}],"name":"TicketAddressChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint256","name":"_ticketId","type":"uint256"}],"name":"TicketCleared","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_preSaleState","type":"bool"}],"name":"TogglePresaleState","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_state","type":"bool"}],"name":"ToggleSaleState","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_whitelistSaleActive","type":"bool"}],"name":"ToggleWhitelistSaleState","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":"_user","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"WhitelistBuy","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bool","name":"_whitelistBuyOnce","type":"bool"}],"name":"WhitelistBuyOnceChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_user","type":"address"},{"indexed":false,"internalType":"bool","name":"_status","type":"bool"}],"name":"WhitelistClaimStatusChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"_whitelistRoot","type":"bytes32"}],"name":"WhitelistRootChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address payable","name":"_newWithdrawalWallet","type":"address"}],"name":"WithdrawalWalletChanged","type":"event"},{"inputs":[{"internalType":"address[]","name":"_receivers","type":"address[]"},{"internalType":"uint256[]","name":"_numTokens","type":"uint256[]"}],"name":"airdrop","outputs":[],"stateMutability":"nonpayable","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":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"buy","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_supplyLimit","type":"uint256"}],"name":"changeSupplyLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_ticketId","type":"uint256"}],"name":"clearTicket","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"devWallet","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"emergencyWithdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mintLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"mintPrice","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":"presaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_ticketId","type":"uint256"},{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"presaleBuy","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"reserve","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":[],"name":"saleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_baseURI","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_devSaleShare","type":"uint256"}],"name":"setDevSaleShare","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_devWallet","type":"address"}],"name":"setDevWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintLimit","type":"uint256"}],"name":"setMintLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_mintPrice","type":"uint256"}],"name":"setMintPrice","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_smartContractAllowance","type":"bool"}],"name":"setSmartContractAllowance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_ticketAddress","type":"address"}],"name":"setTicketAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bool","name":"_whitelistBuyOnce","type":"bool"}],"name":"setWhitelistBuyOnce","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_user","type":"address"},{"internalType":"bool","name":"_status","type":"bool"}],"name":"setWhitelistClaimStatus","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"_whitelistRoot","type":"bytes32"}],"name":"setWhitelistRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address payable","name":"_withdrawalWallet","type":"address"}],"name":"setWithdrawalWallet","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"smartContractAllowance","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"supplyLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","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":[],"name":"ticketAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"togglePresaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"toggleWhitelistSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"usedTickets","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_collection","type":"address"},{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"viewOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_amount","type":"uint256"},{"internalType":"bytes32[]","name":"_merkleProof","type":"bytes32[]"}],"name":"whitelistBuy","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"whitelistBuyOnce","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"whitelistClaimed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"whitelistSaleActive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawalWallet","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
6080604052600019600855600d805460ff191690553480156200002157600080fd5b5060405162003b2c38038062003b2c83398101604081905262000044916200031d565b8251839083906200005d906001906020850190620001a7565b50805162000073906002906020840190620001a7565b505050620000906200008a6200013c60201b60201c565b62000140565b600b8a90556009899055600a889055600d80546001600160a01b0380891664010000000002600160201b600160c01b031990921691909117909155600e80548783166001600160a01b031991821617909155600f80549287169290911691909117905580516200010890600c906020840190620001a7565b506010879055620001286127108862000192602090811b6200241f17901c565b601155506200048398505050505050505050565b3390565b600780546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000620001a082846200040c565b9392505050565b828054620001b59062000430565b90600052602060002090601f016020900481019282620001d9576000855562000224565b82601f10620001f457805160ff191683800117855562000224565b8280016001018555821562000224579182015b828111156200022457825182559160200191906001019062000207565b506200023292915062000236565b5090565b5b8082111562000232576000815560010162000237565b80516001600160a01b03811681146200026557600080fd5b919050565b600082601f8301126200027b578081fd5b81516001600160401b03808211156200029857620002986200046d565b604051601f8301601f19908116603f01168101908282118183101715620002c357620002c36200046d565b81604052838152602092508683858801011115620002df578485fd5b8491505b83821015620003025785820183015181830184015290820190620002e3565b838211156200031357848385830101525b9695505050505050565b6000806000806000806000806000806101408b8d0312156200033d578586fd5b8a51995060208b0151985060408b0151975060608b015196506200036460808c016200024d565b95506200037460a08c016200024d565b94506200038460c08c016200024d565b60e08c01519094506001600160401b0380821115620003a1578485fd5b620003af8e838f016200026a565b94506101008d0151915080821115620003c6578384fd5b620003d48e838f016200026a565b93506101208d0151915080821115620003eb578283fd5b50620003fa8d828e016200026a565b9150509295989b9194979a5092959850565b6000828210156200042b57634e487b7160e01b81526011600452602481fd5b500390565b600181811c908216806200044557607f821691505b602082108114156200046757634e487b7160e01b600052602260045260246000fd5b50919050565b634e487b7160e01b600052604160045260246000fd5b61369980620004936000396000f3fe6080604052600436106103855760003560e01c80636817c76c116101d1578063a22cb46511610102578063d96a094a116100a0578063ed9a5bbb1161006f578063ed9a5bbb14610a28578063f2fde38b14610a48578063f4a0a52814610a68578063f5aa406d14610a8857600080fd5b8063d96a094a14610987578063db2e21bc1461099a578063db4bec44146109af578063e985e9c5146109df57600080fd5b8063b89fe999116100dc578063b89fe99914610911578063c87b56dd14610926578063d44e357314610946578063d7e2875c1461096657600080fd5b8063a22cb465146108b1578063ab26320e146108d1578063b88d4fde146108f157600080fd5b8063819b25ba1161016f5780638ea5220f116101495780638ea5220f1461084657806395d89b4114610866578063996517cf1461087b5780639e6a1d7d1461089157600080fd5b8063819b25ba146107f357806389b0649b146108135780638da5cb5b1461082857600080fd5b806370a08231116101ab57806370a082311461076e578063715018a61461078e57806371efdc21146107a357806375796f76146107d357600080fd5b80636817c76c1461072457806368428a1b1461073a5780636c0360eb1461075957600080fd5b8063386bfc98116102b657806355f804b3116102545780636352211e116102235780636352211e146106b7578063646d7a7f146106d757806367243482146106f157806368124a6a1461071157600080fd5b806355f804b31461063757806357a8e3fe14610657578063591e194b146106775780635c4e7e061461069757600080fd5b806342842e0e1161029057806342842e0e146105af5780634a7d80b3146105cf5780634f6ccce7146105f757806353135ca01461061757600080fd5b8063386bfc98146105635780633ad7f56c146105795780633ccfd60b1461059a57600080fd5b806318160ddd1161032357806323b872dd116102fd57806323b872dd146104ee5780632f745c591461050e57806330d1980c1461052e5780633100a5351461054e57600080fd5b806318160ddd1461049557806319d1997a146104b85780631f53ac02146104ce57600080fd5b806308e992871161035f57806308e992871461042057806309499f5314610442578063095ea7b3146104625780630983061c1461048257600080fd5b806301ffc9a71461039157806306fdde03146103c6578063081812fc146103e857600080fd5b3661038c57005b600080fd5b34801561039d57600080fd5b506103b16103ac3660046131bc565b610aa8565b60405190151581526020015b60405180910390f35b3480156103d257600080fd5b506103db610b15565b6040516103bd919061338c565b3480156103f457600080fd5b506104086104033660046131a4565b610ba7565b6040516001600160a01b0390911681526020016103bd565b34801561042c57600080fd5b5061044061043b36600461318a565b610beb565b005b34801561044e57600080fd5b5061044061045d3660046130c3565b610c6c565b34801561046e57600080fd5b5061044061047d3660046130f7565b610ca4565b610440610490366004613282565b610d32565b3480156104a157600080fd5b506104aa610faf565b6040519081526020016103bd565b3480156104c457600080fd5b506104aa600b5481565b3480156104da57600080fd5b506104406104e9366004612f97565b610fce565b3480156104fa57600080fd5b50610440610509366004613007565b611046565b34801561051a57600080fd5b506104aa6105293660046130f7565b611051565b34801561053a57600080fd5b506104086105493660046130f7565b61114d565b34801561055a57600080fd5b506104406111cf565b34801561056f57600080fd5b506104aa60135481565b34801561058557600080fd5b50600d546103b1906301000000900460ff1681565b3480156105a657600080fd5b5061044061125b565b3480156105bb57600080fd5b506104406105ca366004613007565b611342565b3480156105db57600080fd5b50600d546104089064010000000090046001600160a01b031681565b34801561060357600080fd5b506104aa6106123660046131a4565b61135d565b34801561062357600080fd5b50600d546103b19062010000900460ff1681565b34801561064357600080fd5b506104406106523660046131f4565b611407565b34801561066357600080fd5b50600f54610408906001600160a01b031681565b34801561068357600080fd5b5061044061069236600461318a565b611475565b3480156106a357600080fd5b506104406106b23660046131a4565b6114f4565b3480156106c357600080fd5b506104086106d23660046131a4565b611565565b3480156106e357600080fd5b50600d546103b19060ff1681565b3480156106fd57600080fd5b5061044061070c366004613122565b611577565b61044061071f366004613239565b611678565b34801561073057600080fd5b506104aa600a5481565b34801561074657600080fd5b50600d546103b190610100900460ff1681565b34801561076557600080fd5b506103db611894565b34801561077a57600080fd5b506104aa610789366004612f97565b611922565b34801561079a57600080fd5b50610440611970565b3480156107af57600080fd5b506103b16107be3660046131a4565b60126020526000908152604090205460ff1681565b3480156107df57600080fd5b506104406107ee366004612f97565b6119a6565b3480156107ff57600080fd5b5061044061080e3660046131a4565b611a2f565b34801561081f57600080fd5b50610440611a92565b34801561083457600080fd5b506007546001600160a01b0316610408565b34801561085257600080fd5b50600e54610408906001600160a01b031681565b34801561087257600080fd5b506103db611b16565b34801561088757600080fd5b506104aa60095481565b34801561089d57600080fd5b506104406108ac3660046131a4565b611b25565b3480156108bd57600080fd5b506104406108cc3660046130c3565b611b84565b3480156108dd57600080fd5b506104406108ec3660046131a4565b611c1a565b3480156108fd57600080fd5b5061044061090c366004613047565b611cfd565b34801561091d57600080fd5b50610440611d37565b34801561093257600080fd5b506103db6109413660046131a4565b611dbd565b34801561095257600080fd5b506104406109613660046131a4565b611e88565b34801561097257600080fd5b50600f546103b190600160a01b900460ff1681565b6104406109953660046131a4565b611f81565b3480156109a657600080fd5b5061044061217b565b3480156109bb57600080fd5b506103b16109ca366004612f97565b60146020526000908152604090205460ff1681565b3480156109eb57600080fd5b506103b16109fa366004612fcf565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b348015610a3457600080fd5b50610440610a43366004612f97565b6121e1565b348015610a5457600080fd5b50610440610a63366004612f97565b6122c9565b348015610a7457600080fd5b50610440610a833660046131a4565b612361565b348015610a9457600080fd5b50610440610aa33660046131a4565b6123c0565b60006001600160e01b031982166380ac58cd60e01b1480610ad957506001600160e01b03198216635b5e139f60e01b145b80610af457506001600160e01b0319821663780e9d6360e01b145b80610b0f57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060018054610b249061358c565b80601f0160208091040260200160405190810160405280929190818152602001828054610b509061358c565b8015610b9d5780601f10610b7257610100808354040283529160200191610b9d565b820191906000526020600020905b815481529060010190602001808311610b8057829003601f168201915b5050505050905090565b6000610bb28261242b565b610bcf576040516333d1c03960e21b815260040160405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6007546001600160a01b03163314610c1e5760405162461bcd60e51b8152600401610c159061346c565b60405180910390fd5b600d805460ff191682151590811790915560405160ff909116151581527f2a5bfbb68782e57b3242e612145304c845af3404e2d328a12dd2e7c078cd0117906020015b60405180910390a150565b6007546001600160a01b03163314610c965760405162461bcd60e51b8152600401610c159061346c565b610ca0828261245f565b5050565b6000610caf82611565565b9050806001600160a01b0316836001600160a01b03161415610ce45760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b03821614801590610d045750610d0281336109fa565b155b15610d22576040516367d9dca160e11b815260040160405180910390fd5b610d2d8383836124bb565b505050565b600d5462010000900460ff16610da05760405162461bcd60e51b815260206004820152602d60248201527f44726f7073706163653a3a70726573616c654275793a2050726573616c65206960448201526c39903737ba1020b1ba34bb329760991b6064820152608401610c15565b33600f546040516331a9108f60e11b8152600481018590526001600160a01b039283169290911690636352211e9060240160206040518083038186803b158015610de957600080fd5b505afa158015610dfd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e219190612fb3565b6001600160a01b031614610e865760405162461bcd60e51b815260206004820152602660248201527f44726f7073706163653a3a70726573616c654275793a20696e76616c6964207460448201526534b1b5b2ba1760d11b6064820152608401610c15565b60008281526012602052604090205460ff1615610ef95760405162461bcd60e51b815260206004820152602b60248201527f44726f7073706163653a3a70726573616c654275793a205469636b657420616c60448201526a3932b0b23c903ab9b2b21760a91b6064820152608401610c15565b600954811115610f1b5760405162461bcd60e51b8152600401610c15906134a1565b600a54610f289082612517565b341015610f475760405162461bcd60e51b8152600401610c1590613420565b6000828152601260205260409020805460ff19166001179055610f6981612523565b60408051338152602081018490529081018290527fb77d41b776d1d5cc75b500402614335da616afa8aa95b49325e22db7f1ca86cc906060015b60405180910390a15050565b6000546001600160801b03600160801b82048116918116919091031690565b6007546001600160a01b03163314610ff85760405162461bcd60e51b8152600401610c159061346c565b600e80546001600160a01b0319166001600160a01b0383169081179091556040519081527f268c00f4ec08b34fdde24b52e47a09d62f3f3837eb3b8ac7206cefb3bb5e534590602001610c61565b610d2d838383612590565b600061105c83611922565b821061107b576040516306ed618760e11b815260040160405180910390fd5b600080546001600160801b03169080805b8381101561114757600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff1615801592820192909252906110f3575061113f565b80516001600160a01b03161561110857805192505b876001600160a01b0316836001600160a01b0316141561113d578684141561113657509350610b0f92505050565b6001909301925b505b60010161108c565b50600080fd5b6040516331a9108f60e11b8152600481018290526000906001600160a01b03841690636352211e9060240160206040518083038186803b15801561119057600080fd5b505afa1580156111a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c89190612fb3565b9392505050565b6007546001600160a01b031633146111f95760405162461bcd60e51b8152600401610c159061346c565b600d805460ff610100808304821615810261ff001990931692909217928390556040517f5a454f976028c400c4159ac85c61452441fcf06b9888c7c780c5980e3c3123dd936112519390049091161515815260200190565b60405180910390a1565b6007546001600160a01b031633146112855760405162461bcd60e51b8152600401610c159061346c565b600e5460105447916001600160a01b0316906108fc906112b490612710906112ae908690612517565b906127aa565b6040518115909202916000818181858888f193505050501580156112dc573d6000803e3d6000fd5b50600d60049054906101000a90046001600160a01b03166001600160a01b03166108fc61131a6127106112ae6011548661251790919063ffffffff16565b6040518115909202916000818181858888f19350505050158015610ca0573d6000803e3d6000fd5b610d2d83838360405180602001604052806000815250611cfd565b600080546001600160801b031681805b828110156113ed57600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff161515918101829052906113e457858314156113dd5750949350505050565b6001909201915b5060010161136d565b506040516329c8c00760e21b815260040160405180910390fd5b6007546001600160a01b031633146114315760405162461bcd60e51b8152600401610c159061346c565b805161144490600c906020840190612e2b565b507f5411e8ebf1636d9e83d5fc4900bf80cbac82e8790da2a4c94db4895e889eedf6600c604051610c61919061339f565b6007546001600160a01b0316331461149f5760405162461bcd60e51b8152600401610c159061346c565b600f805460ff60a01b1916600160a01b8315158102919091179182905560405160ff9190920416151581527fc6e0fb794d60d245727554ed563b17ec5cd901c15ee395b10535ce370b1bdccd90602001610c61565b6007546001600160a01b0316331461151e5760405162461bcd60e51b8152600401610c159061346c565b601081905561152f6127108261241f565b6011556010546040519081527fd20ab7c161b1f8ebfab00e747660c0fa31ae9123063e580b5be0aeab18623db290602001610c61565b6000611570826127b6565b5192915050565b6007546001600160a01b031633146115a15760405162461bcd60e51b8152600401610c159061346c565b8281146115f05760405162461bcd60e51b815260206004820152601a60248201527f41697264726f70206c656e67746873206d757374206d617463680000000000006044820152606401610c15565b60005b838110156116715761165f85858381811061161e57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906116339190612f97565b84848481811061165357634e487b7160e01b600052603260045260246000fd5b905060200201356128d8565b80611669816135c7565b9150506115f3565b5050505050565b600d546301000000900460ff166116f75760405162461bcd60e51b815260206004820152603960248201527f44726f70537061636553616c653a3a77686974656c6973744275793a2057686960448201527f74656c69737420427579206973206e6f74204163746976652e000000000000006064820152608401610c15565b6009548311156117195760405162461bcd60e51b8152600401610c15906134a1565b600a546117269084612517565b3410156117455760405162461bcd60e51b8152600401610c1590613420565b6117503383836128f2565b6117b55760405162461bcd60e51b815260206004820152603060248201527f44726f7073706163653a3a77686974656c6973744275793a205573657220697360448201526f081b9bdd081dda1a5d195b1a5cdd195960821b6064820152608401610c15565b600f54600160a01b900460ff1615611843573360009081526014602052604090205460ff16156118385760405162461bcd60e51b815260206004820152602860248201527f44726f7073706163653a3a77686974656c6973744275793a20416c72656164796044820152670818db185a5b595960c21b6064820152608401610c15565b61184333600161245f565b61184c83612523565b7f8714612a507e7fcd9f26d997e561a61611f4bad945c787b8865dc23823ef037b33604080516001600160a01b039092168252602082018690520160405180910390a1505050565b600c80546118a19061358c565b80601f01602080910402602001604051908101604052809291908181526020018280546118cd9061358c565b801561191a5780601f106118ef5761010080835404028352916020019161191a565b820191906000526020600020905b8154815290600101906020018083116118fd57829003601f168201915b505050505081565b60006001600160a01b03821661194b576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b03166000908152600460205260409020546001600160401b031690565b6007546001600160a01b0316331461199a5760405162461bcd60e51b8152600401610c159061346c565b6119a46000612978565b565b6007546001600160a01b031633146119d05760405162461bcd60e51b8152600401610c159061346c565b600d8054640100000000600160c01b0319166401000000006001600160a01b038481168202929092179283905560405192041681527fb470355146314037ce5186813b4b7c65bff2b87f98d44ff063570d0e22d65ba390602001610c61565b6007546001600160a01b03163314611a595760405162461bcd60e51b8152600401610c159061346c565b611a6281612523565b6040518181527fdb7b64a879507c32bda4d0cf22dee29ed875c7157ecbbc10fe11bf14fab06d1290602001610c61565b6007546001600160a01b03163314611abc5760405162461bcd60e51b8152600401610c159061346c565b600d805460ff62010000808304821615810262ff00001990931692909217928390556040517f38822fae85453c65b78e1b7d02e45cae5eb0d7961e34226fb29c49dab9d3a357936112519390049091161515815260200190565b606060028054610b249061358c565b6007546001600160a01b03163314611b4f5760405162461bcd60e51b8152600401610c159061346c565b60098190556040518181527f9ae30a041b5f2244849dc754c675b09aef4ad230b48995476fd6e6415d1fe8ab90602001610c61565b6001600160a01b038216331415611bae5760405163b06307db60e01b815260040160405180910390fd5b3360008181526006602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6007546001600160a01b03163314611c445760405162461bcd60e51b8152600401610c159061346c565b60008181526012602052604090205460ff16611cb55760405162461bcd60e51b815260206004820152602a60248201527f44726f7073706163653a3a636c6561725469636b65743a205469636b657420696044820152691cc81b9bdd081d5cd95960b21b6064820152608401610c15565b60008181526012602052604090819020805460ff19169055517f256e63760868166c3f047c49d3e1614c1ca6c620d715c552c54ddb4ba428719c90610c619083815260200190565b611d08848484612590565b611d14848484846129ca565b611d31576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6007546001600160a01b03163314611d615760405162461bcd60e51b8152600401610c159061346c565b600d805460ff6301000000808304821615810263ff0000001990931692909217928390556040517ffabb6e4b24bd8ac3a08555e569d13590c5006dc61e4aae65e74296d3df6759ed936112519390049091161515815260200190565b6060611dc88261242b565b611e2c5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610c15565b6000600c8054611e3b9061358c565b905011611e575760405180602001604052806000815250610b0f565b600c611e6283612ad9565b604051602001611e739291906132cf565b60405160208183030381529060405292915050565b6007546001600160a01b03163314611eb25760405162461bcd60e51b8152600401610c159061346c565b611eba610faf565b600b541015611f4c5760405162461bcd60e51b815260206004820152605260248201527f44726f70737061636553616c653a3a6368616e6765537570706c794c696d697460448201527f3a20537570706c79204c696d69742063616e277420626520726564756365642060648201527162656c6f7720746f74616c20737570706c7960701b608482015260a401610c15565b600b8190556040518181527f178f2d92de18f124251b08e25bacba56eda0716625c1e799fc6c8ed1ee7d1d0790602001610c61565b600d54610100900460ff16611fe45760405162461bcd60e51b815260206004820152602360248201527f44726f7073706163653a3a6275793a2053616c65206973206e6f7420616374696044820152623b329760e91b6064820152608401610c15565b6009548111156120535760405162461bcd60e51b815260206004820152603460248201527f44726f7073706163653a3a6275793a20546f6f206d616e7920746f6b656e73206044820152733337b91037b732903a3930b739b0b1ba34b7b71760611b6064820152608401610c15565b600a546120609082612517565b3410156120bd5760405162461bcd60e51b815260206004820152602560248201527f44726f7073706163653a3a6275793a20496e73756666696369656e742070617960448201526436b2b73a1760d91b6064820152608401610c15565b600d5460ff1661213c5732331461213c5760405162461bcd60e51b815260206004820152603760248201527f44726f7073706163653a3a6275793a20536d61727420636f6e7472616374732060448201527f617265206e6f7420616c6c6f77656420746f206275792e0000000000000000006064820152608401610c15565b61214581612523565b60408051338152602081018390527fe3d4187f6ca4248660cc0ac8b8056515bac4a8132be2eca31d6d0cc170722a7e9101610c61565b6007546001600160a01b031633146121a55760405162461bcd60e51b8152600401610c159061346c565b6007546040516001600160a01b03909116904780156108fc02916000818181858888f193505050501580156121de573d6000803e3d6000fd5b50565b6007546001600160a01b0316331461220b5760405162461bcd60e51b8152600401610c159061346c565b6001600160a01b03811661227b5760405162461bcd60e51b815260206004820152603160248201527f44726f70537061636553616c653a3a7365745469636b6574416464726573733a6044820152701024b73b30b634b21030b2323932b9b99760791b6064820152608401610c15565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f4846b8d14a603fbd3567c63384f41a947d787c004e59ce39ee755d0485ae5ed890602001610c61565b6007546001600160a01b031633146122f35760405162461bcd60e51b8152600401610c159061346c565b6001600160a01b0381166123585760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c15565b6121de81612978565b6007546001600160a01b0316331461238b5760405162461bcd60e51b8152600401610c159061346c565b600a8190556040518181527f25b1f9f6b6e61dfca5575239769e4450ed2e49176670837f5d1a82a9a2fc693f90602001610c61565b6007546001600160a01b031633146123ea5760405162461bcd60e51b8152600401610c159061346c565b60138190556040518181527f6be426d58d2fb0cea1f78182904380aac426a50029637dc9e9d2e40bc44ac05090602001610c61565b60006111c88284613549565b600080546001600160801b031682108015610b0f575050600090815260036020526040902054600160e01b900460ff161590565b6001600160a01b038216600081815260146020908152604091829020805460ff19168515159081179091558251938452908301527f9df634e89ddfd6892a56594ccd1a1971304a02d24cb197afdd540194c0b653a29101610fa3565b60008281526005602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60006111c8828461352a565b600b5461253882612532610faf565b90612bf2565b11156125865760405162461bcd60e51b815260206004820152601760248201527f4e6f7420656e6f75676820746f6b656e73206c6566742e0000000000000000006044820152606401610c15565b6121de33826128d8565b600061259b826127b6565b80519091506000906001600160a01b0316336001600160a01b031614806125c9575081516125c990336109fa565b806125e45750336125d984610ba7565b6001600160a01b0316145b90508061260457604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b0316146126395760405162a1148160e81b815260040160405180910390fd5b6001600160a01b03841661266057604051633a954ecd60e21b815260040160405180910390fd5b61267060008484600001516124bb565b6001600160a01b038581166000908152600460209081526040808320805467ffffffffffffffff198082166001600160401b0392831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600390945282852080546001600160e01b031916909417600160a01b429092169190910217909255908601808352912054909116612763576000546001600160801b031681101561276357825160008281526003602090815260409091208054918601516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b5082846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4611671565b60006111c88284613516565b60408051606081018252600080825260208201819052918101829052905482906001600160801b03168110156128bf57600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff161515918101829052906128bd5780516001600160a01b031615612854579392505050565b5060001901600081815260036020908152604091829020825160608101845290546001600160a01b038116808352600160a01b82046001600160401b031693830193909352600160e01b900460ff16151592810192909252156128b8579392505050565b612854565b505b604051636f96cda160e11b815260040160405180910390fd5b610ca0828260405180602001604052806000815250612bfe565b6040516bffffffffffffffffffffffff19606085901b166020820152600090819060340160405160208183030381529060405280519060200120905061296f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506013549150849050612c0b565b95945050505050565b600780546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006001600160a01b0384163b15612acd57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612a0e90339089908890889060040161334f565b602060405180830381600087803b158015612a2857600080fd5b505af1925050508015612a58575060408051601f3d908101601f19168201909252612a55918101906131d8565b60015b612ab3573d808015612a86576040519150601f19603f3d011682016040523d82523d6000602084013e612a8b565b606091505b508051612aab576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612ad1565b5060015b949350505050565b606081612afd5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612b275780612b11816135c7565b9150612b209050600a83613516565b9150612b01565b6000816001600160401b03811115612b4f57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612b79576020820181803683370190505b5090505b8415612ad157612b8e600183613549565b9150612b9b600a866135e2565b612ba69060306134fe565b60f81b818381518110612bc957634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350612beb600a86613516565b9450612b7d565b60006111c882846134fe565b610d2d8383836001612c21565b600082612c188584612da9565b14949350505050565b6000546001600160801b03166001600160a01b038516612c5357604051622e076360e81b815260040160405180910390fd5b83612c715760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260046020908152604080832080546001600160801b031981166001600160401b038083168c0181169182176801000000000000000067ffffffffffffffff1990941690921783900481168c018116909202179091558584526003909252822080546001600160e01b031916909317600160a01b42909216919091021790915581905b85811015612d835760405182906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4838015612d595750612d5760008884886129ca565b155b15612d77576040516368d2bf6b60e11b815260040160405180910390fd5b60019182019101612d02565b50600080546001600160801b0319166001600160801b0392909216919091179055611671565b600081815b8451811015612e23576000858281518110612dd957634e487b7160e01b600052603260045260246000fd5b60200260200101519050808311612dff5760008381526020829052604090209250612e10565b600081815260208490526040902092505b5080612e1b816135c7565b915050612dae565b509392505050565b828054612e379061358c565b90600052602060002090601f016020900481019282612e595760008555612e9f565b82601f10612e7257805160ff1916838001178555612e9f565b82800160010185558215612e9f579182015b82811115612e9f578251825591602001919060010190612e84565b50612eab929150612eaf565b5090565b5b80821115612eab5760008155600101612eb0565b60006001600160401b0380841115612ede57612ede613622565b604051601f8501601f19908116603f01168101908282118183101715612f0657612f06613622565b81604052809350858152868686011115612f1f57600080fd5b858560208301376000602087830101525050509392505050565b60008083601f840112612f4a578182fd5b5081356001600160401b03811115612f60578182fd5b6020830191508360208260051b8501011115612f7b57600080fd5b9250929050565b80358015158114612f9257600080fd5b919050565b600060208284031215612fa8578081fd5b81356111c881613638565b600060208284031215612fc4578081fd5b81516111c881613638565b60008060408385031215612fe1578081fd5b8235612fec81613638565b91506020830135612ffc81613638565b809150509250929050565b60008060006060848603121561301b578081fd5b833561302681613638565b9250602084013561303681613638565b929592945050506040919091013590565b6000806000806080858703121561305c578081fd5b843561306781613638565b9350602085013561307781613638565b92506040850135915060608501356001600160401b03811115613098578182fd5b8501601f810187136130a8578182fd5b6130b787823560208401612ec4565b91505092959194509250565b600080604083850312156130d5578182fd5b82356130e081613638565b91506130ee60208401612f82565b90509250929050565b60008060408385031215613109578182fd5b823561311481613638565b946020939093013593505050565b60008060008060408587031215613137578384fd5b84356001600160401b038082111561314d578586fd5b61315988838901612f39565b90965094506020870135915080821115613171578384fd5b5061317e87828801612f39565b95989497509550505050565b60006020828403121561319b578081fd5b6111c882612f82565b6000602082840312156131b5578081fd5b5035919050565b6000602082840312156131cd578081fd5b81356111c88161364d565b6000602082840312156131e9578081fd5b81516111c88161364d565b600060208284031215613205578081fd5b81356001600160401b0381111561321a578182fd5b8201601f8101841361322a578182fd5b612ad184823560208401612ec4565b60008060006040848603121561324d578081fd5b8335925060208401356001600160401b03811115613269578182fd5b61327586828701612f39565b9497909650939450505050565b60008060408385031215613294578182fd5b50508035926020909101359150565b600081518084526132bb816020860160208601613560565b601f01601f19169290920160200192915050565b60008084546132dd8161358c565b600182811680156132f5576001811461330657613332565b60ff19841687528287019450613332565b8886526020808720875b858110156133295781548a820152908401908201613310565b50505082870194505b505050508351613346818360208801613560565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090613382908301846132a3565b9695505050505050565b6020815260006111c860208301846132a3565b600060208083528184546133b28161358c565b808487015260406001808416600081146133d357600181146133e757613412565b60ff19851689840152606089019550613412565b898852868820885b8581101561340a5781548b82018601529083019088016133ef565b8a0184019650505b509398975050505050505050565b6020808252602c908201527f44726f7073706163653a3a70726573616c654275793a20496e7375666669636960408201526b32b73a103830bcb6b2b73a1760a11b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252603b908201527f44726f7073706163653a3a70726573616c654275793a20546f6f206d616e792060408201527f746f6b656e7320666f72206f6e65207472616e73616374696f6e2e0000000000606082015260800190565b60008219821115613511576135116135f6565b500190565b6000826135255761352561360c565b500490565b6000816000190483118215151615613544576135446135f6565b500290565b60008282101561355b5761355b6135f6565b500390565b60005b8381101561357b578181015183820152602001613563565b83811115611d315750506000910152565b600181811c908216806135a057607f821691505b602082108114156135c157634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156135db576135db6135f6565b5060010190565b6000826135f1576135f161360c565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146121de57600080fd5b6001600160e01b0319811681146121de57600080fdfea2646970667358221220513d47451cdfa280bf8f9cbd19b6673132a166ccf2d2fb638aff8f92af9acbae64736f6c6343000804003300000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000000000000005dc000000000000000000000000d11902466587415de497440d27045c09de26ce70000000000000000000000000856701083ed11a0d35bac3b769b4c8efe3330d170000000000000000000000007ba0a79ec30259e2792a43989edd97c6e40bb336000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000000000000000000000000000000000000000002b576f6d656e20616e6420576561706f6e7320536561736f6e2054776f3a20417274697269756d2057617273000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000657415754574f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002f68747470733a2f2f7374617469632e64726f7073706163652e6172742f6d657461646174612f7761772d73322f312f0000000000000000000000000000000000
Deployed Bytecode
0x6080604052600436106103855760003560e01c80636817c76c116101d1578063a22cb46511610102578063d96a094a116100a0578063ed9a5bbb1161006f578063ed9a5bbb14610a28578063f2fde38b14610a48578063f4a0a52814610a68578063f5aa406d14610a8857600080fd5b8063d96a094a14610987578063db2e21bc1461099a578063db4bec44146109af578063e985e9c5146109df57600080fd5b8063b89fe999116100dc578063b89fe99914610911578063c87b56dd14610926578063d44e357314610946578063d7e2875c1461096657600080fd5b8063a22cb465146108b1578063ab26320e146108d1578063b88d4fde146108f157600080fd5b8063819b25ba1161016f5780638ea5220f116101495780638ea5220f1461084657806395d89b4114610866578063996517cf1461087b5780639e6a1d7d1461089157600080fd5b8063819b25ba146107f357806389b0649b146108135780638da5cb5b1461082857600080fd5b806370a08231116101ab57806370a082311461076e578063715018a61461078e57806371efdc21146107a357806375796f76146107d357600080fd5b80636817c76c1461072457806368428a1b1461073a5780636c0360eb1461075957600080fd5b8063386bfc98116102b657806355f804b3116102545780636352211e116102235780636352211e146106b7578063646d7a7f146106d757806367243482146106f157806368124a6a1461071157600080fd5b806355f804b31461063757806357a8e3fe14610657578063591e194b146106775780635c4e7e061461069757600080fd5b806342842e0e1161029057806342842e0e146105af5780634a7d80b3146105cf5780634f6ccce7146105f757806353135ca01461061757600080fd5b8063386bfc98146105635780633ad7f56c146105795780633ccfd60b1461059a57600080fd5b806318160ddd1161032357806323b872dd116102fd57806323b872dd146104ee5780632f745c591461050e57806330d1980c1461052e5780633100a5351461054e57600080fd5b806318160ddd1461049557806319d1997a146104b85780631f53ac02146104ce57600080fd5b806308e992871161035f57806308e992871461042057806309499f5314610442578063095ea7b3146104625780630983061c1461048257600080fd5b806301ffc9a71461039157806306fdde03146103c6578063081812fc146103e857600080fd5b3661038c57005b600080fd5b34801561039d57600080fd5b506103b16103ac3660046131bc565b610aa8565b60405190151581526020015b60405180910390f35b3480156103d257600080fd5b506103db610b15565b6040516103bd919061338c565b3480156103f457600080fd5b506104086104033660046131a4565b610ba7565b6040516001600160a01b0390911681526020016103bd565b34801561042c57600080fd5b5061044061043b36600461318a565b610beb565b005b34801561044e57600080fd5b5061044061045d3660046130c3565b610c6c565b34801561046e57600080fd5b5061044061047d3660046130f7565b610ca4565b610440610490366004613282565b610d32565b3480156104a157600080fd5b506104aa610faf565b6040519081526020016103bd565b3480156104c457600080fd5b506104aa600b5481565b3480156104da57600080fd5b506104406104e9366004612f97565b610fce565b3480156104fa57600080fd5b50610440610509366004613007565b611046565b34801561051a57600080fd5b506104aa6105293660046130f7565b611051565b34801561053a57600080fd5b506104086105493660046130f7565b61114d565b34801561055a57600080fd5b506104406111cf565b34801561056f57600080fd5b506104aa60135481565b34801561058557600080fd5b50600d546103b1906301000000900460ff1681565b3480156105a657600080fd5b5061044061125b565b3480156105bb57600080fd5b506104406105ca366004613007565b611342565b3480156105db57600080fd5b50600d546104089064010000000090046001600160a01b031681565b34801561060357600080fd5b506104aa6106123660046131a4565b61135d565b34801561062357600080fd5b50600d546103b19062010000900460ff1681565b34801561064357600080fd5b506104406106523660046131f4565b611407565b34801561066357600080fd5b50600f54610408906001600160a01b031681565b34801561068357600080fd5b5061044061069236600461318a565b611475565b3480156106a357600080fd5b506104406106b23660046131a4565b6114f4565b3480156106c357600080fd5b506104086106d23660046131a4565b611565565b3480156106e357600080fd5b50600d546103b19060ff1681565b3480156106fd57600080fd5b5061044061070c366004613122565b611577565b61044061071f366004613239565b611678565b34801561073057600080fd5b506104aa600a5481565b34801561074657600080fd5b50600d546103b190610100900460ff1681565b34801561076557600080fd5b506103db611894565b34801561077a57600080fd5b506104aa610789366004612f97565b611922565b34801561079a57600080fd5b50610440611970565b3480156107af57600080fd5b506103b16107be3660046131a4565b60126020526000908152604090205460ff1681565b3480156107df57600080fd5b506104406107ee366004612f97565b6119a6565b3480156107ff57600080fd5b5061044061080e3660046131a4565b611a2f565b34801561081f57600080fd5b50610440611a92565b34801561083457600080fd5b506007546001600160a01b0316610408565b34801561085257600080fd5b50600e54610408906001600160a01b031681565b34801561087257600080fd5b506103db611b16565b34801561088757600080fd5b506104aa60095481565b34801561089d57600080fd5b506104406108ac3660046131a4565b611b25565b3480156108bd57600080fd5b506104406108cc3660046130c3565b611b84565b3480156108dd57600080fd5b506104406108ec3660046131a4565b611c1a565b3480156108fd57600080fd5b5061044061090c366004613047565b611cfd565b34801561091d57600080fd5b50610440611d37565b34801561093257600080fd5b506103db6109413660046131a4565b611dbd565b34801561095257600080fd5b506104406109613660046131a4565b611e88565b34801561097257600080fd5b50600f546103b190600160a01b900460ff1681565b6104406109953660046131a4565b611f81565b3480156109a657600080fd5b5061044061217b565b3480156109bb57600080fd5b506103b16109ca366004612f97565b60146020526000908152604090205460ff1681565b3480156109eb57600080fd5b506103b16109fa366004612fcf565b6001600160a01b03918216600090815260066020908152604080832093909416825291909152205460ff1690565b348015610a3457600080fd5b50610440610a43366004612f97565b6121e1565b348015610a5457600080fd5b50610440610a63366004612f97565b6122c9565b348015610a7457600080fd5b50610440610a833660046131a4565b612361565b348015610a9457600080fd5b50610440610aa33660046131a4565b6123c0565b60006001600160e01b031982166380ac58cd60e01b1480610ad957506001600160e01b03198216635b5e139f60e01b145b80610af457506001600160e01b0319821663780e9d6360e01b145b80610b0f57506301ffc9a760e01b6001600160e01b03198316145b92915050565b606060018054610b249061358c565b80601f0160208091040260200160405190810160405280929190818152602001828054610b509061358c565b8015610b9d5780601f10610b7257610100808354040283529160200191610b9d565b820191906000526020600020905b815481529060010190602001808311610b8057829003601f168201915b5050505050905090565b6000610bb28261242b565b610bcf576040516333d1c03960e21b815260040160405180910390fd5b506000908152600560205260409020546001600160a01b031690565b6007546001600160a01b03163314610c1e5760405162461bcd60e51b8152600401610c159061346c565b60405180910390fd5b600d805460ff191682151590811790915560405160ff909116151581527f2a5bfbb68782e57b3242e612145304c845af3404e2d328a12dd2e7c078cd0117906020015b60405180910390a150565b6007546001600160a01b03163314610c965760405162461bcd60e51b8152600401610c159061346c565b610ca0828261245f565b5050565b6000610caf82611565565b9050806001600160a01b0316836001600160a01b03161415610ce45760405163250fdee360e21b815260040160405180910390fd5b336001600160a01b03821614801590610d045750610d0281336109fa565b155b15610d22576040516367d9dca160e11b815260040160405180910390fd5b610d2d8383836124bb565b505050565b600d5462010000900460ff16610da05760405162461bcd60e51b815260206004820152602d60248201527f44726f7073706163653a3a70726573616c654275793a2050726573616c65206960448201526c39903737ba1020b1ba34bb329760991b6064820152608401610c15565b33600f546040516331a9108f60e11b8152600481018590526001600160a01b039283169290911690636352211e9060240160206040518083038186803b158015610de957600080fd5b505afa158015610dfd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e219190612fb3565b6001600160a01b031614610e865760405162461bcd60e51b815260206004820152602660248201527f44726f7073706163653a3a70726573616c654275793a20696e76616c6964207460448201526534b1b5b2ba1760d11b6064820152608401610c15565b60008281526012602052604090205460ff1615610ef95760405162461bcd60e51b815260206004820152602b60248201527f44726f7073706163653a3a70726573616c654275793a205469636b657420616c60448201526a3932b0b23c903ab9b2b21760a91b6064820152608401610c15565b600954811115610f1b5760405162461bcd60e51b8152600401610c15906134a1565b600a54610f289082612517565b341015610f475760405162461bcd60e51b8152600401610c1590613420565b6000828152601260205260409020805460ff19166001179055610f6981612523565b60408051338152602081018490529081018290527fb77d41b776d1d5cc75b500402614335da616afa8aa95b49325e22db7f1ca86cc906060015b60405180910390a15050565b6000546001600160801b03600160801b82048116918116919091031690565b6007546001600160a01b03163314610ff85760405162461bcd60e51b8152600401610c159061346c565b600e80546001600160a01b0319166001600160a01b0383169081179091556040519081527f268c00f4ec08b34fdde24b52e47a09d62f3f3837eb3b8ac7206cefb3bb5e534590602001610c61565b610d2d838383612590565b600061105c83611922565b821061107b576040516306ed618760e11b815260040160405180910390fd5b600080546001600160801b03169080805b8381101561114757600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff1615801592820192909252906110f3575061113f565b80516001600160a01b03161561110857805192505b876001600160a01b0316836001600160a01b0316141561113d578684141561113657509350610b0f92505050565b6001909301925b505b60010161108c565b50600080fd5b6040516331a9108f60e11b8152600481018290526000906001600160a01b03841690636352211e9060240160206040518083038186803b15801561119057600080fd5b505afa1580156111a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c89190612fb3565b9392505050565b6007546001600160a01b031633146111f95760405162461bcd60e51b8152600401610c159061346c565b600d805460ff610100808304821615810261ff001990931692909217928390556040517f5a454f976028c400c4159ac85c61452441fcf06b9888c7c780c5980e3c3123dd936112519390049091161515815260200190565b60405180910390a1565b6007546001600160a01b031633146112855760405162461bcd60e51b8152600401610c159061346c565b600e5460105447916001600160a01b0316906108fc906112b490612710906112ae908690612517565b906127aa565b6040518115909202916000818181858888f193505050501580156112dc573d6000803e3d6000fd5b50600d60049054906101000a90046001600160a01b03166001600160a01b03166108fc61131a6127106112ae6011548661251790919063ffffffff16565b6040518115909202916000818181858888f19350505050158015610ca0573d6000803e3d6000fd5b610d2d83838360405180602001604052806000815250611cfd565b600080546001600160801b031681805b828110156113ed57600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff161515918101829052906113e457858314156113dd5750949350505050565b6001909201915b5060010161136d565b506040516329c8c00760e21b815260040160405180910390fd5b6007546001600160a01b031633146114315760405162461bcd60e51b8152600401610c159061346c565b805161144490600c906020840190612e2b565b507f5411e8ebf1636d9e83d5fc4900bf80cbac82e8790da2a4c94db4895e889eedf6600c604051610c61919061339f565b6007546001600160a01b0316331461149f5760405162461bcd60e51b8152600401610c159061346c565b600f805460ff60a01b1916600160a01b8315158102919091179182905560405160ff9190920416151581527fc6e0fb794d60d245727554ed563b17ec5cd901c15ee395b10535ce370b1bdccd90602001610c61565b6007546001600160a01b0316331461151e5760405162461bcd60e51b8152600401610c159061346c565b601081905561152f6127108261241f565b6011556010546040519081527fd20ab7c161b1f8ebfab00e747660c0fa31ae9123063e580b5be0aeab18623db290602001610c61565b6000611570826127b6565b5192915050565b6007546001600160a01b031633146115a15760405162461bcd60e51b8152600401610c159061346c565b8281146115f05760405162461bcd60e51b815260206004820152601a60248201527f41697264726f70206c656e67746873206d757374206d617463680000000000006044820152606401610c15565b60005b838110156116715761165f85858381811061161e57634e487b7160e01b600052603260045260246000fd5b90506020020160208101906116339190612f97565b84848481811061165357634e487b7160e01b600052603260045260246000fd5b905060200201356128d8565b80611669816135c7565b9150506115f3565b5050505050565b600d546301000000900460ff166116f75760405162461bcd60e51b815260206004820152603960248201527f44726f70537061636553616c653a3a77686974656c6973744275793a2057686960448201527f74656c69737420427579206973206e6f74204163746976652e000000000000006064820152608401610c15565b6009548311156117195760405162461bcd60e51b8152600401610c15906134a1565b600a546117269084612517565b3410156117455760405162461bcd60e51b8152600401610c1590613420565b6117503383836128f2565b6117b55760405162461bcd60e51b815260206004820152603060248201527f44726f7073706163653a3a77686974656c6973744275793a205573657220697360448201526f081b9bdd081dda1a5d195b1a5cdd195960821b6064820152608401610c15565b600f54600160a01b900460ff1615611843573360009081526014602052604090205460ff16156118385760405162461bcd60e51b815260206004820152602860248201527f44726f7073706163653a3a77686974656c6973744275793a20416c72656164796044820152670818db185a5b595960c21b6064820152608401610c15565b61184333600161245f565b61184c83612523565b7f8714612a507e7fcd9f26d997e561a61611f4bad945c787b8865dc23823ef037b33604080516001600160a01b039092168252602082018690520160405180910390a1505050565b600c80546118a19061358c565b80601f01602080910402602001604051908101604052809291908181526020018280546118cd9061358c565b801561191a5780601f106118ef5761010080835404028352916020019161191a565b820191906000526020600020905b8154815290600101906020018083116118fd57829003601f168201915b505050505081565b60006001600160a01b03821661194b576040516323d3ad8160e21b815260040160405180910390fd5b506001600160a01b03166000908152600460205260409020546001600160401b031690565b6007546001600160a01b0316331461199a5760405162461bcd60e51b8152600401610c159061346c565b6119a46000612978565b565b6007546001600160a01b031633146119d05760405162461bcd60e51b8152600401610c159061346c565b600d8054640100000000600160c01b0319166401000000006001600160a01b038481168202929092179283905560405192041681527fb470355146314037ce5186813b4b7c65bff2b87f98d44ff063570d0e22d65ba390602001610c61565b6007546001600160a01b03163314611a595760405162461bcd60e51b8152600401610c159061346c565b611a6281612523565b6040518181527fdb7b64a879507c32bda4d0cf22dee29ed875c7157ecbbc10fe11bf14fab06d1290602001610c61565b6007546001600160a01b03163314611abc5760405162461bcd60e51b8152600401610c159061346c565b600d805460ff62010000808304821615810262ff00001990931692909217928390556040517f38822fae85453c65b78e1b7d02e45cae5eb0d7961e34226fb29c49dab9d3a357936112519390049091161515815260200190565b606060028054610b249061358c565b6007546001600160a01b03163314611b4f5760405162461bcd60e51b8152600401610c159061346c565b60098190556040518181527f9ae30a041b5f2244849dc754c675b09aef4ad230b48995476fd6e6415d1fe8ab90602001610c61565b6001600160a01b038216331415611bae5760405163b06307db60e01b815260040160405180910390fd5b3360008181526006602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6007546001600160a01b03163314611c445760405162461bcd60e51b8152600401610c159061346c565b60008181526012602052604090205460ff16611cb55760405162461bcd60e51b815260206004820152602a60248201527f44726f7073706163653a3a636c6561725469636b65743a205469636b657420696044820152691cc81b9bdd081d5cd95960b21b6064820152608401610c15565b60008181526012602052604090819020805460ff19169055517f256e63760868166c3f047c49d3e1614c1ca6c620d715c552c54ddb4ba428719c90610c619083815260200190565b611d08848484612590565b611d14848484846129ca565b611d31576040516368d2bf6b60e11b815260040160405180910390fd5b50505050565b6007546001600160a01b03163314611d615760405162461bcd60e51b8152600401610c159061346c565b600d805460ff6301000000808304821615810263ff0000001990931692909217928390556040517ffabb6e4b24bd8ac3a08555e569d13590c5006dc61e4aae65e74296d3df6759ed936112519390049091161515815260200190565b6060611dc88261242b565b611e2c5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610c15565b6000600c8054611e3b9061358c565b905011611e575760405180602001604052806000815250610b0f565b600c611e6283612ad9565b604051602001611e739291906132cf565b60405160208183030381529060405292915050565b6007546001600160a01b03163314611eb25760405162461bcd60e51b8152600401610c159061346c565b611eba610faf565b600b541015611f4c5760405162461bcd60e51b815260206004820152605260248201527f44726f70737061636553616c653a3a6368616e6765537570706c794c696d697460448201527f3a20537570706c79204c696d69742063616e277420626520726564756365642060648201527162656c6f7720746f74616c20737570706c7960701b608482015260a401610c15565b600b8190556040518181527f178f2d92de18f124251b08e25bacba56eda0716625c1e799fc6c8ed1ee7d1d0790602001610c61565b600d54610100900460ff16611fe45760405162461bcd60e51b815260206004820152602360248201527f44726f7073706163653a3a6275793a2053616c65206973206e6f7420616374696044820152623b329760e91b6064820152608401610c15565b6009548111156120535760405162461bcd60e51b815260206004820152603460248201527f44726f7073706163653a3a6275793a20546f6f206d616e7920746f6b656e73206044820152733337b91037b732903a3930b739b0b1ba34b7b71760611b6064820152608401610c15565b600a546120609082612517565b3410156120bd5760405162461bcd60e51b815260206004820152602560248201527f44726f7073706163653a3a6275793a20496e73756666696369656e742070617960448201526436b2b73a1760d91b6064820152608401610c15565b600d5460ff1661213c5732331461213c5760405162461bcd60e51b815260206004820152603760248201527f44726f7073706163653a3a6275793a20536d61727420636f6e7472616374732060448201527f617265206e6f7420616c6c6f77656420746f206275792e0000000000000000006064820152608401610c15565b61214581612523565b60408051338152602081018390527fe3d4187f6ca4248660cc0ac8b8056515bac4a8132be2eca31d6d0cc170722a7e9101610c61565b6007546001600160a01b031633146121a55760405162461bcd60e51b8152600401610c159061346c565b6007546040516001600160a01b03909116904780156108fc02916000818181858888f193505050501580156121de573d6000803e3d6000fd5b50565b6007546001600160a01b0316331461220b5760405162461bcd60e51b8152600401610c159061346c565b6001600160a01b03811661227b5760405162461bcd60e51b815260206004820152603160248201527f44726f70537061636553616c653a3a7365745469636b6574416464726573733a6044820152701024b73b30b634b21030b2323932b9b99760791b6064820152608401610c15565b600f80546001600160a01b0319166001600160a01b0383169081179091556040519081527f4846b8d14a603fbd3567c63384f41a947d787c004e59ce39ee755d0485ae5ed890602001610c61565b6007546001600160a01b031633146122f35760405162461bcd60e51b8152600401610c159061346c565b6001600160a01b0381166123585760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c15565b6121de81612978565b6007546001600160a01b0316331461238b5760405162461bcd60e51b8152600401610c159061346c565b600a8190556040518181527f25b1f9f6b6e61dfca5575239769e4450ed2e49176670837f5d1a82a9a2fc693f90602001610c61565b6007546001600160a01b031633146123ea5760405162461bcd60e51b8152600401610c159061346c565b60138190556040518181527f6be426d58d2fb0cea1f78182904380aac426a50029637dc9e9d2e40bc44ac05090602001610c61565b60006111c88284613549565b600080546001600160801b031682108015610b0f575050600090815260036020526040902054600160e01b900460ff161590565b6001600160a01b038216600081815260146020908152604091829020805460ff19168515159081179091558251938452908301527f9df634e89ddfd6892a56594ccd1a1971304a02d24cb197afdd540194c0b653a29101610fa3565b60008281526005602052604080822080546001600160a01b0319166001600160a01b0387811691821790925591518593918516917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591a4505050565b60006111c8828461352a565b600b5461253882612532610faf565b90612bf2565b11156125865760405162461bcd60e51b815260206004820152601760248201527f4e6f7420656e6f75676820746f6b656e73206c6566742e0000000000000000006044820152606401610c15565b6121de33826128d8565b600061259b826127b6565b80519091506000906001600160a01b0316336001600160a01b031614806125c9575081516125c990336109fa565b806125e45750336125d984610ba7565b6001600160a01b0316145b90508061260457604051632ce44b5f60e11b815260040160405180910390fd5b846001600160a01b031682600001516001600160a01b0316146126395760405162a1148160e81b815260040160405180910390fd5b6001600160a01b03841661266057604051633a954ecd60e21b815260040160405180910390fd5b61267060008484600001516124bb565b6001600160a01b038581166000908152600460209081526040808320805467ffffffffffffffff198082166001600160401b0392831660001901831617909255898616808652838620805493841693831660019081018416949094179055898652600390945282852080546001600160e01b031916909417600160a01b429092169190910217909255908601808352912054909116612763576000546001600160801b031681101561276357825160008281526003602090815260409091208054918601516001600160401b0316600160a01b026001600160e01b03199092166001600160a01b03909316929092171790555b5082846001600160a01b0316866001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4611671565b60006111c88284613516565b60408051606081018252600080825260208201819052918101829052905482906001600160801b03168110156128bf57600081815260036020908152604091829020825160608101845290546001600160a01b0381168252600160a01b81046001600160401b031692820192909252600160e01b90910460ff161515918101829052906128bd5780516001600160a01b031615612854579392505050565b5060001901600081815260036020908152604091829020825160608101845290546001600160a01b038116808352600160a01b82046001600160401b031693830193909352600160e01b900460ff16151592810192909252156128b8579392505050565b612854565b505b604051636f96cda160e11b815260040160405180910390fd5b610ca0828260405180602001604052806000815250612bfe565b6040516bffffffffffffffffffffffff19606085901b166020820152600090819060340160405160208183030381529060405280519060200120905061296f848480806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250506013549150849050612c0b565b95945050505050565b600780546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b60006001600160a01b0384163b15612acd57604051630a85bd0160e11b81526001600160a01b0385169063150b7a0290612a0e90339089908890889060040161334f565b602060405180830381600087803b158015612a2857600080fd5b505af1925050508015612a58575060408051601f3d908101601f19168201909252612a55918101906131d8565b60015b612ab3573d808015612a86576040519150601f19603f3d011682016040523d82523d6000602084013e612a8b565b606091505b508051612aab576040516368d2bf6b60e11b815260040160405180910390fd5b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050612ad1565b5060015b949350505050565b606081612afd5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612b275780612b11816135c7565b9150612b209050600a83613516565b9150612b01565b6000816001600160401b03811115612b4f57634e487b7160e01b600052604160045260246000fd5b6040519080825280601f01601f191660200182016040528015612b79576020820181803683370190505b5090505b8415612ad157612b8e600183613549565b9150612b9b600a866135e2565b612ba69060306134fe565b60f81b818381518110612bc957634e487b7160e01b600052603260045260246000fd5b60200101906001600160f81b031916908160001a905350612beb600a86613516565b9450612b7d565b60006111c882846134fe565b610d2d8383836001612c21565b600082612c188584612da9565b14949350505050565b6000546001600160801b03166001600160a01b038516612c5357604051622e076360e81b815260040160405180910390fd5b83612c715760405163b562e8dd60e01b815260040160405180910390fd5b6001600160a01b038516600081815260046020908152604080832080546001600160801b031981166001600160401b038083168c0181169182176801000000000000000067ffffffffffffffff1990941690921783900481168c018116909202179091558584526003909252822080546001600160e01b031916909317600160a01b42909216919091021790915581905b85811015612d835760405182906001600160a01b038916906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4838015612d595750612d5760008884886129ca565b155b15612d77576040516368d2bf6b60e11b815260040160405180910390fd5b60019182019101612d02565b50600080546001600160801b0319166001600160801b0392909216919091179055611671565b600081815b8451811015612e23576000858281518110612dd957634e487b7160e01b600052603260045260246000fd5b60200260200101519050808311612dff5760008381526020829052604090209250612e10565b600081815260208490526040902092505b5080612e1b816135c7565b915050612dae565b509392505050565b828054612e379061358c565b90600052602060002090601f016020900481019282612e595760008555612e9f565b82601f10612e7257805160ff1916838001178555612e9f565b82800160010185558215612e9f579182015b82811115612e9f578251825591602001919060010190612e84565b50612eab929150612eaf565b5090565b5b80821115612eab5760008155600101612eb0565b60006001600160401b0380841115612ede57612ede613622565b604051601f8501601f19908116603f01168101908282118183101715612f0657612f06613622565b81604052809350858152868686011115612f1f57600080fd5b858560208301376000602087830101525050509392505050565b60008083601f840112612f4a578182fd5b5081356001600160401b03811115612f60578182fd5b6020830191508360208260051b8501011115612f7b57600080fd5b9250929050565b80358015158114612f9257600080fd5b919050565b600060208284031215612fa8578081fd5b81356111c881613638565b600060208284031215612fc4578081fd5b81516111c881613638565b60008060408385031215612fe1578081fd5b8235612fec81613638565b91506020830135612ffc81613638565b809150509250929050565b60008060006060848603121561301b578081fd5b833561302681613638565b9250602084013561303681613638565b929592945050506040919091013590565b6000806000806080858703121561305c578081fd5b843561306781613638565b9350602085013561307781613638565b92506040850135915060608501356001600160401b03811115613098578182fd5b8501601f810187136130a8578182fd5b6130b787823560208401612ec4565b91505092959194509250565b600080604083850312156130d5578182fd5b82356130e081613638565b91506130ee60208401612f82565b90509250929050565b60008060408385031215613109578182fd5b823561311481613638565b946020939093013593505050565b60008060008060408587031215613137578384fd5b84356001600160401b038082111561314d578586fd5b61315988838901612f39565b90965094506020870135915080821115613171578384fd5b5061317e87828801612f39565b95989497509550505050565b60006020828403121561319b578081fd5b6111c882612f82565b6000602082840312156131b5578081fd5b5035919050565b6000602082840312156131cd578081fd5b81356111c88161364d565b6000602082840312156131e9578081fd5b81516111c88161364d565b600060208284031215613205578081fd5b81356001600160401b0381111561321a578182fd5b8201601f8101841361322a578182fd5b612ad184823560208401612ec4565b60008060006040848603121561324d578081fd5b8335925060208401356001600160401b03811115613269578182fd5b61327586828701612f39565b9497909650939450505050565b60008060408385031215613294578182fd5b50508035926020909101359150565b600081518084526132bb816020860160208601613560565b601f01601f19169290920160200192915050565b60008084546132dd8161358c565b600182811680156132f5576001811461330657613332565b60ff19841687528287019450613332565b8886526020808720875b858110156133295781548a820152908401908201613310565b50505082870194505b505050508351613346818360208801613560565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090613382908301846132a3565b9695505050505050565b6020815260006111c860208301846132a3565b600060208083528184546133b28161358c565b808487015260406001808416600081146133d357600181146133e757613412565b60ff19851689840152606089019550613412565b898852868820885b8581101561340a5781548b82018601529083019088016133ef565b8a0184019650505b509398975050505050505050565b6020808252602c908201527f44726f7073706163653a3a70726573616c654275793a20496e7375666669636960408201526b32b73a103830bcb6b2b73a1760a11b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b6020808252603b908201527f44726f7073706163653a3a70726573616c654275793a20546f6f206d616e792060408201527f746f6b656e7320666f72206f6e65207472616e73616374696f6e2e0000000000606082015260800190565b60008219821115613511576135116135f6565b500190565b6000826135255761352561360c565b500490565b6000816000190483118215151615613544576135446135f6565b500290565b60008282101561355b5761355b6135f6565b500390565b60005b8381101561357b578181015183820152602001613563565b83811115611d315750506000910152565b600181811c908216806135a057607f821691505b602082108114156135c157634e487b7160e01b600052602260045260246000fd5b50919050565b60006000198214156135db576135db6135f6565b5060010190565b6000826135f1576135f161360c565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b03811681146121de57600080fd5b6001600160e01b0319811681146121de57600080fdfea2646970667358221220513d47451cdfa280bf8f9cbd19b6673132a166ccf2d2fb638aff8f92af9acbae64736f6c63430008040033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000000000000005dc000000000000000000000000d11902466587415de497440d27045c09de26ce70000000000000000000000000856701083ed11a0d35bac3b769b4c8efe3330d170000000000000000000000007ba0a79ec30259e2792a43989edd97c6e40bb336000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000001a000000000000000000000000000000000000000000000000000000000000001e0000000000000000000000000000000000000000000000000000000000000002b576f6d656e20616e6420576561706f6e7320536561736f6e2054776f3a20417274697269756d2057617273000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000657415754574f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002f68747470733a2f2f7374617469632e64726f7073706163652e6172742f6d657461646174612f7761772d73322f312f0000000000000000000000000000000000
-----Decoded View---------------
Arg [0] : _supplyLimit (uint256): 100000
Arg [1] : _mintLimit (uint256): 50
Arg [2] : _mintPrice (uint256): 50000000000000000
Arg [3] : _devSaleShare (uint256): 1500
Arg [4] : _withdrawalWallet (address): 0xd11902466587415De497440D27045c09De26cE70
Arg [5] : _devWallet (address): 0x856701083eD11A0D35bAc3B769B4c8efE3330d17
Arg [6] : _ticketAddress (address): 0x7ba0A79eC30259E2792A43989EdD97c6E40Bb336
Arg [7] : _name (string): Women and Weapons Season Two: Artirium Wars
Arg [8] : _ticker (string): WAWTWO
Arg [9] : _baseURI (string): https://static.dropspace.art/metadata/waw-s2/1/
-----Encoded View---------------
18 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000186a0
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000032
Arg [2] : 00000000000000000000000000000000000000000000000000b1a2bc2ec50000
Arg [3] : 00000000000000000000000000000000000000000000000000000000000005dc
Arg [4] : 000000000000000000000000d11902466587415de497440d27045c09de26ce70
Arg [5] : 000000000000000000000000856701083ed11a0d35bac3b769b4c8efe3330d17
Arg [6] : 0000000000000000000000007ba0a79ec30259e2792a43989edd97c6e40bb336
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000140
Arg [8] : 00000000000000000000000000000000000000000000000000000000000001a0
Arg [9] : 00000000000000000000000000000000000000000000000000000000000001e0
Arg [10] : 000000000000000000000000000000000000000000000000000000000000002b
Arg [11] : 576f6d656e20616e6420576561706f6e7320536561736f6e2054776f3a204172
Arg [12] : 74697269756d2057617273000000000000000000000000000000000000000000
Arg [13] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [14] : 57415754574f0000000000000000000000000000000000000000000000000000
Arg [15] : 000000000000000000000000000000000000000000000000000000000000002f
Arg [16] : 68747470733a2f2f7374617469632e64726f7073706163652e6172742f6d6574
Arg [17] : 61646174612f7761772d73322f312f0000000000000000000000000000000000
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.