Overview
TokenID
912
Total Transfers
-
Market
Onchain Market Cap
$0.00
Circulating Supply Market Cap
-
Other Info
Token Contract
Loading...
Loading
Loading...
Loading
Loading...
Loading
# | Exchange | Pair | Price | 24H Volume | % Volume |
---|
Contract Name:
VegasReapersContract
Compiler Version
v0.8.5+commit.a4f2e591
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.5; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Enumerable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/IERC721Metadata.sol"; import {MintWhitelist} from "./Mint.sol"; /* * Dev by @_MrCode_ * * * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ * */ contract VegasReapersContract is MintWhitelist { /// @notice constructor constructor( address[5] memory receiverAddresses_, uint256[5] memory receiverPercentages_, uint256 firstPaymentRemaining_ ) ERC721("Vegas Reapers", "VGS") { firstPaymentRemaining = firstPaymentRemaining_; receiverAddresses = receiverAddresses_; receiverPercentages = receiverPercentages_; for (uint8 i = 0; i < receiverAddresses_.length; i++) { addressToIndex[receiverAddresses_[i]] = i + 1; } royaltyStages.push(RoyaltyStage(block.timestamp, 0, 0, 0, 0)); // reserve first 1 tokens for the team for (uint256 tokenId = 1; tokenId <= 11; tokenId++) { setTokenId(tokenId); } // register the supported interfaces to conform to ERC721 via ERC165 _registerInterface(type(IERC721).interfaceId); _registerInterface(type(IERC721Metadata).interfaceId); _registerInterface(type(IERC721Enumerable).interfaceId); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "./MerkleProof.sol"; import "./Royalties.sol"; abstract contract BaseMint is Royalties { using SafeMath for uint256; /** * @dev See {IERC721-safeTransferFrom}. * @param from address from which to transfer the token * @param to address to which to transfer the token * @param tokenId to transfer */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { _updateTokenOwners(from, to, tokenId); _tryToChangeRoyaltyStage(); super.safeTransferFrom(from, to, tokenId); } /** * @dev See {IERC721-transferFrom}. * @param from address from which to transfer the token * @param to address to which to transfer the token * @param tokenId to transfer */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { _updateTokenOwners(from, to, tokenId); _tryToChangeRoyaltyStage(); super.transferFrom(from, to, tokenId); } /** * @dev Mint n tokens for an address * @param to address to mint tokens for * @param count_ number of tokens to mint */ function mintNTokensFor(address to, uint8 count_) public payable nonReentrant { require(publicMintingStarted, NOT_STARTED); _internalMint(to, count_, false); } /** * @dev Mint new tokens * @param count_ the number of tokens to be minted */ function _internalMint( address to, uint8 count_, bool addRoles ) internal { require(!paused(), "Minting is paused"); require(count_ > 0, CANT_MINT); uint256 startCount; if (addRoles) { require( numberOfMintedWhitelistTokens + count_ <= MAX_WHITELIST_TOKENS, "Cant mint more" ); numberOfMintedWhitelistTokens += count_; startCount = numberOfMintedTokensFor[msg.sender] - count_; require( msg.value == MINT_PRICE_WHITELIST.mul(count_), WRONG_BALANCE ); } else { require(msg.value == MINT_PRICE.mul(count_), WRONG_BALANCE); require(count_ <= MAX_TOKENS_PER_PURCHASE, TOO_MANY); require( totalSupply() + count_ <= MAX_TOKENS - MAX_RESERVED_TOKENS + mintedReservedTokens, TOO_MANY ); } for (uint8 i = 0; i < count_; i++) { uint256 tokenId = randomId(); if (addRoles) { startCount++; tokenRoles[tokenId] = startCount == 1 ? ROLE_LION : ROLE_INFERNAL; } _mintToken(to, tokenId); } distributePayout(count_); } /** * @dev Mint token for an address * @param to address to mint token for */ function _mintRandomToken(address to) internal { uint256 tokenId = randomId(); _mintToken(to, tokenId); } /** * @dev Mint token for an address * @param to address to mint token for * @param tokenId to be minted */ function _mintToken(address to, uint256 tokenId) internal { uint256 currentIndex = ownerTokenList[msg.sender].length; ownerTokenList[to].push(tokenId); ownedTokensDetails[to][tokenId] = NFTDetails( tokenId, currentIndex, block.timestamp, 0 ); royaltyStages[getLastRoyaltyStageIndex()].totalSupply++; _safeMint(to, tokenId); } function distributePayout(uint8 count_) internal { uint256 value = msg.value; if (firstPaymentRemaining > 0) { address reserve = receiverAddresses[receiverAddresses.length - 1]; if (value > firstPaymentRemaining) { value -= firstPaymentRemaining; sendValueTo(reserve, firstPaymentRemaining); firstPaymentRemaining = 0; } else { firstPaymentRemaining -= value; sendValueTo(reserve, value); return; } } if ( currentMaxTokensBeforeAutoWithdraw + count_ < MAX_TOKENS_BEFORE_AUTO_WITHDRAW && totalSupply() + count_ < MAX_TOKENS - MAX_RESERVED_TOKENS + mintedReservedTokens ) { currentMaxTokensBeforeAutoWithdraw += count_; for (uint8 i; i < receiverAddresses.length; i++) { currentTeamBalance[i] += (value * receiverPercentages[i]) / 100; } return; } currentMaxTokensBeforeAutoWithdraw = 0; for (uint8 i; i < receiverAddresses.length; i++) { uint256 valueToSend = (value * receiverPercentages[i]) / 100; valueToSend += currentTeamBalance[i]; currentTeamBalance[i] = 0; sendValueTo(receiverAddresses[i], valueToSend); } } /** * @dev Change token owner details mappings */ function _updateTokenOwners( address from, address to, uint256 tokenId ) internal { uint256 currentIndex = ownerTokenList[to].length; ownerTokenList[to].push(tokenId); ownedTokensDetails[to][tokenId] = NFTDetails( tokenId, currentIndex, block.timestamp, 0 ); _withdrawRoyaltyOfTokenTo(from, from, tokenId); NFTDetails storage details = ownedTokensDetails[from][tokenId]; details.endTime = block.timestamp; uint256[] storage fromList = ownerTokenList[from]; fromList[details.index] = fromList[fromList.length - 1]; fromList.pop(); } } abstract contract MintReserve is BaseMint { function canMintReserved(uint256 count_) internal view { require( mintedReservedTokens + count_ <= MAX_RESERVED_TOKENS, CANT_MINT ); } /** * @dev Mint reserved team tokens to a specific address * @param to addresses to mint token for * @param tokenIds numbers of tokens to be minted */ function mintReservedTeamTokensTo( address[] memory to, uint256[] memory tokenIds ) public onlyOwner { require(to.length == tokenIds.length, WRONG_LENGTH); canMintReserved(to.length); mintedReservedTokens += tokenIds.length; for (uint256 i; i < to.length; i++) { _mintToken(to[i], tokenIds[i]); } } /** * @dev Mint reserved tokens to a specific address * @param to address to mint token for * @param counts numbers of tokens to be minted */ function mintReservedTokensTo(address[] memory to, uint8[] memory counts) public onlyOwner { uint256 totalCount; for (uint256 i; i < counts.length; i++) { totalCount += counts[i]; } canMintReserved(totalCount); mintedReservedTokens += totalCount; for (uint256 i; i < to.length; i++) { address to_ = to[i]; for (uint256 j; j < counts[i]; j++) { _mintRandomToken(to_); } } } } abstract contract MintWhitelist is MintReserve, MerkleProof { using SafeMath for uint256; function startPublicMinting() public onlyOwner { require(!publicMintingStarted, ALREADY_ENABLED); whitelistMintingStarted = false; publicMintingStarted = true; } function flipWhitelistMinting() public onlyOwner { whitelistMintingStarted = !whitelistMintingStarted; } /** * @dev Mint a free token * @param to addresses to mint token for * @param proof to check if is whitelisted */ function mintForFee(address to, bytes32[] memory proof) public nonReentrant { hasValidProof(proof, merkleRootMintFree); require(!claimedFree[msg.sender], CANT_MINT); claimedFree[msg.sender] = true; _mintToken(to, randomId()); } /** * @dev Mint a free token * @param to addresses to mint token for * @param proof to check if is whitelisted */ function mintWhitelist( address to, uint8 count, bytes32[] memory proof ) public payable nonReentrant { hasValidProof(proof, merkleRoot); require( numberOfMintedTokensFor[msg.sender] + count <= MAX_WHITELIST_PER_PURCHASE, "Cant mint more" ); increaseAddressCount(count); _internalMint(to, count, true); } /** * @dev Mint one token if it has gold tokens * @param to address to mint tokens for * @param proof to check if is whitelisted */ function mintForFreeWithGold(address to, bytes32[] memory proof) public payable nonReentrant { hasValidProof(proof, merkleRootGoldMintFree); require(!claimedGoldFree[msg.sender], CANT_MINT); claimedGoldFree[msg.sender] = true; canMintFromGold(1); increaseAddressCount(1); _internalMint(to, 1, true); } /** * @dev Whitelist mint tokens to a specific address * @param to address to mint token for * @param count_ number of tokens to mint */ function mintWhitelistGoldTo(address to, uint8 count_) public payable nonReentrant { require(whitelistMintingStarted, NOT_STARTED); require(count_ > 0, "Mint more"); canMintFromGold(count_); increaseAddressCount(count_); _internalMint(to, count_, true); } function increaseAddressCount(uint256 count_) internal { uint256 currentMintedTokens = count_ + numberOfMintedTokensFor[msg.sender]; numberOfMintedTokensFor[msg.sender] = currentMintedTokens; addressRoles[msg.sender] = currentMintedTokens == 1 ? ROLE_LION : ROLE_INFERNAL; } function canMintFromGold(uint256 count_) internal { uint256[] memory tokenIds = soulToken.goldTokensByOwner(msg.sender); require(tokenIds.length > 0, CANT_MINT); uint256 tempCount = count_; uint256 finalCount; for (uint256 i; i < tokenIds.length; i++) { if (finalCount == count_) { break; } uint256 tokenId = tokenIds[i]; uint256 oldTokensCount = goldTokenUsed[tokenId]; uint256 tokensToMint = MAX_PRE_SALE_TOKENS - oldTokensCount; if (tokensToMint > tempCount) { tokensToMint = tempCount; } uint8 mintedTokensForGold = uint8(oldTokensCount + tokensToMint); goldTokenUsed[tokenId] = mintedTokensForGold; soulToken.setGoldRole(tokenId, mintedTokensForGold); finalCount += tokensToMint; tempCount -= tokensToMint; } require(finalCount == count_, "can't mint for gold"); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT 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; /** * @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; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT 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); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "@openzeppelin/contracts/access/Ownable.sol"; /** * @dev These functions deal with verification of Merkle trees (hash trees), */ abstract contract MerkleProof is Ownable { string private MERKLE_CHANGES_DISABLED = "MerkleRoot changes are disabled"; // merkle tree root used to validate if the sender can mint bytes32 public merkleRootMintFree; bytes32 public merkleRootGoldMintFree; bytes32 public merkleRoot; /** * @dev Set the merkle tree mint free root hash * @param merkleRoot_ hash to save */ function setMerkleRoot(bytes32 merkleRoot_) external onlyOwner { merkleRoot = merkleRoot_; } /** * @dev Set the merkle tree mint free root hash * @param merkleRootMintFree_ hash to save */ function setMerkleRootMintFree(bytes32 merkleRootMintFree_) external onlyOwner { merkleRootMintFree = merkleRootMintFree_; } /** * @dev Set the merkle tree gold mint free root hash * @param merkleRootGoldMintFree_ hash to save */ function setMerkleRootGoldMintFree(bytes32 merkleRootGoldMintFree_) external onlyOwner { merkleRootGoldMintFree = merkleRootGoldMintFree_; } /** * @dev Returns true if a leaf can be proved to be a part of a Merkle tree * defined by root. For this, a proof must be provided, containing * sibling hashes on the branch from the leaf to the root of the tree. Each * pair of leaves and each pair of pre-images are assumed to be sorted. * @param proof hashes to validate * @param merkleRoot_ merkle root to compare with */ function hasValidProof(bytes32[] memory proof, bytes32 merkleRoot_) internal view { bytes32 computedHash = keccak256(abi.encodePacked(msg.sender)); for (uint256 i = 0; i < proof.length; i++) { bytes32 proofElement = proof[i]; computedHash = keccak256( computedHash <= proofElement ? abi.encodePacked(computedHash, proofElement) : abi.encodePacked(proofElement, computedHash) ); } // Check if the computed hash (root) is equal to the provided root require(computedHash == merkleRoot_, "the proof is not valid"); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "./Balances.sol"; abstract contract Royalties is Balances, ReentrancyGuard { using SafeMath for uint256; function getValidRoyaltyIndex() private view returns (uint8 index) { index = addressToIndex[msg.sender]; require(index > 0, NO_ACCESS); } function withdrawTeamMemberRoyaltyTo(address to, uint256 valueToWithdraw) public { uint8 index = getValidRoyaltyIndex() - 1; uint256 value = currentTeamRoyalty[index]; require(value > 0, NO_BALANCE); require(value >= valueToWithdraw, TOO_MANY); valueToWithdraw = valueToWithdraw > 0 ? valueToWithdraw : value; currentTeamRoyalty[index] = value - valueToWithdraw; totalRoyaltyWithdrawed += valueToWithdraw; depositor.withdrawTo(to, valueToWithdraw); } /** * @dev Change the interval when the royalties can be shared * @param royaltyInterval_ time to collect royalties */ function changeRoyaltyInterval(uint256 royaltyInterval_) public onlyOwner { require(royaltyInterval != royaltyInterval_, SAME_VALUE); royaltyInterval = royaltyInterval_; } /** * @dev Create a new royalty stage to collecty royalties * Current stage would become available for royalty withdrawing */ function nextRoyaltyStage() public onlyOwner { require(canChangeRoyaltyStage(), DISABLED_CHANGES); _nextRoyaltyStage(); } /** * @dev Get last royalty stage index */ function getLastRoyaltyStageIndex() internal view returns (uint256) { return royaltyStages.length - 1; } /** * @dev Create a new royalty stage */ function _nextRoyaltyStage() private { uint256 valueAdded = address(depositor).balance - (totalRoyaltyAdded - totalRoyaltyWithdrawed); totalRoyaltyAdded += valueAdded; uint256 communityRoyalty = valueAdded / 5; // 20% uint256 teamRoyalty = valueAdded - communityRoyalty; for (uint8 i; i < receiverAddresses.length; i++) { currentTeamRoyalty[i] += (teamRoyalty * receiverPercentages[i]) / 100; } uint256 lastIndex = getLastRoyaltyStageIndex(); royaltyStages[lastIndex].endDate = block.timestamp; royaltyStages[lastIndex].amount = communityRoyalty; royaltyStages[lastIndex].totalSupply = totalSupply(); royaltyStages.push(RoyaltyStage(block.timestamp, 0, 0, 0, 0)); } /** * @dev Check if a new royalty stage can be created */ function canChangeRoyaltyStage() private view returns (bool) { RoyaltyStage memory lastStage = royaltyStages[ getLastRoyaltyStageIndex() ]; uint256 valueAdded = address(depositor).balance - (totalRoyaltyAdded - totalRoyaltyWithdrawed); return valueAdded > 0 && (block.timestamp - lastStage.startDate) >= royaltyInterval; } /** * @dev Create a new royalty stage if it's possible on each mint/transfer * Used when tokens are transferred */ function _tryToChangeRoyaltyStage() internal { if (canChangeRoyaltyStage()) { _nextRoyaltyStage(); } } /** * @dev Withdraw royalties for all royalty stages that the sender didn't collect royalties * The royalties are based on the tokens that the sender holded on each royalty stage * @param to address that will receive the royalty * @param inputTokenId for which to collect royalties */ function withdrawRoyaltyOfTokenTo(address to, uint256 inputTokenId) public { _withdrawRoyaltyOfTokenTo(msg.sender, to, inputTokenId); } function _withdrawRoyaltyOfTokenTo( address from, address to, uint256 inputTokenId ) internal { uint256 userLastIndex = ownerRoyaltyStageIndex[from]; uint256 lastIndex = getLastRoyaltyStageIndex(); require(userLastIndex < lastIndex, NO_BALANCE); bool hasInputToken = inputTokenId > 0; uint256 royaltyAmount; for (uint256 i = userLastIndex; i < lastIndex; i++) { RoyaltyStage memory stage = royaltyStages[i]; if (stage.amount == 0) { continue; } uint256 eligibleTokenCount; uint256 n = hasInputToken ? 1 : ownerTokenList[from].length; for (uint256 j; j < n; j++) { uint256 tokenId; if (hasInputToken) { tokenId = inputTokenId; } else { tokenId = ownerTokenList[from][j]; } if (royaltyTokenClaimed[i][tokenId]) { continue; } NFTDetails memory details = ownedTokensDetails[from][tokenId]; if ( stage.startDate <= details.starTime && details.endTime < stage.endDate ) { eligibleTokenCount++; royaltyTokenClaimed[i][tokenId] = true; } } if (eligibleTokenCount == 0) { continue; } royaltyStages[i].totalWithdrawals += eligibleTokenCount; royaltyAmount += (stage.amount / stage.totalSupply) * eligibleTokenCount; } require(royaltyAmount > 0, NO_BALANCE); if (!hasInputToken) { ownerRoyaltyStageIndex[from] = lastIndex; } totalRoyaltyWithdrawed += royaltyAmount; depositor.withdrawTo(to, royaltyAmount); } function withdrawUnclaimedRoyaltyTo(address to) public onlyOwner nonReentrant { uint256 royaltyToWitdraw; for ( uint256 i = unclaimedRoyaltyStageIndex; i < royaltyStages.length; i++ ) { RoyaltyStage memory stage = royaltyStages[i]; if ((block.timestamp - stage.startDate) < WITHDRAW_ROYALTY_TIME) { unclaimedRoyaltyStageIndex = i; break; } uint256 unclaimedCount = stage.totalSupply - stage.totalWithdrawals; if (unclaimedCount == 0) { continue; } royaltyStages[i].totalWithdrawals = stage.totalSupply; royaltyToWitdraw += unclaimedCount * (stage.amount / stage.totalSupply); } require(royaltyToWitdraw > 0, NO_BALANCE); totalRoyaltyWithdrawed += royaltyToWitdraw; depositor.withdrawTo(to, royaltyToWitdraw); } }
// 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; /** * @dev Contract module that helps prevent reentrant calls to a function. * * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier * available, which can be applied to functions to make sure there are no nested * (reentrant) calls to them. * * Note that because there is a single `nonReentrant` guard, functions marked as * `nonReentrant` may not call one another. This can be worked around by making * those functions `private`, and then adding `external` `nonReentrant` entry * points to them. * * TIP: If you would like to learn more about reentrancy and alternative ways * to protect against it, check out our blog post * https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul]. */ abstract contract ReentrancyGuard { // Booleans are more expensive than uint256 or any type that takes up a full // word because each write operation emits an extra SLOAD to first read the // slot's contents, replace the bits taken up by the boolean, and then write // back. This is the compiler's defense against contract upgrades and // pointer aliasing, and it cannot be disabled. // The values being non-zero value makes deployment a bit more expensive, // but in exchange the refund on every call to nonReentrant will be lower in // amount. Since refunds are capped to a percentage of the total // transaction's gas, it is best to keep them low in cases like this one, to // increase the likelihood of the full refund coming into effect. uint256 private constant _NOT_ENTERED = 1; uint256 private constant _ENTERED = 2; uint256 private _status; constructor() { _status = _NOT_ENTERED; } /** * @dev Prevents a contract from calling itself, directly or indirectly. * Calling a `nonReentrant` function from another `nonReentrant` * function is not supported. It is possible to prevent this from happening * by making the `nonReentrant` function external, and make it call a * `private` function that does the actual work. */ modifier nonReentrant() { // On the first call to nonReentrant, _notEntered will be true require(_status != _ENTERED, "ReentrancyGuard: reentrant call"); // Any calls to nonReentrant after this point will fail _status = _ENTERED; _; // By storing the original value once again, a refund is triggered (see // https://eips.ethereum.org/EIPS/eip-2200) _status = _NOT_ENTERED; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "./Base.sol"; abstract contract Balances is Base { function withdrawTeamMemberBalanceTo(address to, uint256 valueToWithdraw) public { uint8 index = getValidIndex() - 1; uint256 value = currentTeamBalance[index]; require(value > 0, NO_BALANCE); require(value >= valueToWithdraw, TOO_MANY); valueToWithdraw = valueToWithdraw > 0 ? valueToWithdraw : value; currentTeamBalance[index] = value - valueToWithdraw; sendValueTo(to, valueToWithdraw); } function getValidIndex() internal view returns (uint8 index) { index = addressToIndex[msg.sender]; require(index > 0, NO_ACCESS); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Pausable.sol"; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/introspection/ERC165Storage.sol"; import "./Fields.sol"; abstract contract Base is Ownable, Fields, ERC165Storage, ERC721Pausable, ERC721Enumerable { /* * accepts ether sent with no txData */ receive() external payable {} /* * refuses ether sent with txData that does not match any function signature in the contract */ fallback() external {} /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function pause() public onlyOwner { super._pause(); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function unpause() public onlyOwner { super._unpause(); } function setDepositor(IDepositor depositor_) public onlyOwner { depositor = depositor_; } function setSoulToken(ISoulToken soulToken_) public onlyOwner { soulToken = soulToken_; } /// @notice Allows gas-less trading on OpenSea by safelisting the ProxyRegistry of the user /// @dev Override isApprovedForAll to check first if current operator is owner's OpenSea proxy /// @inheritdoc ERC721 function isApprovedForAll(address owner, address operator) public view override returns (bool) { // allows gas less trading on OpenSea return super.isApprovedForAll(owner, operator); } /** * @dev baseURI for computing {tokenURI}. Empty by default, can be overwritten * in child contracts. */ function _baseURI() internal view override returns (string memory) { return baseURI; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721, ERC165Storage, ERC721Enumerable) returns (bool) { return super.supportsInterface(interfaceId); } /** * @dev Send an amount of value to a specific address * @param to_ address that will receive the value * @param value to be sent to the address */ function sendValueTo(address to_, uint256 value) internal { address payable to = payable(to_); (bool success, ) = to.call{value: value}(""); require(success, FUNCTION_CALL_ERROR); } /** * @dev See {ERC721-_beforeTokenTransfer}. * * Requirements: * * - the contract must not be paused. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override(ERC721Pausable, ERC721Enumerable) { super._beforeTokenTransfer(from, to, tokenId); } /** * @dev Set the baseURI to a given uri * @param baseURI_ string to save */ function changeBaseURI(string memory baseURI_) external onlyOwner { baseURI = baseURI_; } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function exists(uint256 tokenId) public view returns (bool) { return _exists(tokenId); } /** * @dev Get the list of tokens for a specific owner * @param _owner address to retrieve token ids for */ function tokensByOwner(address _owner) external view returns (uint256[] memory) { uint256 tokenCount = balanceOf(_owner); if (tokenCount == 0) { return new uint256[](0); } else { uint256[] memory result = new uint256[](tokenCount); for (uint256 index; index < tokenCount; index++) { result[index] = tokenOfOwnerByIndex(_owner, index); } return result; } } /** * @dev Withdraw remaining contract balance to owner */ function withdrawRemainingContractBalance() public onlyOwner { uint256 remainingBalance = address(this).balance; for (uint8 i; i < currentTeamBalance.length; i++) { remainingBalance -= currentTeamBalance[i]; } require(remainingBalance > 0, NO_BALANCE); sendValueTo(owner(), remainingBalance); } /** * Get random index and save it */ function randomId() internal returns (uint256) { uint256 totalSize = 1000 - totalSupply() - numberOfReservedTeamCustomTokens; uint256 index = uint256( keccak256( abi.encodePacked( nonce, block.coinbase, block.difficulty, block.timestamp ) ) ) % totalSize; totalSize--; uint256 value; uint256 currentValue = indices[index]; if (currentValue != 0) { value = currentValue; } else { value = index; } uint16 currentLastValue = indices[totalSize]; // Move last value to selected position if (currentLastValue == 0) { // Array position not initialized, so use position indices[index] = uint16(totalSize); } else { // Array position holds a value so use that indices[index] = currentLastValue; } nonce++; // Don't allow a zero index, start counting at 1 return value + 1; } /** * Set token index id */ function setTokenId(uint256 tokenId) internal { uint256 totalSize = 1000 - totalSupply() - tokenId; indices[tokenId - 1] = uint16(totalSize); nonce++; numberOfReservedTeamCustomTokens++; } function limitMaxWhitelistTokensTo(uint256 maxTokens) public onlyOwner { MAX_WHITELIST_TOKENS = maxTokens; } function limitMaxTokensTo(uint256 maxTokens) public onlyOwner { require( totalSupply() + MAX_RESERVED_TOKENS - mintedReservedTokens <= maxTokens, "Invalid number of tokens" ); MAX_TOKENS = maxTokens; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC721.sol"; import "../../../security/Pausable.sol"; /** * @dev ERC721 token with pausable token transfers, minting and burning. * * Useful for scenarios such as preventing trades until the end of an evaluation * period, or having an emergency switch for freezing all token transfers in the * event of a large bug. */ abstract contract ERC721Pausable is ERC721, Pausable { /** * @dev See {ERC721-_beforeTokenTransfer}. * * Requirements: * * - the contract must not be paused. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); require(!paused(), "ERC721Pausable: token transfer while paused"); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC721.sol"; import "./IERC721Enumerable.sol"; /** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */ abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex; // Array with all token ids, used for enumeration uint256[] private _allTokens; // Mapping from token id to position in the allTokens array mapping(uint256 => uint256) private _allTokensIndex; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; } /** * @dev See {IERC721Enumerable-tokenByIndex}. */ function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` cannot be the zero address. * - `to` cannot be the zero address. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnumeration(from, tokenId); } if (to == address(0)) { _removeTokenFromAllTokensEnumeration(tokenId); } else if (to != from) { _addTokenToOwnerEnumeration(to, tokenId); } } /** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */ function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = ERC721.balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; } /** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */ function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); } /** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes). * This has O(1) time complexity, but alters the order of the _ownedTokens array. * @param from address representing the previous owner of the given token ID * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address */ function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = ERC721.balanceOf(from) - 1; uint256 tokenIndex = _ownedTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary if (tokenIndex != lastTokenIndex) { uint256 lastTokenId = _ownedTokens[from][lastTokenIndex]; _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index } // This also deletes the contents at the last position of the array delete _ownedTokensIndex[tokenId]; delete _ownedTokens[from][lastTokenIndex]; } /** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */ function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding // an 'if' statement (like in _removeTokenFromOwnerEnumeration) uint256 lastTokenId = _allTokens[lastTokenIndex]; _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index // This also deletes the contents at the last position of the array delete _allTokensIndex[tokenId]; _allTokens.pop(); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ERC165.sol"; /** * @dev Storage based implementation of the {IERC165} interface. * * Contracts may inherit from this and call {_registerInterface} to declare * their support of an interface. */ abstract contract ERC165Storage is ERC165 { /** * @dev Mapping of interface ids to whether or not it's supported. */ mapping(bytes4 => bool) private _supportedInterfaces; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return super.supportsInterface(interfaceId) || _supportedInterfaces[interfaceId]; } /** * @dev Registers the contract as an implementer of the interface defined by * `interfaceId`. Support of the actual ERC165 interface is automatic and * registering its interface id is not required. * * See {IERC165-supportsInterface}. * * Requirements: * * - `interfaceId` cannot be the ERC165 invalid interface (`0xffffffff`). */ function _registerInterface(bytes4 interfaceId) internal virtual { require(interfaceId != 0xffffffff, "ERC165: invalid interface id"); _supportedInterfaces[interfaceId] = true; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.5; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; interface IDepositor { function getContractBalance() external view returns (uint256); function withdrawTo(address to_, uint256 value) external; } interface ISoulToken { function goldTokensByOwner(address _owner) external view returns (uint256[] memory); function ownerOf(uint256 tokenId) external view returns (address); function setGoldRole(uint256 tokenId, uint256 numberOfMintedTokens) external; } contract Fields { // struct that holds information about when a token was created/transferred struct NFTDetails { uint256 tokenId; uint256 index; uint256 starTime; uint256 endTime; } // struct that holds information about royalty stages to reward token owners struct RoyaltyStage { uint256 startDate; uint256 endDate; uint256 amount; uint256 totalSupply; uint256 totalWithdrawals; } // nonce to be used on generating the random token id uint16 nonce; uint16[1000] indices; // maximum number of tokens that can be minted. can be changed to lower number uint256 internal MAX_TOKENS = 1000; uint256 internal MAX_WHITELIST_TOKENS = 500; uint256 internal MAX_WHITELIST_PER_PURCHASE = 5; // maximum number of tokens that can be minted in a single transaction uint256 internal constant MAX_TOKENS_PER_PURCHASE = 15; // maximum number of tokens that can be minted at pre-sale uint256 internal constant MAX_PRE_SALE_TOKENS = 10; // max number of reserved tokens uint256 internal constant MAX_RESERVED_TOKENS = 60; // minted reserved tokens uint256 internal mintedReservedTokens; uint256 internal firstPaymentRemaining; // the price to mint a token uint256 internal constant MINT_PRICE = 0.06 ether; uint256 internal constant MINT_PRICE_WHITELIST = 0.04 ether; uint8 internal currentMaxTokensBeforeAutoWithdraw; uint8 internal constant MAX_TOKENS_BEFORE_AUTO_WITHDRAW = 25; uint8 numberOfReservedTeamCustomTokens; uint256 public numberOfMintedWhitelistTokens; bool public whitelistMintingStarted = true; bool public publicMintingStarted; string internal constant ROLE_LION = "LION"; string internal constant ROLE_INFERNAL = "INFERNAL"; mapping(address => string) public addressRoles; mapping(uint256 => string) public tokenRoles; mapping(address => uint256) public numberOfMintedTokensFor; mapping(uint256 => uint8) goldTokenUsed; mapping(address => bool) internal claimedFree; mapping(address => bool) internal claimedGoldFree; mapping(address => uint8) internal mintedWhitelist; // receiver address to ge the funds address[5] internal receiverAddresses; // receiver percentage of total funds uint256[5] internal receiverPercentages; // current balance to withdraw from contract by a specific address uint256[5] internal currentTeamBalance; // mapping from address to index of receiverAddresses array mapping(address => uint8) internal addressToIndex; // current royalty to withdraw from contract by a specific address uint256[5] internal currentTeamRoyalty; // mapping from address to index of royalty receiverAddresses array mapping(address => uint8) internal addressRoyaltyToIndex; // the baseURI for token metadata string internal baseURI; // mapping from owner to list of token ids mapping(address => uint256[]) internal ownerTokenList; // mapping from token ID to token details of the owner tokens list mapping(address => mapping(uint256 => NFTDetails)) internal ownedTokensDetails; // mapping from owner address to the stage index to start collecting royalties mapping(address => uint256) internal ownerRoyaltyStageIndex; // the interval in which royalty gets collected uint256 public royaltyInterval = 4 weeks; // royalty stage details RoyaltyStage[] public royaltyStages; // mapping from owner address to the stage index to start collecting royalties mapping(uint256 => mapping(uint256 => bool)) internal royaltyTokenClaimed; // total royalty added to the depositor uint256 internal totalRoyaltyAdded; // total royalty withdrawed uint256 internal totalRoyaltyWithdrawed; // index from which the owner will withdraw the unclaimed rewards; uint256 internal unclaimedRoyaltyStageIndex; uint256 internal constant WITHDRAW_ROYALTY_TIME = 365 days; IDepositor internal depositor; ISoulToken internal soulToken; string internal constant SAME_VALUE = "same value"; string internal constant WRONG_BALANCE = "wrong balance"; string internal constant DISABLED_CHANGES = "disabled changes"; string internal constant NO_BALANCE = "no balance"; string internal constant WRONG_LENGTH = "wrong length"; string internal constant TOO_MANY = "too many"; string internal constant NOT_STARTED = "not started"; string internal constant NO_ACCESS = "no access"; string internal constant CANT_MINT = "can't mint"; string internal constant ALREADY_ENABLED = "already enabled"; string internal constant FUNCTION_CALL_ERROR = "Function call not successful"; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "metadata": { "useLiteralContent": true }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address[5]","name":"receiverAddresses_","type":"address[5]"},{"internalType":"uint256[5]","name":"receiverPercentages_","type":"uint256[5]"},{"internalType":"uint256","name":"firstPaymentRemaining_","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"approved","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"owner","type":"address"},{"indexed":true,"internalType":"address","name":"operator","type":"address"},{"indexed":false,"internalType":"bool","name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"addressRoles","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"string","name":"baseURI_","type":"string"}],"name":"changeBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"royaltyInterval_","type":"uint256"}],"name":"changeRoyaltyInterval","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"exists","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"flipWhitelistMinting","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"maxTokens","type":"uint256"}],"name":"limitMaxTokensTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"maxTokens","type":"uint256"}],"name":"limitMaxWhitelistTokensTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"merkleRoot","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRootGoldMintFree","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"merkleRootMintFree","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"mintForFee","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"mintForFreeWithGold","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint8","name":"count_","type":"uint8"}],"name":"mintNTokensFor","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address[]","name":"to","type":"address[]"},{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"mintReservedTeamTokensTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"to","type":"address[]"},{"internalType":"uint8[]","name":"counts","type":"uint8[]"}],"name":"mintReservedTokensTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint8","name":"count","type":"uint8"},{"internalType":"bytes32[]","name":"proof","type":"bytes32[]"}],"name":"mintWhitelist","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint8","name":"count_","type":"uint8"}],"name":"mintWhitelistGoldTo","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"nextRoyaltyStage","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"numberOfMintedTokensFor","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"numberOfMintedWhitelistTokens","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMintingStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"royaltyInterval","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"royaltyStages","outputs":[{"internalType":"uint256","name":"startDate","type":"uint256"},{"internalType":"uint256","name":"endDate","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"uint256","name":"totalSupply","type":"uint256"},{"internalType":"uint256","name":"totalWithdrawals","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IDepositor","name":"depositor_","type":"address"}],"name":"setDepositor","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"merkleRoot_","type":"bytes32"}],"name":"setMerkleRoot","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"merkleRootGoldMintFree_","type":"bytes32"}],"name":"setMerkleRootGoldMintFree","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"merkleRootMintFree_","type":"bytes32"}],"name":"setMerkleRootMintFree","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract ISoulToken","name":"soulToken_","type":"address"}],"name":"setSoulToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startPublicMinting","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"tokenRoles","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_owner","type":"address"}],"name":"tokensByOwner","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"whitelistMintingStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdrawRemainingContractBalance","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"inputTokenId","type":"uint256"}],"name":"withdrawRoyaltyOfTokenTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"valueToWithdraw","type":"uint256"}],"name":"withdrawTeamMemberBalanceTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"valueToWithdraw","type":"uint256"}],"name":"withdrawTeamMemberRoyaltyTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"withdrawUnclaimedRoyaltyTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]
Contract Creation Code
6103e860409081556101f460415560056042556047805460ff191660011790556224ea0060695560c09052601f60808190527f4d65726b6c65526f6f74206368616e676573206172652064697361626c65640060a09081526200006691607e919062000509565b503480156200007457600080fd5b50604051620059c3380380620059c3833981016040819052620000979162000688565b6040518060400160405280600d81526020016c5665676173205265617065727360981b8152506040518060400160405280600381526020016256475360e81b815250620000f3620000ed6200034c60201b60201c565b62000350565b81516200010890607290602085019062000509565b5080516200011e90607390602084019062000509565b50506078805460ff19169055506001607d55604481905562000144604f84600562000598565b50620001546054836005620005e3565b5060005b60058160ff161015620001e1576200017281600162000765565b605e6000868460ff16600581106200018e576200018e62000860565b60200201516001600160a01b03166001600160a01b0316815260200190815260200160002060006101000a81548160ff021916908360ff1602179055508080620001d89062000827565b91505062000158565b506040805160a0810182524281526000602082018181529282018181526060830182815260808401838152606a8054600180820183559190955294517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5160059095029485015594517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5284015590517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a53830155517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5482015591517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a55909201919091555b600b81116200030c57620002f781620003a0565b80620003038162000809565b915050620002e3565b506200031f6380ac58cd60e01b62000485565b62000331635b5e139f60e01b62000485565b6200034363780e9d6360e01b62000485565b50505062000876565b3390565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b600081620003ad607b5490565b620003bb906103e86200078d565b620003c791906200078d565b9050806001620003d881856200078d565b6103e88110620003ec57620003ec62000860565b601091828204019190066002026101000a81548161ffff021916908361ffff1602179055506000601481819054906101000a900461ffff16809291906200043390620007e4565b825461ffff91821661010093840a90810292021916179091556045805460ff9290049190911691506001620004688362000827565b91906101000a81548160ff021916908360ff160217905550505050565b6001600160e01b03198082161415620004e45760405162461bcd60e51b815260206004820152601c60248201527f4552433136353a20696e76616c696420696e7465726661636520696400000000604482015260640160405180910390fd5b6001600160e01b0319166000908152607160205260409020805460ff19166001179055565b8280546200051790620007a7565b90600052602060002090601f0160209004810192826200053b576000855562000586565b82601f106200055657805160ff191683800117855562000586565b8280016001018555821562000586579182015b828111156200058657825182559160200191906001019062000569565b506200059492915062000613565b5090565b826005810192821562000586579160200282015b828111156200058657825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190620005ac565b82600581019282156200058657916020028201828111156200058657825182559160200191906001019062000569565b5b8082111562000594576000815560010162000614565b600082601f8301126200063c57600080fd5b620006466200072e565b80838560a0860111156200065957600080fd5b60005b60058110156200067d5781518452602093840193909101906001016200065c565b509095945050505050565b600080600061016084860312156200069f57600080fd5b84601f850112620006af57600080fd5b620006b96200072e565b808560a0870188811115620006cd57600080fd5b6000805b6005811015620007085783516001600160a01b0381168114620006f2578283fd5b86526020958601959390930192600101620006d1565b50508296506200071989826200062a565b95505050505061014084015190509250925092565b60405160a081016001600160401b03811182821017156200075f57634e487b7160e01b600052604160045260246000fd5b60405290565b600060ff821660ff84168060ff038211156200078557620007856200084a565b019392505050565b600082821015620007a257620007a26200084a565b500390565b600181811c90821680620007bc57607f821691505b60208210811415620007de57634e487b7160e01b600052602260045260246000fd5b50919050565b600061ffff80831681811415620007ff57620007ff6200084a565b6001019392505050565b60006000198214156200082057620008206200084a565b5060010190565b600060ff821660ff8114156200084157620008416200084a565b60010192915050565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b61513d80620008866000396000f3fe6080604052600436106103905760003560e01c80636c6ccb4b116101dc578063b0f4ef4d11610102578063e6106bd5116100a0578063f2fde38b1161006f578063f2fde38b14610a33578063f4ed63ca14610a53578063fb3fa71614610a69578063fc7de55a14610a8957610397565b8063e6106bd5146109b3578063e7e50673146109d3578063e985e9c5146109f3578063f2c098b714610a1357610397565b8063c712810c116100dc578063c712810c1461093d578063c87b56dd14610953578063d9eec5ca14610973578063db9accf61461099357610397565b8063b0f4ef4d146108dd578063b88d4fde146108fd578063c3a2ea551461091d57610397565b80638f4839001161017a578063a209952311610149578063a209952314610835578063a22cb46514610855578063a2b8d52d14610875578063abe559681461089557610397565b80638f483900146107d557806392e87b59146107f557806395d89b411461080b5780639da058e91461082057610397565b80637cb64759116101b65780637cb647591461076f57806381b66ba01461078f5780638456cb59146107a25780638da5cb5b146107b757610397565b80636c6ccb4b1461071a57806370a082311461073a578063715018a61461075a57610397565b806335c347fa116102c1578063454223981161025f5780635896996e1161022e5780635896996e1461069f5780635c975abb146106cc5780636352211e146106e4578063646acd011461070457610397565b8063454223981461062c5780634f558e791461063f5780634f6ccce71461065f5780635815885d1461067f57610397565b80633f1924d01161029b5780633f1924d0146105bd5780633f4ba83a146105d757806342842e0e146105ec57806344f195d31461060c57610397565b806335c347fa1461055e57806337951d8f1461057d57806339a0c6f91461059d57610397565b806318160ddd1161032e5780632eb4a7ab116103085780632eb4a7ab146105005780632f745c591461051657806331086272146105365780633225d3df1461054957610397565b806318160ddd146104ac5780631bb59fcb146104cb57806323b872dd146104e057610397565b8063081812fc1161036a578063081812fc14610414578063095ea7b31461044c57806309c65e581461046c5780630d381a281461047f57610397565b806301ffc9a7146103a657806306fdde03146103db578063071f172a146103fd57610397565b3661039757005b3480156103a357600080fd5b50005b3480156103b257600080fd5b506103c66103c1366004614c05565b610aa9565b60405190151581526020015b60405180910390f35b3480156103e757600080fd5b506103f0610aba565b6040516103d29190614d64565b34801561040957600080fd5b50610412610b4c565b005b34801561042057600080fd5b5061043461042f366004614bec565b610bd9565b6040516001600160a01b0390911681526020016103d2565b34801561045857600080fd5b50610412610467366004614918565b610c6e565b61041261047a366004614944565b610d84565b34801561048b57600080fd5b5061049f61049a36600461477e565b610e0d565b6040516103d29190614d20565b3480156104b857600080fd5b50607b545b6040519081526020016103d2565b3480156104d757600080fd5b50610412610ecc565b3480156104ec57600080fd5b506104126104fb3660046147d4565b610f0a565b34801561050c57600080fd5b506104bd60815481565b34801561052257600080fd5b506104bd610531366004614918565b610f28565b610412610544366004614895565b610fbe565b34801561055557600080fd5b50610412611087565b34801561056a57600080fd5b506047546103c690610100900460ff1681565b34801561058957600080fd5b5061041261059836600461477e565b611156565b3480156105a957600080fd5b506104126105b8366004614c3f565b6111a2565b3480156105c957600080fd5b506047546103c69060ff1681565b3480156105e357600080fd5b506104126111e3565b3480156105f857600080fd5b506104126106073660046147d4565b611215565b34801561061857600080fd5b506104126106273660046149d9565b611233565b61041261063a366004614979565b611323565b34801561064b57600080fd5b506103c661065a366004614bec565b6113db565b34801561066b57600080fd5b506104bd61067a366004614bec565b6113fa565b34801561068b57600080fd5b5061041261069a366004614bec565b61148d565b3480156106ab57600080fd5b506104bd6106ba36600461477e565b604a6020526000908152604090205481565b3480156106d857600080fd5b5060785460ff166103c6565b3480156106f057600080fd5b506104346106ff366004614bec565b6114bc565b34801561071057600080fd5b506104bd60695481565b34801561072657600080fd5b50610412610735366004614bec565b611533565b34801561074657600080fd5b506104bd61075536600461477e565b6115d3565b34801561076657600080fd5b5061041261165a565b34801561077b57600080fd5b5061041261078a366004614bec565b61168e565b61041261079d366004614944565b6116bd565b3480156107ae57600080fd5b5061041261178f565b3480156107c357600080fd5b506000546001600160a01b0316610434565b3480156107e157600080fd5b506104126107f0366004614895565b6117c1565b34801561080157600080fd5b506104bd607f5481565b34801561081757600080fd5b506103f0611879565b34801561082c57600080fd5b50610412611888565b34801561084157600080fd5b50610412610850366004614918565b611914565b34801561086157600080fd5b506104126108703660046148e5565b611a13565b34801561088157600080fd5b50610412610890366004614918565b611ad8565b3480156108a157600080fd5b506108b56108b0366004614bec565b611ae3565b604080519586526020860194909452928401919091526060830152608082015260a0016103d2565b3480156108e957600080fd5b506104126108f8366004614a9b565b611b24565b34801561090957600080fd5b50610412610918366004614815565b611c3a565b34801561092957600080fd5b50610412610938366004614bec565b611c6c565b34801561094957600080fd5b506104bd60465481565b34801561095f57600080fd5b506103f061096e366004614bec565b611c9b565b34801561097f57600080fd5b5061041261098e36600461477e565b611d76565b34801561099f57600080fd5b506104126109ae366004614bec565b611fb8565b3480156109bf57600080fd5b506104126109ce366004614918565b61202f565b3480156109df57600080fd5b506103f06109ee366004614bec565b6121a4565b3480156109ff57600080fd5b506103c6610a0e36600461479b565b61223e565b348015610a1f57600080fd5b50610412610a2e36600461477e565b61226e565b348015610a3f57600080fd5b50610412610a4e36600461477e565b6122ba565b348015610a5f57600080fd5b506104bd60805481565b348015610a7557600080fd5b506103f0610a8436600461477e565b612352565b348015610a9557600080fd5b50610412610aa4366004614bec565b61236b565b6000610ab48261239a565b92915050565b606060728054610ac990614fc8565b80601f0160208091040260200160405190810160405280929190818152602001828054610af590614fc8565b8015610b425780601f10610b1757610100808354040283529160200191610b42565b820191906000526020600020905b815481529060010190602001808311610b2557829003601f168201915b5050505050905090565b6000546001600160a01b03163314610b7f5760405162461bcd60e51b8152600401610b7690614dc9565b60405180910390fd5b610b876123bf565b6040518060400160405280601081526020016f64697361626c6564206368616e67657360801b81525090610bce5760405162461bcd60e51b8152600401610b769190614d64565b50610bd7612478565b565b6000818152607460205260408120546001600160a01b0316610c525760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b76565b506000908152607660205260409020546001600160a01b031690565b6000610c79826114bc565b9050806001600160a01b0316836001600160a01b03161415610ce75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610b76565b336001600160a01b0382161480610d035750610d03813361223e565b610d755760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b76565b610d7f83836126dc565b505050565b6002607d541415610da75760405162461bcd60e51b8152600401610b7690614e4f565b6002607d5560475460408051808201909152600b81526a1b9bdd081cdd185c9d195960aa1b602082015290610100900460ff16610df75760405162461bcd60e51b8152600401610b769190614d64565b50610e048282600061274a565b50506001607d55565b60606000610e1a836115d3565b905080610e3b5760408051600080825260208201909252905b509392505050565b60008167ffffffffffffffff811115610e5657610e566150c6565b604051908082528060200260200182016040528015610e7f578160200160208202803683370190505b50905060005b82811015610e3357610e978582610f28565b828281518110610ea957610ea96150b0565b602090810291909101015280610ebe8161501f565b915050610e85565b50919050565b6000546001600160a01b03163314610ef65760405162461bcd60e51b8152600401610b7690614dc9565b6047805460ff19811660ff90911615179055565b610f15838383612aa7565b610f1d612bdd565b610d7f838383612bf2565b6000610f33836115d3565b8210610f955760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610b76565b506001600160a01b03919091166000908152607960209081526040808320938352929052205490565b6002607d541415610fe15760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55608054610ff4908290612c23565b336000908152604d6020908152604091829020548251808401909352600a83526918d85b89dd081b5a5b9d60b21b9183019190915260ff161561104a5760405162461bcd60e51b8152600401610b769190614d64565b50336000908152604d60205260409020805460ff1916600190811790915561107190612d40565b61107b6001612f7b565b610e048260018061274a565b6000546001600160a01b031633146110b15760405162461bcd60e51b8152600401610b7690614dc9565b4760005b60058160ff1610156110f75760598160ff16600581106110d7576110d76150b0565b01546110e39083614f4b565b9150806110ef8161503a565b9150506110b5565b5060408051808201909152600a8152696e6f2062616c616e636560b01b6020820152816111375760405162461bcd60e51b8152600401610b769190614d64565b5061115361114d6000546001600160a01b031690565b82613019565b50565b6000546001600160a01b031633146111805760405162461bcd60e51b8152600401610b7690614dc9565b607080546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146111cc5760405162461bcd60e51b8152600401610b7690614dc9565b80516111df9060659060208401906145a5565b5050565b6000546001600160a01b0316331461120d5760405162461bcd60e51b8152600401610b7690614dc9565b610bd76130cb565b611220838383612aa7565b611228612bdd565b610d7f83838361315e565b6000546001600160a01b0316331461125d5760405162461bcd60e51b8152600401610b7690614dc9565b80518251146040518060400160405280600c81526020016b0eee4dedcce40d8cadccee8d60a31b815250906112a55760405162461bcd60e51b8152600401610b769190614d64565b506112b08251613179565b8051604360008282546112c39190614edb565b90915550600090505b8251811015610d7f576113118382815181106112ea576112ea6150b0565b6020026020010151838381518110611304576113046150b0565b60200260200101516131cc565b8061131b8161501f565b9150506112cc565b6002607d5414156113465760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55608154611359908290612c23565b604254336000908152604a602052604090205461137a9060ff851690614edb565b11156113b95760405162461bcd60e51b815260206004820152600e60248201526d43616e74206d696e74206d6f726560901b6044820152606401610b76565b6113c58260ff16612f7b565b6113d18383600161274a565b50506001607d5550565b6000818152607460205260408120546001600160a01b03161515610ab4565b6000611405607b5490565b82106114685760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610b76565b607b828154811061147b5761147b6150b0565b90600052602060002001549050919050565b6000546001600160a01b031633146114b75760405162461bcd60e51b8152600401610b7690614dc9565b608055565b6000818152607460205260408120546001600160a01b031680610ab45760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610b76565b6000546001600160a01b0316331461155d5760405162461bcd60e51b8152600401610b7690614dc9565b80604354603c61156c607b5490565b6115769190614edb565b6115809190614f4b565b11156115ce5760405162461bcd60e51b815260206004820152601860248201527f496e76616c6964206e756d626572206f6620746f6b656e7300000000000000006044820152606401610b76565b604055565b60006001600160a01b03821661163e5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610b76565b506001600160a01b031660009081526075602052604090205490565b6000546001600160a01b031633146116845760405162461bcd60e51b8152600401610b7690614dc9565b610bd7600061329a565b6000546001600160a01b031633146116b85760405162461bcd60e51b8152600401610b7690614dc9565b608155565b6002607d5414156116e05760405162461bcd60e51b8152600401610b7690614e4f565b6002607d5560475460408051808201909152600b81526a1b9bdd081cdd185c9d195960aa1b60208201529060ff1661172b5760405162461bcd60e51b8152600401610b769190614d64565b5060008160ff161161176b5760405162461bcd60e51b81526020600482015260096024820152684d696e74206d6f726560b81b6044820152606401610b76565b6117778160ff16612d40565b6117838160ff16612f7b565b610e048282600161274a565b6000546001600160a01b031633146117b95760405162461bcd60e51b8152600401610b7690614dc9565b610bd76132ea565b6002607d5414156117e45760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55607f546117f7908290612c23565b336000908152604c6020908152604091829020548251808401909352600a83526918d85b89dd081b5a5b9d60b21b9183019190915260ff161561184d5760405162461bcd60e51b8152600401610b769190614d64565b50336000908152604c60205260409020805460ff19166001179055610e0482611874613365565b6131cc565b606060738054610ac990614fc8565b6000546001600160a01b031633146118b25760405162461bcd60e51b8152600401610b7690614dc9565b60475460408051808201909152600f81526e185b1c9958591e48195b98589b1959608a1b602082015290610100900460ff16156119025760405162461bcd60e51b8152600401610b769190614d64565b506047805461ffff1916610100179055565b6000600161192061355a565b61192a9190614f62565b9050600060598260ff1660058110611944576119446150b0565b01549050600081116040518060400160405280600a8152602001696e6f2062616c616e636560b01b8152509061198d5760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152838210156119ce5760405162461bcd60e51b8152600401610b769190614d64565b50600083116119dd57806119df565b825b92506119eb8382614f4b565b60598360ff1660058110611a0157611a016150b0565b0155611a0d8484613019565b50505050565b6001600160a01b038216331415611a6c5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b76565b3360008181526077602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6111df3383836135b4565b606a8181548110611af357600080fd5b6000918252602090912060059091020180546001820154600283015460038401546004909401549294509092909185565b6000546001600160a01b03163314611b4e5760405162461bcd60e51b8152600401610b7690614dc9565b6000805b8251811015611b9757828181518110611b6d57611b6d6150b0565b602002602001015160ff1682611b839190614edb565b915080611b8f8161501f565b915050611b52565b50611ba181613179565b8060436000828254611bb39190614edb565b90915550600090505b8351811015611a0d576000848281518110611bd957611bd96150b0565b6020026020010151905060005b848381518110611bf857611bf86150b0565b602002602001015160ff16811015611c2557611c138261396b565b80611c1d8161501f565b915050611be6565b50508080611c329061501f565b915050611bbc565b611c443383613981565b611c605760405162461bcd60e51b8152600401610b7690614dfe565b611a0d84848484613a58565b6000546001600160a01b03163314611c965760405162461bcd60e51b8152600401610b7690614dc9565b604155565b6000818152607460205260409020546060906001600160a01b0316611d1a5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610b76565b6000611d24613a8b565b90506000815111611d445760405180602001604052806000815250611d6f565b80611d4e84613a9a565b604051602001611d5f929190614cb4565b6040516020818303038152906040525b9392505050565b6000546001600160a01b03163314611da05760405162461bcd60e51b8152600401610b7690614dc9565b6002607d541415611dc35760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55606e546000905b606a54811015611ef1576000606a8281548110611dee57611dee6150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090506301e13380816000015142611e509190614f4b565b1015611e615750606e819055611ef1565b600081608001518260600151611e779190614f4b565b905080611e85575050611edf565b8160600151606a8481548110611e9d57611e9d6150b0565b90600052602060002090600502016004018190555081606001518260400151611ec69190614f18565b611ed09082614f2c565b611eda9085614edb565b935050505b80611ee98161501f565b915050611dcf565b5060408051808201909152600a8152696e6f2062616c616e636560b01b602082015281611f315760405162461bcd60e51b8152600401610b769190614d64565b5080606d6000828254611f449190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038481166004830152602482018490529091169063205c287890604401600060405180830381600087803b158015611f9757600080fd5b505af1158015611fab573d6000803e3d6000fd5b50506001607d5550505050565b6000546001600160a01b03163314611fe25760405162461bcd60e51b8152600401610b7690614dc9565b8060695414156040518060400160405280600a81526020016973616d652076616c756560b01b815250906120295760405162461bcd60e51b8152600401610b769190614d64565b50606955565b6000600161203b61355a565b6120459190614f62565b90506000605f8260ff166005811061205f5761205f6150b0565b01549050600081116040518060400160405280600a8152602001696e6f2062616c616e636560b01b815250906120a85760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152838210156120e95760405162461bcd60e51b8152600401610b769190614d64565b50600083116120f857806120fa565b825b92506121068382614f4b565b605f8360ff166005811061211c5761211c6150b0565b018190555082606d60008282546121339190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038681166004830152602482018690529091169063205c287890604401600060405180830381600087803b15801561218657600080fd5b505af115801561219a573d6000803e3d6000fd5b5050505050505050565b604960205260009081526040902080546121bd90614fc8565b80601f01602080910402602001604051908101604052809291908181526020018280546121e990614fc8565b80156122365780601f1061220b57610100808354040283529160200191612236565b820191906000526020600020905b81548152906001019060200180831161221957829003601f168201915b505050505081565b6001600160a01b03808316600090815260776020908152604080832093851683529290529081205460ff16611d6f565b6000546001600160a01b031633146122985760405162461bcd60e51b8152600401610b7690614dc9565b606f80546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146122e45760405162461bcd60e51b8152600401610b7690614dc9565b6001600160a01b0381166123495760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610b76565b6111538161329a565b604860205260009081526040902080546121bd90614fc8565b6000546001600160a01b031633146123955760405162461bcd60e51b8152600401610b7690614dc9565b607f55565b60006001600160e01b0319821663780e9d6360e01b1480610ab45750610ab482613b98565b600080606a6123cc613bd8565b815481106123dc576123dc6150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090506000606d54606c5461243b9190614f4b565b606f5461245291906001600160a01b031631614f4b565b90506000811180156124715750606954825161246e9042614f4b565b10155b9250505090565b6000606d54606c5461248a9190614f4b565b606f546124a191906001600160a01b031631614f4b565b905080606c60008282546124b59190614edb565b90915550600090506124c8600583614f18565b905060006124d68284614f4b565b905060005b60058160ff16101561255357606460548260ff16600581106124ff576124ff6150b0565b015461250b9084614f2c565b6125159190614f18565b605f8260ff166005811061252b5761252b6150b0565b01600082825461253b9190614edb565b9091555081905061254b8161503a565b9150506124db565b50600061255e613bd8565b905042606a8281548110612574576125746150b0565b90600052602060002090600502016001018190555082606a828154811061259d5761259d6150b0565b6000918252602090912060026005909202010155607b54606a82815481106125c7576125c76150b0565b60009182526020808320600592830201600301939093556040805160a0810182524281529384018381529084018381526060850184815260808601858152606a8054600181018255965295517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a51959094029485019390935590517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a52840155517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a53830155517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5482015590517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a559091015550505050565b600081815260766020526040902080546001600160a01b0319166001600160a01b0384169081179091558190612711826114bc565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60785460ff16156127915760405162461bcd60e51b8152602060048201526011602482015270135a5b9d1a5b99c81a5cc81c185d5cd959607a1b6044820152606401610b76565b60408051808201909152600a81526918d85b89dd081b5a5b9d60b21b602082015260ff83166127d35760405162461bcd60e51b8152600401610b769190614d64565b50600081156128c9576041548360ff166046546127f09190614edb565b111561282f5760405162461bcd60e51b815260206004820152600e60248201526d43616e74206d696e74206d6f726560901b6044820152606401610b76565b8260ff16604660008282546128449190614edb565b9091555050336000908152604a60205260409020546128679060ff851690614f4b565b905061287d668e1bc9bf04000060ff8516613bef565b34146040518060400160405280600d81526020016c77726f6e672062616c616e636560981b815250906128c35760405162461bcd60e51b8152600401610b769190614d64565b506129df565b6128dd66d529ae9e86000060ff8516613bef565b34146040518060400160405280600d81526020016c77726f6e672062616c616e636560981b815250906129235760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152600f60ff851611156129685760405162461bcd60e51b8152600401610b769190614d64565b50604354603c60405461297b9190614f4b565b6129859190614edb565b8360ff16612992607b5490565b61299c9190614edb565b111560405180604001604052806008815260200167746f6f206d616e7960c01b815250906129dd5760405162461bcd60e51b8152600401610b769190614d64565b505b60005b8360ff168160ff161015612a9d5760006129fa613365565b90508315612a805782612a0c8161501f565b93505082600114612a3d5760405180604001604052806008815260200167125391915493905360c21b815250612a5b565b604051806040016040528060048152602001632624a7a760e11b8152505b60008281526049602090815260409091208251612a7e93919291909101906145a5565b505b612a8a86826131cc565b5080612a958161503a565b9150506129e2565b50611a0d83613bfb565b6001600160a01b0382166000818152606660209081526040808320805460018082018355918552838520810187905582516080810184528781528085018281524282860190815260608301888152988852606787528588208a89529096529390952094518555915190840155905160028301559151600390910155612b2d8480846135b4565b6001600160a01b038416600081815260676020908152604080832086845282528083204260038201559383526066909152902080548190612b7090600190614f4b565b81548110612b8057612b806150b0565b906000526020600020015481836001015481548110612ba157612ba16150b0565b906000526020600020018190555080805480612bbf57612bbf61509a565b60019003818190600052602060002001600090559055505050505050565b612be56123bf565b15610bd757610bd7612478565b612bfc3382613981565b612c185760405162461bcd60e51b8152600401610b7690614dfe565b610d7f838383613e51565b6040516bffffffffffffffffffffffff193360601b16602082015260009060340160405160208183030381529060405280519060200120905060005b8351811015612cf7576000848281518110612c7c57612c7c6150b0565b6020026020010151905080831115612cb6576040805160208101839052908101849052606001604051602081830303815290604052612cda565b60408051602081018590529081018290526060016040516020818303038152906040525b805190602001209250508080612cef9061501f565b915050612c5f565b50818114610d7f5760405162461bcd60e51b81526020600482015260166024820152751d1a19481c1c9bdbd9881a5cc81b9bdd081d985b1a5960521b6044820152606401610b76565b607054604051633cadb18d60e11b81523360048201526000916001600160a01b03169063795b631a9060240160006040518083038186803b158015612d8457600080fd5b505afa158015612d98573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612dc09190810190614b54565b905060008151116040518060400160405280600a81526020016918d85b89dd081b5a5b9d60b21b81525090612e085760405162461bcd60e51b8152600401610b769190614d64565b50816000805b8351811015612f355784821415612e2457612f35565b6000848281518110612e3857612e386150b0565b6020908102919091018101516000818152604b909252604082205490925060ff1690612e6582600a614f4b565b905085811115612e725750845b6000612e7e8284614edb565b6000858152604b602052604090819020805460ff191660ff841690811790915560705491516361c3200360e01b81526004810188905260248101919091529192506001600160a01b0316906361c3200390604401600060405180830381600087803b158015612eec57600080fd5b505af1158015612f00573d6000803e3d6000fd5b505050508186612f109190614edb565b9550612f1c8288614f4b565b9650505050508080612f2d9061501f565b915050612e0e565b50838114611a0d5760405162461bcd60e51b815260206004820152601360248201527218d85b89dd081b5a5b9d08199bdc8819dbdb19606a1b6044820152606401610b76565b336000908152604a6020526040812054612f959083614edb565b336000908152604a60205260409020819055905060018114612fd75760405180604001604052806008815260200167125391915493905360c21b815250612ff5565b604051806040016040528060048152602001632624a7a760e11b8152505b3360009081526048602090815260409091208251610d7f93919291909101906145a5565b60405182906000906001600160a01b0383169084908381818185875af1925050503d8060008114613066576040519150601f19603f3d011682016040523d82523d6000602084013e61306b565b606091505b50509050806040518060400160405280601c81526020017f46756e6374696f6e2063616c6c206e6f74207375636365737366756c00000000815250906130c45760405162461bcd60e51b8152600401610b769190614d64565b5050505050565b60785460ff166131145760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610b76565b6078805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b610d7f83838360405180602001604052806000815250611c3a565b603c816043546131899190614edb565b11156040518060400160405280600a81526020016918d85b89dd081b5a5b9d60b21b815250906111df5760405162461bcd60e51b8152600401610b769190614d64565b336000908152606660209081526040808320546001600160a01b0386168085528285208054600181810183559187528587200187905583516080810185528781528086018481524282870190815260608301898152948952606788528689208a8a5290975294909620955186559251928501929092559151600284015551600390920191909155606a61325d613bd8565b8154811061326d5761326d6150b0565b60009182526020822060036005909202010180549161328b8361501f565b9190505550610d7f8383613ffc565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60785460ff16156133305760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610b76565b6078805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131413390565b604554600090819060ff6101009091041661337f607b5490565b61338b906103e8614f4b565b6133959190614f4b565b60008054604051600160a01b90910460f01b6001600160f01b03191660208201524160601b6bffffffffffffffffffffffff191660228201524460368201524260568201529192509082906076016040516020818303038152906040528051906020012060001c613406919061505a565b90508161341281614fb1565b9250506000806001836103e8811061342c5761342c6150b0565b601081049190910154600f9091166002026101000a900461ffff16905080156134575780915061345b565b8291505b60006001856103e88110613471576134716150b0565b601081049190910154600f9091166002026101000a900461ffff169050806134d257846001856103e881106134a8576134a86150b0565b601091828204019190066002026101000a81548161ffff021916908361ffff16021790555061350d565b806001856103e881106134e7576134e76150b0565b601091828204019190066002026101000a81548161ffff021916908361ffff1602179055505b60008054600160a01b900461ffff1690601461352883614ffd565b91906101000a81548161ffff021916908361ffff160217905550508260016135509190614edb565b9550505050505090565b336000908152605e602090815260409182902054825180840190935260098352686e6f2061636365737360b81b9183019190915260ff1690816135b05760405162461bcd60e51b8152600401610b769190614d64565b5090565b6001600160a01b038316600090815260686020526040812054906135d6613bd8565b90508082106040518060400160405280600a8152602001696e6f2062616c616e636560b01b8152509061361c5760405162461bcd60e51b8152600401610b769190614d64565b508215156000835b83811015613883576000606a8281548110613641576136416150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090508060400151600014156136a15750613871565b600080856136c7576001600160a01b038b166000908152606660205260409020546136ca565b60015b905060005b818110156137fb57600087156136e657508961371e565b6001600160a01b038d166000908152606660205260409020805483908110613710576137106150b0565b906000526020600020015490505b6000868152606b6020908152604080832084845290915290205460ff161561374657506137e9565b6001600160a01b038d166000908152606760209081526040808320848452825291829020825160808101845281548152600182015492810192909252600281015492820183905260030154606082015286519091108015906137af575085602001518160600151105b156137e657846137be8161501f565b6000898152606b602090815260408083208784529091529020805460ff191660011790559550505b50505b806137f38161501f565b9150506136cf565b508161380957505050613871565b81606a858154811061381d5761381d6150b0565b9060005260206000209060050201600401600082825461383d9190614edb565b909155505060608301516040840151839161385791614f18565b6138619190614f2c565b61386b9086614edb565b94505050505b8061387b8161501f565b915050613624565b5060408051808201909152600a8152696e6f2062616c616e636560b01b6020820152816138c35760405162461bcd60e51b8152600401610b769190614d64565b50816138e5576001600160a01b03871660009081526068602052604090208390555b80606d60008282546138f79190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038881166004830152602482018490529091169063205c287890604401600060405180830381600087803b15801561394a57600080fd5b505af115801561395e573d6000803e3d6000fd5b5050505050505050505050565b6000613975613365565b90506111df82826131cc565b6000818152607460205260408120546001600160a01b03166139fa5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b76565b6000613a05836114bc565b9050806001600160a01b0316846001600160a01b03161480613a405750836001600160a01b0316613a3584610bd9565b6001600160a01b0316145b80613a505750613a50818561223e565b949350505050565b613a63848484613e51565b613a6f84848484614016565b611a0d5760405162461bcd60e51b8152600401610b7690614d77565b606060658054610ac990614fc8565b606081613abe5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613ae85780613ad28161501f565b9150613ae19050600a83614f18565b9150613ac2565b60008167ffffffffffffffff811115613b0357613b036150c6565b6040519080825280601f01601f191660200182016040528015613b2d576020820181803683370190505b5090505b8415613a5057613b42600183614f4b565b9150613b4f600a8661505a565b613b5a906030614edb565b60f81b818381518110613b6f57613b6f6150b0565b60200101906001600160f81b031916908160001a905350613b91600a86614f18565b9450613b31565b60006001600160e01b031982166380ac58cd60e01b1480613bc957506001600160e01b03198216635b5e139f60e01b145b80610ab45750610ab482614123565b606a54600090613bea90600190614f4b565b905090565b6000611d6f8284614f2c565b604454349015613c87576000604f613c1560016005614f4b565b60058110613c2557613c256150b0565b01546044546001600160a01b039091169150821115613c6357604454613c4b9083614f4b565b9150613c5981604454613019565b6000604455613c85565b8160446000828254613c759190614f4b565b90915550610d7f90508183613019565b505b604554601990613c9b90849060ff16614ef3565b60ff16108015613cdb5750604354603c604054613cb89190614f4b565b613cc29190614edb565b8260ff16613ccf607b5490565b613cd99190614edb565b105b15613d8b5760458054839190600090613cf890849060ff16614ef3565b92506101000a81548160ff021916908360ff16021790555060005b60058160ff161015610d7f57606460548260ff1660058110613d3757613d376150b0565b0154613d439084614f2c565b613d4d9190614f18565b60598260ff1660058110613d6357613d636150b0565b016000828254613d739190614edb565b90915550819050613d838161503a565b915050613d13565b6045805460ff1916905560005b60058160ff161015610d7f576000606460548360ff1660058110613dbe57613dbe6150b0565b0154613dca9085614f2c565b613dd49190614f18565b905060598260ff1660058110613dec57613dec6150b0565b0154613df89082614edb565b9050600060598360ff1660058110613e1257613e126150b0565b0155613e3e604f60ff841660058110613e2d57613e2d6150b0565b01546001600160a01b031682613019565b5080613e498161503a565b915050613d98565b826001600160a01b0316613e64826114bc565b6001600160a01b031614613ecc5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610b76565b6001600160a01b038216613f2e5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610b76565b613f3983838361415f565b613f446000826126dc565b6001600160a01b0383166000908152607560205260408120805460019290613f6d908490614f4b565b90915550506001600160a01b0382166000908152607560205260408120805460019290613f9b908490614edb565b909155505060008181526074602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6111df82826040518060200160405280600081525061416a565b60006001600160a01b0384163b1561411857604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061405a903390899088908890600401614ce3565b602060405180830381600087803b15801561407457600080fd5b505af19250505080156140a4575060408051601f3d908101601f191682019092526140a191810190614c22565b60015b6140fe573d8080156140d2576040519150601f19603f3d011682016040523d82523d6000602084013e6140d7565b606091505b5080516140f65760405162461bcd60e51b8152600401610b7690614d77565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050613a50565b506001949350505050565b60006301ffc9a760e01b6001600160e01b031983161480610ab45750506001600160e01b03191660009081526071602052604090205460ff1690565b610d7f83838361419d565b6141748383614260565b6141816000848484614016565b610d7f5760405162461bcd60e51b8152600401610b7690614d77565b6141a88383836143ae565b6001600160a01b038316614203576141fe81607b80546000838152607c60205260408120829055600182018355919091527f5569044719a1ec3b04d0afa9e7a5310c7c0473331d13dc9fafe143b2c4e8148a0155565b614226565b816001600160a01b0316836001600160a01b031614614226576142268382614415565b6001600160a01b03821661423d57610d7f816144b2565b826001600160a01b0316826001600160a01b031614610d7f57610d7f8282614561565b6001600160a01b0382166142b65760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b76565b6000818152607460205260409020546001600160a01b03161561431b5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b76565b6143276000838361415f565b6001600160a01b0382166000908152607560205260408120805460019290614350908490614edb565b909155505060008181526074602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60785460ff1615610d7f5760405162461bcd60e51b815260206004820152602b60248201527f4552433732315061757361626c653a20746f6b656e207472616e73666572207760448201526a1a1a5b19481c185d5cd95960aa1b6064820152608401610b76565b60006001614422846115d3565b61442c9190614f4b565b6000838152607a602052604090205490915080821461447f576001600160a01b03841660009081526079602090815260408083208584528252808320548484528184208190558352607a90915290208190555b506000918252607a602090815260408084208490556001600160a01b039094168352607981528383209183525290812055565b607b546000906144c490600190614f4b565b6000838152607c6020526040812054607b80549394509092849081106144ec576144ec6150b0565b9060005260206000200154905080607b838154811061450d5761450d6150b0565b6000918252602080832090910192909255828152607c9091526040808220849055858252812055607b8054806145455761454561509a565b6001900381819060005260206000200160009055905550505050565b600061456c836115d3565b6001600160a01b0390931660009081526079602090815260408083208684528252808320859055938252607a9052919091209190915550565b8280546145b190614fc8565b90600052602060002090601f0160209004810192826145d35760008555614619565b82601f106145ec57805160ff1916838001178555614619565b82800160010185558215614619579182015b828111156146195782518255916020019190600101906145fe565b506135b09291505b808211156135b05760008155600101614621565b600067ffffffffffffffff83111561464f5761464f6150c6565b614662601f8401601f1916602001614e86565b905082815283838301111561467657600080fd5b828260208301376000602084830101529392505050565b600082601f83011261469e57600080fd5b813560206146b36146ae83614eb7565b614e86565b80838252828201915082860187848660051b89010111156146d357600080fd5b60005b858110156146fb5781356146e9816150dc565b845292840192908401906001016146d6565b5090979650505050505050565b600082601f83011261471957600080fd5b813560206147296146ae83614eb7565b80838252828201915082860187848660051b890101111561474957600080fd5b60005b858110156146fb5781358452928401929084019060010161474c565b803560ff8116811461477957600080fd5b919050565b60006020828403121561479057600080fd5b8135611d6f816150dc565b600080604083850312156147ae57600080fd5b82356147b9816150dc565b915060208301356147c9816150dc565b809150509250929050565b6000806000606084860312156147e957600080fd5b83356147f4816150dc565b92506020840135614804816150dc565b929592945050506040919091013590565b6000806000806080858703121561482b57600080fd5b8435614836816150dc565b93506020850135614846816150dc565b925060408501359150606085013567ffffffffffffffff81111561486957600080fd5b8501601f8101871361487a57600080fd5b61488987823560208401614635565b91505092959194509250565b600080604083850312156148a857600080fd5b82356148b3816150dc565b9150602083013567ffffffffffffffff8111156148cf57600080fd5b6148db85828601614708565b9150509250929050565b600080604083850312156148f857600080fd5b8235614903816150dc565b9150602083013580151581146147c957600080fd5b6000806040838503121561492b57600080fd5b8235614936816150dc565b946020939093013593505050565b6000806040838503121561495757600080fd5b8235614962816150dc565b915061497060208401614768565b90509250929050565b60008060006060848603121561498e57600080fd5b8335614999816150dc565b92506149a760208501614768565b9150604084013567ffffffffffffffff8111156149c357600080fd5b6149cf86828701614708565b9150509250925092565b600080604083850312156149ec57600080fd5b823567ffffffffffffffff80821115614a0457600080fd5b614a108683870161468d565b9350602091508185013581811115614a2757600080fd5b85019050601f81018613614a3a57600080fd5b8035614a486146ae82614eb7565b80828252848201915084840189868560051b8701011115614a6857600080fd5b600094505b83851015614a8b578035835260019490940193918501918501614a6d565b5080955050505050509250929050565b60008060408385031215614aae57600080fd5b823567ffffffffffffffff80821115614ac657600080fd5b614ad28683870161468d565b9350602091508185013581811115614ae957600080fd5b85019050601f81018613614afc57600080fd5b8035614b0a6146ae82614eb7565b80828252848201915084840189868560051b8701011115614b2a57600080fd5b600094505b83851015614a8b57614b4081614768565b835260019490940193918501918501614b2f565b60006020808385031215614b6757600080fd5b825167ffffffffffffffff811115614b7e57600080fd5b8301601f81018513614b8f57600080fd5b8051614b9d6146ae82614eb7565b80828252848201915084840188868560051b8701011115614bbd57600080fd5b600094505b83851015614be0578051835260019490940193918501918501614bc2565b50979650505050505050565b600060208284031215614bfe57600080fd5b5035919050565b600060208284031215614c1757600080fd5b8135611d6f816150f1565b600060208284031215614c3457600080fd5b8151611d6f816150f1565b600060208284031215614c5157600080fd5b813567ffffffffffffffff811115614c6857600080fd5b8201601f81018413614c7957600080fd5b613a5084823560208401614635565b60008151808452614ca0816020860160208601614f85565b601f01601f19169290920160200192915050565b60008351614cc6818460208801614f85565b835190830190614cda818360208801614f85565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090614d1690830184614c88565b9695505050505050565b6020808252825182820181905260009190848201906040850190845b81811015614d5857835183529284019291840191600101614d3c565b50909695505050505050565b602081526000611d6f6020830184614c88565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b604051601f8201601f1916810167ffffffffffffffff81118282101715614eaf57614eaf6150c6565b604052919050565b600067ffffffffffffffff821115614ed157614ed16150c6565b5060051b60200190565b60008219821115614eee57614eee61506e565b500190565b600060ff821660ff84168060ff03821115614f1057614f1061506e565b019392505050565b600082614f2757614f27615084565b500490565b6000816000190483118215151615614f4657614f4661506e565b500290565b600082821015614f5d57614f5d61506e565b500390565b600060ff821660ff841680821015614f7c57614f7c61506e565b90039392505050565b60005b83811015614fa0578181015183820152602001614f88565b83811115611a0d5750506000910152565b600081614fc057614fc061506e565b506000190190565b600181811c90821680614fdc57607f821691505b60208210811415610ec657634e487b7160e01b600052602260045260246000fd5b600061ffff808316818114156150155761501561506e565b6001019392505050565b60006000198214156150335761503361506e565b5060010190565b600060ff821660ff8114156150515761505161506e565b60010192915050565b60008261506957615069615084565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461115357600080fd5b6001600160e01b03198116811461115357600080fdfea2646970667358221220f4a746ebee8008cc56cc50ecd5b966c234108355dbd95bc7965cde2461e0a9d964736f6c63430008050033000000000000000000000000c8821cf81dc4a2cb563ed4214f9743606b2f7573000000000000000000000000e9eb0964d6f36c14a0f5657d8788c8892e2ceb6800000000000000000000000021f23e44c17604df9a9e42197e1906580b8e31f2000000000000000000000000dab3a39668a77c12b9b3f0593ebc534d5e861d340000000000000000000000006b148541b80033798a6cab79600f3f0df616b0ed0000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000000f000000000000000000000000000000000000000000000000000000000000000f0000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000a688906bd8b0000
Deployed Bytecode
0x6080604052600436106103905760003560e01c80636c6ccb4b116101dc578063b0f4ef4d11610102578063e6106bd5116100a0578063f2fde38b1161006f578063f2fde38b14610a33578063f4ed63ca14610a53578063fb3fa71614610a69578063fc7de55a14610a8957610397565b8063e6106bd5146109b3578063e7e50673146109d3578063e985e9c5146109f3578063f2c098b714610a1357610397565b8063c712810c116100dc578063c712810c1461093d578063c87b56dd14610953578063d9eec5ca14610973578063db9accf61461099357610397565b8063b0f4ef4d146108dd578063b88d4fde146108fd578063c3a2ea551461091d57610397565b80638f4839001161017a578063a209952311610149578063a209952314610835578063a22cb46514610855578063a2b8d52d14610875578063abe559681461089557610397565b80638f483900146107d557806392e87b59146107f557806395d89b411461080b5780639da058e91461082057610397565b80637cb64759116101b65780637cb647591461076f57806381b66ba01461078f5780638456cb59146107a25780638da5cb5b146107b757610397565b80636c6ccb4b1461071a57806370a082311461073a578063715018a61461075a57610397565b806335c347fa116102c1578063454223981161025f5780635896996e1161022e5780635896996e1461069f5780635c975abb146106cc5780636352211e146106e4578063646acd011461070457610397565b8063454223981461062c5780634f558e791461063f5780634f6ccce71461065f5780635815885d1461067f57610397565b80633f1924d01161029b5780633f1924d0146105bd5780633f4ba83a146105d757806342842e0e146105ec57806344f195d31461060c57610397565b806335c347fa1461055e57806337951d8f1461057d57806339a0c6f91461059d57610397565b806318160ddd1161032e5780632eb4a7ab116103085780632eb4a7ab146105005780632f745c591461051657806331086272146105365780633225d3df1461054957610397565b806318160ddd146104ac5780631bb59fcb146104cb57806323b872dd146104e057610397565b8063081812fc1161036a578063081812fc14610414578063095ea7b31461044c57806309c65e581461046c5780630d381a281461047f57610397565b806301ffc9a7146103a657806306fdde03146103db578063071f172a146103fd57610397565b3661039757005b3480156103a357600080fd5b50005b3480156103b257600080fd5b506103c66103c1366004614c05565b610aa9565b60405190151581526020015b60405180910390f35b3480156103e757600080fd5b506103f0610aba565b6040516103d29190614d64565b34801561040957600080fd5b50610412610b4c565b005b34801561042057600080fd5b5061043461042f366004614bec565b610bd9565b6040516001600160a01b0390911681526020016103d2565b34801561045857600080fd5b50610412610467366004614918565b610c6e565b61041261047a366004614944565b610d84565b34801561048b57600080fd5b5061049f61049a36600461477e565b610e0d565b6040516103d29190614d20565b3480156104b857600080fd5b50607b545b6040519081526020016103d2565b3480156104d757600080fd5b50610412610ecc565b3480156104ec57600080fd5b506104126104fb3660046147d4565b610f0a565b34801561050c57600080fd5b506104bd60815481565b34801561052257600080fd5b506104bd610531366004614918565b610f28565b610412610544366004614895565b610fbe565b34801561055557600080fd5b50610412611087565b34801561056a57600080fd5b506047546103c690610100900460ff1681565b34801561058957600080fd5b5061041261059836600461477e565b611156565b3480156105a957600080fd5b506104126105b8366004614c3f565b6111a2565b3480156105c957600080fd5b506047546103c69060ff1681565b3480156105e357600080fd5b506104126111e3565b3480156105f857600080fd5b506104126106073660046147d4565b611215565b34801561061857600080fd5b506104126106273660046149d9565b611233565b61041261063a366004614979565b611323565b34801561064b57600080fd5b506103c661065a366004614bec565b6113db565b34801561066b57600080fd5b506104bd61067a366004614bec565b6113fa565b34801561068b57600080fd5b5061041261069a366004614bec565b61148d565b3480156106ab57600080fd5b506104bd6106ba36600461477e565b604a6020526000908152604090205481565b3480156106d857600080fd5b5060785460ff166103c6565b3480156106f057600080fd5b506104346106ff366004614bec565b6114bc565b34801561071057600080fd5b506104bd60695481565b34801561072657600080fd5b50610412610735366004614bec565b611533565b34801561074657600080fd5b506104bd61075536600461477e565b6115d3565b34801561076657600080fd5b5061041261165a565b34801561077b57600080fd5b5061041261078a366004614bec565b61168e565b61041261079d366004614944565b6116bd565b3480156107ae57600080fd5b5061041261178f565b3480156107c357600080fd5b506000546001600160a01b0316610434565b3480156107e157600080fd5b506104126107f0366004614895565b6117c1565b34801561080157600080fd5b506104bd607f5481565b34801561081757600080fd5b506103f0611879565b34801561082c57600080fd5b50610412611888565b34801561084157600080fd5b50610412610850366004614918565b611914565b34801561086157600080fd5b506104126108703660046148e5565b611a13565b34801561088157600080fd5b50610412610890366004614918565b611ad8565b3480156108a157600080fd5b506108b56108b0366004614bec565b611ae3565b604080519586526020860194909452928401919091526060830152608082015260a0016103d2565b3480156108e957600080fd5b506104126108f8366004614a9b565b611b24565b34801561090957600080fd5b50610412610918366004614815565b611c3a565b34801561092957600080fd5b50610412610938366004614bec565b611c6c565b34801561094957600080fd5b506104bd60465481565b34801561095f57600080fd5b506103f061096e366004614bec565b611c9b565b34801561097f57600080fd5b5061041261098e36600461477e565b611d76565b34801561099f57600080fd5b506104126109ae366004614bec565b611fb8565b3480156109bf57600080fd5b506104126109ce366004614918565b61202f565b3480156109df57600080fd5b506103f06109ee366004614bec565b6121a4565b3480156109ff57600080fd5b506103c6610a0e36600461479b565b61223e565b348015610a1f57600080fd5b50610412610a2e36600461477e565b61226e565b348015610a3f57600080fd5b50610412610a4e36600461477e565b6122ba565b348015610a5f57600080fd5b506104bd60805481565b348015610a7557600080fd5b506103f0610a8436600461477e565b612352565b348015610a9557600080fd5b50610412610aa4366004614bec565b61236b565b6000610ab48261239a565b92915050565b606060728054610ac990614fc8565b80601f0160208091040260200160405190810160405280929190818152602001828054610af590614fc8565b8015610b425780601f10610b1757610100808354040283529160200191610b42565b820191906000526020600020905b815481529060010190602001808311610b2557829003601f168201915b5050505050905090565b6000546001600160a01b03163314610b7f5760405162461bcd60e51b8152600401610b7690614dc9565b60405180910390fd5b610b876123bf565b6040518060400160405280601081526020016f64697361626c6564206368616e67657360801b81525090610bce5760405162461bcd60e51b8152600401610b769190614d64565b50610bd7612478565b565b6000818152607460205260408120546001600160a01b0316610c525760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b76565b506000908152607660205260409020546001600160a01b031690565b6000610c79826114bc565b9050806001600160a01b0316836001600160a01b03161415610ce75760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610b76565b336001600160a01b0382161480610d035750610d03813361223e565b610d755760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610b76565b610d7f83836126dc565b505050565b6002607d541415610da75760405162461bcd60e51b8152600401610b7690614e4f565b6002607d5560475460408051808201909152600b81526a1b9bdd081cdd185c9d195960aa1b602082015290610100900460ff16610df75760405162461bcd60e51b8152600401610b769190614d64565b50610e048282600061274a565b50506001607d55565b60606000610e1a836115d3565b905080610e3b5760408051600080825260208201909252905b509392505050565b60008167ffffffffffffffff811115610e5657610e566150c6565b604051908082528060200260200182016040528015610e7f578160200160208202803683370190505b50905060005b82811015610e3357610e978582610f28565b828281518110610ea957610ea96150b0565b602090810291909101015280610ebe8161501f565b915050610e85565b50919050565b6000546001600160a01b03163314610ef65760405162461bcd60e51b8152600401610b7690614dc9565b6047805460ff19811660ff90911615179055565b610f15838383612aa7565b610f1d612bdd565b610d7f838383612bf2565b6000610f33836115d3565b8210610f955760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610b76565b506001600160a01b03919091166000908152607960209081526040808320938352929052205490565b6002607d541415610fe15760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55608054610ff4908290612c23565b336000908152604d6020908152604091829020548251808401909352600a83526918d85b89dd081b5a5b9d60b21b9183019190915260ff161561104a5760405162461bcd60e51b8152600401610b769190614d64565b50336000908152604d60205260409020805460ff1916600190811790915561107190612d40565b61107b6001612f7b565b610e048260018061274a565b6000546001600160a01b031633146110b15760405162461bcd60e51b8152600401610b7690614dc9565b4760005b60058160ff1610156110f75760598160ff16600581106110d7576110d76150b0565b01546110e39083614f4b565b9150806110ef8161503a565b9150506110b5565b5060408051808201909152600a8152696e6f2062616c616e636560b01b6020820152816111375760405162461bcd60e51b8152600401610b769190614d64565b5061115361114d6000546001600160a01b031690565b82613019565b50565b6000546001600160a01b031633146111805760405162461bcd60e51b8152600401610b7690614dc9565b607080546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146111cc5760405162461bcd60e51b8152600401610b7690614dc9565b80516111df9060659060208401906145a5565b5050565b6000546001600160a01b0316331461120d5760405162461bcd60e51b8152600401610b7690614dc9565b610bd76130cb565b611220838383612aa7565b611228612bdd565b610d7f83838361315e565b6000546001600160a01b0316331461125d5760405162461bcd60e51b8152600401610b7690614dc9565b80518251146040518060400160405280600c81526020016b0eee4dedcce40d8cadccee8d60a31b815250906112a55760405162461bcd60e51b8152600401610b769190614d64565b506112b08251613179565b8051604360008282546112c39190614edb565b90915550600090505b8251811015610d7f576113118382815181106112ea576112ea6150b0565b6020026020010151838381518110611304576113046150b0565b60200260200101516131cc565b8061131b8161501f565b9150506112cc565b6002607d5414156113465760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55608154611359908290612c23565b604254336000908152604a602052604090205461137a9060ff851690614edb565b11156113b95760405162461bcd60e51b815260206004820152600e60248201526d43616e74206d696e74206d6f726560901b6044820152606401610b76565b6113c58260ff16612f7b565b6113d18383600161274a565b50506001607d5550565b6000818152607460205260408120546001600160a01b03161515610ab4565b6000611405607b5490565b82106114685760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610b76565b607b828154811061147b5761147b6150b0565b90600052602060002001549050919050565b6000546001600160a01b031633146114b75760405162461bcd60e51b8152600401610b7690614dc9565b608055565b6000818152607460205260408120546001600160a01b031680610ab45760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610b76565b6000546001600160a01b0316331461155d5760405162461bcd60e51b8152600401610b7690614dc9565b80604354603c61156c607b5490565b6115769190614edb565b6115809190614f4b565b11156115ce5760405162461bcd60e51b815260206004820152601860248201527f496e76616c6964206e756d626572206f6620746f6b656e7300000000000000006044820152606401610b76565b604055565b60006001600160a01b03821661163e5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610b76565b506001600160a01b031660009081526075602052604090205490565b6000546001600160a01b031633146116845760405162461bcd60e51b8152600401610b7690614dc9565b610bd7600061329a565b6000546001600160a01b031633146116b85760405162461bcd60e51b8152600401610b7690614dc9565b608155565b6002607d5414156116e05760405162461bcd60e51b8152600401610b7690614e4f565b6002607d5560475460408051808201909152600b81526a1b9bdd081cdd185c9d195960aa1b60208201529060ff1661172b5760405162461bcd60e51b8152600401610b769190614d64565b5060008160ff161161176b5760405162461bcd60e51b81526020600482015260096024820152684d696e74206d6f726560b81b6044820152606401610b76565b6117778160ff16612d40565b6117838160ff16612f7b565b610e048282600161274a565b6000546001600160a01b031633146117b95760405162461bcd60e51b8152600401610b7690614dc9565b610bd76132ea565b6002607d5414156117e45760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55607f546117f7908290612c23565b336000908152604c6020908152604091829020548251808401909352600a83526918d85b89dd081b5a5b9d60b21b9183019190915260ff161561184d5760405162461bcd60e51b8152600401610b769190614d64565b50336000908152604c60205260409020805460ff19166001179055610e0482611874613365565b6131cc565b606060738054610ac990614fc8565b6000546001600160a01b031633146118b25760405162461bcd60e51b8152600401610b7690614dc9565b60475460408051808201909152600f81526e185b1c9958591e48195b98589b1959608a1b602082015290610100900460ff16156119025760405162461bcd60e51b8152600401610b769190614d64565b506047805461ffff1916610100179055565b6000600161192061355a565b61192a9190614f62565b9050600060598260ff1660058110611944576119446150b0565b01549050600081116040518060400160405280600a8152602001696e6f2062616c616e636560b01b8152509061198d5760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152838210156119ce5760405162461bcd60e51b8152600401610b769190614d64565b50600083116119dd57806119df565b825b92506119eb8382614f4b565b60598360ff1660058110611a0157611a016150b0565b0155611a0d8484613019565b50505050565b6001600160a01b038216331415611a6c5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610b76565b3360008181526077602090815260408083206001600160a01b03871680855290835292819020805460ff191686151590811790915590519081529192917f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a35050565b6111df3383836135b4565b606a8181548110611af357600080fd5b6000918252602090912060059091020180546001820154600283015460038401546004909401549294509092909185565b6000546001600160a01b03163314611b4e5760405162461bcd60e51b8152600401610b7690614dc9565b6000805b8251811015611b9757828181518110611b6d57611b6d6150b0565b602002602001015160ff1682611b839190614edb565b915080611b8f8161501f565b915050611b52565b50611ba181613179565b8060436000828254611bb39190614edb565b90915550600090505b8351811015611a0d576000848281518110611bd957611bd96150b0565b6020026020010151905060005b848381518110611bf857611bf86150b0565b602002602001015160ff16811015611c2557611c138261396b565b80611c1d8161501f565b915050611be6565b50508080611c329061501f565b915050611bbc565b611c443383613981565b611c605760405162461bcd60e51b8152600401610b7690614dfe565b611a0d84848484613a58565b6000546001600160a01b03163314611c965760405162461bcd60e51b8152600401610b7690614dc9565b604155565b6000818152607460205260409020546060906001600160a01b0316611d1a5760405162461bcd60e51b815260206004820152602f60248201527f4552433732314d657461646174613a2055524920717565727920666f72206e6f60448201526e3732bc34b9ba32b73a103a37b5b2b760891b6064820152608401610b76565b6000611d24613a8b565b90506000815111611d445760405180602001604052806000815250611d6f565b80611d4e84613a9a565b604051602001611d5f929190614cb4565b6040516020818303038152906040525b9392505050565b6000546001600160a01b03163314611da05760405162461bcd60e51b8152600401610b7690614dc9565b6002607d541415611dc35760405162461bcd60e51b8152600401610b7690614e4f565b6002607d55606e546000905b606a54811015611ef1576000606a8281548110611dee57611dee6150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090506301e13380816000015142611e509190614f4b565b1015611e615750606e819055611ef1565b600081608001518260600151611e779190614f4b565b905080611e85575050611edf565b8160600151606a8481548110611e9d57611e9d6150b0565b90600052602060002090600502016004018190555081606001518260400151611ec69190614f18565b611ed09082614f2c565b611eda9085614edb565b935050505b80611ee98161501f565b915050611dcf565b5060408051808201909152600a8152696e6f2062616c616e636560b01b602082015281611f315760405162461bcd60e51b8152600401610b769190614d64565b5080606d6000828254611f449190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038481166004830152602482018490529091169063205c287890604401600060405180830381600087803b158015611f9757600080fd5b505af1158015611fab573d6000803e3d6000fd5b50506001607d5550505050565b6000546001600160a01b03163314611fe25760405162461bcd60e51b8152600401610b7690614dc9565b8060695414156040518060400160405280600a81526020016973616d652076616c756560b01b815250906120295760405162461bcd60e51b8152600401610b769190614d64565b50606955565b6000600161203b61355a565b6120459190614f62565b90506000605f8260ff166005811061205f5761205f6150b0565b01549050600081116040518060400160405280600a8152602001696e6f2062616c616e636560b01b815250906120a85760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152838210156120e95760405162461bcd60e51b8152600401610b769190614d64565b50600083116120f857806120fa565b825b92506121068382614f4b565b605f8360ff166005811061211c5761211c6150b0565b018190555082606d60008282546121339190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038681166004830152602482018690529091169063205c287890604401600060405180830381600087803b15801561218657600080fd5b505af115801561219a573d6000803e3d6000fd5b5050505050505050565b604960205260009081526040902080546121bd90614fc8565b80601f01602080910402602001604051908101604052809291908181526020018280546121e990614fc8565b80156122365780601f1061220b57610100808354040283529160200191612236565b820191906000526020600020905b81548152906001019060200180831161221957829003601f168201915b505050505081565b6001600160a01b03808316600090815260776020908152604080832093851683529290529081205460ff16611d6f565b6000546001600160a01b031633146122985760405162461bcd60e51b8152600401610b7690614dc9565b606f80546001600160a01b0319166001600160a01b0392909216919091179055565b6000546001600160a01b031633146122e45760405162461bcd60e51b8152600401610b7690614dc9565b6001600160a01b0381166123495760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610b76565b6111538161329a565b604860205260009081526040902080546121bd90614fc8565b6000546001600160a01b031633146123955760405162461bcd60e51b8152600401610b7690614dc9565b607f55565b60006001600160e01b0319821663780e9d6360e01b1480610ab45750610ab482613b98565b600080606a6123cc613bd8565b815481106123dc576123dc6150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090506000606d54606c5461243b9190614f4b565b606f5461245291906001600160a01b031631614f4b565b90506000811180156124715750606954825161246e9042614f4b565b10155b9250505090565b6000606d54606c5461248a9190614f4b565b606f546124a191906001600160a01b031631614f4b565b905080606c60008282546124b59190614edb565b90915550600090506124c8600583614f18565b905060006124d68284614f4b565b905060005b60058160ff16101561255357606460548260ff16600581106124ff576124ff6150b0565b015461250b9084614f2c565b6125159190614f18565b605f8260ff166005811061252b5761252b6150b0565b01600082825461253b9190614edb565b9091555081905061254b8161503a565b9150506124db565b50600061255e613bd8565b905042606a8281548110612574576125746150b0565b90600052602060002090600502016001018190555082606a828154811061259d5761259d6150b0565b6000918252602090912060026005909202010155607b54606a82815481106125c7576125c76150b0565b60009182526020808320600592830201600301939093556040805160a0810182524281529384018381529084018381526060850184815260808601858152606a8054600181018255965295517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a51959094029485019390935590517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a52840155517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a53830155517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a5482015590517f116fea137db6e131133e7f2bab296045d8f41cc5607279db17b218cab0929a559091015550505050565b600081815260766020526040902080546001600160a01b0319166001600160a01b0384169081179091558190612711826114bc565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60785460ff16156127915760405162461bcd60e51b8152602060048201526011602482015270135a5b9d1a5b99c81a5cc81c185d5cd959607a1b6044820152606401610b76565b60408051808201909152600a81526918d85b89dd081b5a5b9d60b21b602082015260ff83166127d35760405162461bcd60e51b8152600401610b769190614d64565b50600081156128c9576041548360ff166046546127f09190614edb565b111561282f5760405162461bcd60e51b815260206004820152600e60248201526d43616e74206d696e74206d6f726560901b6044820152606401610b76565b8260ff16604660008282546128449190614edb565b9091555050336000908152604a60205260409020546128679060ff851690614f4b565b905061287d668e1bc9bf04000060ff8516613bef565b34146040518060400160405280600d81526020016c77726f6e672062616c616e636560981b815250906128c35760405162461bcd60e51b8152600401610b769190614d64565b506129df565b6128dd66d529ae9e86000060ff8516613bef565b34146040518060400160405280600d81526020016c77726f6e672062616c616e636560981b815250906129235760405162461bcd60e51b8152600401610b769190614d64565b50604080518082019091526008815267746f6f206d616e7960c01b6020820152600f60ff851611156129685760405162461bcd60e51b8152600401610b769190614d64565b50604354603c60405461297b9190614f4b565b6129859190614edb565b8360ff16612992607b5490565b61299c9190614edb565b111560405180604001604052806008815260200167746f6f206d616e7960c01b815250906129dd5760405162461bcd60e51b8152600401610b769190614d64565b505b60005b8360ff168160ff161015612a9d5760006129fa613365565b90508315612a805782612a0c8161501f565b93505082600114612a3d5760405180604001604052806008815260200167125391915493905360c21b815250612a5b565b604051806040016040528060048152602001632624a7a760e11b8152505b60008281526049602090815260409091208251612a7e93919291909101906145a5565b505b612a8a86826131cc565b5080612a958161503a565b9150506129e2565b50611a0d83613bfb565b6001600160a01b0382166000818152606660209081526040808320805460018082018355918552838520810187905582516080810184528781528085018281524282860190815260608301888152988852606787528588208a89529096529390952094518555915190840155905160028301559151600390910155612b2d8480846135b4565b6001600160a01b038416600081815260676020908152604080832086845282528083204260038201559383526066909152902080548190612b7090600190614f4b565b81548110612b8057612b806150b0565b906000526020600020015481836001015481548110612ba157612ba16150b0565b906000526020600020018190555080805480612bbf57612bbf61509a565b60019003818190600052602060002001600090559055505050505050565b612be56123bf565b15610bd757610bd7612478565b612bfc3382613981565b612c185760405162461bcd60e51b8152600401610b7690614dfe565b610d7f838383613e51565b6040516bffffffffffffffffffffffff193360601b16602082015260009060340160405160208183030381529060405280519060200120905060005b8351811015612cf7576000848281518110612c7c57612c7c6150b0565b6020026020010151905080831115612cb6576040805160208101839052908101849052606001604051602081830303815290604052612cda565b60408051602081018590529081018290526060016040516020818303038152906040525b805190602001209250508080612cef9061501f565b915050612c5f565b50818114610d7f5760405162461bcd60e51b81526020600482015260166024820152751d1a19481c1c9bdbd9881a5cc81b9bdd081d985b1a5960521b6044820152606401610b76565b607054604051633cadb18d60e11b81523360048201526000916001600160a01b03169063795b631a9060240160006040518083038186803b158015612d8457600080fd5b505afa158015612d98573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f19168201604052612dc09190810190614b54565b905060008151116040518060400160405280600a81526020016918d85b89dd081b5a5b9d60b21b81525090612e085760405162461bcd60e51b8152600401610b769190614d64565b50816000805b8351811015612f355784821415612e2457612f35565b6000848281518110612e3857612e386150b0565b6020908102919091018101516000818152604b909252604082205490925060ff1690612e6582600a614f4b565b905085811115612e725750845b6000612e7e8284614edb565b6000858152604b602052604090819020805460ff191660ff841690811790915560705491516361c3200360e01b81526004810188905260248101919091529192506001600160a01b0316906361c3200390604401600060405180830381600087803b158015612eec57600080fd5b505af1158015612f00573d6000803e3d6000fd5b505050508186612f109190614edb565b9550612f1c8288614f4b565b9650505050508080612f2d9061501f565b915050612e0e565b50838114611a0d5760405162461bcd60e51b815260206004820152601360248201527218d85b89dd081b5a5b9d08199bdc8819dbdb19606a1b6044820152606401610b76565b336000908152604a6020526040812054612f959083614edb565b336000908152604a60205260409020819055905060018114612fd75760405180604001604052806008815260200167125391915493905360c21b815250612ff5565b604051806040016040528060048152602001632624a7a760e11b8152505b3360009081526048602090815260409091208251610d7f93919291909101906145a5565b60405182906000906001600160a01b0383169084908381818185875af1925050503d8060008114613066576040519150601f19603f3d011682016040523d82523d6000602084013e61306b565b606091505b50509050806040518060400160405280601c81526020017f46756e6374696f6e2063616c6c206e6f74207375636365737366756c00000000815250906130c45760405162461bcd60e51b8152600401610b769190614d64565b5050505050565b60785460ff166131145760405162461bcd60e51b815260206004820152601460248201527314185d5cd8589b194e881b9bdd081c185d5cd95960621b6044820152606401610b76565b6078805460ff191690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b6040516001600160a01b03909116815260200160405180910390a1565b610d7f83838360405180602001604052806000815250611c3a565b603c816043546131899190614edb565b11156040518060400160405280600a81526020016918d85b89dd081b5a5b9d60b21b815250906111df5760405162461bcd60e51b8152600401610b769190614d64565b336000908152606660209081526040808320546001600160a01b0386168085528285208054600181810183559187528587200187905583516080810185528781528086018481524282870190815260608301898152948952606788528689208a8a5290975294909620955186559251928501929092559151600284015551600390920191909155606a61325d613bd8565b8154811061326d5761326d6150b0565b60009182526020822060036005909202010180549161328b8361501f565b9190505550610d7f8383613ffc565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60785460ff16156133305760405162461bcd60e51b815260206004820152601060248201526f14185d5cd8589b194e881c185d5cd95960821b6044820152606401610b76565b6078805460ff191660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586131413390565b604554600090819060ff6101009091041661337f607b5490565b61338b906103e8614f4b565b6133959190614f4b565b60008054604051600160a01b90910460f01b6001600160f01b03191660208201524160601b6bffffffffffffffffffffffff191660228201524460368201524260568201529192509082906076016040516020818303038152906040528051906020012060001c613406919061505a565b90508161341281614fb1565b9250506000806001836103e8811061342c5761342c6150b0565b601081049190910154600f9091166002026101000a900461ffff16905080156134575780915061345b565b8291505b60006001856103e88110613471576134716150b0565b601081049190910154600f9091166002026101000a900461ffff169050806134d257846001856103e881106134a8576134a86150b0565b601091828204019190066002026101000a81548161ffff021916908361ffff16021790555061350d565b806001856103e881106134e7576134e76150b0565b601091828204019190066002026101000a81548161ffff021916908361ffff1602179055505b60008054600160a01b900461ffff1690601461352883614ffd565b91906101000a81548161ffff021916908361ffff160217905550508260016135509190614edb565b9550505050505090565b336000908152605e602090815260409182902054825180840190935260098352686e6f2061636365737360b81b9183019190915260ff1690816135b05760405162461bcd60e51b8152600401610b769190614d64565b5090565b6001600160a01b038316600090815260686020526040812054906135d6613bd8565b90508082106040518060400160405280600a8152602001696e6f2062616c616e636560b01b8152509061361c5760405162461bcd60e51b8152600401610b769190614d64565b508215156000835b83811015613883576000606a8281548110613641576136416150b0565b90600052602060002090600502016040518060a00160405290816000820154815260200160018201548152602001600282015481526020016003820154815260200160048201548152505090508060400151600014156136a15750613871565b600080856136c7576001600160a01b038b166000908152606660205260409020546136ca565b60015b905060005b818110156137fb57600087156136e657508961371e565b6001600160a01b038d166000908152606660205260409020805483908110613710576137106150b0565b906000526020600020015490505b6000868152606b6020908152604080832084845290915290205460ff161561374657506137e9565b6001600160a01b038d166000908152606760209081526040808320848452825291829020825160808101845281548152600182015492810192909252600281015492820183905260030154606082015286519091108015906137af575085602001518160600151105b156137e657846137be8161501f565b6000898152606b602090815260408083208784529091529020805460ff191660011790559550505b50505b806137f38161501f565b9150506136cf565b508161380957505050613871565b81606a858154811061381d5761381d6150b0565b9060005260206000209060050201600401600082825461383d9190614edb565b909155505060608301516040840151839161385791614f18565b6138619190614f2c565b61386b9086614edb565b94505050505b8061387b8161501f565b915050613624565b5060408051808201909152600a8152696e6f2062616c616e636560b01b6020820152816138c35760405162461bcd60e51b8152600401610b769190614d64565b50816138e5576001600160a01b03871660009081526068602052604090208390555b80606d60008282546138f79190614edb565b9091555050606f5460405163040b850f60e31b81526001600160a01b038881166004830152602482018490529091169063205c287890604401600060405180830381600087803b15801561394a57600080fd5b505af115801561395e573d6000803e3d6000fd5b5050505050505050505050565b6000613975613365565b90506111df82826131cc565b6000818152607460205260408120546001600160a01b03166139fa5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610b76565b6000613a05836114bc565b9050806001600160a01b0316846001600160a01b03161480613a405750836001600160a01b0316613a3584610bd9565b6001600160a01b0316145b80613a505750613a50818561223e565b949350505050565b613a63848484613e51565b613a6f84848484614016565b611a0d5760405162461bcd60e51b8152600401610b7690614d77565b606060658054610ac990614fc8565b606081613abe5750506040805180820190915260018152600360fc1b602082015290565b8160005b8115613ae85780613ad28161501f565b9150613ae19050600a83614f18565b9150613ac2565b60008167ffffffffffffffff811115613b0357613b036150c6565b6040519080825280601f01601f191660200182016040528015613b2d576020820181803683370190505b5090505b8415613a5057613b42600183614f4b565b9150613b4f600a8661505a565b613b5a906030614edb565b60f81b818381518110613b6f57613b6f6150b0565b60200101906001600160f81b031916908160001a905350613b91600a86614f18565b9450613b31565b60006001600160e01b031982166380ac58cd60e01b1480613bc957506001600160e01b03198216635b5e139f60e01b145b80610ab45750610ab482614123565b606a54600090613bea90600190614f4b565b905090565b6000611d6f8284614f2c565b604454349015613c87576000604f613c1560016005614f4b565b60058110613c2557613c256150b0565b01546044546001600160a01b039091169150821115613c6357604454613c4b9083614f4b565b9150613c5981604454613019565b6000604455613c85565b8160446000828254613c759190614f4b565b90915550610d7f90508183613019565b505b604554601990613c9b90849060ff16614ef3565b60ff16108015613cdb5750604354603c604054613cb89190614f4b565b613cc29190614edb565b8260ff16613ccf607b5490565b613cd99190614edb565b105b15613d8b5760458054839190600090613cf890849060ff16614ef3565b92506101000a81548160ff021916908360ff16021790555060005b60058160ff161015610d7f57606460548260ff1660058110613d3757613d376150b0565b0154613d439084614f2c565b613d4d9190614f18565b60598260ff1660058110613d6357613d636150b0565b016000828254613d739190614edb565b90915550819050613d838161503a565b915050613d13565b6045805460ff1916905560005b60058160ff161015610d7f576000606460548360ff1660058110613dbe57613dbe6150b0565b0154613dca9085614f2c565b613dd49190614f18565b905060598260ff1660058110613dec57613dec6150b0565b0154613df89082614edb565b9050600060598360ff1660058110613e1257613e126150b0565b0155613e3e604f60ff841660058110613e2d57613e2d6150b0565b01546001600160a01b031682613019565b5080613e498161503a565b915050613d98565b826001600160a01b0316613e64826114bc565b6001600160a01b031614613ecc5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201526839903737ba1037bbb760b91b6064820152608401610b76565b6001600160a01b038216613f2e5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610b76565b613f3983838361415f565b613f446000826126dc565b6001600160a01b0383166000908152607560205260408120805460019290613f6d908490614f4b565b90915550506001600160a01b0382166000908152607560205260408120805460019290613f9b908490614edb565b909155505060008181526074602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b6111df82826040518060200160405280600081525061416a565b60006001600160a01b0384163b1561411857604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061405a903390899088908890600401614ce3565b602060405180830381600087803b15801561407457600080fd5b505af19250505080156140a4575060408051601f3d908101601f191682019092526140a191810190614c22565b60015b6140fe573d8080156140d2576040519150601f19603f3d011682016040523d82523d6000602084013e6140d7565b606091505b5080516140f65760405162461bcd60e51b8152600401610b7690614d77565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050613a50565b506001949350505050565b60006301ffc9a760e01b6001600160e01b031983161480610ab45750506001600160e01b03191660009081526071602052604090205460ff1690565b610d7f83838361419d565b6141748383614260565b6141816000848484614016565b610d7f5760405162461bcd60e51b8152600401610b7690614d77565b6141a88383836143ae565b6001600160a01b038316614203576141fe81607b80546000838152607c60205260408120829055600182018355919091527f5569044719a1ec3b04d0afa9e7a5310c7c0473331d13dc9fafe143b2c4e8148a0155565b614226565b816001600160a01b0316836001600160a01b031614614226576142268382614415565b6001600160a01b03821661423d57610d7f816144b2565b826001600160a01b0316826001600160a01b031614610d7f57610d7f8282614561565b6001600160a01b0382166142b65760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610b76565b6000818152607460205260409020546001600160a01b03161561431b5760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610b76565b6143276000838361415f565b6001600160a01b0382166000908152607560205260408120805460019290614350908490614edb565b909155505060008181526074602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60785460ff1615610d7f5760405162461bcd60e51b815260206004820152602b60248201527f4552433732315061757361626c653a20746f6b656e207472616e73666572207760448201526a1a1a5b19481c185d5cd95960aa1b6064820152608401610b76565b60006001614422846115d3565b61442c9190614f4b565b6000838152607a602052604090205490915080821461447f576001600160a01b03841660009081526079602090815260408083208584528252808320548484528184208190558352607a90915290208190555b506000918252607a602090815260408084208490556001600160a01b039094168352607981528383209183525290812055565b607b546000906144c490600190614f4b565b6000838152607c6020526040812054607b80549394509092849081106144ec576144ec6150b0565b9060005260206000200154905080607b838154811061450d5761450d6150b0565b6000918252602080832090910192909255828152607c9091526040808220849055858252812055607b8054806145455761454561509a565b6001900381819060005260206000200160009055905550505050565b600061456c836115d3565b6001600160a01b0390931660009081526079602090815260408083208684528252808320859055938252607a9052919091209190915550565b8280546145b190614fc8565b90600052602060002090601f0160209004810192826145d35760008555614619565b82601f106145ec57805160ff1916838001178555614619565b82800160010185558215614619579182015b828111156146195782518255916020019190600101906145fe565b506135b09291505b808211156135b05760008155600101614621565b600067ffffffffffffffff83111561464f5761464f6150c6565b614662601f8401601f1916602001614e86565b905082815283838301111561467657600080fd5b828260208301376000602084830101529392505050565b600082601f83011261469e57600080fd5b813560206146b36146ae83614eb7565b614e86565b80838252828201915082860187848660051b89010111156146d357600080fd5b60005b858110156146fb5781356146e9816150dc565b845292840192908401906001016146d6565b5090979650505050505050565b600082601f83011261471957600080fd5b813560206147296146ae83614eb7565b80838252828201915082860187848660051b890101111561474957600080fd5b60005b858110156146fb5781358452928401929084019060010161474c565b803560ff8116811461477957600080fd5b919050565b60006020828403121561479057600080fd5b8135611d6f816150dc565b600080604083850312156147ae57600080fd5b82356147b9816150dc565b915060208301356147c9816150dc565b809150509250929050565b6000806000606084860312156147e957600080fd5b83356147f4816150dc565b92506020840135614804816150dc565b929592945050506040919091013590565b6000806000806080858703121561482b57600080fd5b8435614836816150dc565b93506020850135614846816150dc565b925060408501359150606085013567ffffffffffffffff81111561486957600080fd5b8501601f8101871361487a57600080fd5b61488987823560208401614635565b91505092959194509250565b600080604083850312156148a857600080fd5b82356148b3816150dc565b9150602083013567ffffffffffffffff8111156148cf57600080fd5b6148db85828601614708565b9150509250929050565b600080604083850312156148f857600080fd5b8235614903816150dc565b9150602083013580151581146147c957600080fd5b6000806040838503121561492b57600080fd5b8235614936816150dc565b946020939093013593505050565b6000806040838503121561495757600080fd5b8235614962816150dc565b915061497060208401614768565b90509250929050565b60008060006060848603121561498e57600080fd5b8335614999816150dc565b92506149a760208501614768565b9150604084013567ffffffffffffffff8111156149c357600080fd5b6149cf86828701614708565b9150509250925092565b600080604083850312156149ec57600080fd5b823567ffffffffffffffff80821115614a0457600080fd5b614a108683870161468d565b9350602091508185013581811115614a2757600080fd5b85019050601f81018613614a3a57600080fd5b8035614a486146ae82614eb7565b80828252848201915084840189868560051b8701011115614a6857600080fd5b600094505b83851015614a8b578035835260019490940193918501918501614a6d565b5080955050505050509250929050565b60008060408385031215614aae57600080fd5b823567ffffffffffffffff80821115614ac657600080fd5b614ad28683870161468d565b9350602091508185013581811115614ae957600080fd5b85019050601f81018613614afc57600080fd5b8035614b0a6146ae82614eb7565b80828252848201915084840189868560051b8701011115614b2a57600080fd5b600094505b83851015614a8b57614b4081614768565b835260019490940193918501918501614b2f565b60006020808385031215614b6757600080fd5b825167ffffffffffffffff811115614b7e57600080fd5b8301601f81018513614b8f57600080fd5b8051614b9d6146ae82614eb7565b80828252848201915084840188868560051b8701011115614bbd57600080fd5b600094505b83851015614be0578051835260019490940193918501918501614bc2565b50979650505050505050565b600060208284031215614bfe57600080fd5b5035919050565b600060208284031215614c1757600080fd5b8135611d6f816150f1565b600060208284031215614c3457600080fd5b8151611d6f816150f1565b600060208284031215614c5157600080fd5b813567ffffffffffffffff811115614c6857600080fd5b8201601f81018413614c7957600080fd5b613a5084823560208401614635565b60008151808452614ca0816020860160208601614f85565b601f01601f19169290920160200192915050565b60008351614cc6818460208801614f85565b835190830190614cda818360208801614f85565b01949350505050565b6001600160a01b0385811682528416602082015260408101839052608060608201819052600090614d1690830184614c88565b9695505050505050565b6020808252825182820181905260009190848201906040850190845b81811015614d5857835183529284019291840191600101614d3c565b50909695505050505050565b602081526000611d6f6020830184614c88565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b6020808252601f908201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00604082015260600190565b604051601f8201601f1916810167ffffffffffffffff81118282101715614eaf57614eaf6150c6565b604052919050565b600067ffffffffffffffff821115614ed157614ed16150c6565b5060051b60200190565b60008219821115614eee57614eee61506e565b500190565b600060ff821660ff84168060ff03821115614f1057614f1061506e565b019392505050565b600082614f2757614f27615084565b500490565b6000816000190483118215151615614f4657614f4661506e565b500290565b600082821015614f5d57614f5d61506e565b500390565b600060ff821660ff841680821015614f7c57614f7c61506e565b90039392505050565b60005b83811015614fa0578181015183820152602001614f88565b83811115611a0d5750506000910152565b600081614fc057614fc061506e565b506000190190565b600181811c90821680614fdc57607f821691505b60208210811415610ec657634e487b7160e01b600052602260045260246000fd5b600061ffff808316818114156150155761501561506e565b6001019392505050565b60006000198214156150335761503361506e565b5060010190565b600060ff821660ff8114156150515761505161506e565b60010192915050565b60008261506957615069615084565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b038116811461115357600080fd5b6001600160e01b03198116811461115357600080fdfea2646970667358221220f4a746ebee8008cc56cc50ecd5b966c234108355dbd95bc7965cde2461e0a9d964736f6c63430008050033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000c8821cf81dc4a2cb563ed4214f9743606b2f7573000000000000000000000000e9eb0964d6f36c14a0f5657d8788c8892e2ceb6800000000000000000000000021f23e44c17604df9a9e42197e1906580b8e31f2000000000000000000000000dab3a39668a77c12b9b3f0593ebc534d5e861d340000000000000000000000006b148541b80033798a6cab79600f3f0df616b0ed0000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000000f000000000000000000000000000000000000000000000000000000000000000f0000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000a688906bd8b0000
-----Decoded View---------------
Arg [0] : receiverAddresses_ (address[5]): 0xC8821cF81Dc4A2cB563eD4214F9743606b2f7573,0xE9eb0964d6f36c14a0F5657d8788c8892E2cEB68,0x21f23e44C17604dF9a9e42197e1906580B8e31f2,0xDAb3A39668a77C12B9B3f0593ebc534d5E861d34,0x6b148541b80033798A6CAb79600F3F0Df616B0ed
Arg [1] : receiverPercentages_ (uint256[5]): 50,15,15,8,12
Arg [2] : firstPaymentRemaining_ (uint256): 750000000000000000
-----Encoded View---------------
11 Constructor Arguments found :
Arg [0] : 000000000000000000000000c8821cf81dc4a2cb563ed4214f9743606b2f7573
Arg [1] : 000000000000000000000000e9eb0964d6f36c14a0f5657d8788c8892e2ceb68
Arg [2] : 00000000000000000000000021f23e44c17604df9a9e42197e1906580b8e31f2
Arg [3] : 000000000000000000000000dab3a39668a77c12b9b3f0593ebc534d5e861d34
Arg [4] : 0000000000000000000000006b148541b80033798a6cab79600f3f0df616b0ed
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000032
Arg [6] : 000000000000000000000000000000000000000000000000000000000000000f
Arg [7] : 000000000000000000000000000000000000000000000000000000000000000f
Arg [8] : 0000000000000000000000000000000000000000000000000000000000000008
Arg [9] : 000000000000000000000000000000000000000000000000000000000000000c
Arg [10] : 0000000000000000000000000000000000000000000000000a688906bd8b0000
Loading...
Loading
Loading...
Loading
[ 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.