Feature Tip: Add private address tag to any address under My Name Tag !
ERC-1155
NFT
Overview
Max Total Supply
6,000
Holders
1,344
Market
Volume (24H)
N/A
Min Price (24H)
N/A
Max Price (24H)
N/A
Other Info
Token Contract
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
RedVillagePortal
Compiler Version
v0.8.9+commit.e5eed63a
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.6; import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol"; import { ERC1155, ERC1155Supply } from "@openzeppelin/contracts/token/ERC1155/extensions/ERC1155Supply.sol"; import { TokenHolder } from "./PortalHelpers.sol"; // // +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ // |T| |h| |e| |R| |e| |d| |V| |i| |l| |l| |a| |g| |e| // +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ +-+ // // // The Red Village + Pellar 2022 // contract RedVillagePortal is ERC1155Supply, Ownable { using TokenHolder for TokenHolder.Holders; struct TokenBalance { uint16[] paymentRatios; address[] paymentWallets; } struct TokenConfig { address TEAM_WALLET; uint256 MAX_PUBLIC_SALE_SUPPLY; uint256 MAX_PRESALE_SUPPLY; uint256 MAX_TEAM_SUPPLY; uint256 MAX_PUBLIC_PER_WALLET; uint256 MAX_PUBLIC_PER_TXN; uint256 MAX_PRESALE_PER_WALLET; uint256 MAX_PRESALE_PER_TXN; uint256 PRICE; string baseURI; } struct TokenWhitelist { uint8[] standards; // 0 -> 721, 1 -> 1155 uint256[] erc1155Ids; address[] contracts; // external contracts mapping(address => uint256) allocated; } struct TokenInfo { bool salesActive; bool presalesActive; bool teamClaimed; uint256 presaleClaimed; uint256 publicClaimed; TokenConfig config; } // variables mapping(uint256 => bool) public tradingPaused; mapping(uint256 => TokenInfo) public tokens; mapping(uint256 => TokenWhitelist) whitelists; mapping(uint256 => TokenHolder.Holders) holders; mapping(uint256 => TokenBalance) tokenBalances; constructor() ERC1155("") { TokenConfig storage config = tokens[1].config; config.MAX_PUBLIC_SALE_SUPPLY = 5965; // MAX_PUBLIC_SALE_SUPPLY + MAX_TEAM_SUPPLY = MAX_SUPPLY config.MAX_PRESALE_SUPPLY = 2000; config.MAX_TEAM_SUPPLY = 35; config.MAX_PUBLIC_PER_WALLET = 28; config.MAX_PUBLIC_PER_TXN = 14; config.MAX_PRESALE_PER_WALLET = 0; config.MAX_PRESALE_PER_TXN = 0; config.PRICE = 0.1 ether; config.TEAM_WALLET = 0xCD38B6d9c4b12654aD06Aae2842a0FC3D861188b; config.baseURI = ""; tokenBalances[1].paymentRatios = [900, 100]; tokenBalances[1].paymentWallets = [0xCBf7f6b967c2314Ed0694D39512AA18AD4d01878, 0x909680a5E46a3401D4dD75148B61E129451fa266]; } /* User */ function presaleClaim(uint256 _tokenId, uint16 _amount) external payable { TokenInfo storage token = tokens[_tokenId]; TokenConfig memory config = token.config; require(token.presalesActive, "Claim is not active"); require(tx.origin == msg.sender, "Not allowed"); require(tokenEligible(_tokenId, msg.sender) || whitelistAllocated(_tokenId, msg.sender) >= _amount, "Not eligible"); require(whitelistAllocated(_tokenId, msg.sender) == 0 || whitelistAllocated(_tokenId, msg.sender) >= _amount, "Exceed max"); require(config.MAX_PRESALE_PER_TXN == 0 || _amount <= config.MAX_PRESALE_PER_TXN, "Exceed max"); require(config.MAX_PRESALE_PER_WALLET == 0 || balanceOf(msg.sender, _tokenId) + _amount <= config.MAX_PRESALE_PER_WALLET, "Exceed max"); require(token.presaleClaimed + _amount <= config.MAX_PRESALE_SUPPLY, "Exceed total"); require(msg.value >= (_amount * config.PRICE), "Ether value incorrect"); if (whitelistAllocated(_tokenId, msg.sender) >= _amount) { whitelists[_tokenId].allocated[msg.sender] -= _amount; } _mint(msg.sender, _tokenId, _amount, ""); tokens[_tokenId].presaleClaimed += _amount; } function claim(uint256 _tokenId, uint16 _amount) external payable { TokenInfo storage token = tokens[_tokenId]; TokenConfig memory config = token.config; require(token.salesActive, "Claim is not active"); require(tx.origin == msg.sender, "Not allowed"); require(_amount <= config.MAX_PUBLIC_PER_TXN, "Exceed max"); require(balanceOf(msg.sender, _tokenId) + _amount <= config.MAX_PUBLIC_PER_WALLET, "Exceed max"); require(token.publicClaimed + token.presaleClaimed + _amount <= config.MAX_PUBLIC_SALE_SUPPLY, "Exceed total"); require(msg.value >= (_amount * config.PRICE), "Ether value incorrect"); _mint(msg.sender, _tokenId, _amount, ""); token.publicClaimed += _amount; } /* View */ function whitelistAllocated(uint256 _tokenId, address _account) public view returns (uint256) { return whitelists[_tokenId].allocated[_account]; } function tokenEligible(uint256 _tokenId, address _account) public view returns (bool) { uint256 size = whitelists[_tokenId].standards.length; for (uint256 i = 0; i < size; i++) { if (whitelists[_tokenId].standards[i] == 0 && IERC721(whitelists[_tokenId].contracts[i]).balanceOf(_account) > 0) { return true; } else if (whitelists[_tokenId].standards[i] == 1 && IERC1155(whitelists[_tokenId].contracts[i]).balanceOf(_account, whitelists[_tokenId].erc1155Ids[i]) > 0) { return true; } } return false; } function getHoldersLength(uint256 _tokenId) public view returns (uint256) { return holders[_tokenId].accounts.length; } function getHolders( uint256 _tokenId, uint256 _start, uint256 _end ) external view returns (address[] memory, uint256[] memory) { uint256 maxSize = getHoldersLength(_tokenId); _end = _end > maxSize ? maxSize : _end; uint256 size = _end - _start; address[] memory accounts = new address[](size); uint256[] memory balances = new uint256[](size); for (uint256 i = 0; i < size; i++) { address holder = holders[_tokenId].accounts[_start + i]; accounts[i] = holder; balances[i] = balanceOf(holder, _tokenId); } return (accounts, balances); } function uri(uint256 _tokenId) public view override returns (string memory) { require(exists(_tokenId), "Non exists token"); return tokens[_tokenId].config.baseURI; } function getPaymentDetail(uint256 _tokenId) public view returns (uint16[] memory, address[] memory) { return (tokenBalances[_tokenId].paymentRatios, tokenBalances[_tokenId].paymentWallets); } /* Admin */ function setTokenInfo( uint256 _tokenId, uint256 _maxPublicSale, uint256 _maxPresale, uint256 _maxTeamSupply, uint256 _maxPerAccount, uint256 _maxPerTxn, uint256 _maxPresalePerAccount, uint256 _maxPresalePerTxn, address _teamWallet, uint256 _price ) external onlyOwner { require(!exists(_tokenId), "Token exist"); TokenConfig storage config = tokens[_tokenId].config; config.MAX_PUBLIC_SALE_SUPPLY = _maxPublicSale; config.MAX_PRESALE_SUPPLY = _maxPresale; config.MAX_TEAM_SUPPLY = _maxTeamSupply; config.MAX_PUBLIC_PER_WALLET = _maxPerAccount; config.MAX_PUBLIC_PER_TXN = _maxPerTxn; config.MAX_PRESALE_PER_WALLET = _maxPresalePerAccount; config.MAX_PRESALE_PER_TXN = _maxPresalePerTxn; config.PRICE = _price; config.TEAM_WALLET = _teamWallet; } function setExternalContract( uint256 _tokenId, uint8[] calldata _standards, address[] calldata _contracts, uint256[] calldata _ids ) external onlyOwner { require(_standards.length == _contracts.length, "Input mismatch"); require(_ids.length == _contracts.length, "Input mismatch"); for (uint256 i = 0; i < _standards.length; i++) { require(_standards[i] == 0 || _standards[i] == 1, "Incorrect value"); } whitelists[_tokenId].standards = _standards; whitelists[_tokenId].contracts = _contracts; whitelists[_tokenId].erc1155Ids = _ids; } function setBaseURI(uint256[] calldata _tokenIds, string[] calldata _baseURI) external onlyOwner { require(_tokenIds.length == _baseURI.length, "Input mismatch"); for (uint256 i = 0; i < _tokenIds.length; i++) { tokens[_tokenIds[i]].config.baseURI = _baseURI[i]; } } function setTradingPause(uint256[] calldata _tokenIds, bool _status) external onlyOwner { for (uint256 i = 0; i < _tokenIds.length; i++) { tradingPaused[_tokenIds[i]] = _status; } } function togglePresaleActive(uint256[] calldata _tokenIds, bool _status) external onlyOwner { for (uint256 i = 0; i < _tokenIds.length; i++) { tokens[_tokenIds[i]].presalesActive = _status; } } function toggleSaleActive(uint256[] calldata _tokenIds, bool _status) external onlyOwner { for (uint256 i = 0; i < _tokenIds.length; i++) { tokens[_tokenIds[i]].salesActive = _status; } } function addWhitelist( uint256 _tokenId, address[] calldata _accounts, uint256[] calldata _amount ) external onlyOwner { require(_accounts.length == _amount.length, "Input mismatch"); for (uint256 i = 0; i < _accounts.length; i++) { whitelists[_tokenId].allocated[_accounts[i]] = _amount[i]; } } function teamClaim(uint256 _tokenId) external onlyOwner { TokenInfo storage token = tokens[_tokenId]; TokenConfig memory config = token.config; require(!token.teamClaimed, "Team claimed"); _mint(config.TEAM_WALLET, _tokenId, config.MAX_TEAM_SUPPLY, ""); token.teamClaimed = true; } function updatePayment( uint256 _tokenId, uint16[] calldata _ratios, address[] calldata _accounts ) external onlyOwner { require(_ratios.length == _accounts.length, "Input mismatch"); uint256 percentage = 0; for (uint256 i = 0; i < _ratios.length; i++) { percentage += _ratios[i]; } require(percentage == 1000, "Invalid percentage"); tokenBalances[_tokenId].paymentRatios = _ratios; tokenBalances[_tokenId].paymentWallets = _accounts; } function withdraw(uint256 _tokenId) public onlyOwner { TokenBalance storage tokenBalance = tokenBalances[_tokenId]; uint256 maxBalance = address(this).balance; for (uint256 i = 0; i < tokenBalance.paymentRatios.length; i++) { uint256 balance = (maxBalance * tokenBalance.paymentRatios[i]) / 1000; payable(tokenBalance.paymentWallets[i]).transfer(balance); } } function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override { super._beforeTokenTransfer(operator, from, to, ids, amounts, data); for (uint256 i = 0; i < ids.length; i++) { uint256 tokenId = ids[i]; require(from == address(0) || !tradingPaused[tokenId], "Token paused"); if (amounts[i] == 0) continue; if (from != address(0) && balanceOf(from, tokenId) == amounts[i]) { holders[tokenId].removeHolder(from); } if (to != address(0)) { holders[tokenId].addHolder(to); } } } } interface IERC721 { function balanceOf(address) external view returns (uint256); } interface IERC1155 { function balanceOf(address, uint256) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _setOwner(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC1155.sol"; /** * @dev Extension of ERC1155 that adds tracking of total supply per id. * * Useful for scenarios where Fungible and Non-fungible tokens have to be * clearly identified. Note: While a totalSupply of 1 might mean the * corresponding is an NFT, there is no guarantees that no other token with the * same id are not going to be minted. */ abstract contract ERC1155Supply is ERC1155 { mapping(uint256 => uint256) private _totalSupply; /** * @dev Total amount of tokens in with a given id. */ function totalSupply(uint256 id) public view virtual returns (uint256) { return _totalSupply[id]; } /** * @dev Indicates weither any token exist with a given id, or not. */ function exists(uint256 id) public view virtual returns (bool) { return ERC1155Supply.totalSupply(id) > 0; } /** * @dev See {ERC1155-_mint}. */ function _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal virtual override { super._mint(account, id, amount, data); _totalSupply[id] += amount; } /** * @dev See {ERC1155-_mintBatch}. */ function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual override { super._mintBatch(to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] += amounts[i]; } } /** * @dev See {ERC1155-_burn}. */ function _burn( address account, uint256 id, uint256 amount ) internal virtual override { super._burn(account, id, amount); _totalSupply[id] -= amount; } /** * @dev See {ERC1155-_burnBatch}. */ function _burnBatch( address account, uint256[] memory ids, uint256[] memory amounts ) internal virtual override { super._burnBatch(account, ids, amounts); for (uint256 i = 0; i < ids.length; ++i) { _totalSupply[ids[i]] -= amounts[i]; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.9; library TokenHolder { struct Holders { address[] accounts; mapping(address => uint256) indexes; // account value to index } function addHolder(Holders storage _holders, address _account) internal { if (_holders.indexes[_account] != 0) return; // already exists _holders.accounts.push(_account); // The value is stored at length-1, but adding 1 to all indexes // and use 0 as a sentinel value _holders.indexes[_account] = _holders.accounts.length; } function removeHolder(Holders storage _holders, address _account) internal { uint256 valueIndex = _holders.indexes[_account]; if (valueIndex == 0) return; // removed not exists value uint256 toDeleteIndex = valueIndex - 1; // when add we not sub for 1 so now must sub 1 (for not out of bound) uint256 lastIndex = _holders.accounts.length - 1; if (lastIndex != toDeleteIndex) { // swap address lastvalue = _holders.accounts[lastIndex]; // Move the last value to the index where the value to delete is _holders.accounts[toDeleteIndex] = lastvalue; // Update the index for the moved value _holders.indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex } // Delete the slot where the moved value was stored _holders.accounts.pop(); // Delete the index for the deleted slot _holders.indexes[_account] = 0; // set to 0 } function containsHolder(Holders storage _holders, address _account) internal view returns (bool) { return _holders.indexes[_account] != 0; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC1155.sol"; import "./IERC1155Receiver.sol"; import "./extensions/IERC1155MetadataURI.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of the basic standard multi-token. * See https://eips.ethereum.org/EIPS/eip-1155 * Originally based on code by Enjin: https://github.com/enjin/erc-1155 * * _Available since v3.1._ */ contract ERC1155 is Context, ERC165, IERC1155, IERC1155MetadataURI { using Address for address; // Mapping from token ID to account balances mapping(uint256 => mapping(address => uint256)) private _balances; // Mapping from account to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; // Used as the URI for all token types by relying on ID substitution, e.g. https://token-cdn-domain/{id}.json string private _uri; /** * @dev See {_setURI}. */ constructor(string memory uri_) { _setURI(uri_); } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC1155).interfaceId || interfaceId == type(IERC1155MetadataURI).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC1155MetadataURI-uri}. * * This implementation returns the same URI for *all* token types. It relies * on the token type ID substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * Clients calling this function must replace the `\{id\}` substring with the * actual token type ID. */ function uri(uint256) public view virtual override returns (string memory) { return _uri; } /** * @dev See {IERC1155-balanceOf}. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) public view virtual override returns (uint256) { require(account != address(0), "ERC1155: balance query for the zero address"); return _balances[id][account]; } /** * @dev See {IERC1155-balanceOfBatch}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] memory accounts, uint256[] memory ids) public view virtual override returns (uint256[] memory) { require(accounts.length == ids.length, "ERC1155: accounts and ids length mismatch"); uint256[] memory batchBalances = new uint256[](accounts.length); for (uint256 i = 0; i < accounts.length; ++i) { batchBalances[i] = balanceOf(accounts[i], ids[i]); } return batchBalances; } /** * @dev See {IERC1155-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(_msgSender() != operator, "ERC1155: setting approval status for self"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC1155-isApprovedForAll}. */ function isApprovedForAll(address account, address operator) public view virtual override returns (bool) { return _operatorApprovals[account][operator]; } /** * @dev See {IERC1155-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: caller is not owner nor approved" ); _safeTransferFrom(from, to, id, amount, data); } /** * @dev See {IERC1155-safeBatchTransferFrom}. */ function safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) public virtual override { require( from == _msgSender() || isApprovedForAll(from, _msgSender()), "ERC1155: transfer caller is not owner nor approved" ); _safeBatchTransferFrom(from, to, ids, amounts, data); } /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, _asSingletonArray(id), _asSingletonArray(amount), data); uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; emit TransferSingle(operator, from, to, id, amount); _doSafeTransferAcceptanceCheck(operator, from, to, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _safeBatchTransferFrom( address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); require(to != address(0), "ERC1155: transfer to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, from, to, ids, amounts, data); for (uint256 i = 0; i < ids.length; ++i) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 fromBalance = _balances[id][from]; require(fromBalance >= amount, "ERC1155: insufficient balance for transfer"); unchecked { _balances[id][from] = fromBalance - amount; } _balances[id][to] += amount; } emit TransferBatch(operator, from, to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, from, to, ids, amounts, data); } /** * @dev Sets a new URI for all token types, by relying on the token type ID * substitution mechanism * https://eips.ethereum.org/EIPS/eip-1155#metadata[defined in the EIP]. * * By this mechanism, any occurrence of the `\{id\}` substring in either the * URI or any of the amounts in the JSON file at said URI will be replaced by * clients with the token type ID. * * For example, the `https://token-cdn-domain/\{id\}.json` URI would be * interpreted by clients as * `https://token-cdn-domain/000000000000000000000000000000000000000000000000000000000004cce0.json` * for token type ID 0x4cce0. * * See {uri}. * * Because these URIs cannot be meaningfully represented by the {URI} event, * this function emits no events. */ function _setURI(string memory newuri) internal virtual { _uri = newuri; } /** * @dev Creates `amount` tokens of token type `id`, and assigns them to `account`. * * Emits a {TransferSingle} event. * * Requirements: * * - `account` cannot be the zero address. * - If `account` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function _mint( address account, uint256 id, uint256 amount, bytes memory data ) internal virtual { require(account != address(0), "ERC1155: mint to the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), account, _asSingletonArray(id), _asSingletonArray(amount), data); _balances[id][account] += amount; emit TransferSingle(operator, address(0), account, id, amount); _doSafeTransferAcceptanceCheck(operator, address(0), account, id, amount, data); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_mint}. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function _mintBatch( address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual { require(to != address(0), "ERC1155: mint to the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, address(0), to, ids, amounts, data); for (uint256 i = 0; i < ids.length; i++) { _balances[ids[i]][to] += amounts[i]; } emit TransferBatch(operator, address(0), to, ids, amounts); _doSafeBatchTransferAcceptanceCheck(operator, address(0), to, ids, amounts, data); } /** * @dev Destroys `amount` tokens of token type `id` from `account` * * Requirements: * * - `account` cannot be the zero address. * - `account` must have at least `amount` tokens of token type `id`. */ function _burn( address account, uint256 id, uint256 amount ) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), _asSingletonArray(id), _asSingletonArray(amount), ""); uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][account] = accountBalance - amount; } emit TransferSingle(operator, account, address(0), id, amount); } /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {_burn}. * * Requirements: * * - `ids` and `amounts` must have the same length. */ function _burnBatch( address account, uint256[] memory ids, uint256[] memory amounts ) internal virtual { require(account != address(0), "ERC1155: burn from the zero address"); require(ids.length == amounts.length, "ERC1155: ids and amounts length mismatch"); address operator = _msgSender(); _beforeTokenTransfer(operator, account, address(0), ids, amounts, ""); for (uint256 i = 0; i < ids.length; i++) { uint256 id = ids[i]; uint256 amount = amounts[i]; uint256 accountBalance = _balances[id][account]; require(accountBalance >= amount, "ERC1155: burn amount exceeds balance"); unchecked { _balances[id][account] = accountBalance - amount; } } emit TransferBatch(operator, account, address(0), ids, amounts); } /** * @dev Hook that is called before any token transfer. This includes minting * and burning, as well as batched variants. * * The same hook is called on both single and batched variants. For single * transfers, the length of the `id` and `amount` arrays will be 1. * * Calling conditions (for each `id` and `amount` pair): * * - When `from` and `to` are both non-zero, `amount` of ``from``'s tokens * of token type `id` will be transferred to `to`. * - When `from` is zero, `amount` tokens of token type `id` will be minted * for `to`. * - when `to` is zero, `amount` of ``from``'s tokens of token type `id` * will be burned. * - `from` and `to` are never both zero. * - `ids` and `amounts` have the same, non-zero length. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) internal virtual {} function _doSafeTransferAcceptanceCheck( address operator, address from, address to, uint256 id, uint256 amount, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155Received(operator, from, id, amount, data) returns (bytes4 response) { if (response != IERC1155Receiver.onERC1155Received.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _doSafeBatchTransferAcceptanceCheck( address operator, address from, address to, uint256[] memory ids, uint256[] memory amounts, bytes memory data ) private { if (to.isContract()) { try IERC1155Receiver(to).onERC1155BatchReceived(operator, from, ids, amounts, data) returns ( bytes4 response ) { if (response != IERC1155Receiver.onERC1155BatchReceived.selector) { revert("ERC1155: ERC1155Receiver rejected tokens"); } } catch Error(string memory reason) { revert(reason); } catch { revert("ERC1155: transfer to non ERC1155Receiver implementer"); } } } function _asSingletonArray(uint256 element) private pure returns (uint256[] memory) { uint256[] memory array = new uint256[](1); array[0] = element; return array; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC1155 compliant contract, as defined in the * https://eips.ethereum.org/EIPS/eip-1155[EIP]. * * _Available since v3.1._ */ interface IERC1155 is IERC165 { /** * @dev Emitted when `value` tokens of token type `id` are transferred from `from` to `to` by `operator`. */ event TransferSingle(address indexed operator, address indexed from, address indexed to, uint256 id, uint256 value); /** * @dev Equivalent to multiple {TransferSingle} events, where `operator`, `from` and `to` are the same for all * transfers. */ event TransferBatch( address indexed operator, address indexed from, address indexed to, uint256[] ids, uint256[] values ); /** * @dev Emitted when `account` grants or revokes permission to `operator` to transfer their tokens, according to * `approved`. */ event ApprovalForAll(address indexed account, address indexed operator, bool approved); /** * @dev Emitted when the URI for token type `id` changes to `value`, if it is a non-programmatic URI. * * If an {URI} event was emitted for `id`, the standard * https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[guarantees] that `value` will equal the value * returned by {IERC1155MetadataURI-uri}. */ event URI(string value, uint256 indexed id); /** * @dev Returns the amount of tokens of token type `id` owned by `account`. * * Requirements: * * - `account` cannot be the zero address. */ function balanceOf(address account, uint256 id) external view returns (uint256); /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {balanceOf}. * * Requirements: * * - `accounts` and `ids` must have the same length. */ function balanceOfBatch(address[] calldata accounts, uint256[] calldata ids) external view returns (uint256[] memory); /** * @dev Grants or revokes permission to `operator` to transfer the caller's tokens, according to `approved`, * * Emits an {ApprovalForAll} event. * * Requirements: * * - `operator` cannot be the caller. */ function setApprovalForAll(address operator, bool approved) external; /** * @dev Returns true if `operator` is approved to transfer ``account``'s tokens. * * See {setApprovalForAll}. */ function isApprovedForAll(address account, address operator) external view returns (bool); /** * @dev Transfers `amount` tokens of token type `id` from `from` to `to`. * * Emits a {TransferSingle} event. * * Requirements: * * - `to` cannot be the zero address. * - If the caller is not `from`, it must be have been approved to spend ``from``'s tokens via {setApprovalForAll}. * - `from` must have a balance of tokens of type `id` of at least `amount`. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155Received} and return the * acceptance magic value. */ function safeTransferFrom( address from, address to, uint256 id, uint256 amount, bytes calldata data ) external; /** * @dev xref:ROOT:erc1155.adoc#batch-operations[Batched] version of {safeTransferFrom}. * * Emits a {TransferBatch} event. * * Requirements: * * - `ids` and `amounts` must have the same length. * - If `to` refers to a smart contract, it must implement {IERC1155Receiver-onERC1155BatchReceived} and return the * acceptance magic value. */ function safeBatchTransferFrom( address from, address to, uint256[] calldata ids, uint256[] calldata amounts, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev _Available since v3.1._ */ interface IERC1155Receiver is IERC165 { /** @dev Handles the receipt of a single ERC1155 token type. This function is called at the end of a `safeTransferFrom` after the balance has been updated. To accept the transfer, this must return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` (i.e. 0xf23a6e61, or its own function selector). @param operator The address which initiated the transfer (i.e. msg.sender) @param from The address which previously owned the token @param id The ID of the token being transferred @param value The amount of tokens being transferred @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` if transfer is allowed */ function onERC1155Received( address operator, address from, uint256 id, uint256 value, bytes calldata data ) external returns (bytes4); /** @dev Handles the receipt of a multiple ERC1155 token types. This function is called at the end of a `safeBatchTransferFrom` after the balances have been updated. To accept the transfer(s), this must return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` (i.e. 0xbc197c81, or its own function selector). @param operator The address which initiated the batch transfer (i.e. msg.sender) @param from The address which previously owned the token @param ids An array containing ids of each token being transferred (order and length must match values array) @param values An array containing amounts of each token being transferred (order and length must match ids array) @param data Additional data with no specified format @return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` if transfer is allowed */ function onERC1155BatchReceived( address operator, address from, uint256[] calldata ids, uint256[] calldata values, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC1155.sol"; /** * @dev Interface of the optional ERC1155MetadataExtension interface, as defined * in the https://eips.ethereum.org/EIPS/eip-1155#metadata-extensions[EIP]. * * _Available since v3.1._ */ interface IERC1155MetadataURI is IERC1155 { /** * @dev Returns the URI for token type `id`. * * If the `\{id\}` substring is present in the URI, it must be replaced by * clients with the actual token type ID. */ function uri(uint256 id) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
{ "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":[],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"indexed":false,"internalType":"uint256[]","name":"values","type":"uint256[]"}],"name":"TransferBatch","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"value","type":"uint256"}],"name":"TransferSingle","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"string","name":"value","type":"string"},{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"URI","type":"event"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"address[]","name":"_accounts","type":"address[]"},{"internalType":"uint256[]","name":"_amount","type":"uint256[]"}],"name":"addWhitelist","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"accounts","type":"address[]"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"}],"name":"balanceOfBatch","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint16","name":"_amount","type":"uint16"}],"name":"claim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_start","type":"uint256"},{"internalType":"uint256","name":"_end","type":"uint256"}],"name":"getHolders","outputs":[{"internalType":"address[]","name":"","type":"address[]"},{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getHoldersLength","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"getPaymentDetail","outputs":[{"internalType":"uint16[]","name":"","type":"uint16[]"},{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"account","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint16","name":"_amount","type":"uint16"}],"name":"presaleClaim","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"uint256[]","name":"amounts","type":"uint256[]"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeBatchTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"},{"internalType":"string[]","name":"_baseURI","type":"string[]"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint8[]","name":"_standards","type":"uint8[]"},{"internalType":"address[]","name":"_contracts","type":"address[]"},{"internalType":"uint256[]","name":"_ids","type":"uint256[]"}],"name":"setExternalContract","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_maxPublicSale","type":"uint256"},{"internalType":"uint256","name":"_maxPresale","type":"uint256"},{"internalType":"uint256","name":"_maxTeamSupply","type":"uint256"},{"internalType":"uint256","name":"_maxPerAccount","type":"uint256"},{"internalType":"uint256","name":"_maxPerTxn","type":"uint256"},{"internalType":"uint256","name":"_maxPresalePerAccount","type":"uint256"},{"internalType":"uint256","name":"_maxPresalePerTxn","type":"uint256"},{"internalType":"address","name":"_teamWallet","type":"address"},{"internalType":"uint256","name":"_price","type":"uint256"}],"name":"setTokenInfo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"},{"internalType":"bool","name":"_status","type":"bool"}],"name":"setTradingPause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"teamClaim","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"},{"internalType":"bool","name":"_status","type":"bool"}],"name":"togglePresaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"_tokenIds","type":"uint256[]"},{"internalType":"bool","name":"_status","type":"bool"}],"name":"toggleSaleActive","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"address","name":"_account","type":"address"}],"name":"tokenEligible","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tokens","outputs":[{"internalType":"bool","name":"salesActive","type":"bool"},{"internalType":"bool","name":"presalesActive","type":"bool"},{"internalType":"bool","name":"teamClaimed","type":"bool"},{"internalType":"uint256","name":"presaleClaimed","type":"uint256"},{"internalType":"uint256","name":"publicClaimed","type":"uint256"},{"components":[{"internalType":"address","name":"TEAM_WALLET","type":"address"},{"internalType":"uint256","name":"MAX_PUBLIC_SALE_SUPPLY","type":"uint256"},{"internalType":"uint256","name":"MAX_PRESALE_SUPPLY","type":"uint256"},{"internalType":"uint256","name":"MAX_TEAM_SUPPLY","type":"uint256"},{"internalType":"uint256","name":"MAX_PUBLIC_PER_WALLET","type":"uint256"},{"internalType":"uint256","name":"MAX_PUBLIC_PER_TXN","type":"uint256"},{"internalType":"uint256","name":"MAX_PRESALE_PER_WALLET","type":"uint256"},{"internalType":"uint256","name":"MAX_PRESALE_PER_TXN","type":"uint256"},{"internalType":"uint256","name":"PRICE","type":"uint256"},{"internalType":"string","name":"baseURI","type":"string"}],"internalType":"struct RedVillagePortal.TokenConfig","name":"config","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tradingPaused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint16[]","name":"_ratios","type":"uint16[]"},{"internalType":"address[]","name":"_accounts","type":"address[]"}],"name":"updatePayment","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"uri","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"address","name":"_account","type":"address"}],"name":"whitelistAllocated","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040523480156200001157600080fd5b506040805160208101909152600081526200002c81620002c4565b506200003833620002dd565b600160009081526006602090815261174d7f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a35556107d07f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a365560237f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3755601c7f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3855600e7f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a39557f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3a8290557f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3b82905567016345785d8a00007f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3c557f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3480546001600160a01b03191673cd38b6d9c4b12654ad06aae2842a0fc3d861188b17815560408051928301908190529183905291620001f1917f3e5fec24aa4dc4e5aee2e025e51e1392c72a2500577559fae9665c6d52bd6a3d916200032f565b50604080518082019091526103848152606460208083019190915260016000526009905262000244907f92e85d02570a8092d09a6e3a57665bc3815a2699a4074001bf1ccabf660f5a36906002620003be565b506040805180820190915273cbf7f6b967c2314ed0694d39512aa18ad4d01878815273909680a5e46a3401d4dd75148b61e129451fa266602080830191909152600160005260099052620002bc907f92e85d02570a8092d09a6e3a57665bc3815a2699a4074001bf1ccabf660f5a3790600262000469565b505062000515565b8051620002d99060029060208401906200032f565b5050565b600480546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b8280546200033d90620004d8565b90600052602060002090601f016020900481019282620003615760008555620003ac565b82601f106200037c57805160ff1916838001178555620003ac565b82800160010185558215620003ac579182015b82811115620003ac5782518255916020019190600101906200038f565b50620003ba929150620004c1565b5090565b82805482825590600052602060002090600f01601090048101928215620003ac5791602002820160005b838211156200042a57835183826101000a81548161ffff021916908361ffff1602179055509260200192600201602081600101049283019260010302620003e8565b80156200045a5782816101000a81549061ffff02191690556002016020816001010492830192600103026200042a565b5050620003ba929150620004c1565b828054828255906000526020600020908101928215620003ac579160200282015b82811115620003ac57825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906200048a565b5b80821115620003ba5760008155600101620004c2565b600181811c90821680620004ed57607f821691505b602082108114156200050f57634e487b7160e01b600052602260045260246000fd5b50919050565b613e0780620005256000396000f3fe6080604052600436106101e25760003560e01c806375c5b6fc11610102578063ae5bc07311610095578063dc1ccbd111610064578063dc1ccbd1146105f0578063e985e9c514610610578063f242432a14610659578063f2fde38b1461067957600080fd5b8063ae5bc07314610570578063b38299af14610583578063bd85b039146105a3578063be7d8408146105d057600080fd5b80638da5cb5b116100d15780638da5cb5b146104d8578063a026da8c14610500578063a22cb46514610520578063a943c0c61461054057600080fd5b806375c5b6fc14610465578063786541c1146104855780638a2eb1ef146104a55780638b1a3696146104c557600080fd5b80633b9d15511161017a5780634f558e79116101495780634f558e79146103cf5780634f64b2be146103fe57806367d3294a14610430578063715018a61461045057600080fd5b80633b9d15511461032657806342c23abe1461034657806346ec7ab6146103745780634e1273f4146103a257600080fd5b806316a076cc116101b657806316a076cc146102a4578063178f4ab5146102c65780632e1a7d4d146102e65780632eb2c2d61461030657600080fd5b8062fdd58e146101e757806301ffc9a71461021a578063056d483c1461024a5780630e89341c14610277575b600080fd5b3480156101f357600080fd5b50610207610202366004612fd8565b610699565b6040519081526020015b60405180910390f35b34801561022657600080fd5b5061023a610235366004613018565b610733565b6040519015158152602001610211565b34801561025657600080fd5b5061020761026536600461303c565b60009081526008602052604090205490565b34801561028357600080fd5b5061029761029236600461303c565b610783565b60405161021191906130a2565b3480156102b057600080fd5b506102c46102bf3660046130b5565b610875565b005b3480156102d257600080fd5b5061023a6102e1366004613130565b61094f565b3480156102f257600080fd5b506102c461030136600461303c565b610bd5565b34801561031257600080fd5b506102c46103213660046132a5565b610cda565b34801561033257600080fd5b506102c4610341366004613399565b610d71565b34801561035257600080fd5b5061036661036136600461343c565b610ef1565b6040516102119291906134dc565b34801561038057600080fd5b5061039461038f36600461303c565b61107f565b60405161021192919061350a565b3480156103ae57600080fd5b506103c26103bd366004613565565b611171565b604051610211919061362f565b3480156103db57600080fd5b5061023a6103ea36600461303c565b600090815260036020526040902054151590565b34801561040a57600080fd5b5061041e61041936600461303c565b61129a565b60405161021196959493929190613642565b34801561043c57600080fd5b5061020761044b366004613130565b6113df565b34801561045c57600080fd5b506102c461140b565b34801561047157600080fd5b506102c461048036600461371d565b611441565b34801561049157600080fd5b506102c46104a036600461371d565b6114cc565b3480156104b157600080fd5b506102c46104c0366004613770565b61155a565b6102c46104d33660046137fb565b61163a565b3480156104e457600080fd5b506004546040516001600160a01b039091168152602001610211565b34801561050c57600080fd5b506102c461051b36600461303c565b611945565b34801561052c57600080fd5b506102c461053b36600461381e565b611b0d565b34801561054c57600080fd5b5061023a61055b36600461303c565b60056020526000908152604090205460ff1681565b6102c461057e3660046137fb565b611be4565b34801561058f57600080fd5b506102c461059e366004613770565b611fe7565b3480156105af57600080fd5b506102076105be36600461303c565b60009081526003602052604090205490565b3480156105dc57600080fd5b506102c46105eb36600461371d565b61210b565b3480156105fc57600080fd5b506102c461060b366004613848565b612191565b34801561061c57600080fd5b5061023a61062b3660046138b3565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561066557600080fd5b506102c46106743660046138dd565b61225a565b34801561068557600080fd5b506102c4610694366004613941565b6122e1565b60006001600160a01b03831661070a5760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000818152602081815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b148061076457506001600160e01b031982166303a24d0760e21b145b8061072d57506301ffc9a760e01b6001600160e01b031983161461072d565b6000818152600360205260409020546060906107d45760405162461bcd60e51b815260206004820152601060248201526f2737b71032bc34b9ba39903a37b5b2b760811b6044820152606401610701565b6000828152600660205260409020600c0180546107f09061395c565b80601f016020809104026020016040519081016040528092919081815260200182805461081c9061395c565b80156108695780601f1061083e57610100808354040283529160200191610869565b820191906000526020600020905b81548152906001019060200180831161084c57829003601f168201915b50505050509050919050565b6004546001600160a01b0316331461089f5760405162461bcd60e51b815260040161070190613997565b60008a815260036020526040902054156108e95760405162461bcd60e51b815260206004820152600b60248201526a151bdad95b88195e1a5cdd60aa1b6044820152606401610701565b6000998a52600660208190526040909a206004810199909955600589019790975597870194909455600786019290925560088501556009840155600a830155600b82015560030180546001600160a01b0319166001600160a01b03909216919091179055565b600082815260076020526040812054815b81811015610bca576000858152600760205260409020805482908110610988576109886139cc565b60009182526020918290209181049091015460ff601f9092166101000a900416158015610a5b575060008581526007602052604081206002018054839081106109d3576109d36139cc565b6000918252602090912001546040516370a0823160e01b81526001600160a01b038781166004830152909116906370a082319060240160206040518083038186803b158015610a2157600080fd5b505afa158015610a35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5991906139e2565b115b15610a6b5760019250505061072d565b6000858152600760205260409020805482908110610a8b57610a8b6139cc565b90600052602060002090602091828204019190069054906101000a900460ff1660ff166001148015610ba857506000858152600760205260408120600201805483908110610adb57610adb6139cc565b60009182526020808320909101548883526007909152604090912060010180546001600160a01b039092169162fdd58e91889186908110610b1e57610b1e6139cc565b6000918252602090912001546040516001600160e01b031960e085901b1681526001600160a01b039092166004830152602482015260440160206040518083038186803b158015610b6e57600080fd5b505afa158015610b82573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ba691906139e2565b115b15610bb85760019250505061072d565b80610bc281613a11565b915050610960565b506000949350505050565b6004546001600160a01b03163314610bff5760405162461bcd60e51b815260040161070190613997565b60008181526009602052604081209047905b8254811015610cd45760006103e8846000018381548110610c3457610c346139cc565b60009182526020909120601082040154610c5e91600f166002026101000a900461ffff1685613a2c565b610c689190613a4b565b9050836001018281548110610c7f57610c7f6139cc565b60009182526020822001546040516001600160a01b039091169183156108fc02918491818181858888f19350505050158015610cbf573d6000803e3d6000fd5b50508080610ccc90613a11565b915050610c11565b50505050565b6001600160a01b038516331480610cf65750610cf6853361062b565b610d5d5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b6064820152608401610701565b610d6a858585858561237c565b5050505050565b6004546001600160a01b03163314610d9b5760405162461bcd60e51b815260040161070190613997565b848314610dba5760405162461bcd60e51b815260040161070190613a6d565b808314610dd95760405162461bcd60e51b815260040161070190613a6d565b60005b85811015610e9357868682818110610df657610df66139cc565b9050602002016020810190610e0b9190613a95565b60ff161580610e435750868682818110610e2757610e276139cc565b9050602002016020810190610e3c9190613a95565b60ff166001145b610e815760405162461bcd60e51b815260206004820152600f60248201526e496e636f72726563742076616c756560881b6044820152606401610701565b80610e8b81613a11565b915050610ddc565b506000878152600760205260409020610ead908787612d62565b506000878152600760205260409020610eca906002018585612e0b565b506000878152600760205260409020610ee7906001018383612e5e565b5050505050505050565b6000838152600860205260409020546060908190808411610f125783610f14565b805b93506000610f228686613ab8565b90506000816001600160401b03811115610f3e57610f3e61315c565b604051908082528060200260200182016040528015610f67578160200160208202803683370190505b5090506000826001600160401b03811115610f8457610f8461315c565b604051908082528060200260200182016040528015610fad578160200160208202803683370190505b50905060005b838110156110705760008a8152600860205260408120610fd3838c613acf565b81548110610fe357610fe36139cc565b9060005260206000200160009054906101000a90046001600160a01b0316905080848381518110611016576110166139cc565b60200260200101906001600160a01b031690816001600160a01b031681525050611040818c610699565b838381518110611052576110526139cc565b6020908102919091010152508061106881613a11565b915050610fb3565b50909890975095505050505050565b600081815260096020908152604091829020805483518184028101840190945280845260609384936001840192849183018282801561110557602002820191906000526020600020906000905b82829054906101000a900461ffff1661ffff16815260200190600201906020826001010492830192600103820291508084116110cc5790505b505050505091508080548060200260200160405190810160405280929190818152602001828054801561116157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611143575b5050505050905091509150915091565b606081518351146111d65760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610701565b600083516001600160401b038111156111f1576111f161315c565b60405190808252806020026020018201604052801561121a578160200160208202803683370190505b50905060005b84518110156112925761126585828151811061123e5761123e6139cc565b6020026020010151858381518110611258576112586139cc565b6020026020010151610699565b828281518110611277576112776139cc565b602090810291909101015261128b81613a11565b9050611220565b509392505050565b6006602081815260009283526040928390208054600182015460028301548651610140810188526003850180546001600160a01b0316825260048601549682019690965260058501549781019790975294830154606087015260078301546080870152600883015460a0870152600983015460c0870152600a83015460e0870152600b83015461010087810191909152600c8401805460ff80861699938604811698620100009096041696939593916101208401916113589061395c565b80601f01602080910402602001604051908101604052809291908181526020018280546113849061395c565b80156113d15780601f106113a6576101008083540402835291602001916113d1565b820191906000526020600020905b8154815290600101906020018083116113b457829003601f168201915b505050505081525050905086565b60008281526007602090815260408083206001600160a01b038516845260030190915290205492915050565b6004546001600160a01b031633146114355760405162461bcd60e51b815260040161070190613997565b61143f600061255f565b565b6004546001600160a01b0316331461146b5760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd457816005600086868581811061148d5761148d6139cc565b90506020020135815260200190815260200160002060006101000a81548160ff02191690831515021790555080806114c490613a11565b91505061146e565b6004546001600160a01b031633146114f65760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd4578160066000868685818110611518576115186139cc565b90506020020135815260200190815260200160002060000160016101000a81548160ff021916908315150217905550808061155290613a11565b9150506114f9565b6004546001600160a01b031633146115845760405162461bcd60e51b815260040161070190613997565b8281146115a35760405162461bcd60e51b815260040161070190613a6d565b60005b83811015611632578282828181106115c0576115c06139cc565b905060200201356007600088815260200190815260200160002060030160008787858181106115f1576115f16139cc565b90506020020160208101906116069190613941565b6001600160a01b031681526020810191909152604001600020558061162a81613a11565b9150506115a6565b505050505050565b60008281526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c83018054939493919291610120840191906116d59061395c565b80601f01602080910402602001604051908101604052809291908181526020018280546117019061395c565b801561174e5780601f106117235761010080835404028352916020019161174e565b820191906000526020600020905b81548152906001019060200180831161173157829003601f168201915b50505091909252505083549192505060ff166117a25760405162461bcd60e51b8152602060048201526013602482015272436c61696d206973206e6f742061637469766560681b6044820152606401610701565b3233146117df5760405162461bcd60e51b815260206004820152600b60248201526a139bdd08185b1b1bddd95960aa1b6044820152606401610701565b8060a001518361ffff1611156118075760405162461bcd60e51b815260040161070190613ae7565b80608001518361ffff1661181b3387610699565b6118259190613acf565b11156118435760405162461bcd60e51b815260040161070190613ae7565b80602001518361ffff16836001015484600201546118619190613acf565b61186b9190613acf565b11156118a85760405162461bcd60e51b815260206004820152600c60248201526b115e18d95959081d1bdd185b60a21b6044820152606401610701565b6101008101516118bc9061ffff8516613a2c565b3410156119035760405162461bcd60e51b8152602060048201526015602482015274115d1a195c881d985b1d59481a5b98dbdc9c9958dd605a1b6044820152606401610701565b61192233858561ffff16604051806020016040528060008152506125b1565b8261ffff1682600201600082825461193a9190613acf565b909155505050505050565b6004546001600160a01b0316331461196f5760405162461bcd60e51b815260040161070190613997565b60008181526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c8301805493949391929161012084019190611a0a9061395c565b80601f0160208091040260200160405190810160405280929190818152602001828054611a369061395c565b8015611a835780601f10611a5857610100808354040283529160200191611a83565b820191906000526020600020905b815481529060010190602001808311611a6657829003601f168201915b50505091909252505083549192505062010000900460ff1615611ad75760405162461bcd60e51b815260206004820152600c60248201526b1519585b4818db185a5b595960a21b6044820152606401610701565b611afa8160000151848360600151604051806020016040528060008152506125b1565b50805462ff000019166201000017905550565b336001600160a01b0383161415611b785760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610701565b3360008181526001602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b60008281526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c8301805493949391929161012084019190611c7f9061395c565b80601f0160208091040260200160405190810160405280929190818152602001828054611cab9061395c565b8015611cf85780601f10611ccd57610100808354040283529160200191611cf8565b820191906000526020600020905b815481529060010190602001808311611cdb57829003601f168201915b505050919092525050835491925050610100900460ff16611d515760405162461bcd60e51b8152602060048201526013602482015272436c61696d206973206e6f742061637469766560681b6044820152606401610701565b323314611d8e5760405162461bcd60e51b815260206004820152600b60248201526a139bdd08185b1b1bddd95960aa1b6044820152606401610701565b611d98843361094f565b80611db057508261ffff16611dad85336113df565b10155b611deb5760405162461bcd60e51b815260206004820152600c60248201526b4e6f7420656c696769626c6560a01b6044820152606401610701565b611df584336113df565b1580611e0e57508261ffff16611e0b85336113df565b10155b611e2a5760405162461bcd60e51b815260040161070190613ae7565b60e08101511580611e4357508060e001518361ffff1611155b611e5f5760405162461bcd60e51b815260040161070190613ae7565b60c08101511580611e8c57508060c001518361ffff16611e7f3387610699565b611e899190613acf565b11155b611ea85760405162461bcd60e51b815260040161070190613ae7565b80604001518361ffff168360010154611ec19190613acf565b1115611efe5760405162461bcd60e51b815260206004820152600c60248201526b115e18d95959081d1bdd185b60a21b6044820152606401610701565b610100810151611f129061ffff8516613a2c565b341015611f595760405162461bcd60e51b8152602060048201526015602482015274115d1a195c881d985b1d59481a5b98dbdc9c9958dd605a1b6044820152606401610701565b8261ffff16611f6885336113df565b10611fa35760008481526007602090815260408083203384526003019091528120805461ffff86169290611f9d908490613ab8565b90915550505b611fc233858561ffff16604051806020016040528060008152506125b1565b6000848152600660205260408120600101805461ffff8616929061193a908490613acf565b6004546001600160a01b031633146120115760405162461bcd60e51b815260040161070190613997565b8281146120305760405162461bcd60e51b815260040161070190613a6d565b6000805b848110156120855785858281811061204e5761204e6139cc565b90506020020160208101906120639190613b0b565b6120719061ffff1683613acf565b91508061207d81613a11565b915050612034565b50806103e8146120cc5760405162461bcd60e51b8152602060048201526012602482015271496e76616c69642070657263656e7461676560701b6044820152606401610701565b60008681526009602052604090206120e5908686612e99565b506000868152600960205260409020612102906001018484612e0b565b50505050505050565b6004546001600160a01b031633146121355760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd4578160066000868685818110612157576121576139cc565b60209081029290920135835250810191909152604001600020805460ff19169115159190911790558061218981613a11565b915050612138565b6004546001600160a01b031633146121bb5760405162461bcd60e51b815260040161070190613997565b8281146121da5760405162461bcd60e51b815260040161070190613a6d565b60005b83811015610d6a578282828181106121f7576121f76139cc565b90506020028101906122099190613b26565b6006600088888681811061221f5761221f6139cc565b9050602002013581526020019081526020016000206003016009019190612247929190612f34565b508061225281613a11565b9150506121dd565b6001600160a01b0385163314806122765750612276853361062b565b6122d45760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610701565b610d6a85858585856125db565b6004546001600160a01b0316331461230b5760405162461bcd60e51b815260040161070190613997565b6001600160a01b0381166123705760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610701565b6123798161255f565b50565b81518351146123de5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610701565b6001600160a01b0384166124045760405162461bcd60e51b815260040161070190613b6c565b336124138187878787876126fe565b60005b84518110156124f9576000858281518110612433576124336139cc565b602002602001015190506000858381518110612451576124516139cc565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156124a15760405162461bcd60e51b815260040161070190613bb1565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906124de908490613acf565b92505081905550505050806124f290613a11565b9050612416565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612549929190613bfb565b60405180910390a461163281878787878761284c565b600480546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6125bd848484846129b7565b6000838152600360205260408120805484929061193a908490613acf565b6001600160a01b0384166126015760405162461bcd60e51b815260040161070190613b6c565b3361262081878761261188612ab8565b61261a88612ab8565b876126fe565b6000848152602081815260408083206001600160a01b038a168452909152902054838110156126615760405162461bcd60e51b815260040161070190613bb1565b6000858152602081815260408083206001600160a01b038b811685529252808320878503905590881682528120805486929061269e908490613acf565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4612102828888888888612b03565b60005b835181101561210257600084828151811061271e5761271e6139cc565b6020026020010151905060006001600160a01b0316876001600160a01b03161480612758575060008181526005602052604090205460ff16155b6127935760405162461bcd60e51b815260206004820152600c60248201526b151bdad95b881c185d5cd95960a21b6044820152606401610701565b8382815181106127a5576127a56139cc565b6020026020010151600014156127bb575061283a565b6001600160a01b038716158015906127f457508382815181106127e0576127e06139cc565b60200260200101516127f28883610699565b145b156128115760008181526008602052604090206128119088612bcd565b6001600160a01b038616156128385760008181526008602052604090206128389087612cfa565b505b8061284481613a11565b915050612701565b6001600160a01b0384163b156116325760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906128909089908990889088908890600401613c0e565b602060405180830381600087803b1580156128aa57600080fd5b505af19250505080156128da575060408051601f3d908101601f191682019092526128d791810190613c6c565b60015b612987576128e6613c89565b806308c379a0141561292057506128fb613ca5565b806129065750612922565b8060405162461bcd60e51b815260040161070191906130a2565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610701565b6001600160e01b0319811663bc197c8160e01b146121025760405162461bcd60e51b815260040161070190613d2e565b6001600160a01b038416612a175760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610701565b33612a288160008761261188612ab8565b6000848152602081815260408083206001600160a01b038916845290915281208054859290612a58908490613acf565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610d6a81600087878787612b03565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110612af257612af26139cc565b602090810291909101015292915050565b6001600160a01b0384163b156116325760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190612b479089908990889088908890600401613d76565b602060405180830381600087803b158015612b6157600080fd5b505af1925050508015612b91575060408051601f3d908101601f19168201909252612b8e91810190613c6c565b60015b612b9d576128e6613c89565b6001600160e01b0319811663f23a6e6160e01b146121025760405162461bcd60e51b815260040161070190613d2e565b6001600160a01b038116600090815260018301602052604090205480612bf257505050565b6000612bff600183613ab8565b8454909150600090612c1390600190613ab8565b9050818114612c9f576000856000018281548110612c3357612c336139cc565b60009182526020909120015486546001600160a01b0390911691508190879085908110612c6257612c626139cc565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394851617905592909116815260018701909152604090208390555b8454859080612cb057612cb0613dbb565b60008281526020808220830160001990810180546001600160a01b03191690559092019092556001600160a01b039590951681526001959095019093525050604082209190915550565b6001600160a01b038116600090815260018301602052604090205415612d1e575050565b8154600181810184556000848152602080822090930180546001600160a01b039095166001600160a01b031990951685179055845493815293019052604090912055565b82805482825590600052602060002090601f01602090048101928215612dfb5791602002820160005b83821115612dcc57833560ff1683826101000a81548160ff021916908360ff1602179055509260200192600101602081600001049283019260010302612d8b565b8015612df95782816101000a81549060ff0219169055600101602081600001049283019260010302612dcc565b505b50612e07929150612fa7565b5090565b828054828255906000526020600020908101928215612dfb579160200282015b82811115612dfb5781546001600160a01b0319166001600160a01b03843516178255602090920191600190910190612e2b565b828054828255906000526020600020908101928215612dfb579160200282015b82811115612dfb578235825591602001919060010190612e7e565b82805482825590600052602060002090600f01601090048101928215612dfb5791602002820160005b83821115612f0657833561ffff1683826101000a81548161ffff021916908361ffff1602179055509260200192600201602081600101049283019260010302612ec2565b8015612df95782816101000a81549061ffff0219169055600201602081600101049283019260010302612f06565b828054612f409061395c565b90600052602060002090601f016020900481019282612f625760008555612dfb565b82601f10612f7b5782800160ff19823516178555612dfb565b82800160010185558215612dfb5791820182811115612dfb578235825591602001919060010190612e7e565b5b80821115612e075760008155600101612fa8565b80356001600160a01b0381168114612fd357600080fd5b919050565b60008060408385031215612feb57600080fd5b612ff483612fbc565b946020939093013593505050565b6001600160e01b03198116811461237957600080fd5b60006020828403121561302a57600080fd5b813561303581613002565b9392505050565b60006020828403121561304e57600080fd5b5035919050565b6000815180845260005b8181101561307b5760208185018101518683018201520161305f565b8181111561308d576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006130356020830184613055565b6000806000806000806000806000806101408b8d0312156130d557600080fd5b8a35995060208b0135985060408b0135975060608b0135965060808b0135955060a08b0135945060c08b0135935060e08b013592506131176101008c01612fbc565b91506101208b013590509295989b9194979a5092959850565b6000806040838503121561314357600080fd5b8235915061315360208401612fbc565b90509250929050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b03811182821017156131975761319761315c565b6040525050565b60006001600160401b038211156131b7576131b761315c565b5060051b60200190565b600082601f8301126131d257600080fd5b813560206131df8261319e565b6040516131ec8282613172565b83815260059390931b850182019282810191508684111561320c57600080fd5b8286015b848110156132275780358352918301918301613210565b509695505050505050565b600082601f83011261324357600080fd5b81356001600160401b0381111561325c5761325c61315c565b604051613273601f8301601f191660200182613172565b81815284602083860101111561328857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156132bd57600080fd5b6132c686612fbc565b94506132d460208701612fbc565b935060408601356001600160401b03808211156132f057600080fd5b6132fc89838a016131c1565b9450606088013591508082111561331257600080fd5b61331e89838a016131c1565b9350608088013591508082111561333457600080fd5b5061334188828901613232565b9150509295509295909350565b60008083601f84011261336057600080fd5b5081356001600160401b0381111561337757600080fd5b6020830191508360208260051b850101111561339257600080fd5b9250929050565b60008060008060008060006080888a0312156133b457600080fd5b8735965060208801356001600160401b03808211156133d257600080fd5b6133de8b838c0161334e565b909850965060408a01359150808211156133f757600080fd5b6134038b838c0161334e565b909650945060608a013591508082111561341c57600080fd5b506134298a828b0161334e565b989b979a50959850939692959293505050565b60008060006060848603121561345157600080fd5b505081359360208301359350604090920135919050565b600081518084526020808501945080840160005b838110156134a15781516001600160a01b03168752958201959082019060010161347c565b509495945050505050565b600081518084526020808501945080840160005b838110156134a1578151875295820195908201906001016134c0565b6040815260006134ef6040830185613468565b828103602084015261350181856134ac565b95945050505050565b604080825283519082018190526000906020906060840190828701845b8281101561354757815161ffff1684529284019290840190600101613527565b5050508381038285015261355b8186613468565b9695505050505050565b6000806040838503121561357857600080fd5b82356001600160401b038082111561358f57600080fd5b818501915085601f8301126135a357600080fd5b813560206135b08261319e565b6040516135bd8282613172565b83815260059390931b85018201928281019150898411156135dd57600080fd5b948201945b83861015613602576135f386612fbc565b825294820194908201906135e2565b9650508601359250508082111561361857600080fd5b50613625858286016131c1565b9150509250929050565b60208152600061303560208301846134ac565b86151581528515156020820152841515604082015283606082015282608082015260c060a082015261368060c0820183516001600160a01b03169052565b602082015160e082015260006040830151610100818185015260608501519150610120828186015260808601519250610140838187015260a087015161016087015260c087015161018087015260e08701516101a0870152828701516101c0870152818701519350806101e0870152505050613700610200840182613055565b9998505050505050505050565b80358015158114612fd357600080fd5b60008060006040848603121561373257600080fd5b83356001600160401b0381111561374857600080fd5b6137548682870161334e565b909450925061376790506020850161370d565b90509250925092565b60008060008060006060868803121561378857600080fd5b8535945060208601356001600160401b03808211156137a657600080fd5b6137b289838a0161334e565b909650945060408801359150808211156137cb57600080fd5b506137d88882890161334e565b969995985093965092949392505050565b803561ffff81168114612fd357600080fd5b6000806040838503121561380e57600080fd5b82359150613153602084016137e9565b6000806040838503121561383157600080fd5b61383a83612fbc565b91506131536020840161370d565b6000806000806040858703121561385e57600080fd5b84356001600160401b038082111561387557600080fd5b6138818883890161334e565b9096509450602087013591508082111561389a57600080fd5b506138a78782880161334e565b95989497509550505050565b600080604083850312156138c657600080fd5b6138cf83612fbc565b915061315360208401612fbc565b600080600080600060a086880312156138f557600080fd5b6138fe86612fbc565b945061390c60208701612fbc565b9350604086013592506060860135915060808601356001600160401b0381111561393557600080fd5b61334188828901613232565b60006020828403121561395357600080fd5b61303582612fbc565b600181811c9082168061397057607f821691505b6020821081141561399157634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052603260045260246000fd5b6000602082840312156139f457600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b6000600019821415613a2557613a256139fb565b5060010190565b6000816000190483118215151615613a4657613a466139fb565b500290565b600082613a6857634e487b7160e01b600052601260045260246000fd5b500490565b6020808252600e908201526d092dce0eae840dad2e6dac2e8c6d60931b604082015260600190565b600060208284031215613aa757600080fd5b813560ff8116811461303557600080fd5b600082821015613aca57613aca6139fb565b500390565b60008219821115613ae257613ae26139fb565b500190565b6020808252600a908201526908af0c6cacac840dac2f60b31b604082015260600190565b600060208284031215613b1d57600080fd5b613035826137e9565b6000808335601e19843603018112613b3d57600080fd5b8301803591506001600160401b03821115613b5757600080fd5b60200191503681900382131561339257600080fd5b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b6040815260006134ef60408301856134ac565b6001600160a01b0386811682528516602082015260a060408201819052600090613c3a908301866134ac565b8281036060840152613c4c81866134ac565b90508281036080840152613c608185613055565b98975050505050505050565b600060208284031215613c7e57600080fd5b815161303581613002565b600060033d1115613ca25760046000803e5060005160e01c5b90565b600060443d1015613cb35790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715613ce257505050505090565b8285019150815181811115613cfa5750505050505090565b843d8701016020828501011115613d145750505050505090565b613d2360208286010187613172565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090613db090830184613055565b979650505050505050565b634e487b7160e01b600052603160045260246000fdfea2646970667358221220e5252791580c53e3c30a60ae7d12989ae384af3f9f6642976bf94cc8be2e01b164736f6c63430008090033
Deployed Bytecode
0x6080604052600436106101e25760003560e01c806375c5b6fc11610102578063ae5bc07311610095578063dc1ccbd111610064578063dc1ccbd1146105f0578063e985e9c514610610578063f242432a14610659578063f2fde38b1461067957600080fd5b8063ae5bc07314610570578063b38299af14610583578063bd85b039146105a3578063be7d8408146105d057600080fd5b80638da5cb5b116100d15780638da5cb5b146104d8578063a026da8c14610500578063a22cb46514610520578063a943c0c61461054057600080fd5b806375c5b6fc14610465578063786541c1146104855780638a2eb1ef146104a55780638b1a3696146104c557600080fd5b80633b9d15511161017a5780634f558e79116101495780634f558e79146103cf5780634f64b2be146103fe57806367d3294a14610430578063715018a61461045057600080fd5b80633b9d15511461032657806342c23abe1461034657806346ec7ab6146103745780634e1273f4146103a257600080fd5b806316a076cc116101b657806316a076cc146102a4578063178f4ab5146102c65780632e1a7d4d146102e65780632eb2c2d61461030657600080fd5b8062fdd58e146101e757806301ffc9a71461021a578063056d483c1461024a5780630e89341c14610277575b600080fd5b3480156101f357600080fd5b50610207610202366004612fd8565b610699565b6040519081526020015b60405180910390f35b34801561022657600080fd5b5061023a610235366004613018565b610733565b6040519015158152602001610211565b34801561025657600080fd5b5061020761026536600461303c565b60009081526008602052604090205490565b34801561028357600080fd5b5061029761029236600461303c565b610783565b60405161021191906130a2565b3480156102b057600080fd5b506102c46102bf3660046130b5565b610875565b005b3480156102d257600080fd5b5061023a6102e1366004613130565b61094f565b3480156102f257600080fd5b506102c461030136600461303c565b610bd5565b34801561031257600080fd5b506102c46103213660046132a5565b610cda565b34801561033257600080fd5b506102c4610341366004613399565b610d71565b34801561035257600080fd5b5061036661036136600461343c565b610ef1565b6040516102119291906134dc565b34801561038057600080fd5b5061039461038f36600461303c565b61107f565b60405161021192919061350a565b3480156103ae57600080fd5b506103c26103bd366004613565565b611171565b604051610211919061362f565b3480156103db57600080fd5b5061023a6103ea36600461303c565b600090815260036020526040902054151590565b34801561040a57600080fd5b5061041e61041936600461303c565b61129a565b60405161021196959493929190613642565b34801561043c57600080fd5b5061020761044b366004613130565b6113df565b34801561045c57600080fd5b506102c461140b565b34801561047157600080fd5b506102c461048036600461371d565b611441565b34801561049157600080fd5b506102c46104a036600461371d565b6114cc565b3480156104b157600080fd5b506102c46104c0366004613770565b61155a565b6102c46104d33660046137fb565b61163a565b3480156104e457600080fd5b506004546040516001600160a01b039091168152602001610211565b34801561050c57600080fd5b506102c461051b36600461303c565b611945565b34801561052c57600080fd5b506102c461053b36600461381e565b611b0d565b34801561054c57600080fd5b5061023a61055b36600461303c565b60056020526000908152604090205460ff1681565b6102c461057e3660046137fb565b611be4565b34801561058f57600080fd5b506102c461059e366004613770565b611fe7565b3480156105af57600080fd5b506102076105be36600461303c565b60009081526003602052604090205490565b3480156105dc57600080fd5b506102c46105eb36600461371d565b61210b565b3480156105fc57600080fd5b506102c461060b366004613848565b612191565b34801561061c57600080fd5b5061023a61062b3660046138b3565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205460ff1690565b34801561066557600080fd5b506102c46106743660046138dd565b61225a565b34801561068557600080fd5b506102c4610694366004613941565b6122e1565b60006001600160a01b03831661070a5760405162461bcd60e51b815260206004820152602b60248201527f455243313135353a2062616c616e636520717565727920666f7220746865207a60448201526a65726f206164647265737360a81b60648201526084015b60405180910390fd5b506000818152602081815260408083206001600160a01b03861684529091529020545b92915050565b60006001600160e01b03198216636cdb3d1360e11b148061076457506001600160e01b031982166303a24d0760e21b145b8061072d57506301ffc9a760e01b6001600160e01b031983161461072d565b6000818152600360205260409020546060906107d45760405162461bcd60e51b815260206004820152601060248201526f2737b71032bc34b9ba39903a37b5b2b760811b6044820152606401610701565b6000828152600660205260409020600c0180546107f09061395c565b80601f016020809104026020016040519081016040528092919081815260200182805461081c9061395c565b80156108695780601f1061083e57610100808354040283529160200191610869565b820191906000526020600020905b81548152906001019060200180831161084c57829003601f168201915b50505050509050919050565b6004546001600160a01b0316331461089f5760405162461bcd60e51b815260040161070190613997565b60008a815260036020526040902054156108e95760405162461bcd60e51b815260206004820152600b60248201526a151bdad95b88195e1a5cdd60aa1b6044820152606401610701565b6000998a52600660208190526040909a206004810199909955600589019790975597870194909455600786019290925560088501556009840155600a830155600b82015560030180546001600160a01b0319166001600160a01b03909216919091179055565b600082815260076020526040812054815b81811015610bca576000858152600760205260409020805482908110610988576109886139cc565b60009182526020918290209181049091015460ff601f9092166101000a900416158015610a5b575060008581526007602052604081206002018054839081106109d3576109d36139cc565b6000918252602090912001546040516370a0823160e01b81526001600160a01b038781166004830152909116906370a082319060240160206040518083038186803b158015610a2157600080fd5b505afa158015610a35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5991906139e2565b115b15610a6b5760019250505061072d565b6000858152600760205260409020805482908110610a8b57610a8b6139cc565b90600052602060002090602091828204019190069054906101000a900460ff1660ff166001148015610ba857506000858152600760205260408120600201805483908110610adb57610adb6139cc565b60009182526020808320909101548883526007909152604090912060010180546001600160a01b039092169162fdd58e91889186908110610b1e57610b1e6139cc565b6000918252602090912001546040516001600160e01b031960e085901b1681526001600160a01b039092166004830152602482015260440160206040518083038186803b158015610b6e57600080fd5b505afa158015610b82573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ba691906139e2565b115b15610bb85760019250505061072d565b80610bc281613a11565b915050610960565b506000949350505050565b6004546001600160a01b03163314610bff5760405162461bcd60e51b815260040161070190613997565b60008181526009602052604081209047905b8254811015610cd45760006103e8846000018381548110610c3457610c346139cc565b60009182526020909120601082040154610c5e91600f166002026101000a900461ffff1685613a2c565b610c689190613a4b565b9050836001018281548110610c7f57610c7f6139cc565b60009182526020822001546040516001600160a01b039091169183156108fc02918491818181858888f19350505050158015610cbf573d6000803e3d6000fd5b50508080610ccc90613a11565b915050610c11565b50505050565b6001600160a01b038516331480610cf65750610cf6853361062b565b610d5d5760405162461bcd60e51b815260206004820152603260248201527f455243313135353a207472616e736665722063616c6c6572206973206e6f74206044820152711bdddb995c881b9bdc88185c1c1c9bdd995960721b6064820152608401610701565b610d6a858585858561237c565b5050505050565b6004546001600160a01b03163314610d9b5760405162461bcd60e51b815260040161070190613997565b848314610dba5760405162461bcd60e51b815260040161070190613a6d565b808314610dd95760405162461bcd60e51b815260040161070190613a6d565b60005b85811015610e9357868682818110610df657610df66139cc565b9050602002016020810190610e0b9190613a95565b60ff161580610e435750868682818110610e2757610e276139cc565b9050602002016020810190610e3c9190613a95565b60ff166001145b610e815760405162461bcd60e51b815260206004820152600f60248201526e496e636f72726563742076616c756560881b6044820152606401610701565b80610e8b81613a11565b915050610ddc565b506000878152600760205260409020610ead908787612d62565b506000878152600760205260409020610eca906002018585612e0b565b506000878152600760205260409020610ee7906001018383612e5e565b5050505050505050565b6000838152600860205260409020546060908190808411610f125783610f14565b805b93506000610f228686613ab8565b90506000816001600160401b03811115610f3e57610f3e61315c565b604051908082528060200260200182016040528015610f67578160200160208202803683370190505b5090506000826001600160401b03811115610f8457610f8461315c565b604051908082528060200260200182016040528015610fad578160200160208202803683370190505b50905060005b838110156110705760008a8152600860205260408120610fd3838c613acf565b81548110610fe357610fe36139cc565b9060005260206000200160009054906101000a90046001600160a01b0316905080848381518110611016576110166139cc565b60200260200101906001600160a01b031690816001600160a01b031681525050611040818c610699565b838381518110611052576110526139cc565b6020908102919091010152508061106881613a11565b915050610fb3565b50909890975095505050505050565b600081815260096020908152604091829020805483518184028101840190945280845260609384936001840192849183018282801561110557602002820191906000526020600020906000905b82829054906101000a900461ffff1661ffff16815260200190600201906020826001010492830192600103820291508084116110cc5790505b505050505091508080548060200260200160405190810160405280929190818152602001828054801561116157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611143575b5050505050905091509150915091565b606081518351146111d65760405162461bcd60e51b815260206004820152602960248201527f455243313135353a206163636f756e747320616e6420696473206c656e677468604482015268040dad2e6dac2e8c6d60bb1b6064820152608401610701565b600083516001600160401b038111156111f1576111f161315c565b60405190808252806020026020018201604052801561121a578160200160208202803683370190505b50905060005b84518110156112925761126585828151811061123e5761123e6139cc565b6020026020010151858381518110611258576112586139cc565b6020026020010151610699565b828281518110611277576112776139cc565b602090810291909101015261128b81613a11565b9050611220565b509392505050565b6006602081815260009283526040928390208054600182015460028301548651610140810188526003850180546001600160a01b0316825260048601549682019690965260058501549781019790975294830154606087015260078301546080870152600883015460a0870152600983015460c0870152600a83015460e0870152600b83015461010087810191909152600c8401805460ff80861699938604811698620100009096041696939593916101208401916113589061395c565b80601f01602080910402602001604051908101604052809291908181526020018280546113849061395c565b80156113d15780601f106113a6576101008083540402835291602001916113d1565b820191906000526020600020905b8154815290600101906020018083116113b457829003601f168201915b505050505081525050905086565b60008281526007602090815260408083206001600160a01b038516845260030190915290205492915050565b6004546001600160a01b031633146114355760405162461bcd60e51b815260040161070190613997565b61143f600061255f565b565b6004546001600160a01b0316331461146b5760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd457816005600086868581811061148d5761148d6139cc565b90506020020135815260200190815260200160002060006101000a81548160ff02191690831515021790555080806114c490613a11565b91505061146e565b6004546001600160a01b031633146114f65760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd4578160066000868685818110611518576115186139cc565b90506020020135815260200190815260200160002060000160016101000a81548160ff021916908315150217905550808061155290613a11565b9150506114f9565b6004546001600160a01b031633146115845760405162461bcd60e51b815260040161070190613997565b8281146115a35760405162461bcd60e51b815260040161070190613a6d565b60005b83811015611632578282828181106115c0576115c06139cc565b905060200201356007600088815260200190815260200160002060030160008787858181106115f1576115f16139cc565b90506020020160208101906116069190613941565b6001600160a01b031681526020810191909152604001600020558061162a81613a11565b9150506115a6565b505050505050565b60008281526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c83018054939493919291610120840191906116d59061395c565b80601f01602080910402602001604051908101604052809291908181526020018280546117019061395c565b801561174e5780601f106117235761010080835404028352916020019161174e565b820191906000526020600020905b81548152906001019060200180831161173157829003601f168201915b50505091909252505083549192505060ff166117a25760405162461bcd60e51b8152602060048201526013602482015272436c61696d206973206e6f742061637469766560681b6044820152606401610701565b3233146117df5760405162461bcd60e51b815260206004820152600b60248201526a139bdd08185b1b1bddd95960aa1b6044820152606401610701565b8060a001518361ffff1611156118075760405162461bcd60e51b815260040161070190613ae7565b80608001518361ffff1661181b3387610699565b6118259190613acf565b11156118435760405162461bcd60e51b815260040161070190613ae7565b80602001518361ffff16836001015484600201546118619190613acf565b61186b9190613acf565b11156118a85760405162461bcd60e51b815260206004820152600c60248201526b115e18d95959081d1bdd185b60a21b6044820152606401610701565b6101008101516118bc9061ffff8516613a2c565b3410156119035760405162461bcd60e51b8152602060048201526015602482015274115d1a195c881d985b1d59481a5b98dbdc9c9958dd605a1b6044820152606401610701565b61192233858561ffff16604051806020016040528060008152506125b1565b8261ffff1682600201600082825461193a9190613acf565b909155505050505050565b6004546001600160a01b0316331461196f5760405162461bcd60e51b815260040161070190613997565b60008181526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c8301805493949391929161012084019190611a0a9061395c565b80601f0160208091040260200160405190810160405280929190818152602001828054611a369061395c565b8015611a835780601f10611a5857610100808354040283529160200191611a83565b820191906000526020600020905b815481529060010190602001808311611a6657829003601f168201915b50505091909252505083549192505062010000900460ff1615611ad75760405162461bcd60e51b815260206004820152600c60248201526b1519585b4818db185a5b595960a21b6044820152606401610701565b611afa8160000151848360600151604051806020016040528060008152506125b1565b50805462ff000019166201000017905550565b336001600160a01b0383161415611b785760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2073657474696e6720617070726f76616c20737461747573604482015268103337b91039b2b63360b91b6064820152608401610701565b3360008181526001602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b60008281526006602081815260408084208151610140810183526003820180546001600160a01b0316825260048301549482019490945260058201549281019290925292830154606082015260078301546080820152600883015460a0820152600983015460c0820152600a83015460e0820152600b830154610100820152600c8301805493949391929161012084019190611c7f9061395c565b80601f0160208091040260200160405190810160405280929190818152602001828054611cab9061395c565b8015611cf85780601f10611ccd57610100808354040283529160200191611cf8565b820191906000526020600020905b815481529060010190602001808311611cdb57829003601f168201915b505050919092525050835491925050610100900460ff16611d515760405162461bcd60e51b8152602060048201526013602482015272436c61696d206973206e6f742061637469766560681b6044820152606401610701565b323314611d8e5760405162461bcd60e51b815260206004820152600b60248201526a139bdd08185b1b1bddd95960aa1b6044820152606401610701565b611d98843361094f565b80611db057508261ffff16611dad85336113df565b10155b611deb5760405162461bcd60e51b815260206004820152600c60248201526b4e6f7420656c696769626c6560a01b6044820152606401610701565b611df584336113df565b1580611e0e57508261ffff16611e0b85336113df565b10155b611e2a5760405162461bcd60e51b815260040161070190613ae7565b60e08101511580611e4357508060e001518361ffff1611155b611e5f5760405162461bcd60e51b815260040161070190613ae7565b60c08101511580611e8c57508060c001518361ffff16611e7f3387610699565b611e899190613acf565b11155b611ea85760405162461bcd60e51b815260040161070190613ae7565b80604001518361ffff168360010154611ec19190613acf565b1115611efe5760405162461bcd60e51b815260206004820152600c60248201526b115e18d95959081d1bdd185b60a21b6044820152606401610701565b610100810151611f129061ffff8516613a2c565b341015611f595760405162461bcd60e51b8152602060048201526015602482015274115d1a195c881d985b1d59481a5b98dbdc9c9958dd605a1b6044820152606401610701565b8261ffff16611f6885336113df565b10611fa35760008481526007602090815260408083203384526003019091528120805461ffff86169290611f9d908490613ab8565b90915550505b611fc233858561ffff16604051806020016040528060008152506125b1565b6000848152600660205260408120600101805461ffff8616929061193a908490613acf565b6004546001600160a01b031633146120115760405162461bcd60e51b815260040161070190613997565b8281146120305760405162461bcd60e51b815260040161070190613a6d565b6000805b848110156120855785858281811061204e5761204e6139cc565b90506020020160208101906120639190613b0b565b6120719061ffff1683613acf565b91508061207d81613a11565b915050612034565b50806103e8146120cc5760405162461bcd60e51b8152602060048201526012602482015271496e76616c69642070657263656e7461676560701b6044820152606401610701565b60008681526009602052604090206120e5908686612e99565b506000868152600960205260409020612102906001018484612e0b565b50505050505050565b6004546001600160a01b031633146121355760405162461bcd60e51b815260040161070190613997565b60005b82811015610cd4578160066000868685818110612157576121576139cc565b60209081029290920135835250810191909152604001600020805460ff19169115159190911790558061218981613a11565b915050612138565b6004546001600160a01b031633146121bb5760405162461bcd60e51b815260040161070190613997565b8281146121da5760405162461bcd60e51b815260040161070190613a6d565b60005b83811015610d6a578282828181106121f7576121f76139cc565b90506020028101906122099190613b26565b6006600088888681811061221f5761221f6139cc565b9050602002013581526020019081526020016000206003016009019190612247929190612f34565b508061225281613a11565b9150506121dd565b6001600160a01b0385163314806122765750612276853361062b565b6122d45760405162461bcd60e51b815260206004820152602960248201527f455243313135353a2063616c6c6572206973206e6f74206f776e6572206e6f7260448201526808185c1c1c9bdd995960ba1b6064820152608401610701565b610d6a85858585856125db565b6004546001600160a01b0316331461230b5760405162461bcd60e51b815260040161070190613997565b6001600160a01b0381166123705760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610701565b6123798161255f565b50565b81518351146123de5760405162461bcd60e51b815260206004820152602860248201527f455243313135353a2069647320616e6420616d6f756e7473206c656e677468206044820152670dad2e6dac2e8c6d60c31b6064820152608401610701565b6001600160a01b0384166124045760405162461bcd60e51b815260040161070190613b6c565b336124138187878787876126fe565b60005b84518110156124f9576000858281518110612433576124336139cc565b602002602001015190506000858381518110612451576124516139cc565b602090810291909101810151600084815280835260408082206001600160a01b038e1683529093529190912054909150818110156124a15760405162461bcd60e51b815260040161070190613bb1565b6000838152602081815260408083206001600160a01b038e8116855292528083208585039055908b168252812080548492906124de908490613acf565b92505081905550505050806124f290613a11565b9050612416565b50846001600160a01b0316866001600160a01b0316826001600160a01b03167f4a39dc06d4c0dbc64b70af90fd698a233a518aa5d07e595d983b8c0526c8f7fb8787604051612549929190613bfb565b60405180910390a461163281878787878761284c565b600480546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6125bd848484846129b7565b6000838152600360205260408120805484929061193a908490613acf565b6001600160a01b0384166126015760405162461bcd60e51b815260040161070190613b6c565b3361262081878761261188612ab8565b61261a88612ab8565b876126fe565b6000848152602081815260408083206001600160a01b038a168452909152902054838110156126615760405162461bcd60e51b815260040161070190613bb1565b6000858152602081815260408083206001600160a01b038b811685529252808320878503905590881682528120805486929061269e908490613acf565b909155505060408051868152602081018690526001600160a01b03808916928a821692918616917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4612102828888888888612b03565b60005b835181101561210257600084828151811061271e5761271e6139cc565b6020026020010151905060006001600160a01b0316876001600160a01b03161480612758575060008181526005602052604090205460ff16155b6127935760405162461bcd60e51b815260206004820152600c60248201526b151bdad95b881c185d5cd95960a21b6044820152606401610701565b8382815181106127a5576127a56139cc565b6020026020010151600014156127bb575061283a565b6001600160a01b038716158015906127f457508382815181106127e0576127e06139cc565b60200260200101516127f28883610699565b145b156128115760008181526008602052604090206128119088612bcd565b6001600160a01b038616156128385760008181526008602052604090206128389087612cfa565b505b8061284481613a11565b915050612701565b6001600160a01b0384163b156116325760405163bc197c8160e01b81526001600160a01b0385169063bc197c81906128909089908990889088908890600401613c0e565b602060405180830381600087803b1580156128aa57600080fd5b505af19250505080156128da575060408051601f3d908101601f191682019092526128d791810190613c6c565b60015b612987576128e6613c89565b806308c379a0141561292057506128fb613ca5565b806129065750612922565b8060405162461bcd60e51b815260040161070191906130a2565b505b60405162461bcd60e51b815260206004820152603460248201527f455243313135353a207472616e7366657220746f206e6f6e20455243313135356044820152732932b1b2b4bb32b91034b6b83632b6b2b73a32b960611b6064820152608401610701565b6001600160e01b0319811663bc197c8160e01b146121025760405162461bcd60e51b815260040161070190613d2e565b6001600160a01b038416612a175760405162461bcd60e51b815260206004820152602160248201527f455243313135353a206d696e7420746f20746865207a65726f206164647265736044820152607360f81b6064820152608401610701565b33612a288160008761261188612ab8565b6000848152602081815260408083206001600160a01b038916845290915281208054859290612a58908490613acf565b909155505060408051858152602081018590526001600160a01b0380881692600092918516917fc3d58168c5ae7397731d063d5bbf3d657854427343f4c083240f7aacaa2d0f62910160405180910390a4610d6a81600087878787612b03565b60408051600180825281830190925260609160009190602080830190803683370190505090508281600081518110612af257612af26139cc565b602090810291909101015292915050565b6001600160a01b0384163b156116325760405163f23a6e6160e01b81526001600160a01b0385169063f23a6e6190612b479089908990889088908890600401613d76565b602060405180830381600087803b158015612b6157600080fd5b505af1925050508015612b91575060408051601f3d908101601f19168201909252612b8e91810190613c6c565b60015b612b9d576128e6613c89565b6001600160e01b0319811663f23a6e6160e01b146121025760405162461bcd60e51b815260040161070190613d2e565b6001600160a01b038116600090815260018301602052604090205480612bf257505050565b6000612bff600183613ab8565b8454909150600090612c1390600190613ab8565b9050818114612c9f576000856000018281548110612c3357612c336139cc565b60009182526020909120015486546001600160a01b0390911691508190879085908110612c6257612c626139cc565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394851617905592909116815260018701909152604090208390555b8454859080612cb057612cb0613dbb565b60008281526020808220830160001990810180546001600160a01b03191690559092019092556001600160a01b039590951681526001959095019093525050604082209190915550565b6001600160a01b038116600090815260018301602052604090205415612d1e575050565b8154600181810184556000848152602080822090930180546001600160a01b039095166001600160a01b031990951685179055845493815293019052604090912055565b82805482825590600052602060002090601f01602090048101928215612dfb5791602002820160005b83821115612dcc57833560ff1683826101000a81548160ff021916908360ff1602179055509260200192600101602081600001049283019260010302612d8b565b8015612df95782816101000a81549060ff0219169055600101602081600001049283019260010302612dcc565b505b50612e07929150612fa7565b5090565b828054828255906000526020600020908101928215612dfb579160200282015b82811115612dfb5781546001600160a01b0319166001600160a01b03843516178255602090920191600190910190612e2b565b828054828255906000526020600020908101928215612dfb579160200282015b82811115612dfb578235825591602001919060010190612e7e565b82805482825590600052602060002090600f01601090048101928215612dfb5791602002820160005b83821115612f0657833561ffff1683826101000a81548161ffff021916908361ffff1602179055509260200192600201602081600101049283019260010302612ec2565b8015612df95782816101000a81549061ffff0219169055600201602081600101049283019260010302612f06565b828054612f409061395c565b90600052602060002090601f016020900481019282612f625760008555612dfb565b82601f10612f7b5782800160ff19823516178555612dfb565b82800160010185558215612dfb5791820182811115612dfb578235825591602001919060010190612e7e565b5b80821115612e075760008155600101612fa8565b80356001600160a01b0381168114612fd357600080fd5b919050565b60008060408385031215612feb57600080fd5b612ff483612fbc565b946020939093013593505050565b6001600160e01b03198116811461237957600080fd5b60006020828403121561302a57600080fd5b813561303581613002565b9392505050565b60006020828403121561304e57600080fd5b5035919050565b6000815180845260005b8181101561307b5760208185018101518683018201520161305f565b8181111561308d576000602083870101525b50601f01601f19169290920160200192915050565b6020815260006130356020830184613055565b6000806000806000806000806000806101408b8d0312156130d557600080fd5b8a35995060208b0135985060408b0135975060608b0135965060808b0135955060a08b0135945060c08b0135935060e08b013592506131176101008c01612fbc565b91506101208b013590509295989b9194979a5092959850565b6000806040838503121561314357600080fd5b8235915061315360208401612fbc565b90509250929050565b634e487b7160e01b600052604160045260246000fd5b601f8201601f191681016001600160401b03811182821017156131975761319761315c565b6040525050565b60006001600160401b038211156131b7576131b761315c565b5060051b60200190565b600082601f8301126131d257600080fd5b813560206131df8261319e565b6040516131ec8282613172565b83815260059390931b850182019282810191508684111561320c57600080fd5b8286015b848110156132275780358352918301918301613210565b509695505050505050565b600082601f83011261324357600080fd5b81356001600160401b0381111561325c5761325c61315c565b604051613273601f8301601f191660200182613172565b81815284602083860101111561328857600080fd5b816020850160208301376000918101602001919091529392505050565b600080600080600060a086880312156132bd57600080fd5b6132c686612fbc565b94506132d460208701612fbc565b935060408601356001600160401b03808211156132f057600080fd5b6132fc89838a016131c1565b9450606088013591508082111561331257600080fd5b61331e89838a016131c1565b9350608088013591508082111561333457600080fd5b5061334188828901613232565b9150509295509295909350565b60008083601f84011261336057600080fd5b5081356001600160401b0381111561337757600080fd5b6020830191508360208260051b850101111561339257600080fd5b9250929050565b60008060008060008060006080888a0312156133b457600080fd5b8735965060208801356001600160401b03808211156133d257600080fd5b6133de8b838c0161334e565b909850965060408a01359150808211156133f757600080fd5b6134038b838c0161334e565b909650945060608a013591508082111561341c57600080fd5b506134298a828b0161334e565b989b979a50959850939692959293505050565b60008060006060848603121561345157600080fd5b505081359360208301359350604090920135919050565b600081518084526020808501945080840160005b838110156134a15781516001600160a01b03168752958201959082019060010161347c565b509495945050505050565b600081518084526020808501945080840160005b838110156134a1578151875295820195908201906001016134c0565b6040815260006134ef6040830185613468565b828103602084015261350181856134ac565b95945050505050565b604080825283519082018190526000906020906060840190828701845b8281101561354757815161ffff1684529284019290840190600101613527565b5050508381038285015261355b8186613468565b9695505050505050565b6000806040838503121561357857600080fd5b82356001600160401b038082111561358f57600080fd5b818501915085601f8301126135a357600080fd5b813560206135b08261319e565b6040516135bd8282613172565b83815260059390931b85018201928281019150898411156135dd57600080fd5b948201945b83861015613602576135f386612fbc565b825294820194908201906135e2565b9650508601359250508082111561361857600080fd5b50613625858286016131c1565b9150509250929050565b60208152600061303560208301846134ac565b86151581528515156020820152841515604082015283606082015282608082015260c060a082015261368060c0820183516001600160a01b03169052565b602082015160e082015260006040830151610100818185015260608501519150610120828186015260808601519250610140838187015260a087015161016087015260c087015161018087015260e08701516101a0870152828701516101c0870152818701519350806101e0870152505050613700610200840182613055565b9998505050505050505050565b80358015158114612fd357600080fd5b60008060006040848603121561373257600080fd5b83356001600160401b0381111561374857600080fd5b6137548682870161334e565b909450925061376790506020850161370d565b90509250925092565b60008060008060006060868803121561378857600080fd5b8535945060208601356001600160401b03808211156137a657600080fd5b6137b289838a0161334e565b909650945060408801359150808211156137cb57600080fd5b506137d88882890161334e565b969995985093965092949392505050565b803561ffff81168114612fd357600080fd5b6000806040838503121561380e57600080fd5b82359150613153602084016137e9565b6000806040838503121561383157600080fd5b61383a83612fbc565b91506131536020840161370d565b6000806000806040858703121561385e57600080fd5b84356001600160401b038082111561387557600080fd5b6138818883890161334e565b9096509450602087013591508082111561389a57600080fd5b506138a78782880161334e565b95989497509550505050565b600080604083850312156138c657600080fd5b6138cf83612fbc565b915061315360208401612fbc565b600080600080600060a086880312156138f557600080fd5b6138fe86612fbc565b945061390c60208701612fbc565b9350604086013592506060860135915060808601356001600160401b0381111561393557600080fd5b61334188828901613232565b60006020828403121561395357600080fd5b61303582612fbc565b600181811c9082168061397057607f821691505b6020821081141561399157634e487b7160e01b600052602260045260246000fd5b50919050565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052603260045260246000fd5b6000602082840312156139f457600080fd5b5051919050565b634e487b7160e01b600052601160045260246000fd5b6000600019821415613a2557613a256139fb565b5060010190565b6000816000190483118215151615613a4657613a466139fb565b500290565b600082613a6857634e487b7160e01b600052601260045260246000fd5b500490565b6020808252600e908201526d092dce0eae840dad2e6dac2e8c6d60931b604082015260600190565b600060208284031215613aa757600080fd5b813560ff8116811461303557600080fd5b600082821015613aca57613aca6139fb565b500390565b60008219821115613ae257613ae26139fb565b500190565b6020808252600a908201526908af0c6cacac840dac2f60b31b604082015260600190565b600060208284031215613b1d57600080fd5b613035826137e9565b6000808335601e19843603018112613b3d57600080fd5b8301803591506001600160401b03821115613b5757600080fd5b60200191503681900382131561339257600080fd5b60208082526025908201527f455243313135353a207472616e7366657220746f20746865207a65726f206164604082015264647265737360d81b606082015260800190565b6020808252602a908201527f455243313135353a20696e73756666696369656e742062616c616e636520666f60408201526939103a3930b739b332b960b11b606082015260800190565b6040815260006134ef60408301856134ac565b6001600160a01b0386811682528516602082015260a060408201819052600090613c3a908301866134ac565b8281036060840152613c4c81866134ac565b90508281036080840152613c608185613055565b98975050505050505050565b600060208284031215613c7e57600080fd5b815161303581613002565b600060033d1115613ca25760046000803e5060005160e01c5b90565b600060443d1015613cb35790565b6040516003193d81016004833e81513d6001600160401b038160248401118184111715613ce257505050505090565b8285019150815181811115613cfa5750505050505090565b843d8701016020828501011115613d145750505050505090565b613d2360208286010187613172565b509095945050505050565b60208082526028908201527f455243313135353a204552433131353552656365697665722072656a656374656040820152676420746f6b656e7360c01b606082015260800190565b6001600160a01b03868116825285166020820152604081018490526060810183905260a060808201819052600090613db090830184613055565b979650505050505050565b634e487b7160e01b600052603160045260246000fdfea2646970667358221220e5252791580c53e3c30a60ae7d12989ae384af3f9f6642976bf94cc8be2e01b164736f6c63430008090033
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.