ETH Price: $2,620.09 (+1.50%)

Token

Skell Yeah (SKELLYEAH)
 

Overview

Max Total Supply

2,491 SKELLYEAH

Holders

1,110

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A

Other Info

Balance
1 SKELLYEAH
0xcAfDfB1eb0FA4759a053A953Ae194de72f2131D7
Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
SkellYeah

Compiler Version
v0.8.13+commit.abaa5c0e

Optimization Enabled:
Yes with 2000 runs

Other Settings:
default evmVersion
File 1 of 21 : SkellYeah.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

//-----------------------------------------------------------------------------
// geneticchain.io - NextGen Generative NFT Platform
//-----------------------------------------------------------------------------
 /*\_____________________________________________________________   .¿yy¿.   __
 MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM```````/MMM\\\\\  \\$$$$$$S/  .
 MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM``   `/  yyyy    ` _____J$$$^^^^/%#//
 MMMMMMMMMMMMMMMMMMMYYYMMM````      `\/  .¿yü  /  $ùpüüü%%% | ``|//|` __
 MMMMMYYYYMMMMMMM/`     `| ___.¿yüy¿.  .d$$$$  /  $$$$SSSSM |   | ||  MMNNNNNNM
 M/``      ``\/`  .¿ù%%/.  |.d$$$$$$$b.$$$*°^  /  o$$$  __  |   | ||  MMMMMMMMM
 M   .¿yy¿.     .dX$$$$$$7.|$$$$"^"$$$$$$o`  /MM  o$$$  MM  |   | ||  MMYYYYYYM
   \\$$$$$$S/  .S$$o"^"4$$$$$$$` _ `SSSSS\        ____  MM  |___|_||  MM  ____
  J$$$^^^^/%#//oSSS`    YSSSSSS  /  pyyyüüü%%%XXXÙ$$$$  MM  pyyyyyyy, `` ,$$$o
 .$$$` ___     pyyyyyyyyyyyy//+  /  $$$$$$SSSSSSSÙM$$$. `` .S&&T$T$$$byyd$$$$\
 \$$7  ``     //o$$SSXMMSSSS  |  /  $$/&&X  _  ___ %$$$byyd$$$X\$`/S$$$$$$$S\
 o$$l   .\\YS$$X>$X  _  ___|  |  /  $$/%$$b.,.d$$$\`7$$$$$$$$7`.$   `"***"`  __
 o$$l  __  7$$$X>$$b.,.d$$$\  |  /  $$.`7$$$$$$$$%`  `*+SX+*|_\\$  /.     ..\MM
 o$$L  MM  !$$$$\$$$$$$$$$%|__|  /  $$// `*+XX*\'`  `____           ` `/MMMMMMM
 /$$X, `` ,S$$$$\ `*+XX*\'`____  /  %SXX .      .,   NERV   ___.¿yüy¿.   /MMMMM
  7$$$byyd$$$>$X\  .,,_    $$$$  `    ___ .y%%ü¿.  _______  $.d$$$$$$$S.  `MMMM
  `/S$$$$$$$\\$J`.\\$$$ :  $\`.¿yüy¿. `\\  $$$$$$S.//XXSSo  $$$$$"^"$$$$.  /MMM
 y   `"**"`"Xo$7J$$$$$\    $.d$$$$$$$b.    ^``/$$$$.`$$$$o  $$$$\ _ 'SSSo  /MMM
 M/.__   .,\Y$$$\\$$O` _/  $d$$$*°\ pyyyüüü%%%W $$$o.$$$$/  S$$$. `  S$To   MMM
 MMMM`  \$P*$$X+ b$$l  MM  $$$$` _  $$$$$$SSSSM $$$X.$T&&X  o$$$. `  S$To   MMM
 MMMX`  $<.\X\` -X$$l  MM  $$$$  /  $$/&&X      X$$$/$/X$$dyS$$>. `  S$X%/  `MM
 MMMM/   `"`  . -$$$l  MM  yyyy  /  $$/%$$b.__.d$$$$/$.'7$$$$$$$. `  %SXXX.  MM
 MMMMM//   ./M  .<$$S, `` ,S$$>  /  $$.`7$$$$$$$$$$$/S//_'*+%%XX\ `._       /MM
 MMMMMMMMMMMMM\  /$$$$byyd$$$$\  /  $$// `*+XX+*XXXX      ,.      .\MMMMMMMMMMM
 GENETIC/MMMMM\.  /$$$$$$$$$$\|  /  %SXX  ,_  .      .\MMMMMMMMMMMMMMMMMMMMMMMM
 CHAIN/MMMMMMMM/__  `*+YY+*`_\|  /_______//MMMMMMMMMMMMMMMMMMMMMMMMMMM/-/-/-\*/
//-----------------------------------------------------------------------------
// Genetic Chain: Skell Yeah
//-----------------------------------------------------------------------------
// Author: papaver (@tronicdreams)
//-----------------------------------------------------------------------------

import "./GeneticChain721.sol";

//------------------------------------------------------------------------------
// SkellYeah
//------------------------------------------------------------------------------

/**
 * @title GeneticChain - Project #15 - Skell Yeah
 */
contract SkellYeah is GeneticChain721
{

    //-------------------------------------------------------------------------
    // fields
    //-------------------------------------------------------------------------

    // token info
    string private _baseUri;
    string private _tokenIpfsHash;

    // contract info
    string public _contractUri;

    //-------------------------------------------------------------------------
    // ctor
    //-------------------------------------------------------------------------

    constructor(
        string memory baseUri_,
        string memory ipfsHash_,
        string memory contractUri_,
        uint256[3] memory tokenMax_,
        address proxyRegistryAddress)
        GeneticChain721(
          tokenMax_,
          proxyRegistryAddress)
    {
        _baseUri       = baseUri_;
        _tokenIpfsHash = ipfsHash_;
        _contractUri   = contractUri_;
    }

    //-------------------------------------------------------------------------
    // accessors
    //-------------------------------------------------------------------------

    function setTokenIpfsHash(string memory hash)
        public
        onlyOwner
    {
        if (bytes(hash).length == 0) {
            delete _tokenIpfsHash;
        } else {
            _tokenIpfsHash = hash;
        }
    }

    //-------------------------------------------------------------------------

    function setBaseTokenURI(string memory baseUri)
        public
        onlyOwner
    {
        _baseUri = baseUri;
    }

    //-------------------------------------------------------------------------
    // ERC721Metadata
    //-------------------------------------------------------------------------

    function baseTokenURI()
        public
        view
        returns (string memory)
    {
        return _baseUri;
    }

    //-------------------------------------------------------------------------

    /**
     * @dev Returns uri of a token.  Not guarenteed token exists.
     */
    function tokenURI(uint256 tokenId)
        override
        public
        view
        returns (string memory)
    {
        return bytes(_tokenIpfsHash).length == 0
            ? string(abi.encodePacked(
                baseTokenURI(), "/", Strings.toString(tokenId)))
            : string(abi.encodePacked(
                baseTokenURI(),
                    "/", _tokenIpfsHash,
                    "/", Strings.toString(tokenId)));
    }

    //-------------------------------------------------------------------------
    // contractUri
    //-------------------------------------------------------------------------

    function setContractURI(string memory contractUri)
        public
        onlyOwner
    {
        _contractUri = contractUri;
    }

    //-------------------------------------------------------------------------

    function contractURI()
        public view
        returns (string memory)
    {
        return _contractUri;
    }

}

File 2 of 21 : Ownable.sol
// 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 () {
        address msgSender = _msgSender();
        _owner = msgSender;
        emit OwnershipTransferred(address(0), 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 {
        emit OwnershipTransferred(_owner, address(0));
        _owner = 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");
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

File 3 of 21 : IERC721.sol
// 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;
}

File 4 of 21 : IERC721Receiver.sol
// 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);
}

File 5 of 21 : IERC721Enumerable.sol
// 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);
}

File 6 of 21 : IERC721Metadata.sol
// 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);
}

File 7 of 21 : Address.sol
// 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;
        // solhint-disable-next-line no-inline-assembly
        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");

        // solhint-disable-next-line avoid-low-level-calls, avoid-call-value
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (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");

        // solhint-disable-next-line avoid-low-level-calls
        (bool success, bytes memory returndata) = target.delegatecall(data);
        return _verifyCallResult(success, returndata, errorMessage);
    }

    function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private 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

                // solhint-disable-next-line no-inline-assembly
                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 8 of 21 : Context.sol
// 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) {
        this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
        return msg.data;
    }
}

File 9 of 21 : Strings.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant alphabet = "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] = alphabet[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }

}

File 10 of 21 : ECDSA.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

/**
 * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations.
 *
 * These functions can be used to verify that a message was signed by the holder
 * of the private keys of a given address.
 */
library ECDSA {
    /**
     * @dev Returns the address that signed a hashed message (`hash`) with
     * `signature`. This address can then be used for verification purposes.
     *
     * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures:
     * this function rejects them by requiring the `s` value to be in the lower
     * half order, and the `v` value to be either 27 or 28.
     *
     * IMPORTANT: `hash` _must_ be the result of a hash operation for the
     * verification to be secure: it is possible to craft signatures that
     * recover to arbitrary addresses for non-hashed data. A safe way to ensure
     * this is by receiving a hash of the original message (which may otherwise
     * be too long), and then calling {toEthSignedMessageHash} on it.
     */
    function recover(bytes32 hash, bytes memory signature) internal pure returns (address) {
        // Divide the signature in r, s and v variables
        bytes32 r;
        bytes32 s;
        uint8 v;

        // Check the signature length
        // - case 65: r,s,v signature (standard)
        // - case 64: r,vs signature (cf https://eips.ethereum.org/EIPS/eip-2098) _Available since v4.1._
        if (signature.length == 65) {
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            // solhint-disable-next-line no-inline-assembly
            assembly {
                r := mload(add(signature, 0x20))
                s := mload(add(signature, 0x40))
                v := byte(0, mload(add(signature, 0x60)))
            }
        } else if (signature.length == 64) {
            // ecrecover takes the signature parameters, and the only way to get them
            // currently is to use assembly.
            // solhint-disable-next-line no-inline-assembly
            assembly {
                let vs := mload(add(signature, 0x40))
                r := mload(add(signature, 0x20))
                s := and(vs, 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff)
                v := add(shr(255, vs), 27)
            }
        } else {
            revert("ECDSA: invalid signature length");
        }

        return recover(hash, v, r, s);
    }

    /**
     * @dev Overload of {ECDSA-recover} that receives the `v`,
     * `r` and `s` signature fields separately.
     */
    function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
        // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature
        // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines
        // the valid range for s in (281): 0 < s < secp256k1n ÷ 2 + 1, and for v in (282): v ∈ {27, 28}. Most
        // signatures from current libraries generate a unique signature with an s-value in the lower half order.
        //
        // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value
        // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or
        // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept
        // these malleable signatures as well.
        require(uint256(s) <= 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0, "ECDSA: invalid signature 's' value");
        require(v == 27 || v == 28, "ECDSA: invalid signature 'v' value");

        // If the signature is valid (and not malleable), return the signer address
        address signer = ecrecover(hash, v, r, s);
        require(signer != address(0), "ECDSA: invalid signature");

        return signer;
    }

    /**
     * @dev Returns an Ethereum Signed Message, created from a `hash`. This
     * produces hash corresponding to the one signed with the
     * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`]
     * JSON-RPC method as part of EIP-191.
     *
     * See {recover}.
     */
    function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) {
        // 32 is the length in bytes of hash,
        // enforced by the type signature above
        return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash));
    }

    /**
     * @dev Returns an Ethereum Signed Typed Data, created from a
     * `domainSeparator` and a `structHash`. This produces hash corresponding
     * to the one signed with the
     * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`]
     * JSON-RPC method as part of EIP-712.
     *
     * See {recover}.
     */
    function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) {
        return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash));
    }
}

File 11 of 21 : ERC165.sol
// 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;
    }
}

File 12 of 21 : IERC165.sol
// 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);
}

File 13 of 21 : SafeMath.sol
// 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. This function uses a `revert`
     * opcode (which leaves remaining gas untouched) while Solidity uses an
     * invalid opcode to revert (consuming all remaining gas).
     *
     * 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;
        }
    }
}

File 14 of 21 : GeneticChain721.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

//------------------------------------------------------------------------------
// geneticchain.io - NextGen Generative NFT Platform
//------------------------------------------------------------------------------
//________________________________________________________________   .¿yy¿.   __
//MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM```````/MMM\\\\\  \\$$$$$$S/  .
//MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM``   `/  yyyy    ` _____J$$$*^^*/%#//
//MMMMMMMMMMMMMMMMMMMYYYMMM````      `\/  .¿yü  /  $ùpüüü%%% | ``|//|` __
//MMMMMYYYYMMMMMMM/`     `| ___.¿yüy¿.  .d$$$$  /  $$$$SSSSM |   | ||  MMNNNNNNM
//M/``      ``\/`  .¿ù%%/.  |.d$$$$$$$b.$$$*°^  /  o$$$  __  |   | ||  MMMMMMMMM
//M   .¿yy¿.     .dX$$$$$$7.|$$$$"^"$$$$$$o`  /MM  o$$$  MM  |   | ||  MMYYYYYYM
//  \\$$$$$$S/  .S$$o"^"4$$$$$$$` _ `SSSSS\        ____  MM  |___|_||  MM  ____
// J$$$*^^*/%#//oSSS`    YSSSSSS  /  pyyyüüü%%%XXXÙ$$$$  MM  pyyyyyyy, `` ,$$$o
//.$$$` ___     pyyyyyyyyyyyy//+  /  $$$$$$SSSSSSSÙM$$$. `` .S&&T$T$$$byyd$$$$\
//\$$7  ``     //o$$SSXMMSSSS  |  /  $$/&&X  _  ___ %$$$byyd$$$X\$`/S$$$$$$$S\
//o$$l   .\\YS$$X>$X  _  ___|  |  /  $$/%$$b.,.d$$$\`7$$$$$$$$7`.$   `"***"`  __
//o$$l  __  7$$$X>$$b.,.d$$$\  |  /  $$.`7$$$$$$$$%`  `*+SX+*|_\\$  /.     ..\MM
//o$$L  MM  !$$$$\$$$$$$$$$%|__|  /  $$// `*+XX*\'`  `____           ` `/MMMMMMM
///$$X, `` ,S$$$$\ `*+XX*\'`____  /  %SXX .      .,   NERV   ___.¿yüy¿.   /MMMMM
// 7$$$byyd$$$>$X\  .,,_    $$$$  `    ___ .y%%ü¿.  _______  $.d$$$$$$$S.  `MMMM
// `/S$$$$$$$\\$J`.\\$$$ :  $\`.¿yüy¿. `\\  $$$$$$S.//XXSSo  $$$$$"^"$$$$.  /MMM
//y   `"**"`"Xo$7J$$$$$\    $.d$$$$$$$b.    ^``/$$$$.`$$$$o  $$$$\ _ 'SSSo  /MMM
//M/.__   .,\Y$$$\\$$O` _/  $d$$$*°\ pyyyüüü%%%W $$$o.$$$$/  S$$$. `  S$To   MMM
//MMMM`  \$P*$$X+ b$$l  MM  $$$$` _  $$$$$$SSSSM $$$X.$T&&X  o$$$. `  S$To   MMM
//MMMX`  $<.\X\` -X$$l  MM  $$$$  /  $$/&&X      X$$$/$/X$$dyS$$>. `  S$X%/  `MM
//MMMM/   `"`  . -$$$l  MM  yyyy  /  $$/%$$b.__.d$$$$/$.'7$$$$$$$. `  %SXXX.  MM
//MMMMM//   ./M  .<$$S, `` ,S$$>  /  $$.`7$$$$$$$$$$$/S//_'*+%%XX\ `._       /MM
//MMMMMMMMMMMMM\  /$$$$byyd$$$$\  /  $$// `*+XX+*XXXX      ,.      .\MMMMMMMMMMM
//GENETIC/MMMMM\.  /$$$$$$$$$$\|  /  %SXX  ,_  .      .\MMMMMMMMMMMMMMMMMMMMMMMM
//CHAIN/MMMMMMMM/__  `*+YY+*`_\|  /_______//MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM
//------------------------------------------------------------------------------
// Genetic Chain: GeneticChain721
//------------------------------------------------------------------------------
// Author: papaver (@tronicdreams)
//------------------------------------------------------------------------------

import "openzeppelin-solidity/contracts/access/Ownable.sol";
import "openzeppelin-solidity/contracts/utils/cryptography/ECDSA.sol";
import "openzeppelin-solidity/contracts/utils/Strings.sol";

import "./common/meta-transactions/ContentMixin.sol";
import "./common/meta-transactions/NativeMetaTransaction.sol";
import "./geneticchain/ERC721Sequential.sol";
import "./geneticchain/ERC721SeqEnumerable.sol";
import "./libraries/State.sol";

//------------------------------------------------------------------------------
// helper contracts
//------------------------------------------------------------------------------

contract OwnableDelegateProxy {}

//------------------------------------------------------------------------------

contract ProxyRegistry {
    mapping(address => OwnableDelegateProxy) public proxies;
}

//------------------------------------------------------------------------------
// GeneticChain721
//------------------------------------------------------------------------------

/**
 * @title GeneticChain721
 *
 * ERC721 contract with various features:
 *  - low-gas implmentation
 *  - off-chain whitelist verify (secure minting)
 *  - dynamic token allocation
 *  - artist allocation
 *  - gallery allocation
 *  - protected controlled burns
 *  - opensea proxy setup
 */
abstract contract GeneticChain721 is
    ContextMixin,
    ERC721SeqEnumerable,
    NativeMetaTransaction,
    Ownable
{
    using ECDSA for bytes32;
    using State for State.Data;

    //-------------------------------------------------------------------------
    // fields
    //-------------------------------------------------------------------------

    // erc721 metadata
    string constant private __name   = "Skell Yeah";
    string constant private __symbol = "SKELLYEAH";

    // verification address
    address constant private _signer = 0xc1f40b4438d66a736E9246c0c0B3fD5354F1402a;

    // token limits
    uint256 public immutable publicMax;
    uint256 public immutable artistMax;
    uint256 public immutable galleryMax;

    // opensea proxy
    address private immutable _proxyRegistryAddress;

    // contract state
    State.Data private _state;

    // roles
    mapping (address => bool) private _burnerAddress;
    address private _artistAddress = 0x00f630965f882298219edBB1B96e0409EC6C8698;

    // track mint count per address
    mapping (address => uint256) private _mints;

    //-------------------------------------------------------------------------
    // modifiers
    //-------------------------------------------------------------------------

    modifier validTokenId(uint256 tokenId) {
        require(_exists(tokenId), "invalid token");
        _;
    }

    //-------------------------------------------------------------------------

    modifier isArtist() {
        require(_msgSender() == _artistAddress, "caller not artist");
        _;
    }

    //-------------------------------------------------------------------------

    modifier isBurner() {
        require(_burnerAddress[_msgSender()], "caller not burner");
        _;
    }

    //-------------------------------------------------------------------------

    modifier notLocked() {
        require(_state._locked == 0, "contract is locked");
        _;
    }

    //-------------------------------------------------------------------------
    // ctor
    //-------------------------------------------------------------------------

    constructor(
        uint256[3] memory tokenMax_,
        address proxyRegistryAddress)
        ERC721Sequential(__name, __symbol)
    {
        publicMax             = tokenMax_[0];
        artistMax             = tokenMax_[1];
        galleryMax            = tokenMax_[2];
        _proxyRegistryAddress = proxyRegistryAddress;

        _initializeEIP712(__name);
        _state.setMaxPublic(1);

        // start tokens at 1 index
        _owners.push();
    }

    //-------------------------------------------------------------------------
    // accessors
    //-------------------------------------------------------------------------

    /**
     * Check if public minting is live.
     */
    function publicLive()
        public
        view
        returns (bool)
    {
        return _state._live == 1;
    }

    //-------------------------------------------------------------------------

    /**
     * Check if contract is locked.
     */
    function isLocked()
        public
        view
        returns (bool)
    {
        return _state._locked == 1;
    }

    //-------------------------------------------------------------------------

    /**
     * Get total gallery has minted.
     */
    function galleryMinted()
        public view
        returns (uint256)
    {
        return _state._gallery;
    }

    //-------------------------------------------------------------------------

    /**
     * Get total artist has minted.
     */
    function artistMinted()
        public view
        returns (uint256)
    {
        return _state._artist;
    }

    //-------------------------------------------------------------------------

    /**
     * Get total public has minted.
     */
    function publicMinted()
        public view
        returns (uint256)
    {
        return _state._public;
    }

    //-------------------------------------------------------------------------

    /**
     * Get max count allowed to mint per transaction.
     */
    function maxPublic()
        public view
        returns (uint256)
    {
        return _state._maxPublic;
    }

    //-------------------------------------------------------------------------
    // admin
    //-------------------------------------------------------------------------

    /**
     * Set artist address.
     */
    function setArtistAddress(address artistAddress)
        public
        onlyOwner
    {
        _artistAddress = artistAddress;
    }

    //-------------------------------------------------------------------------

    /**
     * Authorize artist address.
     */
    function registerBurnerAddress(address burner)
        public
        onlyOwner
    {
        require(!_burnerAddress[burner], "address already registered");
        _burnerAddress[burner] = true;
    }

    //-------------------------------------------------------------------------

    /**
     * Remove burner address.
     */
    function revokeBurnerAddress(address burner)
        public
        onlyOwner
    {
        require(_burnerAddress[burner], "address not registered");
        delete _burnerAddress[burner];
    }

    //-------------------------------------------------------------------------

    /**
     * Enable/disable public/member minting.
     */
    function toggleLock()
        public
        onlyOwner
    {
        _state.setLocked(_state._locked == 0 ? 1 : 0);
    }

    //-------------------------------------------------------------------------

    /**
     * Enable/disable public minting.
     */
    function togglePublicMint()
        public
        onlyOwner
    {
        _state.setLive(_state._live == 0 ? 1 : 0);
    }

    //-------------------------------------------------------------------------

    /**
     * Set max public mint per transaction.
     */
    function setMaxPublic(uint256 max)
        public
        onlyOwner
    {
        _state.setMaxPublic(max);
    }

    //-------------------------------------------------------------------------
    // security
    //-------------------------------------------------------------------------

    /**
     * Generate hash from input data.
     */
    function generateHash(uint256 allocation, uint256 count)
        private view
        returns(bytes32)
    {
        return ECDSA.toEthSignedMessageHash(
            keccak256(abi.encodePacked(address(this), msg.sender, allocation, count)));
    }

    //-------------------------------------------------------------------------

    /**
     * Validate message was signed by signer.
     */
    function validateSigner(bytes32 msgHash, bytes memory signature, address signer)
        private pure
        returns(bool)
    {
        return msgHash.recover(signature) == signer;
    }

    //-------------------------------------------------------------------------
    // minting
    //-------------------------------------------------------------------------

    /**
     * Allow anyone to mint tokens.
     */
    function mint(uint256 count)
        public
        notLocked
    {
        require(_state._live == 1, "public mint not live");
        require(count <= _state._maxPublic, "exceed allocation");
        require(_state._public + count <= publicMax, "exceed public supply");

        // track public supply
        _state.addPublic(count);

        // mint
        for (uint256 i = 0; i < count; ++i) {
            _safeMint(msg.sender);
        }
    }

    //-------------------------------------------------------------------------

    /**
     * Mint count tokens using securely signed message.
     */
    function secureMint(bytes calldata signature, uint256 allocation, uint256 count)
        external
        notLocked
    {
        bytes32 msgHash = generateHash(allocation, count);
        require(_state._public + count <= publicMax, "exceed public supply");
        require(_mints[msg.sender] + count <= allocation, "exceed allocation");
        require(validateSigner(msgHash, signature, _signer), "invalid sig");

        // track public supply
        _state.addPublic(count);

        // track user mints
        unchecked {
            _mints[msg.sender] += count;
        }

        // mint
        for (uint256 i = 0; i < count; ++i) {
            _safeMint(msg.sender);
        }
    }

    //-------------------------------------------------------------------------

    /**
     * @dev Mint from gallery's token allocation.
     */
    function galleryMintTo(address wallet, uint256 count)
        public
        onlyOwner
    {
        require(_state._gallery + count <= galleryMax, "exceed gallery supply");
        _state.addGallery(count);
        for (uint256 i = 0; i < count; ++i) {
            _safeMint(wallet);
        }
    }

    //-------------------------------------------------------------------------

    /**
     * @dev Mint from artist's token allocation.
     */
    function artistMintTo(address wallet, uint256 count)
        public
        isArtist
    {
        require(_state._artist + count <= artistMax, "exceed artist supply");
        _state.addArtist(count);
        for (uint256 i = 0; i < count; ++i) {
            _safeMint(wallet);
        }
    }

    //-------------------------------------------------------------------------

    /**
     * @dev Allow extending contract for later burns. See {ERC721-_burn}.
     */
    function burn(uint256 tokenId)
        public
        isBurner
    {
        _burn(tokenId);
    }

    //-------------------------------------------------------------------------
    // money
    //-------------------------------------------------------------------------

    /**
     * Pull money out of this contract.
     */
    function withdraw(address to, uint256 amount)
        public
        onlyOwner
    {
        require(amount > 0, "amount empty");
        require(amount <= address(this).balance, "amount exceeds balance");
        require(to != address(0), "address null");
        payable(to).transfer(amount);
    }

    //-------------------------------------------------------------------------
    // approval
    //-------------------------------------------------------------------------

    /**
     * Override isApprovedForAll to whitelist user's OpenSea proxy accounts
     *  to enable gas-less listings.
     */
    function isApprovedForAll(address owner, address operator)
        override(ERC721Sequential, IERC721)
        public
        view
        returns (bool)
    {
        // whitelist OpenSea proxy contract for easy trading
        ProxyRegistry proxyRegistry = ProxyRegistry(_proxyRegistryAddress);
        if (address(proxyRegistry.proxies(owner)) == operator) {
            return true;
        }

        return super.isApprovedForAll(owner, operator);
    }

    //-------------------------------------------------------------------------

    /**
     * This is used instead of msg.sender as transactions won't be sent by
     *  the original token owner, but by OpenSea.
     */
    function _msgSender()
        override
        internal
        view
        returns (address sender)
    {
        return ContextMixin.msgSender();
    }

}

File 15 of 21 : ContentMixin.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

abstract contract ContextMixin {
    function msgSender()
        internal
        view
        returns (address payable sender)
    {
        if (msg.sender == address(this)) {
            bytes memory array = msg.data;
            uint256 index = msg.data.length;
            assembly {
                // Load the 32 bytes word from memory with the address on the lower 20 bytes, and mask those.
                sender := and(
                    mload(add(array, index)),
                    0xffffffffffffffffffffffffffffffffffffffff
                )
            }
        } else {
            sender = payable(msg.sender);
        }
        return sender;
    }
}

File 16 of 21 : EIP712Base.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import {Initializable} from "./Initializable.sol";

contract EIP712Base is Initializable {
    struct EIP712Domain {
        string name;
        string version;
        address verifyingContract;
        bytes32 salt;
    }

    string constant public ERC712_VERSION = "1";

    bytes32 internal constant EIP712_DOMAIN_TYPEHASH = keccak256(
        bytes(
            "EIP712Domain(string name,string version,address verifyingContract,bytes32 salt)"
        )
    );
    bytes32 internal domainSeperator;

    // supposed to be called once while initializing.
    // one of the contracts that inherits this contract follows proxy pattern
    // so it is not possible to do this in a constructor
    function _initializeEIP712(
        string memory name
    )
        internal
        initializer
    {
        _setDomainSeperator(name);
    }

    function _setDomainSeperator(string memory name) internal {
        domainSeperator = keccak256(
            abi.encode(
                EIP712_DOMAIN_TYPEHASH,
                keccak256(bytes(name)),
                keccak256(bytes(ERC712_VERSION)),
                address(this),
                bytes32(getChainId())
            )
        );
    }

    function getDomainSeperator() public view returns (bytes32) {
        return domainSeperator;
    }

    function getChainId() public view returns (uint256) {
        uint256 id;
        assembly {
            id := chainid()
        }
        return id;
    }

    /**
     * Accept message hash and returns hash message in EIP712 compatible form
     * So that it can be used to recover signer from signature signed using EIP712 formatted data
     * https://eips.ethereum.org/EIPS/eip-712
     * "\\x19" makes the encoding deterministic
     * "\\x01" is the version byte to make it compatible to EIP-191
     */
    function toTypedMessageHash(bytes32 messageHash)
        internal
        view
        returns (bytes32)
    {
        return
            keccak256(
                abi.encodePacked("\x19\x01", getDomainSeperator(), messageHash)
            );
    }
}

File 17 of 21 : Initializable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

contract Initializable {
    bool inited = false;

    modifier initializer() {
        require(!inited, "already inited");
        _;
        inited = true;
    }
}

File 18 of 21 : NativeMetaTransaction.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

import {SafeMath} from  "openzeppelin-solidity/contracts/utils/math/SafeMath.sol";
import {EIP712Base} from "./EIP712Base.sol";

contract NativeMetaTransaction is EIP712Base {
    using SafeMath for uint256;
    bytes32 private constant META_TRANSACTION_TYPEHASH = keccak256(
        bytes(
            "MetaTransaction(uint256 nonce,address from,bytes functionSignature)"
        )
    );
    event MetaTransactionExecuted(
        address userAddress,
        address payable relayerAddress,
        bytes functionSignature
    );
    mapping(address => uint256) nonces;

    /*
     * Meta transaction structure.
     * No point of including value field here as if user is doing value transfer then he has the funds to pay for gas
     * He should call the desired function directly in that case.
     */
    struct MetaTransaction {
        uint256 nonce;
        address from;
        bytes functionSignature;
    }

    function executeMetaTransaction(
        address userAddress,
        bytes memory functionSignature,
        bytes32 sigR,
        bytes32 sigS,
        uint8 sigV
    ) public payable returns (bytes memory) {
        MetaTransaction memory metaTx = MetaTransaction({
            nonce: nonces[userAddress],
            from: userAddress,
            functionSignature: functionSignature
        });

        require(
            verify(userAddress, metaTx, sigR, sigS, sigV),
            "Signer and signature do not match"
        );

        // increase nonce for user (to avoid re-use)
        nonces[userAddress] = nonces[userAddress].add(1);

        emit MetaTransactionExecuted(
            userAddress,
            payable(msg.sender),
            functionSignature
        );

        // Append userAddress and relayer address at the end to extract it from calling context
        (bool success, bytes memory returnData) = address(this).call(
            abi.encodePacked(functionSignature, userAddress)
        );
        require(success, "Function call not successful");

        return returnData;
    }

    function hashMetaTransaction(MetaTransaction memory metaTx)
        internal
        pure
        returns (bytes32)
    {
        return
            keccak256(
                abi.encode(
                    META_TRANSACTION_TYPEHASH,
                    metaTx.nonce,
                    metaTx.from,
                    keccak256(metaTx.functionSignature)
                )
            );
    }

    function getNonce(address user) public view returns (uint256 nonce) {
        nonce = nonces[user];
    }

    function verify(
        address signer,
        MetaTransaction memory metaTx,
        bytes32 sigR,
        bytes32 sigS,
        uint8 sigV
    ) internal view returns (bool) {
        require(signer != address(0), "NativeMetaTransaction: INVALID_SIGNER");
        return
            signer ==
            ecrecover(
                toTypedMessageHash(hashMetaTransaction(metaTx)),
                sigV,
                sigR,
                sigS
            );
    }
}

File 19 of 21 : ERC721SeqEnumerable.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

//------------------------------------------------------------------------------
// geneticchain.io - NextGen Generative NFT Platform
//------------------------------------------------------------------------------
//    _______                   __   __        ______ __          __
//   |     __|-----.-----.-----|  |_|__|----. |      |  |--.---.-|__|-----.
//   |    |  |  -__|     |  -__|   _|  |  __| |   ---|     |  _  |  |     |
//   |_______|_____|__|__|_____|____|__|____| |______|__|__|___._|__|__|__|
//
//------------------------------------------------------------------------------
// Genetic Chain: ERC721SeqEnumerable
//------------------------------------------------------------------------------
// Author: papaver (@tronicdreams)
//------------------------------------------------------------------------------

import "openzeppelin-solidity/contracts/token/ERC721/extensions/IERC721Enumerable.sol";
import "./ERC721Sequential.sol";

/**
 * @dev This is a no storage implemntation of the optional extension {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. These functions
 * are mainly for convienence and should NEVER be called from inside a
 * contract on the chain.
 */
abstract contract ERC721SeqEnumerable is ERC721Sequential, IERC721Enumerable {

    address constant zero = address(0);

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(
        bytes4 interfaceId
    ) public view virtual override(IERC165, ERC721Sequential) 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 tokenId) {
        uint256 length = _owners.length;

        unchecked {
            for (; tokenId < length; ++tokenId) {
                if (_owners[tokenId] == owner) {
                    if (index-- == 0) {
                        break;
                    }
                }
            }
        }

        require(tokenId < length, "ERC721Enumerable: owner index out of bounds");
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256 supply) {
        unchecked {
            uint256 length = _owners.length;
            for (uint256 tokenId = 0; tokenId < length; ++tokenId) {
                if (_owners[tokenId] != zero) {
                    ++supply;
                }
            }
        }
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(
        uint256 index
    ) public view virtual override returns (uint256 tokenId) {
        uint256 length = _owners.length;

        unchecked {
            for (; tokenId < length; ++tokenId) {
                if (_owners[tokenId] != zero) {
                    if (index-- == 0) {
                        break;
                    }
                }
            }
        }

        require(tokenId < length, "ERC721Enumerable: global index out of bounds");
    }

    /**
     * @dev Get all tokens owned by owner.
     */
    function ownerTokens(
        address owner
    ) public view returns (uint256[] memory) {
        uint256 tokenCount = ERC721Sequential.balanceOf(owner);
        require(tokenCount != 0, "ERC721Enumerable: owner owns no tokens");

        uint256 length = _owners.length;
        uint256[] memory tokenIds = new uint256[](tokenCount);
        unchecked {
            uint256 i = 0;
            for (uint256 tokenId = 0; tokenId < length; ++tokenId) {
                if (_owners[tokenId] == owner) {
                    tokenIds[i++] = tokenId;
                }
            }
        }

        return tokenIds;
    }

}

File 20 of 21 : ERC721Sequential.sol
// SPDX-License-Identifier: MIT
// Forked from: OpenZeppelin Contracts v4.4.0 (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

//------------------------------------------------------------------------------
// geneticchain.io - NextGen Generative NFT Platform
//------------------------------------------------------------------------------
//    _______                   __   __        ______ __          __
//   |     __|-----.-----.-----|  |_|__|----. |      |  |--.---.-|__|-----.
//   |    |  |  -__|     |  -__|   _|  |  __| |   ---|     |  _  |  |     |
//   |_______|_____|__|__|_____|____|__|____| |______|__|__|___._|__|__|__|
//
//------------------------------------------------------------------------------
// Genetic Chain: ERC721Sequential
//------------------------------------------------------------------------------
// Author: papaver (@tronicdreams)
//------------------------------------------------------------------------------

import "openzeppelin-solidity/contracts/token/ERC721/IERC721.sol";
import "openzeppelin-solidity/contracts/token/ERC721/IERC721Receiver.sol";
import "openzeppelin-solidity/contracts/token/ERC721/extensions/IERC721Metadata.sol";
import "openzeppelin-solidity/contracts/utils/Address.sol";
import "openzeppelin-solidity/contracts/utils/Context.sol";
import "openzeppelin-solidity/contracts/utils/Strings.sol";
import "openzeppelin-solidity/contracts/utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721
 *  [ERC721] Non-Fungible Token Standard
 *
 *  This implmentation of ERC721 assumes sequencial token creation to provide
 *  efficient minting.  Storage for balance are no longer required reducing
 *  gas significantly.  This comes at the price of calculating the balance by
 *  iterating through the entire array.  The balanceOf function should NOT
 *  be used inside a contract.  Gas usage will explode as the size of tokens
 *  increase.  A convenience function is provided which returns the entire
 *  list of owners whose index maps tokenIds to thier owners.  Zero addresses
 *  indicate burned tokens.
 *
 */
contract ERC721Sequential 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
    address[] _owners;

    // 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 balance) {
        require(owner != address(0), "ERC721: balance query for the zero address");

        unchecked {
            uint256 length = _owners.length;
            for (uint256 i = 0; i < length; ++i) {
                if (_owners[i] == owner) {
                    ++balance;
                }
            }
        }

    }

    /**
     * @dev See {IERC721-ownerOf}.
     */
    function ownerOf(uint256 tokenId) public view virtual override returns (address) {
        require(_exists(tokenId), "ERC721: owner query for nonexistent token");
        address owner = _owners[tokenId];
        return owner;
    }

    /**
     * @dev Returns entire list of owner enumerated by thier tokenIds.  Burned tokens
     * will have a zero address.
     */
    function owners() public view returns (address[] memory) {
        address[] memory owners_ = _owners;
        return owners_;
    }

    /**
     * @dev Return largest tokenId minted.
     */
    function maxTokenId() public view returns (uint256) {
        return _owners.length - 1;
    }

    /**
     * @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 = ERC721Sequential.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 {
        _setApprovalForAll(_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 tokenId < _owners.length && _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 = ERC721Sequential.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) internal virtual returns (uint256 tokenId) {
        tokenId = _safeMint(to, "");
    }

    /**
     * @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,
        bytes memory _data
    ) internal virtual returns (uint256 tokenId) {
        tokenId = _mint(to);
        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) internal virtual returns (uint256 tokenId) {
        require(to != address(0), "ERC721: mint to the zero address");
        tokenId = _owners.length;

        _beforeTokenTransfer(address(0), to, tokenId);

        _owners.push(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 = ERC721Sequential.ownerOf(tokenId);

        _beforeTokenTransfer(owner, address(0), tokenId);

        // Clear approvals
        _approve(address(0), tokenId);

        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(ERC721Sequential.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);

        _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(ERC721Sequential.ownerOf(tokenId), to, tokenId);
    }

    /**
     * @dev Approve `operator` to operate on all of `owner` tokens
     *
     * Emits a {ApprovalForAll} event.
     */
    function _setApprovalForAll(
        address owner,
        address operator,
        bool approved
    ) internal virtual {
        require(owner != operator, "ERC721: approve to caller");
        _operatorApprovals[owner][operator] = approved;
        emit ApprovalForAll(owner, operator, approved);
    }

    /**
     * @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 {}
}

File 21 of 21 : State.sol
// SPDX-License-Identifier: MIT

pragma solidity ^0.8.0;

//------------------------------------------------------------------------------
// geneticchain.io - NextGen Generative NFT Platform
//------------------------------------------------------------------------------
//    _______                   __   __        ______ __          __
//   |     __|-----.-----.-----|  |_|__|----. |      |  |--.---.-|__|-----.
//   |    |  |  -__|     |  -__|   _|  |  __| |   ---|     |  _  |  |     |
//   |_______|_____|__|__|_____|____|__|____| |______|__|__|___._|__|__|__|
//
//------------------------------------------------------------------------------
// Genetic Chain: library/State
//------------------------------------------------------------------------------
// Author: papaver (@tronicdreams)
//------------------------------------------------------------------------------

/**
 * @dev Handle contract state efficiently as possbile.
 */
library State {

    //-------------------------------------------------------------------------
    // fields
    //-------------------------------------------------------------------------

    struct Data {
        uint16  _gallery;
        uint16  _artist;
        uint16  _public;
        uint16  _live;
        uint16  _locked;
        uint16  _maxPublic;
    }

    //-------------------------------------------------------------------------
    // methods
    //-------------------------------------------------------------------------

    function addGallery(Data storage data, uint256 count)
        internal
     {
        unchecked {
            data._gallery += uint16(count);
        }
    }

    //-------------------------------------------------------------------------

    function addArtist(Data storage data, uint256 count)
        internal
     {
        unchecked {
            data._artist += uint16(count);
        }
    }

    //-------------------------------------------------------------------------

    function addPublic(Data storage data, uint256 count)
        internal
     {
        unchecked {
            data._public += uint16(count);
        }
    }

    //-------------------------------------------------------------------------

    function setLive(Data storage data, uint256 enable)
        internal
     {
        data._live = uint16(enable);
    }

    //-------------------------------------------------------------------------

    function setLocked(Data storage data, uint256 enable)
        internal
    {
        data._locked = uint16(enable);
    }

    //-------------------------------------------------------------------------

    function setMaxPublic(Data storage data, uint256 maxPublic)
        internal
    {
        data._maxPublic = uint16(maxPublic);
    }

    //-------------------------------------------------------------------------

    function set(Data storage data, uint256 _gallery, uint256 _artist, uint256 _public)
        internal
    {
        data._gallery = uint16(_gallery);
        data._artist  = uint16(_artist);
        data._public  = uint16(_public);
    }

}

Settings
{
  "remappings": [],
  "optimizer": {
    "enabled": true,
    "runs": 2000
  },
  "evmVersion": "london",
  "libraries": {},
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  }
}

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"string","name":"baseUri_","type":"string"},{"internalType":"string","name":"ipfsHash_","type":"string"},{"internalType":"string","name":"contractUri_","type":"string"},{"internalType":"uint256[3]","name":"tokenMax_","type":"uint256[3]"},{"internalType":"address","name":"proxyRegistryAddress","type":"address"}],"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":false,"internalType":"address","name":"userAddress","type":"address"},{"indexed":false,"internalType":"address payable","name":"relayerAddress","type":"address"},{"indexed":false,"internalType":"bytes","name":"functionSignature","type":"bytes"}],"name":"MetaTransactionExecuted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"previousOwner","type":"address"},{"indexed":true,"internalType":"address","name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"ERC712_VERSION","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_contractUri","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":[],"name":"artistMax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"uint256","name":"count","type":"uint256"}],"name":"artistMintTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"artistMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseTokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"userAddress","type":"address"},{"internalType":"bytes","name":"functionSignature","type":"bytes"},{"internalType":"bytes32","name":"sigR","type":"bytes32"},{"internalType":"bytes32","name":"sigS","type":"bytes32"},{"internalType":"uint8","name":"sigV","type":"uint8"}],"name":"executeMetaTransaction","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"galleryMax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"wallet","type":"address"},{"internalType":"uint256","name":"count","type":"uint256"}],"name":"galleryMintTo","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"galleryMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getChainId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getDomainSeperator","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"getNonce","outputs":[{"internalType":"uint256","name":"nonce","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"address","name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"isLocked","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxPublic","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxTokenId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"count","type":"uint256"}],"name":"mint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"ownerTokens","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owners","outputs":[{"internalType":"address[]","name":"","type":"address[]"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicLive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMax","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"publicMinted","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"burner","type":"address"}],"name":"registerBurnerAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"burner","type":"address"}],"name":"revokeBurnerAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"uint256","name":"allocation","type":"uint256"},{"internalType":"uint256","name":"count","type":"uint256"}],"name":"secureMint","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":"address","name":"artistAddress","type":"address"}],"name":"setArtistAddress","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"baseUri","type":"string"}],"name":"setBaseTokenURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"contractUri","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"max","type":"uint256"}],"name":"setMaxPublic","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"hash","type":"string"}],"name":"setTokenIpfsHash","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":[],"name":"toggleLock","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"togglePublicMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"tokenId","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":"tokenId","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"supply","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"}]

6101006040526005805460ff19169055600b80546001600160a01b03191672f630965f882298219edbb1b96e0409ec6c86981790553480156200004157600080fd5b5060405162004ab938038062004ab983398101604081905262000064916200056b565b604080518082018252600a8152690a6d6cad8d840b2cac2d60b31b6020808301918252835180850190945260098452680a6968a9898b28a82960bb1b90840152815185938593929091620000bb916000916200039f565b508051620000d19060019060208401906200039f565b5050506000620000e6620001fb60201b60201c565b600880546001600160a01b0319166001600160a01b038316908117909155604051919250906000907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350815160805260208083015160a05260408084015160c0526001600160a01b03831660e0528051808201909152600a8152690a6d6cad8d840b2cac2d60b31b91810191909152620001849062000217565b620001a0600160096200027b60201b62002a531790919060201c565b50506002805460010181556000528451620001c390600d9060208801906200039f565b508351620001d990600e9060208701906200039f565b508251620001ef90600f9060208601906200039f565b5050505050506200069e565b6000620002126200029f60201b62002a7e1760201c565b905090565b60055460ff1615620002605760405162461bcd60e51b815260206004820152600e60248201526d185b1c9958591e481a5b9a5d195960921b604482015260640160405180910390fd5b6200026b81620002fd565b506005805460ff19166001179055565b815461ffff9091166a01000000000000000000000261ffff60501b19909116179055565b6000303303620002f757600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b03169150620002fa9050565b50335b90565b6040518060800160405280604f815260200162004a6a604f9139805160209182012082519282019290922060408051808201825260018152603160f81b90840152805180840194909452838101919091527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc660608401523060808401524660a0808501919091528151808503909101815260c090930190528151910120600655565b828054620003ad9062000662565b90600052602060002090601f016020900481019282620003d157600085556200041c565b82601f10620003ec57805160ff19168380011785556200041c565b828001600101855582156200041c579182015b828111156200041c578251825591602001919060010190620003ff565b506200042a9291506200042e565b5090565b5b808211156200042a57600081556001016200042f565b634e487b7160e01b600052604160045260246000fd5b604051606081016001600160401b038111828210171562000480576200048062000445565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004b157620004b162000445565b604052919050565b600082601f830112620004cb57600080fd5b81516001600160401b03811115620004e757620004e762000445565b6020620004fd601f8301601f1916820162000486565b82815285828487010111156200051257600080fd5b60005b838110156200053257858101830151828201840152820162000515565b83811115620005445760008385840101525b5095945050505050565b80516001600160a01b03811681146200056657600080fd5b919050565b600080600080600060e086880312156200058457600080fd5b85516001600160401b03808211156200059c57600080fd5b620005aa89838a01620004b9565b9650602091508188015181811115620005c257600080fd5b620005d08a828b01620004b9565b965050604088015181811115620005e657600080fd5b620005f48a828b01620004b9565b9550505087607f8801126200060857600080fd5b620006126200045b565b8060c089018a8111156200062557600080fd5b60608a015b818110156200064357805184529284019284016200062a565b5081955062000652816200054e565b9450505050509295509295909350565b600181811c908216806200067757607f821691505b6020821081036200069857634e487b7160e01b600052602260045260246000fd5b50919050565b60805160a05160c05160e051614376620006f4600039600061250f0152600081816106bd01526114dc0152600081816109d00152610fab01526000818161094801528181611ba00152611ed001526143766000f3fe6080604052600436106103555760003560e01c80638da5cb5b116101bb578063ba8bce55116100f7578063e985e9c511610095578063f2fde38b1161006f578063f2fde38b146109f2578063f3fef3a314610a12578063fbdb849414610a32578063ff9413d814610a5257600080fd5b8063e985e9c51461097f578063ed329fa81461099f578063ef3c6624146109be57600080fd5b8063d547cfb7116100d1578063d547cfb71461090c578063d9ce2f6d14610921578063e527c6dd14610936578063e8a3d4851461096a57600080fd5b8063ba8bce551461089f578063bba7723e146108bf578063c87b56dd146108ec57600080fd5b8063a22cb46511610164578063a4f4f8af1161013e578063a4f4f8af14610816578063affe39c114610837578063b7f751d814610859578063b88d4fde1461087f57600080fd5b8063a22cb465146107ae578063a22e4faa146107ce578063a4e2d634146107ee57600080fd5b80639509af06116101955780639509af061461075957806395d89b4114610779578063a0712d681461078e57600080fd5b80638da5cb5b1461070657806391ba317a14610724578063938e3d7b1461073957600080fd5b80633408e470116102955780634dcc60af1161023357806370a082311161020d57806370a0823114610676578063715018a61461069657806371dedace146106ab5780637dc42975146106df57600080fd5b80634dcc60af146106165780634f6ccce7146106365780636352211e1461065657600080fd5b806342842e0e1161026f57806342842e0e1461059657806342966c68146105b657806344be774f146105d65780634b457935146105f657600080fd5b80633408e470146105555780633763e75b146105685780634047638d1461058157600080fd5b806314d7d5171161030257806323b872dd116102dc57806323b872dd146104bf5780632d0335ab146104df5780632f745c591461051557806330176e131461053557600080fd5b806314d7d5171461046757806318160ddd1461048757806320379ee5146104aa57600080fd5b8063095ea7b311610333578063095ea7b3146103e95780630c53c51c1461040b5780630f7e59701461041e57600080fd5b806301ffc9a71461035a57806306fdde031461038f578063081812fc146103b1575b600080fd5b34801561036657600080fd5b5061037a610375366004613b6a565b610a67565b60405190151581526020015b60405180910390f35b34801561039b57600080fd5b506103a4610ac3565b6040516103869190613bdf565b3480156103bd57600080fd5b506103d16103cc366004613bf2565b610b55565b6040516001600160a01b039091168152602001610386565b3480156103f557600080fd5b50610409610404366004613c20565b610bf3565b005b6103a4610419366004613cf8565b610d36565b34801561042a57600080fd5b506103a46040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525081565b34801561047357600080fd5b50610409610482366004613c20565b610f3c565b34801561049357600080fd5b5061049c611090565b604051908152602001610386565b3480156104b657600080fd5b5060065461049c565b3480156104cb57600080fd5b506104096104da366004613d76565b6110ec565b3480156104eb57600080fd5b5061049c6104fa366004613db7565b6001600160a01b031660009081526007602052604090205490565b34801561052157600080fd5b5061049c610530366004613c20565b61117a565b34801561054157600080fd5b50610409610550366004613dd4565b611253565b34801561056157600080fd5b504661049c565b34801561057457600080fd5b5060095461ffff1661049c565b34801561058d57600080fd5b506104096112e3565b3480156105a257600080fd5b506104096105b1366004613d76565b6113c2565b3480156105c257600080fd5b506104096105d1366004613bf2565b6113dd565b3480156105e257600080fd5b506104096105f1366004613c20565b61145e565b34801561060257600080fd5b50610409610611366004613db7565b6115b2565b34801561062257600080fd5b50610409610631366004613dd4565b6116b8565b34801561064257600080fd5b5061049c610651366004613bf2565b611759565b34801561066257600080fd5b506103d1610671366004613bf2565b611832565b34801561068257600080fd5b5061049c610691366004613db7565b6118e0565b3480156106a257600080fd5b506104096119b9565b3480156106b757600080fd5b5061049c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156106eb57600080fd5b506009546a0100000000000000000000900461ffff1661049c565b34801561071257600080fd5b506008546001600160a01b03166103d1565b34801561073057600080fd5b5061049c611a89565b34801561074557600080fd5b50610409610754366004613dd4565b611aa0565b34801561076557600080fd5b50610409610774366004613e1d565b611b2c565b34801561078557600080fd5b506103a4611d98565b34801561079a57600080fd5b506104096107a9366004613bf2565b611da7565b3480156107ba57600080fd5b506104096107c9366004613e9c565b611fa0565b3480156107da57600080fd5b506104096107e9366004613db7565b611fb2565b3480156107fa57600080fd5b5060095468010000000000000000900461ffff1660011461037a565b34801561082257600080fd5b50600954640100000000900461ffff1661049c565b34801561084357600080fd5b5061084c61205a565b6040516103869190613eda565b34801561086557600080fd5b506009546601000000000000900461ffff1660011461037a565b34801561088b57600080fd5b5061040961089a366004613f27565b6120c0565b3480156108ab57600080fd5b506104096108ba366004613db7565b612155565b3480156108cb57600080fd5b506108df6108da366004613db7565b612257565b6040516103869190613f93565b3480156108f857600080fd5b506103a4610907366004613bf2565b6123a2565b34801561091857600080fd5b506103a4612428565b34801561092d57600080fd5b506103a4612437565b34801561094257600080fd5b5061049c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561097657600080fd5b506103a46124c5565b34801561098b57600080fd5b5061037a61099a366004613fcb565b6124d4565b3480156109ab57600080fd5b5060095462010000900461ffff1661049c565b3480156109ca57600080fd5b5061049c7f000000000000000000000000000000000000000000000000000000000000000081565b3480156109fe57600080fd5b50610409610a0d366004613db7565b6125cb565b348015610a1e57600080fd5b50610409610a2d366004613c20565b612729565b348015610a3e57600080fd5b50610409610a4d366004613bf2565b6128ce565b348015610a5e57600080fd5b50610409612972565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f780e9d63000000000000000000000000000000000000000000000000000000001480610abd5750610abd82612ada565b92915050565b606060008054610ad290613ff9565b80601f0160208091040260200160405190810160405280929190818152602001828054610afe90613ff9565b8015610b4b5780601f10610b2057610100808354040283529160200191610b4b565b820191906000526020600020905b815481529060010190602001808311610b2e57829003601f168201915b5050505050905090565b6000610b6082612bbd565b610bd75760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152600360205260409020546001600160a01b031690565b6000610bfe82611832565b9050806001600160a01b0316836001600160a01b031603610c875760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b806001600160a01b0316610c99612c07565b6001600160a01b03161480610cb55750610cb58161099a612c07565b610d275760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610bce565b610d318383612c11565b505050565b60408051606081810183526001600160a01b03881660008181526007602090815290859020548452830152918101869052610d748782878787612c8c565b610de65760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d61746360448201527f68000000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b6001600160a01b038716600090815260076020526040902054610e0a906001612d94565b6001600160a01b0388166000908152600760205260409081902091909155517f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b90610e5a90899033908a9061402d565b60405180910390a1600080306001600160a01b0316888a604051602001610e82929190614075565b60408051601f1981840301815290829052610e9c916140ac565b6000604051808303816000865af19150503d8060008114610ed9576040519150601f19603f3d011682016040523d82523d6000602084013e610ede565b606091505b509150915081610f305760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610bce565b98975050505050505050565b600b546001600160a01b0316610f50612c07565b6001600160a01b031614610fa65760405162461bcd60e51b815260206004820152601160248201527f63616c6c6572206e6f74206172746973740000000000000000000000000000006044820152606401610bce565b6009547f000000000000000000000000000000000000000000000000000000000000000090610fe090839062010000900461ffff166140de565b111561102e5760405162461bcd60e51b815260206004820152601460248201527f6578636565642061727469737420737570706c790000000000000000000000006044820152606401610bce565b6009805461ffff6201000080830482168501909116027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff90911617905560005b81811015610d315761107f83612da7565b50611089816140f6565b905061106e565b600254600090815b818110156110e75760006001600160a01b0316600282815481106110be576110be614110565b6000918252602090912001546001600160a01b0316146110df578260010192505b600101611098565b505090565b6110fd6110f7612c07565b82612dc2565b61116f5760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610bce565b610d31838383612e95565b6002546000905b808210156111d757836001600160a01b0316600283815481106111a6576111a6614110565b6000918252602090912001546001600160a01b0316036111cc57600019830192156111d7575b816001019150611181565b80821061124c5760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610bce565b5092915050565b61125b612c07565b6001600160a01b03166112766008546001600160a01b031690565b6001600160a01b0316146112cc5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516112df90600d906020840190613a6d565b5050565b6112eb612c07565b6001600160a01b03166113066008546001600160a01b031690565b6001600160a01b03161461135c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009546113c0906601000000000000900461ffff161561137d576000611380565b60015b60099060ff16815461ffff9091166601000000000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff909116179055565b565b610d31838383604051806020016040528060008152506120c0565b600a60006113e9612c07565b6001600160a01b0316815260208101919091526040016000205460ff166114525760405162461bcd60e51b815260206004820152601160248201527f63616c6c6572206e6f74206275726e65720000000000000000000000000000006044820152606401610bce565b61145b81613025565b50565b611466612c07565b6001600160a01b03166114816008546001600160a01b031690565b6001600160a01b0316146114d75760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009547f00000000000000000000000000000000000000000000000000000000000000009061150b90839061ffff166140de565b11156115595760405162461bcd60e51b815260206004820152601560248201527f6578636565642067616c6c65727920737570706c7900000000000000000000006044820152606401610bce565b6009805461ffff8082168401167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090911617905560005b81811015610d31576115a183612da7565b506115ab816140f6565b9050611590565b6115ba612c07565b6001600160a01b03166115d56008546001600160a01b031690565b6001600160a01b03161461162b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166000908152600a602052604090205460ff16156116945760405162461bcd60e51b815260206004820152601a60248201527f6164647265737320616c726561647920726567697374657265640000000000006044820152606401610bce565b6001600160a01b03166000908152600a60205260409020805460ff19166001179055565b6116c0612c07565b6001600160a01b03166116db6008546001600160a01b031690565b6001600160a01b0316146117315760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516000036117465761145b600e6000613af1565b80516112df90600e906020840190613a6d565b6002546000905b808210156117b75760006001600160a01b03166002838154811061178657611786614110565b6000918252602090912001546001600160a01b0316146117ac57600019830192156117b7575b816001019150611760565b80821061182c5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610bce565b50919050565b600061183d82612bbd565b6118af5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610bce565b6000600283815481106118c4576118c4614110565b6000918252602090912001546001600160a01b03169392505050565b60006001600160a01b03821661195e5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610bce565b60025460005b818110156119b257836001600160a01b03166002828154811061198957611989614110565b6000918252602090912001546001600160a01b0316036119aa578260010192505b600101611964565b5050919050565b6119c1612c07565b6001600160a01b03166119dc6008546001600160a01b031690565b6001600160a01b031614611a325760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6008546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a36008805473ffffffffffffffffffffffffffffffffffffffff19169055565b600254600090611a9b90600190614126565b905090565b611aa8612c07565b6001600160a01b0316611ac36008546001600160a01b031690565b6001600160a01b031614611b195760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516112df90600f906020840190613a6d565b60095468010000000000000000900461ffff1615611b8c5760405162461bcd60e51b815260206004820152601260248201527f636f6e7472616374206973206c6f636b656400000000000000000000000000006044820152606401610bce565b6000611b9883836130af565b6009549091507f000000000000000000000000000000000000000000000000000000000000000090611bd7908490640100000000900461ffff166140de565b1115611c255760405162461bcd60e51b815260206004820152601460248201527f657863656564207075626c696320737570706c790000000000000000000000006044820152606401610bce565b336000908152600c60205260409020548390611c429084906140de565b1115611c905760405162461bcd60e51b815260206004820152601160248201527f65786365656420616c6c6f636174696f6e0000000000000000000000000000006044820152606401610bce565b611ce68186868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525073c1f40b4438d66a736e9246c0c0b3fd5354f1402a9250613109915050565b611d325760405162461bcd60e51b815260206004820152600b60248201527f696e76616c6964207369670000000000000000000000000000000000000000006044820152606401610bce565b6009805461ffff640100000000808304821686019091160265ffff0000000019909116179055336000908152600c602052604081208054840190555b82811015611d9057611d7f33612da7565b50611d89816140f6565b9050611d6e565b505050505050565b606060018054610ad290613ff9565b60095468010000000000000000900461ffff1615611e075760405162461bcd60e51b815260206004820152601260248201527f636f6e7472616374206973206c6f636b656400000000000000000000000000006044820152606401610bce565b6009546601000000000000900461ffff16600114611e675760405162461bcd60e51b815260206004820152601460248201527f7075626c6963206d696e74206e6f74206c6976650000000000000000000000006044820152606401610bce565b6009546a0100000000000000000000900461ffff16811115611ecb5760405162461bcd60e51b815260206004820152601160248201527f65786365656420616c6c6f636174696f6e0000000000000000000000000000006044820152606401610bce565b6009547f000000000000000000000000000000000000000000000000000000000000000090611f07908390640100000000900461ffff166140de565b1115611f555760405162461bcd60e51b815260206004820152601460248201527f657863656564207075626c696320737570706c790000000000000000000000006044820152606401610bce565b6009805461ffff640100000000808304821685019091160265ffff000000001990911617905560005b818110156112df57611f8f33612da7565b50611f99816140f6565b9050611f7e565b6112df611fab612c07565b8383613131565b611fba612c07565b6001600160a01b0316611fd56008546001600160a01b031690565b6001600160a01b03161461202b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600b805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6060600060028054806020026020016040519081016040528092919081815260200182805480156120b457602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612096575b50939695505050505050565b6120d16120cb612c07565b83612dc2565b6121435760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610bce565b61214f848484846131ff565b50505050565b61215d612c07565b6001600160a01b03166121786008546001600160a01b031690565b6001600160a01b0316146121ce5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166000908152600a602052604090205460ff166122365760405162461bcd60e51b815260206004820152601660248201527f61646472657373206e6f742072656769737465726564000000000000000000006044820152606401610bce565b6001600160a01b03166000908152600a60205260409020805460ff19169055565b60606000612264836118e0565b9050806000036122dc5760405162461bcd60e51b815260206004820152602660248201527f455243373231456e756d657261626c653a206f776e6572206f776e73206e6f2060448201527f746f6b656e7300000000000000000000000000000000000000000000000000006064820152608401610bce565b60025460008267ffffffffffffffff8111156122fa576122fa613c4c565b604051908082528060200260200182016040528015612323578160200160208202803683370190505b5090506000805b8381101561239757866001600160a01b03166002828154811061234f5761234f614110565b6000918252602090912001546001600160a01b03160361238f578083838060010194508151811061238257612382614110565b6020026020010181815250505b60010161232a565b509095945050505050565b6060600e80546123b190613ff9565b1590506123f1576123c0612428565b600e6123cb84613288565b6040516020016123dd9392919061413d565b604051602081830303815290604052610abd565b6123f9612428565b61240283613288565b604051602001612413929190614217565b60405160208183030381529060405292915050565b6060600d8054610ad290613ff9565b600f805461244490613ff9565b80601f016020809104026020016040519081016040528092919081815260200182805461247090613ff9565b80156124bd5780601f10612492576101008083540402835291602001916124bd565b820191906000526020600020905b8154815290600101906020018083116124a057829003601f168201915b505050505081565b6060600f8054610ad290613ff9565b6040517fc45527910000000000000000000000000000000000000000000000000000000081526001600160a01b0383811660048301526000917f000000000000000000000000000000000000000000000000000000000000000091848116919083169063c455279190602401602060405180830381865afa15801561255d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125819190614253565b6001600160a01b031603612599576001915050610abd565b6001600160a01b0380851660009081526004602090815260408083209387168352929052205460ff165b949350505050565b6125d3612c07565b6001600160a01b03166125ee6008546001600160a01b031690565b6001600160a01b0316146126445760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166126c05760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610bce565b6008546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36008805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b612731612c07565b6001600160a01b031661274c6008546001600160a01b031690565b6001600160a01b0316146127a25760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600081116127f25760405162461bcd60e51b815260206004820152600c60248201527f616d6f756e7420656d70747900000000000000000000000000000000000000006044820152606401610bce565b478111156128425760405162461bcd60e51b815260206004820152601660248201527f616d6f756e7420657863656564732062616c616e6365000000000000000000006044820152606401610bce565b6001600160a01b0382166128985760405162461bcd60e51b815260206004820152600c60248201527f61646472657373206e756c6c00000000000000000000000000000000000000006044820152606401610bce565b6040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015610d31573d6000803e3d6000fd5b6128d6612c07565b6001600160a01b03166128f16008546001600160a01b031690565b6001600160a01b0316146129475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600980546bffff0000000000000000000019166a010000000000000000000061ffff84160217905550565b61297a612c07565b6001600160a01b03166129956008546001600160a01b031690565b6001600160a01b0316146129eb5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009546113c09068010000000000000000900461ffff1615612a0e576000612a11565b60015b60099060ff16815461ffff90911668010000000000000000027fffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffff909116179055565b815461ffff9091166a0100000000000000000000026bffff0000000000000000000019909116179055565b6000303303612ad457600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b03169150612ad79050565b50335b90565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd000000000000000000000000000000000000000000000000000000001480612b6d57507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b80610abd57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610abd565b60025460009082108015610abd575060006001600160a01b031660028381548110612bea57612bea614110565b6000918252602090912001546001600160a01b0316141592915050565b6000611a9b612a7e565b6000818152600360205260409020805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0384169081179091558190612c5382611832565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60006001600160a01b038616612d0a5760405162461bcd60e51b815260206004820152602560248201527f4e61746976654d6574615472616e73616374696f6e3a20494e56414c49445f5360448201527f49474e45520000000000000000000000000000000000000000000000000000006064820152608401610bce565b6001612d1d612d18876133bd565b61343a565b6040805160008152602081018083529290925260ff851690820152606081018690526080810185905260a0016020604051602081039080840390855afa158015612d6b573d6000803e3d6000fd5b505050602060405103516001600160a01b0316866001600160a01b031614905095945050505050565b6000612da082846140de565b9392505050565b6000610abd8260405180602001604052806000815250613485565b6000612dcd82612bbd565b612e3f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610bce565b6000612e4a83611832565b9050806001600160a01b0316846001600160a01b03161480612e855750836001600160a01b0316612e7a84610b55565b6001600160a01b0316145b806125c357506125c381856124d4565b826001600160a01b0316612ea882611832565b6001600160a01b031614612f245760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201527f73206e6f74206f776e00000000000000000000000000000000000000000000006064820152608401610bce565b6001600160a01b038216612f9f5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610bce565b612faa600082612c11565b8160028281548110612fbe57612fbe614110565b60009182526020822001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b03938416179055604051839285811692908716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a4505050565b600061303082611832565b905061303d600083612c11565b6002828154811061305057613050614110565b60009182526020822001805473ffffffffffffffffffffffffffffffffffffffff191690556040518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6040516bffffffffffffffffffffffff1930606090811b8216602084015233901b1660348201526048810183905260688101829052600090612da09060880160405160208183030381529060405280519060200120613511565b60006001600160a01b03821661311f858561354c565b6001600160a01b031614949350505050565b816001600160a01b0316836001600160a01b0316036131925760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610bce565b6001600160a01b03838116600081815260046020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61320a848484612e95565b61321684848484613619565b61214f5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b6060816000036132cb57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156132f557806132df816140f6565b91506132ee9050600a83614286565b91506132cf565b60008167ffffffffffffffff81111561331057613310613c4c565b6040519080825280601f01601f19166020018201604052801561333a576020820181803683370190505b5090505b84156125c35761334f600183614126565b915061335c600a8661429a565b6133679060306140de565b60f81b81838151811061337c5761337c614110565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506133b6600a86614286565b945061333e565b60006040518060800160405280604381526020016142fe604391398051602091820120835184830151604080870151805190860120905161341d950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061344560065490565b6040517f1901000000000000000000000000000000000000000000000000000000000000602082015260228101919091526042810183905260620161341d565b6000613490836137a8565b905061349f6000848385613619565b610abd5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c0161341d565b60008060008084516041036135755750505060208201516040830151606084015160001a613603565b84516040036135bb5750505060408201516020830151907f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81169060ff1c601b01613603565b60405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610bce565b61360f8682858561388e565b9695505050505050565b60006001600160a01b0384163b1561379d57836001600160a01b031663150b7a02613642612c07565b8786866040518563ffffffff1660e01b815260040161366494939291906142ae565b6020604051808303816000875af192505050801561369f575060408051601f3d908101601f1916820190925261369c918101906142e0565b60015b613752573d8080156136cd576040519150601f19603f3d011682016040523d82523d6000602084013e6136d2565b606091505b50805160000361374a5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a02000000000000000000000000000000000000000000000000000000001490506125c3565b506001949350505050565b60006001600160a01b0382166138005760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610bce565b506002546002805460018101825560009182527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace01805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0385169081179091556040518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4919050565b60007f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08211156139265760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b8360ff16601b148061393b57508360ff16601c145b6139ad5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b6040805160008082526020820180845288905260ff871692820192909252606081018590526080810184905260019060a0016020604051602081039080840390855afa158015613a01573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613a645760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610bce565b95945050505050565b828054613a7990613ff9565b90600052602060002090601f016020900481019282613a9b5760008555613ae1565b82601f10613ab457805160ff1916838001178555613ae1565b82800160010185558215613ae1579182015b82811115613ae1578251825591602001919060010190613ac6565b50613aed929150613b27565b5090565b508054613afd90613ff9565b6000825580601f10613b0d575050565b601f01602090049060005260206000209081019061145b91905b5b80821115613aed5760008155600101613b28565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461145b57600080fd5b600060208284031215613b7c57600080fd5b8135612da081613b3c565b60005b83811015613ba2578181015183820152602001613b8a565b8381111561214f5750506000910152565b60008151808452613bcb816020860160208601613b87565b601f01601f19169290920160200192915050565b602081526000612da06020830184613bb3565b600060208284031215613c0457600080fd5b5035919050565b6001600160a01b038116811461145b57600080fd5b60008060408385031215613c3357600080fd5b8235613c3e81613c0b565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff80841115613c7d57613c7d613c4c565b604051601f8501601f19908116603f01168101908282118183101715613ca557613ca5613c4c565b81604052809350858152868686011115613cbe57600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613ce957600080fd5b612da083833560208501613c62565b600080600080600060a08688031215613d1057600080fd5b8535613d1b81613c0b565b9450602086013567ffffffffffffffff811115613d3757600080fd5b613d4388828901613cd8565b9450506040860135925060608601359150608086013560ff81168114613d6857600080fd5b809150509295509295909350565b600080600060608486031215613d8b57600080fd5b8335613d9681613c0b565b92506020840135613da681613c0b565b929592945050506040919091013590565b600060208284031215613dc957600080fd5b8135612da081613c0b565b600060208284031215613de657600080fd5b813567ffffffffffffffff811115613dfd57600080fd5b8201601f81018413613e0e57600080fd5b6125c384823560208401613c62565b60008060008060608587031215613e3357600080fd5b843567ffffffffffffffff80821115613e4b57600080fd5b818701915087601f830112613e5f57600080fd5b813581811115613e6e57600080fd5b886020828501011115613e8057600080fd5b6020928301999098509187013596604001359550909350505050565b60008060408385031215613eaf57600080fd5b8235613eba81613c0b565b915060208301358015158114613ecf57600080fd5b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015613f1b5783516001600160a01b031683529284019291840191600101613ef6565b50909695505050505050565b60008060008060808587031215613f3d57600080fd5b8435613f4881613c0b565b93506020850135613f5881613c0b565b925060408501359150606085013567ffffffffffffffff811115613f7b57600080fd5b613f8787828801613cd8565b91505092959194509250565b6020808252825182820181905260009190848201906040850190845b81811015613f1b57835183529284019291840191600101613faf565b60008060408385031215613fde57600080fd5b8235613fe981613c0b565b91506020830135613ecf81613c0b565b600181811c9082168061400d57607f821691505b60208210810361182c57634e487b7160e01b600052602260045260246000fd5b60006001600160a01b03808616835280851660208401525060606040830152613a646060830184613bb3565b6000815161406b818560208601613b87565b9290920192915050565b60008351614087818460208801613b87565b60609390931b6bffffffffffffffffffffffff19169190920190815260140192915050565b600082516140be818460208701613b87565b9190910192915050565b634e487b7160e01b600052601160045260246000fd5b600082198211156140f1576140f16140c8565b500190565b60006000198203614109576141096140c8565b5060010190565b634e487b7160e01b600052603260045260246000fd5b600082821015614138576141386140c8565b500390565b6000845160206141508285838a01613b87565b602f60f81b918401918252855460019060009080831c8184168061417557607f821691505b858210810361419257634e487b7160e01b84526022600452602484fd5b8080156141a657600181146141bb576141ec565b60ff19841686890152858389010194506141ec565b60008c81526020902060005b848110156141e25781548a82018901529087019088016141c7565b5050858389010194505b5050505061420a61420482602f60f81b815260010190565b88614059565b9998505050505050505050565b60008351614229818460208801613b87565b602f60f81b9083019081528351614247816001840160208801613b87565b01600101949350505050565b60006020828403121561426557600080fd5b8151612da081613c0b565b634e487b7160e01b600052601260045260246000fd5b60008261429557614295614270565b500490565b6000826142a9576142a9614270565b500690565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261360f6080830184613bb3565b6000602082840312156142f257600080fd5b8151612da081613b3c56fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a26469706673582212205ca02a3fc1dfda3345d16da6ff065376cb88d4452ec804ce4e99235ea029951364736f6c634300080d0033454950373132446f6d61696e28737472696e67206e616d652c737472696e672076657273696f6e2c6164647265737320766572696679696e67436f6e74726163742c627974657333322073616c742900000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000018000000000000000000000000000000000000000000000000000000000000009ba00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000005000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c10000000000000000000000000000000000000000000000000000000000000006697066733a2f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5553434d567434376f566a4d4d395a7853334445643842736d74715269343434595277645752763337336a4c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035697066733a2f2f516d54477052324b38696a3238466d746f6743796553336b35645a74337a77715167433765374e655639594e4d430000000000000000000000

Deployed Bytecode

0x6080604052600436106103555760003560e01c80638da5cb5b116101bb578063ba8bce55116100f7578063e985e9c511610095578063f2fde38b1161006f578063f2fde38b146109f2578063f3fef3a314610a12578063fbdb849414610a32578063ff9413d814610a5257600080fd5b8063e985e9c51461097f578063ed329fa81461099f578063ef3c6624146109be57600080fd5b8063d547cfb7116100d1578063d547cfb71461090c578063d9ce2f6d14610921578063e527c6dd14610936578063e8a3d4851461096a57600080fd5b8063ba8bce551461089f578063bba7723e146108bf578063c87b56dd146108ec57600080fd5b8063a22cb46511610164578063a4f4f8af1161013e578063a4f4f8af14610816578063affe39c114610837578063b7f751d814610859578063b88d4fde1461087f57600080fd5b8063a22cb465146107ae578063a22e4faa146107ce578063a4e2d634146107ee57600080fd5b80639509af06116101955780639509af061461075957806395d89b4114610779578063a0712d681461078e57600080fd5b80638da5cb5b1461070657806391ba317a14610724578063938e3d7b1461073957600080fd5b80633408e470116102955780634dcc60af1161023357806370a082311161020d57806370a0823114610676578063715018a61461069657806371dedace146106ab5780637dc42975146106df57600080fd5b80634dcc60af146106165780634f6ccce7146106365780636352211e1461065657600080fd5b806342842e0e1161026f57806342842e0e1461059657806342966c68146105b657806344be774f146105d65780634b457935146105f657600080fd5b80633408e470146105555780633763e75b146105685780634047638d1461058157600080fd5b806314d7d5171161030257806323b872dd116102dc57806323b872dd146104bf5780632d0335ab146104df5780632f745c591461051557806330176e131461053557600080fd5b806314d7d5171461046757806318160ddd1461048757806320379ee5146104aa57600080fd5b8063095ea7b311610333578063095ea7b3146103e95780630c53c51c1461040b5780630f7e59701461041e57600080fd5b806301ffc9a71461035a57806306fdde031461038f578063081812fc146103b1575b600080fd5b34801561036657600080fd5b5061037a610375366004613b6a565b610a67565b60405190151581526020015b60405180910390f35b34801561039b57600080fd5b506103a4610ac3565b6040516103869190613bdf565b3480156103bd57600080fd5b506103d16103cc366004613bf2565b610b55565b6040516001600160a01b039091168152602001610386565b3480156103f557600080fd5b50610409610404366004613c20565b610bf3565b005b6103a4610419366004613cf8565b610d36565b34801561042a57600080fd5b506103a46040518060400160405280600181526020017f310000000000000000000000000000000000000000000000000000000000000081525081565b34801561047357600080fd5b50610409610482366004613c20565b610f3c565b34801561049357600080fd5b5061049c611090565b604051908152602001610386565b3480156104b657600080fd5b5060065461049c565b3480156104cb57600080fd5b506104096104da366004613d76565b6110ec565b3480156104eb57600080fd5b5061049c6104fa366004613db7565b6001600160a01b031660009081526007602052604090205490565b34801561052157600080fd5b5061049c610530366004613c20565b61117a565b34801561054157600080fd5b50610409610550366004613dd4565b611253565b34801561056157600080fd5b504661049c565b34801561057457600080fd5b5060095461ffff1661049c565b34801561058d57600080fd5b506104096112e3565b3480156105a257600080fd5b506104096105b1366004613d76565b6113c2565b3480156105c257600080fd5b506104096105d1366004613bf2565b6113dd565b3480156105e257600080fd5b506104096105f1366004613c20565b61145e565b34801561060257600080fd5b50610409610611366004613db7565b6115b2565b34801561062257600080fd5b50610409610631366004613dd4565b6116b8565b34801561064257600080fd5b5061049c610651366004613bf2565b611759565b34801561066257600080fd5b506103d1610671366004613bf2565b611832565b34801561068257600080fd5b5061049c610691366004613db7565b6118e0565b3480156106a257600080fd5b506104096119b9565b3480156106b757600080fd5b5061049c7f000000000000000000000000000000000000000000000000000000000000000581565b3480156106eb57600080fd5b506009546a0100000000000000000000900461ffff1661049c565b34801561071257600080fd5b506008546001600160a01b03166103d1565b34801561073057600080fd5b5061049c611a89565b34801561074557600080fd5b50610409610754366004613dd4565b611aa0565b34801561076557600080fd5b50610409610774366004613e1d565b611b2c565b34801561078557600080fd5b506103a4611d98565b34801561079a57600080fd5b506104096107a9366004613bf2565b611da7565b3480156107ba57600080fd5b506104096107c9366004613e9c565b611fa0565b3480156107da57600080fd5b506104096107e9366004613db7565b611fb2565b3480156107fa57600080fd5b5060095468010000000000000000900461ffff1660011461037a565b34801561082257600080fd5b50600954640100000000900461ffff1661049c565b34801561084357600080fd5b5061084c61205a565b6040516103869190613eda565b34801561086557600080fd5b506009546601000000000000900461ffff1660011461037a565b34801561088b57600080fd5b5061040961089a366004613f27565b6120c0565b3480156108ab57600080fd5b506104096108ba366004613db7565b612155565b3480156108cb57600080fd5b506108df6108da366004613db7565b612257565b6040516103869190613f93565b3480156108f857600080fd5b506103a4610907366004613bf2565b6123a2565b34801561091857600080fd5b506103a4612428565b34801561092d57600080fd5b506103a4612437565b34801561094257600080fd5b5061049c7f00000000000000000000000000000000000000000000000000000000000009ba81565b34801561097657600080fd5b506103a46124c5565b34801561098b57600080fd5b5061037a61099a366004613fcb565b6124d4565b3480156109ab57600080fd5b5060095462010000900461ffff1661049c565b3480156109ca57600080fd5b5061049c7f000000000000000000000000000000000000000000000000000000000000000581565b3480156109fe57600080fd5b50610409610a0d366004613db7565b6125cb565b348015610a1e57600080fd5b50610409610a2d366004613c20565b612729565b348015610a3e57600080fd5b50610409610a4d366004613bf2565b6128ce565b348015610a5e57600080fd5b50610409612972565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f780e9d63000000000000000000000000000000000000000000000000000000001480610abd5750610abd82612ada565b92915050565b606060008054610ad290613ff9565b80601f0160208091040260200160405190810160405280929190818152602001828054610afe90613ff9565b8015610b4b5780601f10610b2057610100808354040283529160200191610b4b565b820191906000526020600020905b815481529060010190602001808311610b2e57829003601f168201915b5050505050905090565b6000610b6082612bbd565b610bd75760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e000000000000000000000000000000000000000060648201526084015b60405180910390fd5b506000908152600360205260409020546001600160a01b031690565b6000610bfe82611832565b9050806001600160a01b0316836001600160a01b031603610c875760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e6560448201527f72000000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b806001600160a01b0316610c99612c07565b6001600160a01b03161480610cb55750610cb58161099a612c07565b610d275760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610bce565b610d318383612c11565b505050565b60408051606081810183526001600160a01b03881660008181526007602090815290859020548452830152918101869052610d748782878787612c8c565b610de65760405162461bcd60e51b815260206004820152602160248201527f5369676e657220616e64207369676e617475726520646f206e6f74206d61746360448201527f68000000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b6001600160a01b038716600090815260076020526040902054610e0a906001612d94565b6001600160a01b0388166000908152600760205260409081902091909155517f5845892132946850460bff5a0083f71031bc5bf9aadcd40f1de79423eac9b10b90610e5a90899033908a9061402d565b60405180910390a1600080306001600160a01b0316888a604051602001610e82929190614075565b60408051601f1981840301815290829052610e9c916140ac565b6000604051808303816000865af19150503d8060008114610ed9576040519150601f19603f3d011682016040523d82523d6000602084013e610ede565b606091505b509150915081610f305760405162461bcd60e51b815260206004820152601c60248201527f46756e6374696f6e2063616c6c206e6f74207375636365737366756c000000006044820152606401610bce565b98975050505050505050565b600b546001600160a01b0316610f50612c07565b6001600160a01b031614610fa65760405162461bcd60e51b815260206004820152601160248201527f63616c6c6572206e6f74206172746973740000000000000000000000000000006044820152606401610bce565b6009547f000000000000000000000000000000000000000000000000000000000000000590610fe090839062010000900461ffff166140de565b111561102e5760405162461bcd60e51b815260206004820152601460248201527f6578636565642061727469737420737570706c790000000000000000000000006044820152606401610bce565b6009805461ffff6201000080830482168501909116027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff90911617905560005b81811015610d315761107f83612da7565b50611089816140f6565b905061106e565b600254600090815b818110156110e75760006001600160a01b0316600282815481106110be576110be614110565b6000918252602090912001546001600160a01b0316146110df578260010192505b600101611098565b505090565b6110fd6110f7612c07565b82612dc2565b61116f5760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610bce565b610d31838383612e95565b6002546000905b808210156111d757836001600160a01b0316600283815481106111a6576111a6614110565b6000918252602090912001546001600160a01b0316036111cc57600019830192156111d7575b816001019150611181565b80821061124c5760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201527f74206f6620626f756e64730000000000000000000000000000000000000000006064820152608401610bce565b5092915050565b61125b612c07565b6001600160a01b03166112766008546001600160a01b031690565b6001600160a01b0316146112cc5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516112df90600d906020840190613a6d565b5050565b6112eb612c07565b6001600160a01b03166113066008546001600160a01b031690565b6001600160a01b03161461135c5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009546113c0906601000000000000900461ffff161561137d576000611380565b60015b60099060ff16815461ffff9091166601000000000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff909116179055565b565b610d31838383604051806020016040528060008152506120c0565b600a60006113e9612c07565b6001600160a01b0316815260208101919091526040016000205460ff166114525760405162461bcd60e51b815260206004820152601160248201527f63616c6c6572206e6f74206275726e65720000000000000000000000000000006044820152606401610bce565b61145b81613025565b50565b611466612c07565b6001600160a01b03166114816008546001600160a01b031690565b6001600160a01b0316146114d75760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009547f00000000000000000000000000000000000000000000000000000000000000059061150b90839061ffff166140de565b11156115595760405162461bcd60e51b815260206004820152601560248201527f6578636565642067616c6c65727920737570706c7900000000000000000000006044820152606401610bce565b6009805461ffff8082168401167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090911617905560005b81811015610d31576115a183612da7565b506115ab816140f6565b9050611590565b6115ba612c07565b6001600160a01b03166115d56008546001600160a01b031690565b6001600160a01b03161461162b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166000908152600a602052604090205460ff16156116945760405162461bcd60e51b815260206004820152601a60248201527f6164647265737320616c726561647920726567697374657265640000000000006044820152606401610bce565b6001600160a01b03166000908152600a60205260409020805460ff19166001179055565b6116c0612c07565b6001600160a01b03166116db6008546001600160a01b031690565b6001600160a01b0316146117315760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516000036117465761145b600e6000613af1565b80516112df90600e906020840190613a6d565b6002546000905b808210156117b75760006001600160a01b03166002838154811061178657611786614110565b6000918252602090912001546001600160a01b0316146117ac57600019830192156117b7575b816001019150611760565b80821061182c5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201527f7574206f6620626f756e647300000000000000000000000000000000000000006064820152608401610bce565b50919050565b600061183d82612bbd565b6118af5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201527f656e7420746f6b656e00000000000000000000000000000000000000000000006064820152608401610bce565b6000600283815481106118c4576118c4614110565b6000918252602090912001546001600160a01b03169392505050565b60006001600160a01b03821661195e5760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a6560448201527f726f2061646472657373000000000000000000000000000000000000000000006064820152608401610bce565b60025460005b818110156119b257836001600160a01b03166002828154811061198957611989614110565b6000918252602090912001546001600160a01b0316036119aa578260010192505b600101611964565b5050919050565b6119c1612c07565b6001600160a01b03166119dc6008546001600160a01b031690565b6001600160a01b031614611a325760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6008546040516000916001600160a01b0316907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a36008805473ffffffffffffffffffffffffffffffffffffffff19169055565b600254600090611a9b90600190614126565b905090565b611aa8612c07565b6001600160a01b0316611ac36008546001600160a01b031690565b6001600160a01b031614611b195760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b80516112df90600f906020840190613a6d565b60095468010000000000000000900461ffff1615611b8c5760405162461bcd60e51b815260206004820152601260248201527f636f6e7472616374206973206c6f636b656400000000000000000000000000006044820152606401610bce565b6000611b9883836130af565b6009549091507f00000000000000000000000000000000000000000000000000000000000009ba90611bd7908490640100000000900461ffff166140de565b1115611c255760405162461bcd60e51b815260206004820152601460248201527f657863656564207075626c696320737570706c790000000000000000000000006044820152606401610bce565b336000908152600c60205260409020548390611c429084906140de565b1115611c905760405162461bcd60e51b815260206004820152601160248201527f65786365656420616c6c6f636174696f6e0000000000000000000000000000006044820152606401610bce565b611ce68186868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525073c1f40b4438d66a736e9246c0c0b3fd5354f1402a9250613109915050565b611d325760405162461bcd60e51b815260206004820152600b60248201527f696e76616c6964207369670000000000000000000000000000000000000000006044820152606401610bce565b6009805461ffff640100000000808304821686019091160265ffff0000000019909116179055336000908152600c602052604081208054840190555b82811015611d9057611d7f33612da7565b50611d89816140f6565b9050611d6e565b505050505050565b606060018054610ad290613ff9565b60095468010000000000000000900461ffff1615611e075760405162461bcd60e51b815260206004820152601260248201527f636f6e7472616374206973206c6f636b656400000000000000000000000000006044820152606401610bce565b6009546601000000000000900461ffff16600114611e675760405162461bcd60e51b815260206004820152601460248201527f7075626c6963206d696e74206e6f74206c6976650000000000000000000000006044820152606401610bce565b6009546a0100000000000000000000900461ffff16811115611ecb5760405162461bcd60e51b815260206004820152601160248201527f65786365656420616c6c6f636174696f6e0000000000000000000000000000006044820152606401610bce565b6009547f00000000000000000000000000000000000000000000000000000000000009ba90611f07908390640100000000900461ffff166140de565b1115611f555760405162461bcd60e51b815260206004820152601460248201527f657863656564207075626c696320737570706c790000000000000000000000006044820152606401610bce565b6009805461ffff640100000000808304821685019091160265ffff000000001990911617905560005b818110156112df57611f8f33612da7565b50611f99816140f6565b9050611f7e565b6112df611fab612c07565b8383613131565b611fba612c07565b6001600160a01b0316611fd56008546001600160a01b031690565b6001600160a01b03161461202b5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600b805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b6060600060028054806020026020016040519081016040528092919081815260200182805480156120b457602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612096575b50939695505050505050565b6120d16120cb612c07565b83612dc2565b6121435760405162461bcd60e51b815260206004820152603160248201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f60448201527f776e6572206e6f7220617070726f7665640000000000000000000000000000006064820152608401610bce565b61214f848484846131ff565b50505050565b61215d612c07565b6001600160a01b03166121786008546001600160a01b031690565b6001600160a01b0316146121ce5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166000908152600a602052604090205460ff166122365760405162461bcd60e51b815260206004820152601660248201527f61646472657373206e6f742072656769737465726564000000000000000000006044820152606401610bce565b6001600160a01b03166000908152600a60205260409020805460ff19169055565b60606000612264836118e0565b9050806000036122dc5760405162461bcd60e51b815260206004820152602660248201527f455243373231456e756d657261626c653a206f776e6572206f776e73206e6f2060448201527f746f6b656e7300000000000000000000000000000000000000000000000000006064820152608401610bce565b60025460008267ffffffffffffffff8111156122fa576122fa613c4c565b604051908082528060200260200182016040528015612323578160200160208202803683370190505b5090506000805b8381101561239757866001600160a01b03166002828154811061234f5761234f614110565b6000918252602090912001546001600160a01b03160361238f578083838060010194508151811061238257612382614110565b6020026020010181815250505b60010161232a565b509095945050505050565b6060600e80546123b190613ff9565b1590506123f1576123c0612428565b600e6123cb84613288565b6040516020016123dd9392919061413d565b604051602081830303815290604052610abd565b6123f9612428565b61240283613288565b604051602001612413929190614217565b60405160208183030381529060405292915050565b6060600d8054610ad290613ff9565b600f805461244490613ff9565b80601f016020809104026020016040519081016040528092919081815260200182805461247090613ff9565b80156124bd5780601f10612492576101008083540402835291602001916124bd565b820191906000526020600020905b8154815290600101906020018083116124a057829003601f168201915b505050505081565b6060600f8054610ad290613ff9565b6040517fc45527910000000000000000000000000000000000000000000000000000000081526001600160a01b0383811660048301526000917f000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c191848116919083169063c455279190602401602060405180830381865afa15801561255d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125819190614253565b6001600160a01b031603612599576001915050610abd565b6001600160a01b0380851660009081526004602090815260408083209387168352929052205460ff165b949350505050565b6125d3612c07565b6001600160a01b03166125ee6008546001600160a01b031690565b6001600160a01b0316146126445760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6001600160a01b0381166126c05760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f64647265737300000000000000000000000000000000000000000000000000006064820152608401610bce565b6008546040516001600160a01b038084169216907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a36008805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0392909216919091179055565b612731612c07565b6001600160a01b031661274c6008546001600160a01b031690565b6001600160a01b0316146127a25760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600081116127f25760405162461bcd60e51b815260206004820152600c60248201527f616d6f756e7420656d70747900000000000000000000000000000000000000006044820152606401610bce565b478111156128425760405162461bcd60e51b815260206004820152601660248201527f616d6f756e7420657863656564732062616c616e6365000000000000000000006044820152606401610bce565b6001600160a01b0382166128985760405162461bcd60e51b815260206004820152600c60248201527f61646472657373206e756c6c00000000000000000000000000000000000000006044820152606401610bce565b6040516001600160a01b0383169082156108fc029083906000818181858888f19350505050158015610d31573d6000803e3d6000fd5b6128d6612c07565b6001600160a01b03166128f16008546001600160a01b031690565b6001600160a01b0316146129475760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b600980546bffff0000000000000000000019166a010000000000000000000061ffff84160217905550565b61297a612c07565b6001600160a01b03166129956008546001600160a01b031690565b6001600160a01b0316146129eb5760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401610bce565b6009546113c09068010000000000000000900461ffff1615612a0e576000612a11565b60015b60099060ff16815461ffff90911668010000000000000000027fffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffff909116179055565b815461ffff9091166a0100000000000000000000026bffff0000000000000000000019909116179055565b6000303303612ad457600080368080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050503601516001600160a01b03169150612ad79050565b50335b90565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f80ac58cd000000000000000000000000000000000000000000000000000000001480612b6d57507fffffffff0000000000000000000000000000000000000000000000000000000082167f5b5e139f00000000000000000000000000000000000000000000000000000000145b80610abd57507f01ffc9a7000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000831614610abd565b60025460009082108015610abd575060006001600160a01b031660028381548110612bea57612bea614110565b6000918252602090912001546001600160a01b0316141592915050565b6000611a9b612a7e565b6000818152600360205260409020805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0384169081179091558190612c5382611832565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b60006001600160a01b038616612d0a5760405162461bcd60e51b815260206004820152602560248201527f4e61746976654d6574615472616e73616374696f6e3a20494e56414c49445f5360448201527f49474e45520000000000000000000000000000000000000000000000000000006064820152608401610bce565b6001612d1d612d18876133bd565b61343a565b6040805160008152602081018083529290925260ff851690820152606081018690526080810185905260a0016020604051602081039080840390855afa158015612d6b573d6000803e3d6000fd5b505050602060405103516001600160a01b0316866001600160a01b031614905095945050505050565b6000612da082846140de565b9392505050565b6000610abd8260405180602001604052806000815250613485565b6000612dcd82612bbd565b612e3f5760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201527f697374656e7420746f6b656e00000000000000000000000000000000000000006064820152608401610bce565b6000612e4a83611832565b9050806001600160a01b0316846001600160a01b03161480612e855750836001600160a01b0316612e7a84610b55565b6001600160a01b0316145b806125c357506125c381856124d4565b826001600160a01b0316612ea882611832565b6001600160a01b031614612f245760405162461bcd60e51b815260206004820152602960248201527f4552433732313a207472616e73666572206f6620746f6b656e2074686174206960448201527f73206e6f74206f776e00000000000000000000000000000000000000000000006064820152608401610bce565b6001600160a01b038216612f9f5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610bce565b612faa600082612c11565b8160028281548110612fbe57612fbe614110565b60009182526020822001805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b03938416179055604051839285811692908716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9190a4505050565b600061303082611832565b905061303d600083612c11565b6002828154811061305057613050614110565b60009182526020822001805473ffffffffffffffffffffffffffffffffffffffff191690556040518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6040516bffffffffffffffffffffffff1930606090811b8216602084015233901b1660348201526048810183905260688101829052600090612da09060880160405160208183030381529060405280519060200120613511565b60006001600160a01b03821661311f858561354c565b6001600160a01b031614949350505050565b816001600160a01b0316836001600160a01b0316036131925760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610bce565b6001600160a01b03838116600081815260046020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b61320a848484612e95565b61321684848484613619565b61214f5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b6060816000036132cb57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156132f557806132df816140f6565b91506132ee9050600a83614286565b91506132cf565b60008167ffffffffffffffff81111561331057613310613c4c565b6040519080825280601f01601f19166020018201604052801561333a576020820181803683370190505b5090505b84156125c35761334f600183614126565b915061335c600a8661429a565b6133679060306140de565b60f81b81838151811061337c5761337c614110565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506133b6600a86614286565b945061333e565b60006040518060800160405280604381526020016142fe604391398051602091820120835184830151604080870151805190860120905161341d950193845260208401929092526001600160a01b03166040830152606082015260800190565b604051602081830303815290604052805190602001209050919050565b600061344560065490565b6040517f1901000000000000000000000000000000000000000000000000000000000000602082015260228101919091526042810183905260620161341d565b6000613490836137a8565b905061349f6000848385613619565b610abd5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c0161341d565b60008060008084516041036135755750505060208201516040830151606084015160001a613603565b84516040036135bb5750505060408201516020830151907f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81169060ff1c601b01613603565b60405162461bcd60e51b815260206004820152601f60248201527f45434453413a20696e76616c6964207369676e6174757265206c656e677468006044820152606401610bce565b61360f8682858561388e565b9695505050505050565b60006001600160a01b0384163b1561379d57836001600160a01b031663150b7a02613642612c07565b8786866040518563ffffffff1660e01b815260040161366494939291906142ae565b6020604051808303816000875af192505050801561369f575060408051601f3d908101601f1916820190925261369c918101906142e0565b60015b613752573d8080156136cd576040519150601f19603f3d011682016040523d82523d6000602084013e6136d2565b606091505b50805160000361374a5760405162461bcd60e51b815260206004820152603260248201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560448201527f63656976657220696d706c656d656e74657200000000000000000000000000006064820152608401610bce565b805181602001fd5b7fffffffff00000000000000000000000000000000000000000000000000000000167f150b7a02000000000000000000000000000000000000000000000000000000001490506125c3565b506001949350505050565b60006001600160a01b0382166138005760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610bce565b506002546002805460018101825560009182527f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace01805473ffffffffffffffffffffffffffffffffffffffff19166001600160a01b0385169081179091556040518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a4919050565b60007f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a08211156139265760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202773272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b8360ff16601b148061393b57508360ff16601c145b6139ad5760405162461bcd60e51b815260206004820152602260248201527f45434453413a20696e76616c6964207369676e6174757265202776272076616c60448201527f75650000000000000000000000000000000000000000000000000000000000006064820152608401610bce565b6040805160008082526020820180845288905260ff871692820192909252606081018590526080810184905260019060a0016020604051602081039080840390855afa158015613a01573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b038116613a645760405162461bcd60e51b815260206004820152601860248201527f45434453413a20696e76616c6964207369676e617475726500000000000000006044820152606401610bce565b95945050505050565b828054613a7990613ff9565b90600052602060002090601f016020900481019282613a9b5760008555613ae1565b82601f10613ab457805160ff1916838001178555613ae1565b82800160010185558215613ae1579182015b82811115613ae1578251825591602001919060010190613ac6565b50613aed929150613b27565b5090565b508054613afd90613ff9565b6000825580601f10613b0d575050565b601f01602090049060005260206000209081019061145b91905b5b80821115613aed5760008155600101613b28565b7fffffffff000000000000000000000000000000000000000000000000000000008116811461145b57600080fd5b600060208284031215613b7c57600080fd5b8135612da081613b3c565b60005b83811015613ba2578181015183820152602001613b8a565b8381111561214f5750506000910152565b60008151808452613bcb816020860160208601613b87565b601f01601f19169290920160200192915050565b602081526000612da06020830184613bb3565b600060208284031215613c0457600080fd5b5035919050565b6001600160a01b038116811461145b57600080fd5b60008060408385031215613c3357600080fd5b8235613c3e81613c0b565b946020939093013593505050565b634e487b7160e01b600052604160045260246000fd5b600067ffffffffffffffff80841115613c7d57613c7d613c4c565b604051601f8501601f19908116603f01168101908282118183101715613ca557613ca5613c4c565b81604052809350858152868686011115613cbe57600080fd5b858560208301376000602087830101525050509392505050565b600082601f830112613ce957600080fd5b612da083833560208501613c62565b600080600080600060a08688031215613d1057600080fd5b8535613d1b81613c0b565b9450602086013567ffffffffffffffff811115613d3757600080fd5b613d4388828901613cd8565b9450506040860135925060608601359150608086013560ff81168114613d6857600080fd5b809150509295509295909350565b600080600060608486031215613d8b57600080fd5b8335613d9681613c0b565b92506020840135613da681613c0b565b929592945050506040919091013590565b600060208284031215613dc957600080fd5b8135612da081613c0b565b600060208284031215613de657600080fd5b813567ffffffffffffffff811115613dfd57600080fd5b8201601f81018413613e0e57600080fd5b6125c384823560208401613c62565b60008060008060608587031215613e3357600080fd5b843567ffffffffffffffff80821115613e4b57600080fd5b818701915087601f830112613e5f57600080fd5b813581811115613e6e57600080fd5b886020828501011115613e8057600080fd5b6020928301999098509187013596604001359550909350505050565b60008060408385031215613eaf57600080fd5b8235613eba81613c0b565b915060208301358015158114613ecf57600080fd5b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015613f1b5783516001600160a01b031683529284019291840191600101613ef6565b50909695505050505050565b60008060008060808587031215613f3d57600080fd5b8435613f4881613c0b565b93506020850135613f5881613c0b565b925060408501359150606085013567ffffffffffffffff811115613f7b57600080fd5b613f8787828801613cd8565b91505092959194509250565b6020808252825182820181905260009190848201906040850190845b81811015613f1b57835183529284019291840191600101613faf565b60008060408385031215613fde57600080fd5b8235613fe981613c0b565b91506020830135613ecf81613c0b565b600181811c9082168061400d57607f821691505b60208210810361182c57634e487b7160e01b600052602260045260246000fd5b60006001600160a01b03808616835280851660208401525060606040830152613a646060830184613bb3565b6000815161406b818560208601613b87565b9290920192915050565b60008351614087818460208801613b87565b60609390931b6bffffffffffffffffffffffff19169190920190815260140192915050565b600082516140be818460208701613b87565b9190910192915050565b634e487b7160e01b600052601160045260246000fd5b600082198211156140f1576140f16140c8565b500190565b60006000198203614109576141096140c8565b5060010190565b634e487b7160e01b600052603260045260246000fd5b600082821015614138576141386140c8565b500390565b6000845160206141508285838a01613b87565b602f60f81b918401918252855460019060009080831c8184168061417557607f821691505b858210810361419257634e487b7160e01b84526022600452602484fd5b8080156141a657600181146141bb576141ec565b60ff19841686890152858389010194506141ec565b60008c81526020902060005b848110156141e25781548a82018901529087019088016141c7565b5050858389010194505b5050505061420a61420482602f60f81b815260010190565b88614059565b9998505050505050505050565b60008351614229818460208801613b87565b602f60f81b9083019081528351614247816001840160208801613b87565b01600101949350505050565b60006020828403121561426557600080fd5b8151612da081613c0b565b634e487b7160e01b600052601260045260246000fd5b60008261429557614295614270565b500490565b6000826142a9576142a9614270565b500690565b60006001600160a01b0380871683528086166020840152508360408301526080606083015261360f6080830184613bb3565b6000602082840312156142f257600080fd5b8151612da081613b3c56fe4d6574615472616e73616374696f6e2875696e74323536206e6f6e63652c616464726573732066726f6d2c62797465732066756e6374696f6e5369676e617475726529a26469706673582212205ca02a3fc1dfda3345d16da6ff065376cb88d4452ec804ce4e99235ea029951364736f6c634300080d0033

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

00000000000000000000000000000000000000000000000000000000000000e00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000018000000000000000000000000000000000000000000000000000000000000009ba00000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000005000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c10000000000000000000000000000000000000000000000000000000000000006697066733a2f0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5553434d567434376f566a4d4d395a7853334445643842736d74715269343434595277645752763337336a4c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000035697066733a2f2f516d54477052324b38696a3238466d746f6743796553336b35645a74337a77715167433765374e655639594e4d430000000000000000000000

-----Decoded View---------------
Arg [0] : baseUri_ (string): ipfs:/
Arg [1] : ipfsHash_ (string): QmUSCMVt47oVjMM9ZxS3DEd8BsmtqRi444YRwdWRv373jL
Arg [2] : contractUri_ (string): ipfs://QmTGpR2K8ij28FmtogCyeS3k5dZt3zwqQgC7e7NeV9YNMC
Arg [3] : tokenMax_ (uint256[3]): 2490,5,5
Arg [4] : proxyRegistryAddress (address): 0xa5409ec958C83C3f309868babACA7c86DCB077c1

-----Encoded View---------------
15 Constructor Arguments found :
Arg [0] : 00000000000000000000000000000000000000000000000000000000000000e0
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000120
Arg [2] : 0000000000000000000000000000000000000000000000000000000000000180
Arg [3] : 00000000000000000000000000000000000000000000000000000000000009ba
Arg [4] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000005
Arg [6] : 000000000000000000000000a5409ec958c83c3f309868babaca7c86dcb077c1
Arg [7] : 0000000000000000000000000000000000000000000000000000000000000006
Arg [8] : 697066733a2f0000000000000000000000000000000000000000000000000000
Arg [9] : 000000000000000000000000000000000000000000000000000000000000002e
Arg [10] : 516d5553434d567434376f566a4d4d395a7853334445643842736d7471526934
Arg [11] : 3434595277645752763337336a4c000000000000000000000000000000000000
Arg [12] : 0000000000000000000000000000000000000000000000000000000000000035
Arg [13] : 697066733a2f2f516d54477052324b38696a3238466d746f6743796553336b35
Arg [14] : 645a74337a77715167433765374e655639594e4d430000000000000000000000


Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.