ETH Price: $3,421.02 (+3.79%)

Token

SOLIDS (SOLID)
 

Overview

Max Total Supply

1,542 SOLID

Holders

361

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A

Other Info

Balance
0 SOLID
0xf380ed92eca580c4d78b5678348389c82772bd61
Loading...
Loading
Loading...
Loading
Loading...
Loading

OVERVIEW

SOLIDS is a generative architecture project created by FAR. There will be 8,888 unique buildings generated algorithmically and compatible with Metaverses.

# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
Solids

Compiler Version
v0.8.13+commit.abaa5c0e

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
File 1 of 23 : Solids.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.2;

import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Burnable.sol";
import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Royalty.sol";
import "@openzeppelin/contracts/access/Ownable.sol";
import "@openzeppelin/contracts/access/AccessControl.sol";
import "@openzeppelin/contracts/utils/Counters.sol";
import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol";
import "@openzeppelin/contracts/utils/Strings.sol";
import "./FineCoreInterface.sol";

/// @custom:security-contact [email protected]
contract Solids is ERC721Enumerable, ERC721Burnable, ERC721Royalty, AccessControl, Ownable {
    using Counters for Counters.Counter;
    using EnumerableSet for EnumerableSet.UintSet;

    
    bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE");
    FineCoreInterface coreContract;
    
    bool public paused = false;

    uint public TOKEN_LIMIT = 8888; // not including bonus
    uint256 public remaining;
    mapping(uint256 => uint256) public cache;

    address payable public artistAddress = payable(0x70F2D7fA5fAE142E1AF7A95B4d48A9C8e417813D);
    address payable public additionalPayee = payable(0x0000000000000000000000000000000000000000);
    uint256 public additionalPayeePercentage = 0;
    uint256 public additionalPayeeRoyaltyPercentage = 0;
    uint96 public royaltyPercent = 4500;

    string public _contractURI = "ipfs://QmPmtPqQff6nnyvv8LNEpSnLqeARVus8Q5SbUfWSLAw126";
    string public baseURI = "ipfs://QmSBiKg2u4YvEB8rQrJisAvBxCR4L9QYFvFdibkk1kBDby";
    string public artist = "FAR";
    string public description = "SOLIDS is a generative architecture NFT project created by FAR. There are 8,888 + 512 unique buildings generated algorithmically, enabling utility in the Metaverse.";
    string public website = "https://fine.digital";
    string public license = "MIT";

    event recievedFunds(address _from, uint _amount);
    
    constructor(address coreAddress, address shopAddress) ERC721("SOLIDS", "SOLID") {
        _grantRole(DEFAULT_ADMIN_ROLE, msg.sender);
        _grantRole(MINTER_ROLE, shopAddress);
        coreContract = FineCoreInterface(coreAddress);
        // set deafault royalty
        _setDefaultRoyalty(address(this), royaltyPercent);
        remaining = TOKEN_LIMIT; // start with max tokens
    }

    /**
     * @dev receive direct ETH transfers
     * @notice for splitting royalties
     */
    receive() external payable {
        emit recievedFunds(msg.sender, msg.value);
    }

    /**
     * @dev split royalties sent to contract (ONLY ETH!)
     */
    function withdraw() onlyOwner external {
        _splitFunds(address(this).balance);
    }

    /**
     * @dev Split payments
     */
    function _splitFunds(uint256 amount) internal {
        if (amount > 0) {
            uint256 partA = amount * coreContract.platformRoyalty() / 10000;
            coreContract.FINE_TREASURY().transfer(partA);
            uint256 partB = amount * additionalPayeeRoyaltyPercentage / 10000;
            if (partB > 0) additionalPayee.transfer(partB);
            artistAddress.transfer((amount - partA) - partB);
        }
    }

    /**
     * @dev lookup the URI for a token
      * @param tokenId to retieve URI for
     */
    function tokenURI(uint256 tokenId) public view override(ERC721) returns (string memory) {
        return string(abi.encodePacked(baseURI, "/", Strings.toString(tokenId), ".json"));
    }

    // On-chain Data

    /**
     * @dev Update the base URI field
     * @param _uri base for all tokens 
     * @dev Only the admin can call this
     */
    function setContractURI(string calldata _uri) onlyOwner external {
        _contractURI = _uri;
    }

    /**
     * @dev Update the base URI field
     * @param _uri base for all tokens 
     * @dev Only the admin can call this
     */
    function setBaseURI(string calldata _uri) onlyOwner external {
        baseURI = _uri;
    }

    /**
     * @dev Update the royalty percentage
     * @param _percentage for royalties
     * @dev Only the admin can call this
     */
    function setRoyaltyPercent(uint96 _percentage) onlyOwner external {
        royaltyPercent = _percentage;
    }

    /**
     * @dev Update the additional payee sales percentage
     * @param _percentage for sales
     * @dev Only the admin can call this
     */
    function additionalPayeePercent(uint96 _percentage) onlyOwner external {
        additionalPayeePercentage = _percentage;
    }

    /**
     * @dev Update the additional payee royalty percentage
     * @param _percentage for royalty
     * @dev Only the admin can call this
     */
    function additionalPayeeRoyaltyPercent(uint96 _percentage) onlyOwner external {
        additionalPayeeRoyaltyPercentage = _percentage;
    }

    /**
     * @dev Update the description field
     * @param _desc description of the project
     * @dev Only the admin can call this
     */
    function setDescription(string calldata _desc) onlyOwner external {
        description = _desc;
    }

    /**
     * @dev Update the website field
     * @param _url base for all tokens 
     * @dev Only the admin can call this
     */
    function setWebsite(string calldata _url) onlyOwner external {
        website = _url;
    }

    /**
     * @dev pause minting
     * @dev Only the admin can call this
     */
    function pause() onlyOwner external {
        paused = true;
    }

    /**
     * @dev unpause minting
     * @dev Only the admin can call this
     */
    function unpause() onlyOwner external {
        paused = false;
    }

    /**
     * @dev checkPool -maintain interface compatibility
     */
    function checkPool() external view returns (uint256) {
        return remaining;
    }

    /**
     * @dev Draw a token from the remaining ids
     */
    function drawIndex() internal returns (uint256 index) {
        //RNG
        uint randomness = coreContract.getRandomness(remaining, block.timestamp);
        uint256 i = randomness % remaining;

        // if there's a cache at cache[i] then use it
        // otherwise use i itself
        index = cache[i] == 0 ? i : cache[i];

        // grab a number from the tail
        cache[i] = cache[remaining - 1] == 0 ? remaining - 1 : cache[remaining - 1];
        remaining = remaining - 1;
    }

    /**
     * @dev Mint a token 
     * @param to address to mint the token to
     * @dev Only the minter role can call this
     */
    function mint(address to) external onlyRole(MINTER_ROLE) returns (uint) {
        require(!paused, "minting paused");
        require(remaining > 0, "all tokens minted");
        uint id = drawIndex();
        _safeMint(to, id);
        return id;
    }

    /**
     * @dev Mint a bonus token (for infinites AI holders)
     * @param to address to mint the token to
     * @dev Only the minter role can call this
     */
    function mintBonus(address to, uint infiniteId) external onlyRole(MINTER_ROLE) returns (uint bonusId) {
        require(!paused, "minting paused");
        bonusId = 10000 + infiniteId;
        require(!_exists(bonusId), "Token already minted");
        _safeMint(to, bonusId);
    }

    // getters for interface

    function contractURI() public view returns (string memory) {
        return _contractURI;
    }
    
    function getArtistAddress() external view returns (address payable) {
        return artistAddress;
    }

    function getAdditionalPayee() external view returns (address payable) {
        return additionalPayee;
    }

    function getAdditionalPayeePercentage() external view returns (uint256) {
        return additionalPayeePercentage;
    }

    function getTokenLimit() external view returns (uint256) {
        return TOKEN_LIMIT;
    }

    // The following functions are overrides required by Solidity.

    /**
     * @dev get baseURI for all tokens
     */
    function _baseURI() internal view override returns (string memory) {
        return baseURI;
    }

    function _beforeTokenTransfer(address from, address to, uint256 tokenId)
        internal
        override(ERC721, ERC721Enumerable)
    {
        super._beforeTokenTransfer(from, to, tokenId);
    }

    function supportsInterface(bytes4 interfaceId)
        public
        view
        override(ERC721, ERC721Enumerable, ERC721Royalty, AccessControl)
        returns (bool)
    {
        return super.supportsInterface(interfaceId);
    }

    function _burn(uint256 tokenId)
        internal
        override(ERC721, ERC721Royalty)
    {
        super._burn(tokenId);
    }
}

File 2 of 23 : ERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "./IERC721Enumerable.sol";

/**
 * @dev This implements an optional extension of {ERC721} defined in the EIP that adds
 * enumerability of all the token ids in the contract as well as all token ids owned by each
 * account.
 */
abstract contract ERC721Enumerable is ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => mapping(uint256 => uint256)) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) {
        return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds");
        return _ownedTokens[owner][index];
    }

    /**
     * @dev See {IERC721Enumerable-totalSupply}.
     */
    function totalSupply() public view virtual override returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev See {IERC721Enumerable-tokenByIndex}.
     */
    function tokenByIndex(uint256 index) public view virtual override returns (uint256) {
        require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds");
        return _allTokens[index];
    }

    /**
     * @dev Hook that is called before any token transfer. This includes minting
     * and burning.
     *
     * Calling conditions:
     *
     * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be
     * transferred to `to`.
     * - When `from` is zero, `tokenId` will be minted for `to`.
     * - When `to` is zero, ``from``'s `tokenId` will be burned.
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _beforeTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual override {
        super._beforeTokenTransfer(from, to, tokenId);

        if (from == address(0)) {
            _addTokenToAllTokensEnumeration(tokenId);
        } else if (from != to) {
            _removeTokenFromOwnerEnumeration(from, tokenId);
        }
        if (to == address(0)) {
            _removeTokenFromAllTokensEnumeration(tokenId);
        } else if (to != from) {
            _addTokenToOwnerEnumeration(to, tokenId);
        }
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        uint256 length = ERC721.balanceOf(to);
        _ownedTokens[to][length] = tokenId;
        _ownedTokensIndex[tokenId] = length;
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = ERC721.balanceOf(from) - 1;
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        delete _ownedTokensIndex[tokenId];
        delete _ownedTokens[from][lastTokenIndex];
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length - 1;
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        delete _allTokensIndex[tokenId];
        _allTokens.pop();
    }
}

File 3 of 23 : ERC721Burnable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/ERC721Burnable.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "../../../utils/Context.sol";

/**
 * @title ERC721 Burnable Token
 * @dev ERC721 Token that can be irreversibly burned (destroyed).
 */
abstract contract ERC721Burnable is Context, ERC721 {
    /**
     * @dev Burns `tokenId`. See {ERC721-_burn}.
     *
     * Requirements:
     *
     * - The caller must own `tokenId` or be an approved operator.
     */
    function burn(uint256 tokenId) public virtual {
        //solhint-disable-next-line max-line-length
        require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721Burnable: caller is not owner nor approved");
        _burn(tokenId);
    }
}

File 4 of 23 : ERC721Royalty.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/ERC721Royalty.sol)

pragma solidity ^0.8.0;

import "../ERC721.sol";
import "../../common/ERC2981.sol";
import "../../../utils/introspection/ERC165.sol";

/**
 * @dev Extension of ERC721 with the ERC2981 NFT Royalty Standard, a standardized way to retrieve royalty payment
 * information.
 *
 * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for
 * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first.
 *
 * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See
 * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to
 * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported.
 *
 * _Available since v4.5._
 */
abstract contract ERC721Royalty is ERC2981, ERC721 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721, ERC2981) returns (bool) {
        return super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {ERC721-_burn}. This override additionally clears the royalty information for the token.
     */
    function _burn(uint256 tokenId) internal virtual override {
        super._burn(tokenId);
        _resetTokenRoyalty(tokenId);
    }
}

File 5 of 23 : Ownable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/Ownable.sol)

pragma solidity ^0.8.0;

import "../utils/Context.sol";

/**
 * @dev Contract module which provides a basic access control mechanism, where
 * there is an account (an owner) that can be granted exclusive access to
 * specific functions.
 *
 * By default, the owner account will be the one that deploys the contract. This
 * can later be changed with {transferOwnership}.
 *
 * This module is used through inheritance. It will make available the modifier
 * `onlyOwner`, which can be applied to your functions to restrict their use to
 * the owner.
 */
abstract contract Ownable is Context {
    address private _owner;

    event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);

    /**
     * @dev Initializes the contract setting the deployer as the initial owner.
     */
    constructor() {
        _transferOwnership(_msgSender());
    }

    /**
     * @dev Returns the address of the current owner.
     */
    function owner() public view virtual returns (address) {
        return _owner;
    }

    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(owner() == _msgSender(), "Ownable: caller is not the owner");
        _;
    }

    /**
     * @dev Leaves the contract without owner. It will not be possible to call
     * `onlyOwner` functions anymore. Can only be called by the current owner.
     *
     * NOTE: Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public virtual onlyOwner {
        _transferOwnership(address(0));
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Can only be called by the current owner.
     */
    function transferOwnership(address newOwner) public virtual onlyOwner {
        require(newOwner != address(0), "Ownable: new owner is the zero address");
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers ownership of the contract to a new account (`newOwner`).
     * Internal function without access restriction.
     */
    function _transferOwnership(address newOwner) internal virtual {
        address oldOwner = _owner;
        _owner = newOwner;
        emit OwnershipTransferred(oldOwner, newOwner);
    }
}

File 6 of 23 : AccessControl.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (access/AccessControl.sol)

pragma solidity ^0.8.0;

import "./IAccessControl.sol";
import "../utils/Context.sol";
import "../utils/Strings.sol";
import "../utils/introspection/ERC165.sol";

/**
 * @dev Contract module that allows children to implement role-based access
 * control mechanisms. This is a lightweight version that doesn't allow enumerating role
 * members except through off-chain means by accessing the contract event logs. Some
 * applications may benefit from on-chain enumerability, for those cases see
 * {AccessControlEnumerable}.
 *
 * Roles are referred to by their `bytes32` identifier. These should be exposed
 * in the external API and be unique. The best way to achieve this is by
 * using `public constant` hash digests:
 *
 * ```
 * bytes32 public constant MY_ROLE = keccak256("MY_ROLE");
 * ```
 *
 * Roles can be used to represent a set of permissions. To restrict access to a
 * function call, use {hasRole}:
 *
 * ```
 * function foo() public {
 *     require(hasRole(MY_ROLE, msg.sender));
 *     ...
 * }
 * ```
 *
 * Roles can be granted and revoked dynamically via the {grantRole} and
 * {revokeRole} functions. Each role has an associated admin role, and only
 * accounts that have a role's admin role can call {grantRole} and {revokeRole}.
 *
 * By default, the admin role for all roles is `DEFAULT_ADMIN_ROLE`, which means
 * that only accounts with this role will be able to grant or revoke other
 * roles. More complex role relationships can be created by using
 * {_setRoleAdmin}.
 *
 * WARNING: The `DEFAULT_ADMIN_ROLE` is also its own admin: it has permission to
 * grant and revoke this role. Extra precautions should be taken to secure
 * accounts that have been granted it.
 */
abstract contract AccessControl is Context, IAccessControl, ERC165 {
    struct RoleData {
        mapping(address => bool) members;
        bytes32 adminRole;
    }

    mapping(bytes32 => RoleData) private _roles;

    bytes32 public constant DEFAULT_ADMIN_ROLE = 0x00;

    /**
     * @dev Modifier that checks that an account has a specific role. Reverts
     * with a standardized message including the required role.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     *
     * _Available since v4.1._
     */
    modifier onlyRole(bytes32 role) {
        _checkRole(role, _msgSender());
        _;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IAccessControl).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) public view virtual override returns (bool) {
        return _roles[role].members[account];
    }

    /**
     * @dev Revert with a standard message if `account` is missing `role`.
     *
     * The format of the revert reason is given by the following regular expression:
     *
     *  /^AccessControl: account (0x[0-9a-f]{40}) is missing role (0x[0-9a-f]{64})$/
     */
    function _checkRole(bytes32 role, address account) internal view virtual {
        if (!hasRole(role, account)) {
            revert(
                string(
                    abi.encodePacked(
                        "AccessControl: account ",
                        Strings.toHexString(uint160(account), 20),
                        " is missing role ",
                        Strings.toHexString(uint256(role), 32)
                    )
                )
            );
        }
    }

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) public view virtual override returns (bytes32) {
        return _roles[role].adminRole;
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _grantRole(role, account);
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) public virtual override onlyRole(getRoleAdmin(role)) {
        _revokeRole(role, account);
    }

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been revoked `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) public virtual override {
        require(account == _msgSender(), "AccessControl: can only renounce roles for self");

        _revokeRole(role, account);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event. Note that unlike {grantRole}, this function doesn't perform any
     * checks on the calling account.
     *
     * [WARNING]
     * ====
     * This function should only be called from the constructor when setting
     * up the initial roles for the system.
     *
     * Using this function in any other way is effectively circumventing the admin
     * system imposed by {AccessControl}.
     * ====
     *
     * NOTE: This function is deprecated in favor of {_grantRole}.
     */
    function _setupRole(bytes32 role, address account) internal virtual {
        _grantRole(role, account);
    }

    /**
     * @dev Sets `adminRole` as ``role``'s admin role.
     *
     * Emits a {RoleAdminChanged} event.
     */
    function _setRoleAdmin(bytes32 role, bytes32 adminRole) internal virtual {
        bytes32 previousAdminRole = getRoleAdmin(role);
        _roles[role].adminRole = adminRole;
        emit RoleAdminChanged(role, previousAdminRole, adminRole);
    }

    /**
     * @dev Grants `role` to `account`.
     *
     * Internal function without access restriction.
     */
    function _grantRole(bytes32 role, address account) internal virtual {
        if (!hasRole(role, account)) {
            _roles[role].members[account] = true;
            emit RoleGranted(role, account, _msgSender());
        }
    }

    /**
     * @dev Revokes `role` from `account`.
     *
     * Internal function without access restriction.
     */
    function _revokeRole(bytes32 role, address account) internal virtual {
        if (hasRole(role, account)) {
            _roles[role].members[account] = false;
            emit RoleRevoked(role, account, _msgSender());
        }
    }
}

File 7 of 23 : Counters.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol)

pragma solidity ^0.8.0;

/**
 * @title Counters
 * @author Matt Condon (@shrugs)
 * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number
 * of elements in a mapping, issuing ERC721 ids, or counting request ids.
 *
 * Include with `using Counters for Counters.Counter;`
 */
library Counters {
    struct Counter {
        // This variable should never be directly accessed by users of the library: interactions must be restricted to
        // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
        // this feature: see https://github.com/ethereum/solidity/issues/4637
        uint256 _value; // default: 0
    }

    function current(Counter storage counter) internal view returns (uint256) {
        return counter._value;
    }

    function increment(Counter storage counter) internal {
        unchecked {
            counter._value += 1;
        }
    }

    function decrement(Counter storage counter) internal {
        uint256 value = counter._value;
        require(value > 0, "Counter: decrement overflow");
        unchecked {
            counter._value = value - 1;
        }
    }

    function reset(Counter storage counter) internal {
        counter._value = 0;
    }
}

File 8 of 23 : EnumerableSet.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/structs/EnumerableSet.sol)

pragma solidity ^0.8.0;

/**
 * @dev Library for managing
 * https://en.wikipedia.org/wiki/Set_(abstract_data_type)[sets] of primitive
 * types.
 *
 * Sets have the following properties:
 *
 * - Elements are added, removed, and checked for existence in constant time
 * (O(1)).
 * - Elements are enumerated in O(n). No guarantees are made on the ordering.
 *
 * ```
 * contract Example {
 *     // Add the library methods
 *     using EnumerableSet for EnumerableSet.AddressSet;
 *
 *     // Declare a set state variable
 *     EnumerableSet.AddressSet private mySet;
 * }
 * ```
 *
 * As of v3.3.0, sets of type `bytes32` (`Bytes32Set`), `address` (`AddressSet`)
 * and `uint256` (`UintSet`) are supported.
 */
library EnumerableSet {
    // To implement this library for multiple types with as little code
    // repetition as possible, we write it in terms of a generic Set type with
    // bytes32 values.
    // The Set implementation uses private functions, and user-facing
    // implementations (such as AddressSet) are just wrappers around the
    // underlying Set.
    // This means that we can only create new EnumerableSets for types that fit
    // in bytes32.

    struct Set {
        // Storage of set values
        bytes32[] _values;
        // Position of the value in the `values` array, plus 1 because index 0
        // means a value is not in the set.
        mapping(bytes32 => uint256) _indexes;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function _add(Set storage set, bytes32 value) private returns (bool) {
        if (!_contains(set, value)) {
            set._values.push(value);
            // The value is stored at length-1, but we add 1 to all indexes
            // and use 0 as a sentinel value
            set._indexes[value] = set._values.length;
            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function _remove(Set storage set, bytes32 value) private returns (bool) {
        // We read and store the value's index to prevent multiple reads from the same storage slot
        uint256 valueIndex = set._indexes[value];

        if (valueIndex != 0) {
            // Equivalent to contains(set, value)
            // To delete an element from the _values array in O(1), we swap the element to delete with the last one in
            // the array, and then remove the last element (sometimes called as 'swap and pop').
            // This modifies the order of the array, as noted in {at}.

            uint256 toDeleteIndex = valueIndex - 1;
            uint256 lastIndex = set._values.length - 1;

            if (lastIndex != toDeleteIndex) {
                bytes32 lastvalue = set._values[lastIndex];

                // Move the last value to the index where the value to delete is
                set._values[toDeleteIndex] = lastvalue;
                // Update the index for the moved value
                set._indexes[lastvalue] = valueIndex; // Replace lastvalue's index to valueIndex
            }

            // Delete the slot where the moved value was stored
            set._values.pop();

            // Delete the index for the deleted slot
            delete set._indexes[value];

            return true;
        } else {
            return false;
        }
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function _contains(Set storage set, bytes32 value) private view returns (bool) {
        return set._indexes[value] != 0;
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function _length(Set storage set) private view returns (uint256) {
        return set._values.length;
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function _at(Set storage set, uint256 index) private view returns (bytes32) {
        return set._values[index];
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function _values(Set storage set) private view returns (bytes32[] memory) {
        return set._values;
    }

    // Bytes32Set

    struct Bytes32Set {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _add(set._inner, value);
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(Bytes32Set storage set, bytes32 value) internal returns (bool) {
        return _remove(set._inner, value);
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(Bytes32Set storage set, bytes32 value) internal view returns (bool) {
        return _contains(set._inner, value);
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(Bytes32Set storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(Bytes32Set storage set, uint256 index) internal view returns (bytes32) {
        return _at(set._inner, index);
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(Bytes32Set storage set) internal view returns (bytes32[] memory) {
        return _values(set._inner);
    }

    // AddressSet

    struct AddressSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(AddressSet storage set, address value) internal returns (bool) {
        return _add(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(AddressSet storage set, address value) internal returns (bool) {
        return _remove(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(AddressSet storage set, address value) internal view returns (bool) {
        return _contains(set._inner, bytes32(uint256(uint160(value))));
    }

    /**
     * @dev Returns the number of values in the set. O(1).
     */
    function length(AddressSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(AddressSet storage set, uint256 index) internal view returns (address) {
        return address(uint160(uint256(_at(set._inner, index))));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(AddressSet storage set) internal view returns (address[] memory) {
        bytes32[] memory store = _values(set._inner);
        address[] memory result;

        assembly {
            result := store
        }

        return result;
    }

    // UintSet

    struct UintSet {
        Set _inner;
    }

    /**
     * @dev Add a value to a set. O(1).
     *
     * Returns true if the value was added to the set, that is if it was not
     * already present.
     */
    function add(UintSet storage set, uint256 value) internal returns (bool) {
        return _add(set._inner, bytes32(value));
    }

    /**
     * @dev Removes a value from a set. O(1).
     *
     * Returns true if the value was removed from the set, that is if it was
     * present.
     */
    function remove(UintSet storage set, uint256 value) internal returns (bool) {
        return _remove(set._inner, bytes32(value));
    }

    /**
     * @dev Returns true if the value is in the set. O(1).
     */
    function contains(UintSet storage set, uint256 value) internal view returns (bool) {
        return _contains(set._inner, bytes32(value));
    }

    /**
     * @dev Returns the number of values on the set. O(1).
     */
    function length(UintSet storage set) internal view returns (uint256) {
        return _length(set._inner);
    }

    /**
     * @dev Returns the value stored at position `index` in the set. O(1).
     *
     * Note that there are no guarantees on the ordering of values inside the
     * array, and it may change when more values are added or removed.
     *
     * Requirements:
     *
     * - `index` must be strictly less than {length}.
     */
    function at(UintSet storage set, uint256 index) internal view returns (uint256) {
        return uint256(_at(set._inner, index));
    }

    /**
     * @dev Return the entire set in an array
     *
     * WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed
     * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that
     * this function has an unbounded cost, and using it as part of a state-changing function may render the function
     * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block.
     */
    function values(UintSet storage set) internal view returns (uint256[] memory) {
        bytes32[] memory store = _values(set._inner);
        uint256[] memory result;

        assembly {
            result := store
        }

        return result;
    }
}

File 9 of 23 : Strings.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Strings.sol)

pragma solidity ^0.8.0;

/**
 * @dev String operations.
 */
library Strings {
    bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef";

    /**
     * @dev Converts a `uint256` to its ASCII `string` decimal representation.
     */
    function toString(uint256 value) internal pure returns (string memory) {
        // Inspired by OraclizeAPI's implementation - MIT licence
        // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol

        if (value == 0) {
            return "0";
        }
        uint256 temp = value;
        uint256 digits;
        while (temp != 0) {
            digits++;
            temp /= 10;
        }
        bytes memory buffer = new bytes(digits);
        while (value != 0) {
            digits -= 1;
            buffer[digits] = bytes1(uint8(48 + uint256(value % 10)));
            value /= 10;
        }
        return string(buffer);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation.
     */
    function toHexString(uint256 value) internal pure returns (string memory) {
        if (value == 0) {
            return "0x00";
        }
        uint256 temp = value;
        uint256 length = 0;
        while (temp != 0) {
            length++;
            temp >>= 8;
        }
        return toHexString(value, length);
    }

    /**
     * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length.
     */
    function toHexString(uint256 value, uint256 length) internal pure returns (string memory) {
        bytes memory buffer = new bytes(2 * length + 2);
        buffer[0] = "0";
        buffer[1] = "x";
        for (uint256 i = 2 * length + 1; i > 1; --i) {
            buffer[i] = _HEX_SYMBOLS[value & 0xf];
            value >>= 4;
        }
        require(value == 0, "Strings: hex length insufficient");
        return string(buffer);
    }
}

File 10 of 23 : FineCoreInterface.sol
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.2;

interface FineCoreInterface {
    function getProjectAddress(uint id) external view returns (address);
    function getRandomness(uint256 id, uint256 seed) external view returns (uint256 randomnesss);
    function getProjectID(address project) external view returns (uint);
    function FINE_TREASURY() external returns (address payable);
    function platformPercentage() external returns (uint256);
    function platformRoyalty() external returns (uint256);
}

File 11 of 23 : ERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/ERC721.sol)

pragma solidity ^0.8.0;

import "./IERC721.sol";
import "./IERC721Receiver.sol";
import "./extensions/IERC721Metadata.sol";
import "../../utils/Address.sol";
import "../../utils/Context.sol";
import "../../utils/Strings.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including
 * the Metadata extension, but not including the Enumerable extension, which is available separately as
 * {ERC721Enumerable}.
 */
contract ERC721 is Context, ERC165, IERC721, IERC721Metadata {
    using Address for address;
    using Strings for uint256;

    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Mapping from token ID to owner address
    mapping(uint256 => address) private _owners;

    // Mapping owner address to token count
    mapping(address => uint256) private _balances;

    // Mapping from token ID to approved address
    mapping(uint256 => address) private _tokenApprovals;

    // Mapping from owner to operator approvals
    mapping(address => mapping(address => bool)) private _operatorApprovals;

    /**
     * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection.
     */
    constructor(string memory name_, string memory symbol_) {
        _name = name_;
        _symbol = symbol_;
    }

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) {
        return
            interfaceId == type(IERC721).interfaceId ||
            interfaceId == type(IERC721Metadata).interfaceId ||
            super.supportsInterface(interfaceId);
    }

    /**
     * @dev See {IERC721-balanceOf}.
     */
    function balanceOf(address owner) public view virtual override returns (uint256) {
        require(owner != address(0), "ERC721: balance query for the zero address");
        return _balances[owner];
    }

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

    /**
     * @dev See {IERC721Metadata-name}.
     */
    function name() public view virtual override returns (string memory) {
        return _name;
    }

    /**
     * @dev See {IERC721Metadata-symbol}.
     */
    function symbol() public view virtual override returns (string memory) {
        return _symbol;
    }

    /**
     * @dev See {IERC721Metadata-tokenURI}.
     */
    function tokenURI(uint256 tokenId) public view virtual override returns (string memory) {
        require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token");

        string memory baseURI = _baseURI();
        return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : "";
    }

    /**
     * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each
     * token will be the concatenation of the `baseURI` and the `tokenId`. Empty
     * by default, can be overriden in child contracts.
     */
    function _baseURI() internal view virtual returns (string memory) {
        return "";
    }

    /**
     * @dev See {IERC721-approve}.
     */
    function approve(address to, uint256 tokenId) public virtual override {
        address owner = ERC721.ownerOf(tokenId);
        require(to != owner, "ERC721: approval to current owner");

        require(
            _msgSender() == owner || isApprovedForAll(owner, _msgSender()),
            "ERC721: approve caller is not owner nor approved for all"
        );

        _approve(to, tokenId);
    }

    /**
     * @dev See {IERC721-getApproved}.
     */
    function getApproved(uint256 tokenId) public view virtual override returns (address) {
        require(_exists(tokenId), "ERC721: approved query for nonexistent token");

        return _tokenApprovals[tokenId];
    }

    /**
     * @dev See {IERC721-setApprovalForAll}.
     */
    function setApprovalForAll(address operator, bool approved) public virtual override {
        _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 _owners[tokenId] != address(0);
    }

    /**
     * @dev Returns whether `spender` is allowed to manage `tokenId`.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) {
        require(_exists(tokenId), "ERC721: operator query for nonexistent token");
        address owner = ERC721.ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Safely mints `tokenId` and transfers it to `to`.
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function _safeMint(address to, uint256 tokenId) internal virtual {
        _safeMint(to, tokenId, "");
    }

    /**
     * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is
     * forwarded in {IERC721Receiver-onERC721Received} to contract recipients.
     */
    function _safeMint(
        address to,
        uint256 tokenId,
        bytes memory _data
    ) internal virtual {
        _mint(to, tokenId);
        require(
            _checkOnERC721Received(address(0), to, tokenId, _data),
            "ERC721: transfer to non ERC721Receiver implementer"
        );
    }

    /**
     * @dev Mints `tokenId` and transfers it to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible
     *
     * Requirements:
     *
     * - `tokenId` must not exist.
     * - `to` cannot be the zero address.
     *
     * Emits a {Transfer} event.
     */
    function _mint(address to, uint256 tokenId) internal virtual {
        require(to != address(0), "ERC721: mint to the zero address");
        require(!_exists(tokenId), "ERC721: token already minted");

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

        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(address(0), to, tokenId);

        _afterTokenTransfer(address(0), to, tokenId);
    }

    /**
     * @dev Destroys `tokenId`.
     * The approval is cleared when the token is burned.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     *
     * Emits a {Transfer} event.
     */
    function _burn(uint256 tokenId) internal virtual {
        address owner = ERC721.ownerOf(tokenId);

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

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

        _balances[owner] -= 1;
        delete _owners[tokenId];

        emit Transfer(owner, address(0), tokenId);

        _afterTokenTransfer(owner, address(0), tokenId);
    }

    /**
     * @dev Transfers `tokenId` from `from` to `to`.
     *  As opposed to {transferFrom}, this imposes no restrictions on msg.sender.
     *
     * Requirements:
     *
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     *
     * Emits a {Transfer} event.
     */
    function _transfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {
        require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer from incorrect owner");
        require(to != address(0), "ERC721: transfer to the zero address");

        _beforeTokenTransfer(from, to, tokenId);

        // Clear approvals from the previous owner
        _approve(address(0), tokenId);

        _balances[from] -= 1;
        _balances[to] += 1;
        _owners[tokenId] = to;

        emit Transfer(from, to, tokenId);

        _afterTokenTransfer(from, to, tokenId);
    }

    /**
     * @dev Approve `to` to operate on `tokenId`
     *
     * Emits a {Approval} event.
     */
    function _approve(address to, uint256 tokenId) internal virtual {
        _tokenApprovals[tokenId] = to;
        emit Approval(ERC721.ownerOf(tokenId), to, tokenId);
    }

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

    /**
     * @dev Hook that is called after any transfer of tokens. This includes
     * minting and burning.
     *
     * Calling conditions:
     *
     * - when `from` and `to` are both non-zero.
     * - `from` and `to` are never both zero.
     *
     * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks].
     */
    function _afterTokenTransfer(
        address from,
        address to,
        uint256 tokenId
    ) internal virtual {}
}

File 12 of 23 : IERC721Enumerable.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC721/extensions/IERC721Enumerable.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Enumerable is IERC721 {
    /**
     * @dev Returns the total amount of tokens stored by the contract.
     */
    function totalSupply() external view returns (uint256);

    /**
     * @dev Returns a token ID owned by `owner` at a given `index` of its token list.
     * Use along with {balanceOf} to enumerate all of ``owner``'s tokens.
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256);

    /**
     * @dev Returns a token ID at a given `index` of all the tokens stored by the contract.
     * Use along with {totalSupply} to enumerate all tokens.
     */
    function tokenByIndex(uint256 index) external view returns (uint256);
}

File 13 of 23 : IERC721.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721.sol)

pragma solidity ^0.8.0;

import "../../utils/introspection/IERC165.sol";

/**
 * @dev Required interface of an ERC721 compliant contract.
 */
interface IERC721 is IERC165 {
    /**
     * @dev Emitted when `tokenId` token is transferred from `from` to `to`.
     */
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token.
     */
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);

    /**
     * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets.
     */
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    /**
     * @dev Returns the number of tokens in ``owner``'s account.
     */
    function balanceOf(address owner) external view returns (uint256 balance);

    /**
     * @dev Returns the owner of the `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function ownerOf(uint256 tokenId) external view returns (address owner);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients
     * are aware of the ERC721 protocol to prevent tokens from being forever locked.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Transfers `tokenId` token from `from` to `to`.
     *
     * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     *
     * Emits a {Transfer} event.
     */
    function transferFrom(
        address from,
        address to,
        uint256 tokenId
    ) external;

    /**
     * @dev Gives permission to `to` to transfer `tokenId` token to another account.
     * The approval is cleared when the token is transferred.
     *
     * Only a single account can be approved at a time, so approving the zero address clears previous approvals.
     *
     * Requirements:
     *
     * - The caller must own the token or be an approved operator.
     * - `tokenId` must exist.
     *
     * Emits an {Approval} event.
     */
    function approve(address to, uint256 tokenId) external;

    /**
     * @dev Returns the account approved for `tokenId` token.
     *
     * Requirements:
     *
     * - `tokenId` must exist.
     */
    function getApproved(uint256 tokenId) external view returns (address operator);

    /**
     * @dev Approve or remove `operator` as an operator for the caller.
     * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller.
     *
     * Requirements:
     *
     * - The `operator` cannot be the caller.
     *
     * Emits an {ApprovalForAll} event.
     */
    function setApprovalForAll(address operator, bool _approved) external;

    /**
     * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`.
     *
     * See {setApprovalForAll}
     */
    function isApprovedForAll(address owner, address operator) external view returns (bool);

    /**
     * @dev Safely transfers `tokenId` token from `from` to `to`.
     *
     * Requirements:
     *
     * - `from` cannot be the zero address.
     * - `to` cannot be the zero address.
     * - `tokenId` token must exist and be owned by `from`.
     * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}.
     * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer.
     *
     * Emits a {Transfer} event.
     */
    function safeTransferFrom(
        address from,
        address to,
        uint256 tokenId,
        bytes calldata data
    ) external;
}

File 14 of 23 : IERC721Receiver.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/IERC721Receiver.sol)

pragma solidity ^0.8.0;

/**
 * @title ERC721 token receiver interface
 * @dev Interface for any contract that wants to support safeTransfers
 * from ERC721 asset contracts.
 */
interface IERC721Receiver {
    /**
     * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom}
     * by `operator` from `from`, this function is called.
     *
     * It must return its Solidity selector to confirm the token transfer.
     * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted.
     *
     * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`.
     */
    function onERC721Received(
        address operator,
        address from,
        uint256 tokenId,
        bytes calldata data
    ) external returns (bytes4);
}

File 15 of 23 : IERC721Metadata.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (token/ERC721/extensions/IERC721Metadata.sol)

pragma solidity ^0.8.0;

import "../IERC721.sol";

/**
 * @title ERC-721 Non-Fungible Token Standard, optional metadata extension
 * @dev See https://eips.ethereum.org/EIPS/eip-721
 */
interface IERC721Metadata is IERC721 {
    /**
     * @dev Returns the token collection name.
     */
    function name() external view returns (string memory);

    /**
     * @dev Returns the token collection symbol.
     */
    function symbol() external view returns (string memory);

    /**
     * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token.
     */
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

File 16 of 23 : Address.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (utils/Address.sol)

pragma solidity ^0.8.1;

/**
 * @dev Collection of functions related to the address type
 */
library Address {
    /**
     * @dev Returns true if `account` is a contract.
     *
     * [IMPORTANT]
     * ====
     * It is unsafe to assume that an address for which this function returns
     * false is an externally-owned account (EOA) and not a contract.
     *
     * Among others, `isContract` will return false for the following
     * types of addresses:
     *
     *  - an externally-owned account
     *  - a contract in construction
     *  - an address where a contract will be created
     *  - an address where a contract lived, but was destroyed
     * ====
     *
     * [IMPORTANT]
     * ====
     * You shouldn't rely on `isContract` to protect against flash loan attacks!
     *
     * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets
     * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract
     * constructor.
     * ====
     */
    function isContract(address account) internal view returns (bool) {
        // This method relies on extcodesize/address.code.length, which returns 0
        // for contracts in construction, since the code is only stored at the end
        // of the constructor execution.

        return account.code.length > 0;
    }

    /**
     * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
     * `recipient`, forwarding all available gas and reverting on errors.
     *
     * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
     * of certain opcodes, possibly making contracts go over the 2300 gas limit
     * imposed by `transfer`, making them unable to receive funds via
     * `transfer`. {sendValue} removes this limitation.
     *
     * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
     *
     * IMPORTANT: because control is transferred to `recipient`, care must be
     * taken to not create reentrancy vulnerabilities. Consider using
     * {ReentrancyGuard} or the
     * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
     */
    function sendValue(address payable recipient, uint256 amount) internal {
        require(address(this).balance >= amount, "Address: insufficient balance");

        (bool success, ) = recipient.call{value: amount}("");
        require(success, "Address: unable to send value, recipient may have reverted");
    }

    /**
     * @dev Performs a Solidity function call using a low level `call`. A
     * plain `call` is an unsafe replacement for a function call: use this
     * function instead.
     *
     * If `target` reverts with a revert reason, it is bubbled up by this
     * function (like regular Solidity function calls).
     *
     * Returns the raw returned data. To convert to the expected return value,
     * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].
     *
     * Requirements:
     *
     * - `target` must be a contract.
     * - calling `target` with `data` must not revert.
     *
     * _Available since v3.1._
     */
    function functionCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionCall(target, data, "Address: low-level call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with
     * `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, 0, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but also transferring `value` wei to `target`.
     *
     * Requirements:
     *
     * - the calling contract must have an ETH balance of at least `value`.
     * - the called Solidity function must be `payable`.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value
    ) internal returns (bytes memory) {
        return functionCallWithValue(target, data, value, "Address: low-level call with value failed");
    }

    /**
     * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but
     * with `errorMessage` as a fallback revert reason when `target` reverts.
     *
     * _Available since v3.1._
     */
    function functionCallWithValue(
        address target,
        bytes memory data,
        uint256 value,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(address(this).balance >= value, "Address: insufficient balance for call");
        require(isContract(target), "Address: call to non-contract");

        (bool success, bytes memory returndata) = target.call{value: value}(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {
        return functionStaticCall(target, data, "Address: low-level static call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a static call.
     *
     * _Available since v3.3._
     */
    function functionStaticCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal view returns (bytes memory) {
        require(isContract(target), "Address: static call to non-contract");

        (bool success, bytes memory returndata) = target.staticcall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) {
        return functionDelegateCall(target, data, "Address: low-level delegate call failed");
    }

    /**
     * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],
     * but performing a delegate call.
     *
     * _Available since v3.4._
     */
    function functionDelegateCall(
        address target,
        bytes memory data,
        string memory errorMessage
    ) internal returns (bytes memory) {
        require(isContract(target), "Address: delegate call to non-contract");

        (bool success, bytes memory returndata) = target.delegatecall(data);
        return verifyCallResult(success, returndata, errorMessage);
    }

    /**
     * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the
     * revert reason using the provided one.
     *
     * _Available since v4.3._
     */
    function verifyCallResult(
        bool success,
        bytes memory returndata,
        string memory errorMessage
    ) internal pure returns (bytes memory) {
        if (success) {
            return returndata;
        } else {
            // Look for revert reason and bubble it up if present
            if (returndata.length > 0) {
                // The easiest way to bubble the revert reason is using memory via assembly

                assembly {
                    let returndata_size := mload(returndata)
                    revert(add(32, returndata), returndata_size)
                }
            } else {
                revert(errorMessage);
            }
        }
    }
}

File 17 of 23 : Context.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol)

pragma solidity ^0.8.0;

/**
 * @dev Provides information about the current execution context, including the
 * sender of the transaction and its data. While these are generally available
 * via msg.sender and msg.data, they should not be accessed in such a direct
 * manner, since when dealing with meta-transactions the account sending and
 * paying for execution may not be the actual sender (as far as an application
 * is concerned).
 *
 * This contract is only required for intermediate, library-like contracts.
 */
abstract contract Context {
    function _msgSender() internal view virtual returns (address) {
        return msg.sender;
    }

    function _msgData() internal view virtual returns (bytes calldata) {
        return msg.data;
    }
}

File 18 of 23 : ERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/ERC165.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Implementation of the {IERC165} interface.
 *
 * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check
 * for the additional interface id that will be supported. For example:
 *
 * ```solidity
 * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
 *     return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId);
 * }
 * ```
 *
 * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation.
 */
abstract contract ERC165 is IERC165 {
    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) {
        return interfaceId == type(IERC165).interfaceId;
    }
}

File 19 of 23 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol)

pragma solidity ^0.8.0;

/**
 * @dev Interface of the ERC165 standard, as defined in the
 * https://eips.ethereum.org/EIPS/eip-165[EIP].
 *
 * Implementers can declare support of contract interfaces, which can then be
 * queried by others ({ERC165Checker}).
 *
 * For an implementation, see {ERC165}.
 */
interface IERC165 {
    /**
     * @dev Returns true if this contract implements the interface defined by
     * `interfaceId`. See the corresponding
     * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
     * to learn more about how these ids are created.
     *
     * This function call must use less than 30 000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

File 20 of 23 : ERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (token/common/ERC2981.sol)

pragma solidity ^0.8.0;

import "../../interfaces/IERC2981.sol";
import "../../utils/introspection/ERC165.sol";

/**
 * @dev Implementation of the NFT Royalty Standard, a standardized way to retrieve royalty payment information.
 *
 * Royalty information can be specified globally for all token ids via {_setDefaultRoyalty}, and/or individually for
 * specific token ids via {_setTokenRoyalty}. The latter takes precedence over the first.
 *
 * Royalty is specified as a fraction of sale price. {_feeDenominator} is overridable but defaults to 10000, meaning the
 * fee is specified in basis points by default.
 *
 * IMPORTANT: ERC-2981 only specifies a way to signal royalty information and does not enforce its payment. See
 * https://eips.ethereum.org/EIPS/eip-2981#optional-royalty-payments[Rationale] in the EIP. Marketplaces are expected to
 * voluntarily pay royalties together with sales, but note that this standard is not yet widely supported.
 *
 * _Available since v4.5._
 */
abstract contract ERC2981 is IERC2981, ERC165 {
    struct RoyaltyInfo {
        address receiver;
        uint96 royaltyFraction;
    }

    RoyaltyInfo private _defaultRoyaltyInfo;
    mapping(uint256 => RoyaltyInfo) private _tokenRoyaltyInfo;

    /**
     * @dev See {IERC165-supportsInterface}.
     */
    function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC165) returns (bool) {
        return interfaceId == type(IERC2981).interfaceId || super.supportsInterface(interfaceId);
    }

    /**
     * @inheritdoc IERC2981
     */
    function royaltyInfo(uint256 _tokenId, uint256 _salePrice)
        external
        view
        virtual
        override
        returns (address, uint256)
    {
        RoyaltyInfo memory royalty = _tokenRoyaltyInfo[_tokenId];

        if (royalty.receiver == address(0)) {
            royalty = _defaultRoyaltyInfo;
        }

        uint256 royaltyAmount = (_salePrice * royalty.royaltyFraction) / _feeDenominator();

        return (royalty.receiver, royaltyAmount);
    }

    /**
     * @dev The denominator with which to interpret the fee set in {_setTokenRoyalty} and {_setDefaultRoyalty} as a
     * fraction of the sale price. Defaults to 10000 so fees are expressed in basis points, but may be customized by an
     * override.
     */
    function _feeDenominator() internal pure virtual returns (uint96) {
        return 10000;
    }

    /**
     * @dev Sets the royalty information that all ids in this contract will default to.
     *
     * Requirements:
     *
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setDefaultRoyalty(address receiver, uint96 feeNumerator) internal virtual {
        require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice");
        require(receiver != address(0), "ERC2981: invalid receiver");

        _defaultRoyaltyInfo = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Removes default royalty information.
     */
    function _deleteDefaultRoyalty() internal virtual {
        delete _defaultRoyaltyInfo;
    }

    /**
     * @dev Sets the royalty information for a specific token id, overriding the global default.
     *
     * Requirements:
     *
     * - `tokenId` must be already minted.
     * - `receiver` cannot be the zero address.
     * - `feeNumerator` cannot be greater than the fee denominator.
     */
    function _setTokenRoyalty(
        uint256 tokenId,
        address receiver,
        uint96 feeNumerator
    ) internal virtual {
        require(feeNumerator <= _feeDenominator(), "ERC2981: royalty fee will exceed salePrice");
        require(receiver != address(0), "ERC2981: Invalid parameters");

        _tokenRoyaltyInfo[tokenId] = RoyaltyInfo(receiver, feeNumerator);
    }

    /**
     * @dev Resets royalty information for the token id back to the global default.
     */
    function _resetTokenRoyalty(uint256 tokenId) internal virtual {
        delete _tokenRoyaltyInfo[tokenId];
    }
}

File 21 of 23 : IERC2981.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.5.0) (interfaces/IERC2981.sol)

pragma solidity ^0.8.0;

import "./IERC165.sol";

/**
 * @dev Interface for the NFT Royalty Standard.
 *
 * A standardized way to retrieve royalty payment information for non-fungible tokens (NFTs) to enable universal
 * support for royalty payments across all NFT marketplaces and ecosystem participants.
 *
 * _Available since v4.5._
 */
interface IERC2981 is IERC165 {
    /**
     * @dev Returns how much royalty is owed and to whom, based on a sale price that may be denominated in any unit of
     * exchange. The royalty amount is denominated and should be payed in that same unit of exchange.
     */
    function royaltyInfo(uint256 tokenId, uint256 salePrice)
        external
        view
        returns (address receiver, uint256 royaltyAmount);
}

File 22 of 23 : IERC165.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (interfaces/IERC165.sol)

pragma solidity ^0.8.0;

import "../utils/introspection/IERC165.sol";

File 23 of 23 : IAccessControl.sol
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts v4.4.1 (access/IAccessControl.sol)

pragma solidity ^0.8.0;

/**
 * @dev External interface of AccessControl declared to support ERC165 detection.
 */
interface IAccessControl {
    /**
     * @dev Emitted when `newAdminRole` is set as ``role``'s admin role, replacing `previousAdminRole`
     *
     * `DEFAULT_ADMIN_ROLE` is the starting admin for all roles, despite
     * {RoleAdminChanged} not being emitted signaling this.
     *
     * _Available since v3.1._
     */
    event RoleAdminChanged(bytes32 indexed role, bytes32 indexed previousAdminRole, bytes32 indexed newAdminRole);

    /**
     * @dev Emitted when `account` is granted `role`.
     *
     * `sender` is the account that originated the contract call, an admin role
     * bearer except when using {AccessControl-_setupRole}.
     */
    event RoleGranted(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Emitted when `account` is revoked `role`.
     *
     * `sender` is the account that originated the contract call:
     *   - if using `revokeRole`, it is the admin role bearer
     *   - if using `renounceRole`, it is the role bearer (i.e. `account`)
     */
    event RoleRevoked(bytes32 indexed role, address indexed account, address indexed sender);

    /**
     * @dev Returns `true` if `account` has been granted `role`.
     */
    function hasRole(bytes32 role, address account) external view returns (bool);

    /**
     * @dev Returns the admin role that controls `role`. See {grantRole} and
     * {revokeRole}.
     *
     * To change a role's admin, use {AccessControl-_setRoleAdmin}.
     */
    function getRoleAdmin(bytes32 role) external view returns (bytes32);

    /**
     * @dev Grants `role` to `account`.
     *
     * If `account` had not been already granted `role`, emits a {RoleGranted}
     * event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function grantRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from `account`.
     *
     * If `account` had been granted `role`, emits a {RoleRevoked} event.
     *
     * Requirements:
     *
     * - the caller must have ``role``'s admin role.
     */
    function revokeRole(bytes32 role, address account) external;

    /**
     * @dev Revokes `role` from the calling account.
     *
     * Roles are often managed via {grantRole} and {revokeRole}: this function's
     * purpose is to provide a mechanism for accounts to lose their privileges
     * if they are compromised (such as when a trusted device is misplaced).
     *
     * If the calling account had been granted `role`, emits a {RoleRevoked}
     * event.
     *
     * Requirements:
     *
     * - the caller must be `account`.
     */
    function renounceRole(bytes32 role, address account) external;
}

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

Contract Security Audit

Contract ABI

[{"inputs":[{"internalType":"address","name":"coreAddress","type":"address"},{"internalType":"address","name":"shopAddress","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":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":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"previousAdminRole","type":"bytes32"},{"indexed":true,"internalType":"bytes32","name":"newAdminRole","type":"bytes32"}],"name":"RoleAdminChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleGranted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"role","type":"bytes32"},{"indexed":true,"internalType":"address","name":"account","type":"address"},{"indexed":true,"internalType":"address","name":"sender","type":"address"}],"name":"RoleRevoked","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":true,"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"_from","type":"address"},{"indexed":false,"internalType":"uint256","name":"_amount","type":"uint256"}],"name":"recievedFunds","type":"event"},{"inputs":[],"name":"DEFAULT_ADMIN_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"MINTER_ROLE","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"TOKEN_LIMIT","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"_contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"additionalPayee","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint96","name":"_percentage","type":"uint96"}],"name":"additionalPayeePercent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"additionalPayeePercentage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint96","name":"_percentage","type":"uint96"}],"name":"additionalPayeeRoyaltyPercent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"additionalPayeeRoyaltyPercentage","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"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":"artist","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"artistAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"baseURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"burn","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"cache","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"checkPool","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"contractURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"description","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAdditionalPayee","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAdditionalPayeePercentage","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":"getArtistAddress","outputs":[{"internalType":"address payable","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"}],"name":"getRoleAdmin","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTokenLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"grantRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"hasRole","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":"license","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"mint","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"infiniteId","type":"uint256"}],"name":"mintBonus","outputs":[{"internalType":"uint256","name":"bonusId","type":"uint256"}],"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":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"paused","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"remaining","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"renounceRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32","name":"role","type":"bytes32"},{"internalType":"address","name":"account","type":"address"}],"name":"revokeRole","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"uint256","name":"_salePrice","type":"uint256"}],"name":"royaltyInfo","outputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"royaltyPercent","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"operator","type":"address"},{"internalType":"bool","name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_uri","type":"string"}],"name":"setBaseURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_uri","type":"string"}],"name":"setContractURI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_desc","type":"string"}],"name":"setDescription","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint96","name":"_percentage","type":"uint96"}],"name":"setRoyaltyPercent","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"_url","type":"string"}],"name":"setWebsite","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes4","name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"owner","type":"address"},{"internalType":"uint256","name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"website","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"withdraw","outputs":[],"stateMutability":"nonpayable","type":"function"},{"stateMutability":"payable","type":"receive"}]

600e805460ff60a01b191690556122b8600f55601280546001600160a01b03199081167370f2d7fa5fae142e1af7a95b4d48a9c8e417813d1790915560138054909116905560006014819055601555601680546001600160601b03191661119417905560e06040526035608081815290620039b060a03980516200008c91601791602090910190620004b9565b50604051806060016040528060358152602001620039e5603591398051620000bd91601891602090910190620004b9565b50604080518082019091526003808252622320a960e91b6020909201918252620000ea91601991620004b9565b506040518060e0016040528060a481526020016200390c60a4913980516200011b91601a91602090910190620004b9565b506040805180820190915260148082527f68747470733a2f2f66696e652e6469676974616c00000000000000000000000060209092019182526200016291601b91620004b9565b506040805180820190915260038082526213525560ea1b60209092019182526200018f91601c91620004b9565b503480156200019d57600080fd5b5060405162003a1a38038062003a1a833981016040819052620001c0916200057c565b6040805180820182526006815265534f4c49445360d01b60208083019182528351808501909452600584526414d3d3125160da1b9084015281519192916200020b91600291620004b9565b50805162000221906003906020840190620004b9565b5050506200023e62000238620002b960201b60201c565b620002bd565b6200024b6000336200030f565b620002777f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a6826200030f565b600e80546001600160a01b0319166001600160a01b038416179055601654620002ab9030906001600160601b0316620003b4565b5050600f54601055620005f0565b3390565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b6000828152600c602090815260408083206001600160a01b038516845290915290205460ff16620003b0576000828152600c602090815260408083206001600160a01b03851684529091529020805460ff191660011790556200036f3390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45b5050565b6127106001600160601b0382161115620004285760405162461bcd60e51b815260206004820152602a60248201527f455243323938313a20726f79616c7479206665652077696c6c206578636565646044820152692073616c65507269636560b01b60648201526084015b60405180910390fd5b6001600160a01b038216620004805760405162461bcd60e51b815260206004820152601960248201527f455243323938313a20696e76616c69642072656365697665720000000000000060448201526064016200041f565b604080518082019091526001600160a01b039092168083526001600160601b039091166020909201829052600160a01b90910217600055565b828054620004c790620005b4565b90600052602060002090601f016020900481019282620004eb576000855562000536565b82601f106200050657805160ff191683800117855562000536565b8280016001018555821562000536579182015b828111156200053657825182559160200191906001019062000519565b506200054492915062000548565b5090565b5b8082111562000544576000815560010162000549565b80516001600160a01b03811681146200057757600080fd5b919050565b600080604083850312156200059057600080fd5b6200059b836200055f565b9150620005ab602084016200055f565b90509250929050565b600181811c90821680620005c957607f821691505b602082108103620005ea57634e487b7160e01b600052602260045260246000fd5b50919050565b61330c80620006006000396000f3fe6080604052600436106103a65760003560e01c80636b87d24c116101e7578063a217fddf1161010d578063d7eb3f3a116100a0578063ea099ad91161006f578063ea099ad914610afc578063f2fde38b14610b12578063f87f44b914610b32578063f9f3bfd814610b5257600080fd5b8063d7eb3f3a14610a5e578063d9a7c61d14610a7e578063e8a3d48514610a9e578063e985e9c514610ab357600080fd5b8063c0e72740116100dc578063c0e72740146109d5578063c87b56dd146109ea578063d539139314610a0a578063d547741f14610a3e57600080fd5b8063a217fddf1461096b578063a22cb46514610980578063b88d4fde146109a0578063beb0a416146109c057600080fd5b8063867644d91161018557806391d148541161015457806391d14854146108de578063938e3d7b146108fe57806395d89b411461091e5780639f67756d1461093357600080fd5b8063867644d9146108625780638cbe8d80146108825780638da5cb5b146108a057806390c3f38f146108be57600080fd5b806370a08231116101c157806370a0823114610803578063715018a6146108235780637284e416146108385780638456cb591461084d57600080fd5b80636b87d24c146107bb5780636c0360eb146107d05780636ff314c7146107e557600080fd5b80633ccfd60b116102cc5780634bc46a821161026a57806359748cb21161023957806359748cb21461073a5780635c975abb1461075a5780636352211e1461077b5780636a6278421461079b57600080fd5b80634bc46a82146106c45780634f6ccce7146106e457806355234ec01461070457806355f804b31461071a57600080fd5b806342842e0e116102a657806342842e0e1461065a57806342966c681461067a57806343bc16121461069a5780634771218a146106af57600080fd5b80633ccfd60b1461061a5780633f4ba83a1461062f57806340138ff11461064457600080fd5b806323b872dd116103445780632cc88974116103135780632cc88974146105a55780632f2ff15d146105ba5780632f745c59146105da57806336568abe146105fa57600080fd5b806323b872dd14610501578063248a9ca31461052157806328485586146105515780632a55205a1461056657600080fd5b8063081812fc11610380578063081812fc14610465578063095ea7b31461049d57806317bf72c6146104bf57806318160ddd146104ec57600080fd5b806301ffc9a7146103ea578063031bd4c41461041f57806306fdde031461044357600080fd5b366103e557604080513381523460208201527ffb5cb5fc5900f14be0f619816129d1490c275a13734b28ae77072a2f5d676f57910160405180910390a1005b600080fd5b3480156103f657600080fd5b5061040a610405366004612b5d565b610b72565b60405190151581526020015b60405180910390f35b34801561042b57600080fd5b50610435600f5481565b604051908152602001610416565b34801561044f57600080fd5b50610458610b83565b6040516104169190612bd2565b34801561047157600080fd5b50610485610480366004612be5565b610c15565b6040516001600160a01b039091168152602001610416565b3480156104a957600080fd5b506104bd6104b8366004612c13565b610caf565b005b3480156104cb57600080fd5b506104356104da366004612be5565b60116020526000908152604090205481565b3480156104f857600080fd5b50600a54610435565b34801561050d57600080fd5b506104bd61051c366004612c3f565b610dc4565b34801561052d57600080fd5b5061043561053c366004612be5565b6000908152600c602052604090206001015490565b34801561055d57600080fd5b50600f54610435565b34801561057257600080fd5b50610586610581366004612c80565b610df6565b604080516001600160a01b039093168352602083019190915201610416565b3480156105b157600080fd5b50601454610435565b3480156105c657600080fd5b506104bd6105d5366004612ca2565b610ea2565b3480156105e657600080fd5b506104356105f5366004612c13565b610ec8565b34801561060657600080fd5b506104bd610615366004612ca2565b610f5e565b34801561062657600080fd5b506104bd610fdc565b34801561063b57600080fd5b506104bd611011565b34801561065057600080fd5b5061043560145481565b34801561066657600080fd5b506104bd610675366004612c3f565b61104a565b34801561068657600080fd5b506104bd610695366004612be5565b611065565b3480156106a657600080fd5b506104586110df565b3480156106bb57600080fd5b50601054610435565b3480156106d057600080fd5b506104bd6106df366004612cd2565b61116d565b3480156106f057600080fd5b506104356106ff366004612be5565b6111be565b34801561071057600080fd5b5061043560105481565b34801561072657600080fd5b506104bd610735366004612cfb565b611251565b34801561074657600080fd5b50601354610485906001600160a01b031681565b34801561076657600080fd5b50600e5461040a90600160a01b900460ff1681565b34801561078757600080fd5b50610485610796366004612be5565b611287565b3480156107a757600080fd5b506104356107b6366004612d6d565b6112fe565b3480156107c757600080fd5b506104586113db565b3480156107dc57600080fd5b506104586113e8565b3480156107f157600080fd5b506013546001600160a01b0316610485565b34801561080f57600080fd5b5061043561081e366004612d6d565b6113f5565b34801561082f57600080fd5b506104bd61147c565b34801561084457600080fd5b506104586114b0565b34801561085957600080fd5b506104bd6114bd565b34801561086e57600080fd5b506104bd61087d366004612cd2565b6114fc565b34801561088e57600080fd5b506012546001600160a01b0316610485565b3480156108ac57600080fd5b50600d546001600160a01b0316610485565b3480156108ca57600080fd5b506104bd6108d9366004612cfb565b611534565b3480156108ea57600080fd5b5061040a6108f9366004612ca2565b61156a565b34801561090a57600080fd5b506104bd610919366004612cfb565b611595565b34801561092a57600080fd5b506104586115cb565b34801561093f57600080fd5b50601654610953906001600160601b031681565b6040516001600160601b039091168152602001610416565b34801561097757600080fd5b50610435600081565b34801561098c57600080fd5b506104bd61099b366004612d8a565b6115da565b3480156109ac57600080fd5b506104bd6109bb366004612dd3565b6115e5565b3480156109cc57600080fd5b5061045861161d565b3480156109e157600080fd5b5061045861162a565b3480156109f657600080fd5b50610458610a05366004612be5565b611637565b348015610a1657600080fd5b506104357f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b348015610a4a57600080fd5b506104bd610a59366004612ca2565b61166b565b348015610a6a57600080fd5b50601254610485906001600160a01b031681565b348015610a8a57600080fd5b50610435610a99366004612c13565b611691565b348015610aaa57600080fd5b50610458611785565b348015610abf57600080fd5b5061040a610ace366004612eb3565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b348015610b0857600080fd5b5061043560155481565b348015610b1e57600080fd5b506104bd610b2d366004612d6d565b611794565b348015610b3e57600080fd5b506104bd610b4d366004612cfb565b61182c565b348015610b5e57600080fd5b506104bd610b6d366004612cd2565b611862565b6000610b7d8261189a565b92915050565b606060028054610b9290612ee1565b80601f0160208091040260200160405190810160405280929190818152602001828054610bbe90612ee1565b8015610c0b5780601f10610be057610100808354040283529160200191610c0b565b820191906000526020600020905b815481529060010190602001808311610bee57829003601f168201915b5050505050905090565b6000818152600460205260408120546001600160a01b0316610c935760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600660205260409020546001600160a01b031690565b6000610cba82611287565b9050806001600160a01b0316836001600160a01b031603610d275760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610c8a565b336001600160a01b0382161480610d435750610d438133610ace565b610db55760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610c8a565b610dbf83836118bf565b505050565b610dcf335b8261192d565b610deb5760405162461bcd60e51b8152600401610c8a90612f15565b610dbf838383611a24565b60008281526001602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b0316928201929092528291610e6b5750604080518082019091526000546001600160a01b0381168252600160a01b90046001600160601b031660208201525b602081015160009061271090610e8a906001600160601b031687612f7c565b610e949190612fb1565b915196919550909350505050565b6000828152600c6020526040902060010154610ebe8133611bcb565b610dbf8383611c2f565b6000610ed3836113f5565b8210610f355760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610c8a565b506001600160a01b03919091166000908152600860209081526040808320938352929052205490565b6001600160a01b0381163314610fce5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610c8a565b610fd88282611cb5565b5050565b600d546001600160a01b031633146110065760405162461bcd60e51b8152600401610c8a90612fc5565b61100f47611d1c565b565b600d546001600160a01b0316331461103b5760405162461bcd60e51b8152600401610c8a90612fc5565b600e805460ff60a01b19169055565b610dbf838383604051806020016040528060008152506115e5565b61106e33610dc9565b6110d35760405162461bcd60e51b815260206004820152603060248201527f4552433732314275726e61626c653a2063616c6c6572206973206e6f74206f7760448201526f1b995c881b9bdc88185c1c1c9bdd995960821b6064820152608401610c8a565b6110dc81611f15565b50565b601980546110ec90612ee1565b80601f016020809104026020016040519081016040528092919081815260200182805461111890612ee1565b80156111655780601f1061113a57610100808354040283529160200191611165565b820191906000526020600020905b81548152906001019060200180831161114857829003601f168201915b505050505081565b600d546001600160a01b031633146111975760405162461bcd60e51b8152600401610c8a90612fc5565b601680546bffffffffffffffffffffffff19166001600160601b0392909216919091179055565b60006111c9600a5490565b821061122c5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610c8a565b600a828154811061123f5761123f612ffa565b90600052602060002001549050919050565b600d546001600160a01b0316331461127b5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf60188383612aae565b6000818152600460205260408120546001600160a01b031680610b7d5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610c8a565b60007f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a661132b8133611bcb565b600e54600160a01b900460ff16156113765760405162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d1a5b99c81c185d5cd95960921b6044820152606401610c8a565b6000601054116113bc5760405162461bcd60e51b8152602060048201526011602482015270185b1b081d1bdad95b9cc81b5a5b9d1959607a1b6044820152606401610c8a565b60006113c6611f1e565b90506113d28482612062565b91505b50919050565b601c80546110ec90612ee1565b601880546110ec90612ee1565b60006001600160a01b0382166114605760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610c8a565b506001600160a01b031660009081526005602052604090205490565b600d546001600160a01b031633146114a65760405162461bcd60e51b8152600401610c8a90612fc5565b61100f600061207c565b601a80546110ec90612ee1565b600d546001600160a01b031633146114e75760405162461bcd60e51b8152600401610c8a90612fc5565b600e805460ff60a01b1916600160a01b179055565b600d546001600160a01b031633146115265760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160601b0316601555565b600d546001600160a01b0316331461155e5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf601a8383612aae565b6000918252600c602090815260408084206001600160a01b0393909316845291905290205460ff1690565b600d546001600160a01b031633146115bf5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf60178383612aae565b606060038054610b9290612ee1565b610fd83383836120ce565b6115ef338361192d565b61160b5760405162461bcd60e51b8152600401610c8a90612f15565b6116178484848461219c565b50505050565b601b80546110ec90612ee1565b601780546110ec90612ee1565b60606018611644836121cf565b60405160200161165592919061302c565b6040516020818303038152906040529050919050565b6000828152600c60205260409020600101546116878133611bcb565b610dbf8383611cb5565b60007f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a66116be8133611bcb565b600e54600160a01b900460ff16156117095760405162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d1a5b99c81c185d5cd95960921b6044820152606401610c8a565b611715836127106130f6565b6000818152600460205260409020549092506001600160a01b0316156117745760405162461bcd60e51b8152602060048201526014602482015273151bdad95b88185b1c9958591e481b5a5b9d195960621b6044820152606401610c8a565b61177e8483612062565b5092915050565b606060178054610b9290612ee1565b600d546001600160a01b031633146117be5760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160a01b0381166118235760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c8a565b6110dc8161207c565b600d546001600160a01b031633146118565760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf601b8383612aae565b600d546001600160a01b0316331461188c5760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160601b0316601455565b60006001600160e01b03198216637965db0b60e01b1480610b7d5750610b7d826122d0565b600081815260066020526040902080546001600160a01b0319166001600160a01b03841690811790915581906118f482611287565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600460205260408120546001600160a01b03166119a65760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c8a565b60006119b183611287565b9050806001600160a01b0316846001600160a01b031614806119ec5750836001600160a01b03166119e184610c15565b6001600160a01b0316145b80611a1c57506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b0316611a3782611287565b6001600160a01b031614611a9b5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610c8a565b6001600160a01b038216611afd5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c8a565b611b088383836122db565b611b136000826118bf565b6001600160a01b0383166000908152600560205260408120805460019290611b3c90849061310e565b90915550506001600160a01b0382166000908152600560205260408120805460019290611b6a9084906130f6565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b611bd5828261156a565b610fd857611bed816001600160a01b031660146122e6565b611bf88360206122e6565b604051602001611c09929190613125565b60408051601f198184030181529082905262461bcd60e51b8252610c8a91600401612bd2565b611c39828261156a565b610fd8576000828152600c602090815260408083206001600160a01b03851684529091529020805460ff19166001179055611c713390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b611cbf828261156a565b15610fd8576000828152600c602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b80156110dc576000612710600e60009054906101000a90046001600160a01b03166001600160a01b031663d672131b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015611d7c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611da0919061319a565b611daa9084612f7c565b611db49190612fb1565b9050600e60009054906101000a90046001600160a01b03166001600160a01b0316637dafc0d36040518163ffffffff1660e01b81526004016020604051808303816000875af1158015611e0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e2f91906131b3565b6001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015611e67573d6000803e3d6000fd5b50600061271060155484611e7b9190612f7c565b611e859190612fb1565b90508015611ec9576013546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015611ec7573d6000803e3d6000fd5b505b6012546001600160a01b03166108fc82611ee3858761310e565b611eed919061310e565b6040518115909202916000818181858888f19350505050158015611617573d6000803e3d6000fd5b6110dc81612489565b600e546010546040516329e5d83160e01b8152600481019190915242602482015260009182916001600160a01b03909116906329e5d83190604401602060405180830381865afa158015611f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f9a919061319a565b9050600060105482611fac91906131d0565b60008181526011602052604090205490915015611fd757600081815260116020526040902054611fd9565b805b9250601160006001601054611fee919061310e565b81526020019081526020016000205460001461202b57601160006001601054612017919061310e565b81526020019081526020016000205461203a565b600160105461203a919061310e565b6000828152601160205260409020556010546120589060019061310e565b6010555090919050565b610fd88282604051806020016040528060008152506124a3565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b03160361212f5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c8a565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6121a7848484611a24565b6121b3848484846124d6565b6116175760405162461bcd60e51b8152600401610c8a906131e4565b6060816000036121f65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612220578061220a81613236565b91506122199050600a83612fb1565b91506121fa565b60008167ffffffffffffffff81111561223b5761223b612dbd565b6040519080825280601f01601f191660200182016040528015612265576020820181803683370190505b5090505b8415611a1c5761227a60018361310e565b9150612287600a866131d0565b6122929060306130f6565b60f81b8183815181106122a7576122a7612ffa565b60200101906001600160f81b031916908160001a9053506122c9600a86612fb1565b9450612269565b6000610b7d826125d7565b610dbf8383836125fc565b606060006122f5836002612f7c565b6123009060026130f6565b67ffffffffffffffff81111561231857612318612dbd565b6040519080825280601f01601f191660200182016040528015612342576020820181803683370190505b509050600360fc1b8160008151811061235d5761235d612ffa565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061238c5761238c612ffa565b60200101906001600160f81b031916908160001a90535060006123b0846002612f7c565b6123bb9060016130f6565b90505b6001811115612433576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106123ef576123ef612ffa565b1a60f81b82828151811061240557612405612ffa565b60200101906001600160f81b031916908160001a90535060049490941c9361242c8161324f565b90506123be565b5083156124825760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610c8a565b9392505050565b612492816126b4565b600090815260016020526040812055565b6124ad838361275b565b6124ba60008484846124d6565b610dbf5760405162461bcd60e51b8152600401610c8a906131e4565b60006001600160a01b0384163b156125cc57604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061251a903390899088908890600401613266565b6020604051808303816000875af1925050508015612555575060408051601f3d908101601f19168201909252612552918101906132a3565b60015b6125b2573d808015612583576040519150601f19603f3d011682016040523d82523d6000602084013e612588565b606091505b5080516000036125aa5760405162461bcd60e51b8152600401610c8a906131e4565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611a1c565b506001949350505050565b60006001600160e01b0319821663780e9d6360e01b1480610b7d5750610b7d826128a9565b6001600160a01b0383166126575761265281600a80546000838152600b60205260408120829055600182018355919091527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a80155565b61267a565b816001600160a01b0316836001600160a01b03161461267a5761267a83826128e9565b6001600160a01b03821661269157610dbf81612986565b826001600160a01b0316826001600160a01b031614610dbf57610dbf8282612a35565b60006126bf82611287565b90506126cd816000846122db565b6126d86000836118bf565b6001600160a01b038116600090815260056020526040812080546001929061270190849061310e565b909155505060008281526004602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6001600160a01b0382166127b15760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c8a565b6000818152600460205260409020546001600160a01b0316156128165760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c8a565b612822600083836122db565b6001600160a01b038216600090815260056020526040812080546001929061284b9084906130f6565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60006001600160e01b031982166380ac58cd60e01b14806128da57506001600160e01b03198216635b5e139f60e01b145b80610b7d5750610b7d82612a79565b600060016128f6846113f5565b612900919061310e565b600083815260096020526040902054909150808214612953576001600160a01b03841660009081526008602090815260408083208584528252808320548484528184208190558352600990915290208190555b5060009182526009602090815260408084208490556001600160a01b039094168352600881528383209183525290812055565b600a546000906129989060019061310e565b6000838152600b6020526040812054600a80549394509092849081106129c0576129c0612ffa565b9060005260206000200154905080600a83815481106129e1576129e1612ffa565b6000918252602080832090910192909255828152600b9091526040808220849055858252812055600a805480612a1957612a196132c0565b6001900381819060005260206000200160009055905550505050565b6000612a40836113f5565b6001600160a01b039093166000908152600860209081526040808320868452825280832085905593825260099052919091209190915550565b60006001600160e01b0319821663152a902d60e11b1480610b7d57506301ffc9a760e01b6001600160e01b0319831614610b7d565b828054612aba90612ee1565b90600052602060002090601f016020900481019282612adc5760008555612b22565b82601f10612af55782800160ff19823516178555612b22565b82800160010185558215612b22579182015b82811115612b22578235825591602001919060010190612b07565b50612b2e929150612b32565b5090565b5b80821115612b2e5760008155600101612b33565b6001600160e01b0319811681146110dc57600080fd5b600060208284031215612b6f57600080fd5b813561248281612b47565b60005b83811015612b95578181015183820152602001612b7d565b838111156116175750506000910152565b60008151808452612bbe816020860160208601612b7a565b601f01601f19169290920160200192915050565b6020815260006124826020830184612ba6565b600060208284031215612bf757600080fd5b5035919050565b6001600160a01b03811681146110dc57600080fd5b60008060408385031215612c2657600080fd5b8235612c3181612bfe565b946020939093013593505050565b600080600060608486031215612c5457600080fd5b8335612c5f81612bfe565b92506020840135612c6f81612bfe565b929592945050506040919091013590565b60008060408385031215612c9357600080fd5b50508035926020909101359150565b60008060408385031215612cb557600080fd5b823591506020830135612cc781612bfe565b809150509250929050565b600060208284031215612ce457600080fd5b81356001600160601b038116811461248257600080fd5b60008060208385031215612d0e57600080fd5b823567ffffffffffffffff80821115612d2657600080fd5b818501915085601f830112612d3a57600080fd5b813581811115612d4957600080fd5b866020828501011115612d5b57600080fd5b60209290920196919550909350505050565b600060208284031215612d7f57600080fd5b813561248281612bfe565b60008060408385031215612d9d57600080fd5b8235612da881612bfe565b915060208301358015158114612cc757600080fd5b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215612de957600080fd5b8435612df481612bfe565b93506020850135612e0481612bfe565b925060408501359150606085013567ffffffffffffffff80821115612e2857600080fd5b818701915087601f830112612e3c57600080fd5b813581811115612e4e57612e4e612dbd565b604051601f8201601f19908116603f01168101908382118183101715612e7657612e76612dbd565b816040528281528a6020848701011115612e8f57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215612ec657600080fd5b8235612ed181612bfe565b91506020830135612cc781612bfe565b600181811c90821680612ef557607f821691505b6020821081036113d557634e487b7160e01b600052602260045260246000fd5b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b6000816000190483118215151615612f9657612f96612f66565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612fc057612fc0612f9b565b500490565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008151613022818560208601612b7a565b9290920192915050565b600080845481600182811c91508083168061304857607f831692505b6020808410820361306757634e487b7160e01b86526022600452602486fd5b81801561307b576001811461308c576130b9565b60ff198616895284890196506130b9565b60008b81526020902060005b868110156130b15781548b820152908501908301613098565b505084890196505b5050505050506130ed6130dc6130d683602f60f81b815260010190565b86613010565b64173539b7b760d91b815260050190565b95945050505050565b6000821982111561310957613109612f66565b500190565b60008282101561312057613120612f66565b500390565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161315d816017850160208801612b7a565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161318e816028840160208801612b7a565b01602801949350505050565b6000602082840312156131ac57600080fd5b5051919050565b6000602082840312156131c557600080fd5b815161248281612bfe565b6000826131df576131df612f9b565b500690565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60006001820161324857613248612f66565b5060010190565b60008161325e5761325e612f66565b506000190190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061329990830184612ba6565b9695505050505050565b6000602082840312156132b557600080fd5b815161248281612b47565b634e487b7160e01b600052603160045260246000fdfea26469706673582212207fdfa9d0ebdce4a373826d0606b6cfe6dcaa4ae2c0b7f4897eb6ce76cb43024364736f6c634300080d0033534f4c49445320697320612067656e6572617469766520617263686974656374757265204e46542070726f6a6563742063726561746564206279204641522e2054686572652061726520382c383838202b2035313220756e69717565206275696c64696e67732067656e65726174656420616c676f726974686d6963616c6c792c20656e61626c696e67207574696c69747920696e20746865204d65746176657273652e697066733a2f2f516d506d745071516666366e6e797676384c4e4570536e4c716541525675733851355362556657534c4177313236697066733a2f2f516d5342694b6732753459764542387251724a6973417642784352344c3951594676466469626b6b316b4244627900000000000000000000000016213f846a222da24eb4807a6cc5d0a5344994d60000000000000000000000007f6ddf832f4b714a1264893543cb2705c962fa37

Deployed Bytecode

0x6080604052600436106103a65760003560e01c80636b87d24c116101e7578063a217fddf1161010d578063d7eb3f3a116100a0578063ea099ad91161006f578063ea099ad914610afc578063f2fde38b14610b12578063f87f44b914610b32578063f9f3bfd814610b5257600080fd5b8063d7eb3f3a14610a5e578063d9a7c61d14610a7e578063e8a3d48514610a9e578063e985e9c514610ab357600080fd5b8063c0e72740116100dc578063c0e72740146109d5578063c87b56dd146109ea578063d539139314610a0a578063d547741f14610a3e57600080fd5b8063a217fddf1461096b578063a22cb46514610980578063b88d4fde146109a0578063beb0a416146109c057600080fd5b8063867644d91161018557806391d148541161015457806391d14854146108de578063938e3d7b146108fe57806395d89b411461091e5780639f67756d1461093357600080fd5b8063867644d9146108625780638cbe8d80146108825780638da5cb5b146108a057806390c3f38f146108be57600080fd5b806370a08231116101c157806370a0823114610803578063715018a6146108235780637284e416146108385780638456cb591461084d57600080fd5b80636b87d24c146107bb5780636c0360eb146107d05780636ff314c7146107e557600080fd5b80633ccfd60b116102cc5780634bc46a821161026a57806359748cb21161023957806359748cb21461073a5780635c975abb1461075a5780636352211e1461077b5780636a6278421461079b57600080fd5b80634bc46a82146106c45780634f6ccce7146106e457806355234ec01461070457806355f804b31461071a57600080fd5b806342842e0e116102a657806342842e0e1461065a57806342966c681461067a57806343bc16121461069a5780634771218a146106af57600080fd5b80633ccfd60b1461061a5780633f4ba83a1461062f57806340138ff11461064457600080fd5b806323b872dd116103445780632cc88974116103135780632cc88974146105a55780632f2ff15d146105ba5780632f745c59146105da57806336568abe146105fa57600080fd5b806323b872dd14610501578063248a9ca31461052157806328485586146105515780632a55205a1461056657600080fd5b8063081812fc11610380578063081812fc14610465578063095ea7b31461049d57806317bf72c6146104bf57806318160ddd146104ec57600080fd5b806301ffc9a7146103ea578063031bd4c41461041f57806306fdde031461044357600080fd5b366103e557604080513381523460208201527ffb5cb5fc5900f14be0f619816129d1490c275a13734b28ae77072a2f5d676f57910160405180910390a1005b600080fd5b3480156103f657600080fd5b5061040a610405366004612b5d565b610b72565b60405190151581526020015b60405180910390f35b34801561042b57600080fd5b50610435600f5481565b604051908152602001610416565b34801561044f57600080fd5b50610458610b83565b6040516104169190612bd2565b34801561047157600080fd5b50610485610480366004612be5565b610c15565b6040516001600160a01b039091168152602001610416565b3480156104a957600080fd5b506104bd6104b8366004612c13565b610caf565b005b3480156104cb57600080fd5b506104356104da366004612be5565b60116020526000908152604090205481565b3480156104f857600080fd5b50600a54610435565b34801561050d57600080fd5b506104bd61051c366004612c3f565b610dc4565b34801561052d57600080fd5b5061043561053c366004612be5565b6000908152600c602052604090206001015490565b34801561055d57600080fd5b50600f54610435565b34801561057257600080fd5b50610586610581366004612c80565b610df6565b604080516001600160a01b039093168352602083019190915201610416565b3480156105b157600080fd5b50601454610435565b3480156105c657600080fd5b506104bd6105d5366004612ca2565b610ea2565b3480156105e657600080fd5b506104356105f5366004612c13565b610ec8565b34801561060657600080fd5b506104bd610615366004612ca2565b610f5e565b34801561062657600080fd5b506104bd610fdc565b34801561063b57600080fd5b506104bd611011565b34801561065057600080fd5b5061043560145481565b34801561066657600080fd5b506104bd610675366004612c3f565b61104a565b34801561068657600080fd5b506104bd610695366004612be5565b611065565b3480156106a657600080fd5b506104586110df565b3480156106bb57600080fd5b50601054610435565b3480156106d057600080fd5b506104bd6106df366004612cd2565b61116d565b3480156106f057600080fd5b506104356106ff366004612be5565b6111be565b34801561071057600080fd5b5061043560105481565b34801561072657600080fd5b506104bd610735366004612cfb565b611251565b34801561074657600080fd5b50601354610485906001600160a01b031681565b34801561076657600080fd5b50600e5461040a90600160a01b900460ff1681565b34801561078757600080fd5b50610485610796366004612be5565b611287565b3480156107a757600080fd5b506104356107b6366004612d6d565b6112fe565b3480156107c757600080fd5b506104586113db565b3480156107dc57600080fd5b506104586113e8565b3480156107f157600080fd5b506013546001600160a01b0316610485565b34801561080f57600080fd5b5061043561081e366004612d6d565b6113f5565b34801561082f57600080fd5b506104bd61147c565b34801561084457600080fd5b506104586114b0565b34801561085957600080fd5b506104bd6114bd565b34801561086e57600080fd5b506104bd61087d366004612cd2565b6114fc565b34801561088e57600080fd5b506012546001600160a01b0316610485565b3480156108ac57600080fd5b50600d546001600160a01b0316610485565b3480156108ca57600080fd5b506104bd6108d9366004612cfb565b611534565b3480156108ea57600080fd5b5061040a6108f9366004612ca2565b61156a565b34801561090a57600080fd5b506104bd610919366004612cfb565b611595565b34801561092a57600080fd5b506104586115cb565b34801561093f57600080fd5b50601654610953906001600160601b031681565b6040516001600160601b039091168152602001610416565b34801561097757600080fd5b50610435600081565b34801561098c57600080fd5b506104bd61099b366004612d8a565b6115da565b3480156109ac57600080fd5b506104bd6109bb366004612dd3565b6115e5565b3480156109cc57600080fd5b5061045861161d565b3480156109e157600080fd5b5061045861162a565b3480156109f657600080fd5b50610458610a05366004612be5565b611637565b348015610a1657600080fd5b506104357f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a681565b348015610a4a57600080fd5b506104bd610a59366004612ca2565b61166b565b348015610a6a57600080fd5b50601254610485906001600160a01b031681565b348015610a8a57600080fd5b50610435610a99366004612c13565b611691565b348015610aaa57600080fd5b50610458611785565b348015610abf57600080fd5b5061040a610ace366004612eb3565b6001600160a01b03918216600090815260076020908152604080832093909416825291909152205460ff1690565b348015610b0857600080fd5b5061043560155481565b348015610b1e57600080fd5b506104bd610b2d366004612d6d565b611794565b348015610b3e57600080fd5b506104bd610b4d366004612cfb565b61182c565b348015610b5e57600080fd5b506104bd610b6d366004612cd2565b611862565b6000610b7d8261189a565b92915050565b606060028054610b9290612ee1565b80601f0160208091040260200160405190810160405280929190818152602001828054610bbe90612ee1565b8015610c0b5780601f10610be057610100808354040283529160200191610c0b565b820191906000526020600020905b815481529060010190602001808311610bee57829003601f168201915b5050505050905090565b6000818152600460205260408120546001600160a01b0316610c935760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a20617070726f76656420717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b60648201526084015b60405180910390fd5b506000908152600660205260409020546001600160a01b031690565b6000610cba82611287565b9050806001600160a01b0316836001600160a01b031603610d275760405162461bcd60e51b815260206004820152602160248201527f4552433732313a20617070726f76616c20746f2063757272656e74206f776e656044820152603960f91b6064820152608401610c8a565b336001600160a01b0382161480610d435750610d438133610ace565b610db55760405162461bcd60e51b815260206004820152603860248201527f4552433732313a20617070726f76652063616c6c6572206973206e6f74206f7760448201527f6e6572206e6f7220617070726f76656420666f7220616c6c00000000000000006064820152608401610c8a565b610dbf83836118bf565b505050565b610dcf335b8261192d565b610deb5760405162461bcd60e51b8152600401610c8a90612f15565b610dbf838383611a24565b60008281526001602090815260408083208151808301909252546001600160a01b038116808352600160a01b9091046001600160601b0316928201929092528291610e6b5750604080518082019091526000546001600160a01b0381168252600160a01b90046001600160601b031660208201525b602081015160009061271090610e8a906001600160601b031687612f7c565b610e949190612fb1565b915196919550909350505050565b6000828152600c6020526040902060010154610ebe8133611bcb565b610dbf8383611c2f565b6000610ed3836113f5565b8210610f355760405162461bcd60e51b815260206004820152602b60248201527f455243373231456e756d657261626c653a206f776e657220696e646578206f7560448201526a74206f6620626f756e647360a81b6064820152608401610c8a565b506001600160a01b03919091166000908152600860209081526040808320938352929052205490565b6001600160a01b0381163314610fce5760405162461bcd60e51b815260206004820152602f60248201527f416363657373436f6e74726f6c3a2063616e206f6e6c792072656e6f756e636560448201526e103937b632b9903337b91039b2b63360891b6064820152608401610c8a565b610fd88282611cb5565b5050565b600d546001600160a01b031633146110065760405162461bcd60e51b8152600401610c8a90612fc5565b61100f47611d1c565b565b600d546001600160a01b0316331461103b5760405162461bcd60e51b8152600401610c8a90612fc5565b600e805460ff60a01b19169055565b610dbf838383604051806020016040528060008152506115e5565b61106e33610dc9565b6110d35760405162461bcd60e51b815260206004820152603060248201527f4552433732314275726e61626c653a2063616c6c6572206973206e6f74206f7760448201526f1b995c881b9bdc88185c1c1c9bdd995960821b6064820152608401610c8a565b6110dc81611f15565b50565b601980546110ec90612ee1565b80601f016020809104026020016040519081016040528092919081815260200182805461111890612ee1565b80156111655780601f1061113a57610100808354040283529160200191611165565b820191906000526020600020905b81548152906001019060200180831161114857829003601f168201915b505050505081565b600d546001600160a01b031633146111975760405162461bcd60e51b8152600401610c8a90612fc5565b601680546bffffffffffffffffffffffff19166001600160601b0392909216919091179055565b60006111c9600a5490565b821061122c5760405162461bcd60e51b815260206004820152602c60248201527f455243373231456e756d657261626c653a20676c6f62616c20696e646578206f60448201526b7574206f6620626f756e647360a01b6064820152608401610c8a565b600a828154811061123f5761123f612ffa565b90600052602060002001549050919050565b600d546001600160a01b0316331461127b5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf60188383612aae565b6000818152600460205260408120546001600160a01b031680610b7d5760405162461bcd60e51b815260206004820152602960248201527f4552433732313a206f776e657220717565727920666f72206e6f6e657869737460448201526832b73a103a37b5b2b760b91b6064820152608401610c8a565b60007f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a661132b8133611bcb565b600e54600160a01b900460ff16156113765760405162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d1a5b99c81c185d5cd95960921b6044820152606401610c8a565b6000601054116113bc5760405162461bcd60e51b8152602060048201526011602482015270185b1b081d1bdad95b9cc81b5a5b9d1959607a1b6044820152606401610c8a565b60006113c6611f1e565b90506113d28482612062565b91505b50919050565b601c80546110ec90612ee1565b601880546110ec90612ee1565b60006001600160a01b0382166114605760405162461bcd60e51b815260206004820152602a60248201527f4552433732313a2062616c616e636520717565727920666f7220746865207a65604482015269726f206164647265737360b01b6064820152608401610c8a565b506001600160a01b031660009081526005602052604090205490565b600d546001600160a01b031633146114a65760405162461bcd60e51b8152600401610c8a90612fc5565b61100f600061207c565b601a80546110ec90612ee1565b600d546001600160a01b031633146114e75760405162461bcd60e51b8152600401610c8a90612fc5565b600e805460ff60a01b1916600160a01b179055565b600d546001600160a01b031633146115265760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160601b0316601555565b600d546001600160a01b0316331461155e5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf601a8383612aae565b6000918252600c602090815260408084206001600160a01b0393909316845291905290205460ff1690565b600d546001600160a01b031633146115bf5760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf60178383612aae565b606060038054610b9290612ee1565b610fd83383836120ce565b6115ef338361192d565b61160b5760405162461bcd60e51b8152600401610c8a90612f15565b6116178484848461219c565b50505050565b601b80546110ec90612ee1565b601780546110ec90612ee1565b60606018611644836121cf565b60405160200161165592919061302c565b6040516020818303038152906040529050919050565b6000828152600c60205260409020600101546116878133611bcb565b610dbf8383611cb5565b60007f9f2df0fed2c77648de5860a4cc508cd0818c85b8b8a1ab4ceeef8d981c8956a66116be8133611bcb565b600e54600160a01b900460ff16156117095760405162461bcd60e51b815260206004820152600e60248201526d1b5a5b9d1a5b99c81c185d5cd95960921b6044820152606401610c8a565b611715836127106130f6565b6000818152600460205260409020549092506001600160a01b0316156117745760405162461bcd60e51b8152602060048201526014602482015273151bdad95b88185b1c9958591e481b5a5b9d195960621b6044820152606401610c8a565b61177e8483612062565b5092915050565b606060178054610b9290612ee1565b600d546001600160a01b031633146117be5760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160a01b0381166118235760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401610c8a565b6110dc8161207c565b600d546001600160a01b031633146118565760405162461bcd60e51b8152600401610c8a90612fc5565b610dbf601b8383612aae565b600d546001600160a01b0316331461188c5760405162461bcd60e51b8152600401610c8a90612fc5565b6001600160601b0316601455565b60006001600160e01b03198216637965db0b60e01b1480610b7d5750610b7d826122d0565b600081815260066020526040902080546001600160a01b0319166001600160a01b03841690811790915581906118f482611287565b6001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a45050565b6000818152600460205260408120546001600160a01b03166119a65760405162461bcd60e51b815260206004820152602c60248201527f4552433732313a206f70657261746f7220717565727920666f72206e6f6e657860448201526b34b9ba32b73a103a37b5b2b760a11b6064820152608401610c8a565b60006119b183611287565b9050806001600160a01b0316846001600160a01b031614806119ec5750836001600160a01b03166119e184610c15565b6001600160a01b0316145b80611a1c57506001600160a01b0380821660009081526007602090815260408083209388168352929052205460ff165b949350505050565b826001600160a01b0316611a3782611287565b6001600160a01b031614611a9b5760405162461bcd60e51b815260206004820152602560248201527f4552433732313a207472616e736665722066726f6d20696e636f72726563742060448201526437bbb732b960d91b6064820152608401610c8a565b6001600160a01b038216611afd5760405162461bcd60e51b8152602060048201526024808201527f4552433732313a207472616e7366657220746f20746865207a65726f206164646044820152637265737360e01b6064820152608401610c8a565b611b088383836122db565b611b136000826118bf565b6001600160a01b0383166000908152600560205260408120805460019290611b3c90849061310e565b90915550506001600160a01b0382166000908152600560205260408120805460019290611b6a9084906130f6565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b0386811691821790925591518493918716917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91a4505050565b611bd5828261156a565b610fd857611bed816001600160a01b031660146122e6565b611bf88360206122e6565b604051602001611c09929190613125565b60408051601f198184030181529082905262461bcd60e51b8252610c8a91600401612bd2565b611c39828261156a565b610fd8576000828152600c602090815260408083206001600160a01b03851684529091529020805460ff19166001179055611c713390565b6001600160a01b0316816001600160a01b0316837f2f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0d60405160405180910390a45050565b611cbf828261156a565b15610fd8576000828152600c602090815260408083206001600160a01b0385168085529252808320805460ff1916905551339285917ff6391f5c32d9c69d2a47ea670b442974b53935d1edc7fd64eb21e047a839171b9190a45050565b80156110dc576000612710600e60009054906101000a90046001600160a01b03166001600160a01b031663d672131b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015611d7c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611da0919061319a565b611daa9084612f7c565b611db49190612fb1565b9050600e60009054906101000a90046001600160a01b03166001600160a01b0316637dafc0d36040518163ffffffff1660e01b81526004016020604051808303816000875af1158015611e0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e2f91906131b3565b6001600160a01b03166108fc829081150290604051600060405180830381858888f19350505050158015611e67573d6000803e3d6000fd5b50600061271060155484611e7b9190612f7c565b611e859190612fb1565b90508015611ec9576013546040516001600160a01b039091169082156108fc029083906000818181858888f19350505050158015611ec7573d6000803e3d6000fd5b505b6012546001600160a01b03166108fc82611ee3858761310e565b611eed919061310e565b6040518115909202916000818181858888f19350505050158015611617573d6000803e3d6000fd5b6110dc81612489565b600e546010546040516329e5d83160e01b8152600481019190915242602482015260009182916001600160a01b03909116906329e5d83190604401602060405180830381865afa158015611f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f9a919061319a565b9050600060105482611fac91906131d0565b60008181526011602052604090205490915015611fd757600081815260116020526040902054611fd9565b805b9250601160006001601054611fee919061310e565b81526020019081526020016000205460001461202b57601160006001601054612017919061310e565b81526020019081526020016000205461203a565b600160105461203a919061310e565b6000828152601160205260409020556010546120589060019061310e565b6010555090919050565b610fd88282604051806020016040528060008152506124a3565b600d80546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b816001600160a01b0316836001600160a01b03160361212f5760405162461bcd60e51b815260206004820152601960248201527f4552433732313a20617070726f766520746f2063616c6c6572000000000000006044820152606401610c8a565b6001600160a01b03838116600081815260076020908152604080832094871680845294825291829020805460ff191686151590811790915591519182527f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31910160405180910390a3505050565b6121a7848484611a24565b6121b3848484846124d6565b6116175760405162461bcd60e51b8152600401610c8a906131e4565b6060816000036121f65750506040805180820190915260018152600360fc1b602082015290565b8160005b8115612220578061220a81613236565b91506122199050600a83612fb1565b91506121fa565b60008167ffffffffffffffff81111561223b5761223b612dbd565b6040519080825280601f01601f191660200182016040528015612265576020820181803683370190505b5090505b8415611a1c5761227a60018361310e565b9150612287600a866131d0565b6122929060306130f6565b60f81b8183815181106122a7576122a7612ffa565b60200101906001600160f81b031916908160001a9053506122c9600a86612fb1565b9450612269565b6000610b7d826125d7565b610dbf8383836125fc565b606060006122f5836002612f7c565b6123009060026130f6565b67ffffffffffffffff81111561231857612318612dbd565b6040519080825280601f01601f191660200182016040528015612342576020820181803683370190505b509050600360fc1b8160008151811061235d5761235d612ffa565b60200101906001600160f81b031916908160001a905350600f60fb1b8160018151811061238c5761238c612ffa565b60200101906001600160f81b031916908160001a90535060006123b0846002612f7c565b6123bb9060016130f6565b90505b6001811115612433576f181899199a1a9b1b9c1cb0b131b232b360811b85600f16601081106123ef576123ef612ffa565b1a60f81b82828151811061240557612405612ffa565b60200101906001600160f81b031916908160001a90535060049490941c9361242c8161324f565b90506123be565b5083156124825760405162461bcd60e51b815260206004820181905260248201527f537472696e67733a20686578206c656e67746820696e73756666696369656e746044820152606401610c8a565b9392505050565b612492816126b4565b600090815260016020526040812055565b6124ad838361275b565b6124ba60008484846124d6565b610dbf5760405162461bcd60e51b8152600401610c8a906131e4565b60006001600160a01b0384163b156125cc57604051630a85bd0160e11b81526001600160a01b0385169063150b7a029061251a903390899088908890600401613266565b6020604051808303816000875af1925050508015612555575060408051601f3d908101601f19168201909252612552918101906132a3565b60015b6125b2573d808015612583576040519150601f19603f3d011682016040523d82523d6000602084013e612588565b606091505b5080516000036125aa5760405162461bcd60e51b8152600401610c8a906131e4565b805181602001fd5b6001600160e01b031916630a85bd0160e11b149050611a1c565b506001949350505050565b60006001600160e01b0319821663780e9d6360e01b1480610b7d5750610b7d826128a9565b6001600160a01b0383166126575761265281600a80546000838152600b60205260408120829055600182018355919091527fc65a7bb8d6351c1cf70c95a316cc6a92839c986682d98bc35f958f4883f9d2a80155565b61267a565b816001600160a01b0316836001600160a01b03161461267a5761267a83826128e9565b6001600160a01b03821661269157610dbf81612986565b826001600160a01b0316826001600160a01b031614610dbf57610dbf8282612a35565b60006126bf82611287565b90506126cd816000846122db565b6126d86000836118bf565b6001600160a01b038116600090815260056020526040812080546001929061270190849061310e565b909155505060008281526004602052604080822080546001600160a01b0319169055518391906001600160a01b038416907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908390a45050565b6001600160a01b0382166127b15760405162461bcd60e51b815260206004820181905260248201527f4552433732313a206d696e7420746f20746865207a65726f20616464726573736044820152606401610c8a565b6000818152600460205260409020546001600160a01b0316156128165760405162461bcd60e51b815260206004820152601c60248201527f4552433732313a20746f6b656e20616c7265616479206d696e746564000000006044820152606401610c8a565b612822600083836122db565b6001600160a01b038216600090815260056020526040812080546001929061284b9084906130f6565b909155505060008181526004602052604080822080546001600160a01b0319166001600160a01b03861690811790915590518392907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef908290a45050565b60006001600160e01b031982166380ac58cd60e01b14806128da57506001600160e01b03198216635b5e139f60e01b145b80610b7d5750610b7d82612a79565b600060016128f6846113f5565b612900919061310e565b600083815260096020526040902054909150808214612953576001600160a01b03841660009081526008602090815260408083208584528252808320548484528184208190558352600990915290208190555b5060009182526009602090815260408084208490556001600160a01b039094168352600881528383209183525290812055565b600a546000906129989060019061310e565b6000838152600b6020526040812054600a80549394509092849081106129c0576129c0612ffa565b9060005260206000200154905080600a83815481106129e1576129e1612ffa565b6000918252602080832090910192909255828152600b9091526040808220849055858252812055600a805480612a1957612a196132c0565b6001900381819060005260206000200160009055905550505050565b6000612a40836113f5565b6001600160a01b039093166000908152600860209081526040808320868452825280832085905593825260099052919091209190915550565b60006001600160e01b0319821663152a902d60e11b1480610b7d57506301ffc9a760e01b6001600160e01b0319831614610b7d565b828054612aba90612ee1565b90600052602060002090601f016020900481019282612adc5760008555612b22565b82601f10612af55782800160ff19823516178555612b22565b82800160010185558215612b22579182015b82811115612b22578235825591602001919060010190612b07565b50612b2e929150612b32565b5090565b5b80821115612b2e5760008155600101612b33565b6001600160e01b0319811681146110dc57600080fd5b600060208284031215612b6f57600080fd5b813561248281612b47565b60005b83811015612b95578181015183820152602001612b7d565b838111156116175750506000910152565b60008151808452612bbe816020860160208601612b7a565b601f01601f19169290920160200192915050565b6020815260006124826020830184612ba6565b600060208284031215612bf757600080fd5b5035919050565b6001600160a01b03811681146110dc57600080fd5b60008060408385031215612c2657600080fd5b8235612c3181612bfe565b946020939093013593505050565b600080600060608486031215612c5457600080fd5b8335612c5f81612bfe565b92506020840135612c6f81612bfe565b929592945050506040919091013590565b60008060408385031215612c9357600080fd5b50508035926020909101359150565b60008060408385031215612cb557600080fd5b823591506020830135612cc781612bfe565b809150509250929050565b600060208284031215612ce457600080fd5b81356001600160601b038116811461248257600080fd5b60008060208385031215612d0e57600080fd5b823567ffffffffffffffff80821115612d2657600080fd5b818501915085601f830112612d3a57600080fd5b813581811115612d4957600080fd5b866020828501011115612d5b57600080fd5b60209290920196919550909350505050565b600060208284031215612d7f57600080fd5b813561248281612bfe565b60008060408385031215612d9d57600080fd5b8235612da881612bfe565b915060208301358015158114612cc757600080fd5b634e487b7160e01b600052604160045260246000fd5b60008060008060808587031215612de957600080fd5b8435612df481612bfe565b93506020850135612e0481612bfe565b925060408501359150606085013567ffffffffffffffff80821115612e2857600080fd5b818701915087601f830112612e3c57600080fd5b813581811115612e4e57612e4e612dbd565b604051601f8201601f19908116603f01168101908382118183101715612e7657612e76612dbd565b816040528281528a6020848701011115612e8f57600080fd5b82602086016020830137600060208483010152809550505050505092959194509250565b60008060408385031215612ec657600080fd5b8235612ed181612bfe565b91506020830135612cc781612bfe565b600181811c90821680612ef557607f821691505b6020821081036113d557634e487b7160e01b600052602260045260246000fd5b60208082526031908201527f4552433732313a207472616e736665722063616c6c6572206973206e6f74206f6040820152701ddb995c881b9bdc88185c1c1c9bdd9959607a1b606082015260800190565b634e487b7160e01b600052601160045260246000fd5b6000816000190483118215151615612f9657612f96612f66565b500290565b634e487b7160e01b600052601260045260246000fd5b600082612fc057612fc0612f9b565b500490565b6020808252818101527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572604082015260600190565b634e487b7160e01b600052603260045260246000fd5b60008151613022818560208601612b7a565b9290920192915050565b600080845481600182811c91508083168061304857607f831692505b6020808410820361306757634e487b7160e01b86526022600452602486fd5b81801561307b576001811461308c576130b9565b60ff198616895284890196506130b9565b60008b81526020902060005b868110156130b15781548b820152908501908301613098565b505084890196505b5050505050506130ed6130dc6130d683602f60f81b815260010190565b86613010565b64173539b7b760d91b815260050190565b95945050505050565b6000821982111561310957613109612f66565b500190565b60008282101561312057613120612f66565b500390565b7f416363657373436f6e74726f6c3a206163636f756e742000000000000000000081526000835161315d816017850160208801612b7a565b7001034b99036b4b9b9b4b733903937b6329607d1b601791840191820152835161318e816028840160208801612b7a565b01602801949350505050565b6000602082840312156131ac57600080fd5b5051919050565b6000602082840312156131c557600080fd5b815161248281612bfe565b6000826131df576131df612f9b565b500690565b60208082526032908201527f4552433732313a207472616e7366657220746f206e6f6e20455243373231526560408201527131b2b4bb32b91034b6b83632b6b2b73a32b960711b606082015260800190565b60006001820161324857613248612f66565b5060010190565b60008161325e5761325e612f66565b506000190190565b6001600160a01b038581168252841660208201526040810183905260806060820181905260009061329990830184612ba6565b9695505050505050565b6000602082840312156132b557600080fd5b815161248281612b47565b634e487b7160e01b600052603160045260246000fdfea26469706673582212207fdfa9d0ebdce4a373826d0606b6cfe6dcaa4ae2c0b7f4897eb6ce76cb43024364736f6c634300080d0033

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

00000000000000000000000016213f846a222da24eb4807a6cc5d0a5344994d60000000000000000000000007f6ddf832f4b714a1264893543cb2705c962fa37

-----Decoded View---------------
Arg [0] : coreAddress (address): 0x16213f846a222DA24eB4807a6cC5D0A5344994D6
Arg [1] : shopAddress (address): 0x7F6ddF832F4B714a1264893543CB2705C962fa37

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 00000000000000000000000016213f846a222da24eb4807a6cc5d0a5344994d6
Arg [1] : 0000000000000000000000007f6ddf832f4b714a1264893543cb2705c962fa37


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.