Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 25 from a total of 1,905 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Burn To Mint Blo... | 16115707 | 763 days ago | IN | 0 ETH | 0.01414977 | ||||
Burn To Mint Blo... | 16115704 | 763 days ago | IN | 0 ETH | 0.01459186 | ||||
Burn To Mint Blo... | 16115700 | 763 days ago | IN | 0 ETH | 0.01468117 | ||||
Burn To Mint Blo... | 16115697 | 763 days ago | IN | 0 ETH | 0.01489083 | ||||
Burn To Mint Blo... | 16115693 | 763 days ago | IN | 0 ETH | 0.0134003 | ||||
Burn To Mint Blo... | 16115690 | 763 days ago | IN | 0 ETH | 0.01584758 | ||||
Burn To Mint Blo... | 16115686 | 763 days ago | IN | 0 ETH | 0.01440072 | ||||
Burn To Mint Blo... | 16115680 | 763 days ago | IN | 0 ETH | 0.01541521 | ||||
Burn To Mint Blo... | 16115677 | 763 days ago | IN | 0 ETH | 0.01508616 | ||||
Burn To Mint Blo... | 16115673 | 763 days ago | IN | 0 ETH | 0.01547307 | ||||
Burn To Mint Blo... | 16115668 | 763 days ago | IN | 0 ETH | 0.01432617 | ||||
Burn To Mint Blo... | 16115665 | 763 days ago | IN | 0 ETH | 0.01537332 | ||||
Fill Empty Token | 16115587 | 763 days ago | IN | 0 ETH | 0.03409483 | ||||
Mint Panel | 16114091 | 763 days ago | IN | 0 ETH | 0.00900985 | ||||
Mint Panel | 16114025 | 763 days ago | IN | 0 ETH | 0.00519326 | ||||
Mint Panel | 16113718 | 763 days ago | IN | 0 ETH | 0.00673481 | ||||
Fill Empty Token | 16113569 | 763 days ago | IN | 0 ETH | 0.00405073 | ||||
Deconstruct Pane... | 16113563 | 763 days ago | IN | 0 ETH | 0.00087065 | ||||
Fill Empty Token | 16113558 | 763 days ago | IN | 0 ETH | 0.00442721 | ||||
Deconstruct Pane... | 16113528 | 763 days ago | IN | 0 ETH | 0.00078637 | ||||
Mint Panel | 16113394 | 763 days ago | IN | 0 ETH | 0.00604479 | ||||
Mint Panel | 16113145 | 763 days ago | IN | 0 ETH | 0.00652598 | ||||
Mint Panel | 16110140 | 763 days ago | IN | 0 ETH | 0.00544772 | ||||
Fill Empty Token | 16107620 | 764 days ago | IN | 0 ETH | 0.00440984 | ||||
Burn To Mint Blo... | 16107496 | 764 days ago | IN | 0 ETH | 0.01345221 |
Latest 25 internal transactions (View All)
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
13493464 | 1167 days ago | 639.5 ETH | ||||
13487664 | 1168 days ago | 0.1 ETH | ||||
13487662 | 1168 days ago | 20 wei | ||||
13487659 | 1168 days ago | 0.1 ETH | ||||
13487659 | 1168 days ago | 20 wei | ||||
13487658 | 1168 days ago | 20 wei | ||||
13487655 | 1168 days ago | 20 wei | ||||
13487655 | 1168 days ago | 20 wei | ||||
13487651 | 1168 days ago | 40 wei | ||||
13487650 | 1168 days ago | 0.25 ETH | ||||
13487649 | 1168 days ago | 20 wei | ||||
13487647 | 1168 days ago | 20 wei | ||||
13487647 | 1168 days ago | 20 wei | ||||
13487644 | 1168 days ago | 0.05 ETH | ||||
13487642 | 1168 days ago | 20 wei | ||||
13487641 | 1168 days ago | 40 wei | ||||
13487640 | 1168 days ago | 20 wei | ||||
13487639 | 1168 days ago | 20 wei | ||||
13487639 | 1168 days ago | 20 wei | ||||
13487637 | 1168 days ago | 20 wei | ||||
13487635 | 1168 days ago | 0.05 ETH | ||||
13487635 | 1168 days ago | 20 wei | ||||
13487634 | 1168 days ago | 20 wei | ||||
13487633 | 1168 days ago | 20 wei | ||||
13487632 | 1168 days ago | 20 wei |
Loading...
Loading
Contract Name:
TilesMinter
Compiler Version
v0.8.4+commit.c7e474f2
Optimization Enabled:
No with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
//SPDX-License-Identifier: Unlicense pragma solidity ^0.8.0; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "./TilesBlocksCore.sol"; import "./TilesPanelsCore.sol"; contract TilesMinter is Pausable { uint256 public constant BLOCK_PRICE = 5*10**16; //price 0.05 eth uint256 public constant EMPTY_PANEL_PRICE_2 = 0; uint256 public constant EMPTY_PANEL_PRICE_6 = 0; uint256 public constant EMPTY_PANEL_PRICE_4 = 1*10**18; uint256 public constant EMPTY_PANEL_PRICE_9 = 15*10**17; uint256 public constant EMPTY_PANEL_PRICE_16 = 2*10**18; uint256 public constant EMPTY_PANEL_PRICE_25 = 4*10**18; uint256 public constant EMPTY_PANEL_PRICE_36 = 8*10**18; address internal coreBlocksAddress; address internal corePanelsAddress; address public adminAddress; address internal framAddress; address internal pulsAddress; bool public panelMintStarted = false; uint256 public panelMintStartBlock; uint256 public panelBlockLimit = 5*60*24*365; //12 months using SafeMath for uint256; modifier whenNotPausedOrIsAdmin() { require(!paused() || _msgSender() == adminAddress, "Pausable: paused"); _; } modifier onlyAdmin() { require(_msgSender() == adminAddress, "Only the admin can do this"); _; } constructor(address _coreBlocksAddress, address _corePanelsAddress, address _admin, address _framAddress, address _pulsAddress) { coreBlocksAddress = _coreBlocksAddress; corePanelsAddress = _corePanelsAddress; framAddress = _framAddress; pulsAddress = _pulsAddress; adminAddress = _admin; _pause(); } function pause() public onlyAdmin { _pause(); } function unpause() public onlyAdmin { _unpause(); } function startPanelMint() public onlyAdmin { panelMintStarted = true; panelMintStartBlock = block.number; } function setPanelBlockLimit(uint256 _value) public onlyAdmin { panelBlockLimit = _value; } function _isValidLength(uint256 len) internal pure returns(bool) { return (len == 2 || len == 4 || len == 6 || len == 9 || len == 16 || len == 25 || len == 36); } function getEmptyPanelPrice(uint _size) public pure returns(uint256) { if (_size == 2) return EMPTY_PANEL_PRICE_2; if (_size == 4) return EMPTY_PANEL_PRICE_4; if (_size == 6) return EMPTY_PANEL_PRICE_6; if (_size == 9) return EMPTY_PANEL_PRICE_9; if (_size == 16) return EMPTY_PANEL_PRICE_16; if (_size == 25) return EMPTY_PANEL_PRICE_25; if (_size == 36) return EMPTY_PANEL_PRICE_36; return 0; } function mintBlocks(uint256 n) payable external whenNotPausedOrIsAdmin { require(n<=20, "You can only mint up to 20 in the same transaction"); uint256 totalMaxBlocks = TilesBlocksCore(coreBlocksAddress).genesisMintLimit(); uint256 totalMints = TilesBlocksCore(coreBlocksAddress).totalMints(); require(totalMints < totalMaxBlocks, "All Blocks were already minted"); if (totalMaxBlocks - totalMints < 20) n = totalMaxBlocks - totalMints; uint price = BLOCK_PRICE.mul(n); require (msg.value >= price, "Insuficient ether sent"); uint returnAmount = msg.value.sub(price); TilesBlocksCore(coreBlocksAddress).mintGenesis(msg.sender, n); if (returnAmount > 0) payable(msg.sender).transfer(returnAmount); } function burnToMintBlocks(uint256[] memory tokenIds) external whenNotPausedOrIsAdmin { uint256 totalMaxBlocks = TilesBlocksCore(coreBlocksAddress).genesisMintLimit(); uint256 totalMints = TilesBlocksCore(coreBlocksAddress).totalMints(); require(totalMints >= totalMaxBlocks, "Burns can only start after all Blocks are minted"); TilesBlocksCore(coreBlocksAddress).burnToMint(tokenIds, msg.sender); } function isEmergence(address user) public view returns (bool) { return IERC721(pulsAddress).balanceOf(user) > 0 || IERC721(framAddress).balanceOf(user) > 0; } function mintPanel(string memory _name, string memory _desc, uint16 _size, uint256[] memory _blocksTokenIds) payable external whenNotPausedOrIsAdmin { require(block.number > panelMintStartBlock + 10 || _blocksTokenIds.length == 0, " In the first 10 blocks, you can only mint empty panels"); require(_isValidLength(_size), "Invalid size"); require(panelMintStarted, "Panel mint hasn't started"); require(block.number < panelMintStartBlock+panelBlockLimit, "Mint period is over"); require(validateString(_name, 36), "Name is invalid"); require(validateString(_desc, 255), "Description is invalid"); if (_size == _blocksTokenIds.length) { if(_size == 2) require(msg.sender == adminAddress, "Only the owner can mint 2x1 Panels"); if(_size == 6) require(isEmergence(msg.sender) || msg.sender == adminAddress, "Only Emergence holders can mint 3x2 Panels"); // all verifications are done in the Panel contract TilesPanelsCore(corePanelsAddress).mintGenesis(msg.sender, _name, _desc, _size, _blocksTokenIds); require (msg.value == 0, "no payment needed"); } else if (_blocksTokenIds.length == 0) { require(_size != 6 && _size != 2, "2x1 and 3x2 Panels cannot be empty"); uint price = getEmptyPanelPrice(_size); require (msg.value == price, "Wrong ether ammout"); TilesPanelsCore(corePanelsAddress).mintGenesis(msg.sender, _name, _desc, _size, _blocksTokenIds); } else require (_size == _blocksTokenIds.length, "Size differs from blocks count. Partial Panels not allowed"); } function deconstructPanel(uint256 _tokenId) external whenNotPausedOrIsAdmin { require(msg.sender == TilesPanelsCore(corePanelsAddress).ownerOf(_tokenId), "Caller is not the owner"); require(block.number < panelMintStartBlock+panelBlockLimit, "Deconstruct period is over"); TilesPanelsCore(corePanelsAddress).deconstruct(_tokenId); } function fillEmptyToken(uint256 _tokenId, string memory _name, string memory _desc, uint256[] memory _blocksTokenIds) external whenNotPausedOrIsAdmin { require(block.number < panelMintStartBlock+panelBlockLimit, "Fill period is over"); require(msg.sender == TilesPanelsCore(corePanelsAddress).ownerOf(_tokenId), "Caller is not the owner"); require(validateString(_name, 36), "Name is invalid"); require(validateString(_desc, 255), "Description is invalid"); TilesPanelsCore(corePanelsAddress).fillEmptyToken(_tokenId, _name, _desc, _blocksTokenIds); } function withdrawEther() external onlyAdmin { uint balance = address(this).balance; payable(msg.sender).transfer(balance); } function validateString(string memory str, uint16 maxChars) public pure returns (bool){ bytes memory b = bytes(str); if(b.length == 0) return true; if(b.length > maxChars) return false; // Cannot be longer than maxChars characters if(b[0] == 0x20) return false; // Leading space if (b[b.length - 1] == 0x20) return false; // Trailing space bytes1 lastChar = b[0]; for(uint i; i<b.length; i++){ bytes1 char = b[i]; if (char == 0x20 && lastChar == 0x20) return false; // Cannot contain continous spaces if(char == 0x3E || char == 0x3C) return false; lastChar = char; } return true; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // CAUTION // This version of SafeMath should only be used with Solidity 0.8 or later, // because it relies on the compiler's built in overflow checks. /** * @dev Wrappers over Solidity's arithmetic operations. * * NOTE: `SafeMath` is no longer needed starting with Solidity 0.8. The compiler * now has built in overflow checking. */ library SafeMath { /** * @dev Returns the addition of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { uint256 c = a + b; if (c < a) return (false, 0); return (true, c); } } /** * @dev Returns the substraction of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b > a) return (false, 0); return (true, a - b); } } /** * @dev Returns the multiplication of two unsigned integers, with an overflow flag. * * _Available since v3.4._ */ function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { // Gas optimization: this is cheaper than requiring 'a' not being zero, but the // benefit is lost if 'b' is also tested. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 if (a == 0) return (true, 0); uint256 c = a * b; if (c / a != b) return (false, 0); return (true, c); } } /** * @dev Returns the division of two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a / b); } } /** * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. * * _Available since v3.4._ */ function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { unchecked { if (b == 0) return (false, 0); return (true, a % b); } } /** * @dev Returns the addition of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `+` operator. * * Requirements: * * - Addition cannot overflow. */ function add(uint256 a, uint256 b) internal pure returns (uint256) { return a + b; } /** * @dev Returns the subtraction of two unsigned integers, reverting on * overflow (when the result is negative). * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub(uint256 a, uint256 b) internal pure returns (uint256) { return a - b; } /** * @dev Returns the multiplication of two unsigned integers, reverting on * overflow. * * Counterpart to Solidity's `*` operator. * * Requirements: * * - Multiplication cannot overflow. */ function mul(uint256 a, uint256 b) internal pure returns (uint256) { return a * b; } /** * @dev Returns the integer division of two unsigned integers, reverting on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. * * Requirements: * * - The divisor cannot be zero. */ function div(uint256 a, uint256 b) internal pure returns (uint256) { return a / b; } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting when dividing by zero. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod(uint256 a, uint256 b) internal pure returns (uint256) { return a % b; } /** * @dev Returns the subtraction of two unsigned integers, reverting with custom message on * overflow (when the result is negative). * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {trySub}. * * Counterpart to Solidity's `-` operator. * * Requirements: * * - Subtraction cannot overflow. */ function sub( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b <= a, errorMessage); return a - b; } } /** * @dev Returns the integer division of two unsigned integers, reverting with custom message on * division by zero. The result is rounded towards zero. * * Counterpart to Solidity's `/` operator. Note: this function uses a * `revert` opcode (which leaves remaining gas untouched) while Solidity * uses an invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function div( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a / b; } } /** * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo), * reverting with custom message when dividing by zero. * * CAUTION: This function is deprecated because it requires allocating memory for the error * message unnecessarily. For custom revert reasons use {tryMod}. * * Counterpart to Solidity's `%` operator. This function uses a `revert` * opcode (which leaves remaining gas untouched) while Solidity uses an * invalid opcode to revert (consuming all remaining gas). * * Requirements: * * - The divisor cannot be zero. */ function mod( uint256 a, uint256 b, string memory errorMessage ) internal pure returns (uint256) { unchecked { require(b > 0, errorMessage); return a % b; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.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 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 { 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 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 granted `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}. * ==== */ 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); } function _grantRole(bytes32 role, address account) private { if (!hasRole(role, account)) { _roles[role].members[account] = true; emit RoleGranted(role, account, _msgSender()); } } function _revokeRole(bytes32 role, address account) private { if (hasRole(role, account)) { _roles[role].members[account] = false; emit RoleRevoked(role, account, _msgSender()); } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which allows children to implement an emergency stop * mechanism that can be triggered by an authorized account. * * This module is used through inheritance. It will make available the * modifiers `whenNotPaused` and `whenPaused`, which can be applied to * the functions of your contract. Note that they will not be pausable by * simply including this module, only once the modifiers are put in place. */ abstract contract Pausable is Context { /** * @dev Emitted when the pause is triggered by `account`. */ event Paused(address account); /** * @dev Emitted when the pause is lifted by `account`. */ event Unpaused(address account); bool private _paused; /** * @dev Initializes the contract in unpaused state. */ constructor() { _paused = false; } /** * @dev Returns true if the contract is paused, and false otherwise. */ function paused() public view virtual returns (bool) { return _paused; } /** * @dev Modifier to make a function callable only when the contract is not paused. * * Requirements: * * - The contract must not be paused. */ modifier whenNotPaused() { require(!paused(), "Pausable: paused"); _; } /** * @dev Modifier to make a function callable only when the contract is paused. * * Requirements: * * - The contract must be paused. */ modifier whenPaused() { require(paused(), "Pausable: not paused"); _; } /** * @dev Triggers stopped state. * * Requirements: * * - The contract must not be paused. */ function _pause() internal virtual whenNotPaused { _paused = true; emit Paused(_msgSender()); } /** * @dev Returns to normal state. * * Requirements: * * - The contract must be paused. */ function _unpause() internal virtual whenPaused { _paused = false; emit Unpaused(_msgSender()); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../../utils/introspection/IERC165.sol"; /** * @dev Required interface of an ERC721 compliant contract. */ interface IERC721 is IERC165 { /** * @dev Emitted when `tokenId` token is transferred from `from` to `to`. */ event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables `approved` to manage the `tokenId` token. */ event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId); /** * @dev Emitted when `owner` enables or disables (`approved`) `operator` to manage all of its assets. */ event ApprovalForAll(address indexed owner, address indexed operator, bool approved); /** * @dev Returns the number of tokens in ``owner``'s account. */ function balanceOf(address owner) external view returns (uint256 balance); /** * @dev Returns the owner of the `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function ownerOf(uint256 tokenId) external view returns (address owner); /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be have been allowed to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Transfers `tokenId` token from `from` to `to`. * * WARNING: Usage of this method is discouraged, use {safeTransferFrom} whenever possible. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * * Emits a {Transfer} event. */ function transferFrom( address from, address to, uint256 tokenId ) external; /** * @dev Gives permission to `to` to transfer `tokenId` token to another account. * The approval is cleared when the token is transferred. * * Only a single account can be approved at a time, so approving the zero address clears previous approvals. * * Requirements: * * - The caller must own the token or be an approved operator. * - `tokenId` must exist. * * Emits an {Approval} event. */ function approve(address to, uint256 tokenId) external; /** * @dev Returns the account approved for `tokenId` token. * * Requirements: * * - `tokenId` must exist. */ function getApproved(uint256 tokenId) external view returns (address operator); /** * @dev Approve or remove `operator` as an operator for the caller. * Operators can call {transferFrom} or {safeTransferFrom} for any token owned by the caller. * * Requirements: * * - The `operator` cannot be the caller. * * Emits an {ApprovalForAll} event. */ function setApprovalForAll(address operator, bool _approved) external; /** * @dev Returns if the `operator` is allowed to manage all of the assets of `owner`. * * See {setApprovalForAll} */ function isApprovedForAll(address owner, address operator) external view returns (bool); /** * @dev Safely transfers `tokenId` token from `from` to `to`. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If the caller is not `from`, it must be approved to move this token by either {approve} or {setApprovalForAll}. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes calldata data ) external; }
//SPDX-License-Identifier: Unlicense pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; contract TilesBlocksCore is ERC721Enumerable, AccessControl, Ownable { using SafeMath for uint256; bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE"); string public scriptArweave; string public scriptIPFS; mapping(uint256 => uint256) public tokenHash; uint32 public genesisMintLimit = 10000; uint256 public totalMints = 0; string internal _currentBaseURI = ""; event Mint(uint256 tokenId); constructor(address adminAddress, address ownerAddress, string memory baseURI) ERC721("Tiles Blocks", "TILB") { _currentBaseURI = baseURI; _setupRole(DEFAULT_ADMIN_ROLE, adminAddress); transferOwnership(ownerAddress); } function setGenesisMintLimit(uint32 _mintLimit) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); genesisMintLimit = _mintLimit; } function _baseURI() internal view virtual override returns (string memory) { return _currentBaseURI; } function setBaseURI(string memory baseURI) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); _currentBaseURI = baseURI; } function setScriptIPFS(string memory _scriptIPFS) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); scriptIPFS = _scriptIPFS; } function setScriptArweave(string memory _scriptArweave) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); scriptArweave = _scriptArweave; } function _generateRandomHash() internal view returns (bytes32) { return keccak256(abi.encode(blockhash(block.number-1), block.coinbase, totalMints)); } function _generateNewSeed() internal view returns (uint256) { bytes32 hashRandom = _generateRandomHash(); uint256 value = uint8(hashRandom[20]); value = value << 8; value = value + uint8(hashRandom[21]); value = value << 24; value = value.add(totalMints); return uint256(value); } function mintGenesis(address _receiver, uint256 qty) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); require(totalMints + qty <= genesisMintLimit, "Total genesis mint limit reached"); for (uint256 i = 0; i<qty; i++) { _mint(_receiver); } } function _mint(address _receiver) internal { totalMints = totalMints + 1; uint256 token = totalMints; tokenHash[token] = _generateNewSeed(); _safeMint(_receiver, token); emit Mint(token); } function burnToMint(uint256[] memory tokenIds, address _owner) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); //require(totalMints >= genesisMintLimit, "Burns can only start after all Blocks are minted"); require(tokenIds.length < 10, "Total burn limit is 9"); for (uint8 i = 0; i < tokenIds.length; i++) { require(_owner == ownerOf(tokenIds[i]), "Only the owner can burn pieces"); _burn(tokenIds[i]); } for (uint8 i = 0; i < tokenIds.length - 1; i++) { _mint(_owner); } } function burn(uint256 tokenId) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); _burn(tokenId); } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721Enumerable, AccessControl) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } function withdrawEther() public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); uint balance = address(this).balance; payable(msg.sender).transfer(balance); } }
//SPDX-License-Identifier: Unlicense pragma solidity ^0.8.0; import "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import "@openzeppelin/contracts/utils/math/SafeMath.sol"; import "@openzeppelin/contracts/access/AccessControl.sol"; import "@openzeppelin/contracts/access/Ownable.sol"; import "@openzeppelin/contracts/token/ERC721/IERC721.sol"; import "./TilesBlocksCore.sol"; contract TilesPanelsCore is ERC721Enumerable, AccessControl, Ownable { struct Panel { string name; string description; uint16 size; uint16 degradationLevel; bool isEmpty; } uint256 constant TOTAL_MAX_2 = 50; uint256 constant TOTAL_MAX_4 = 500; uint256 constant TOTAL_MAX_6 = 200; uint256 constant TOTAL_MAX_9 = 250; uint256 constant TOTAL_MAX_16 = 80; uint256 constant TOTAL_MAX_25 = 20; uint256 constant TOTAL_MAX_36 = 5; using SafeMath for uint256; bytes32 public constant MINTER_ROLE = keccak256("MINTER_ROLE"); string public scriptArweave; string public scriptIPFS; address internal BLOCKS_CONTRACT; mapping (uint256 => uint256[]) public tokenBlocks; mapping (uint256 => Panel) public tokens; mapping (uint256 => uint256) public totalMints; uint256 public totalGlobalMints = 0; string internal _currentBaseURI = ""; event PanelCreated (uint _tokenId, uint256[] _blocksTokenIds); event PanelDeconstructed (uint _tokenId); constructor(address adminAddress, address ownerAddress, string memory baseURI, address blocks_contract) ERC721("Tiles Panels", "TILP") { _currentBaseURI = baseURI; _setupRole(DEFAULT_ADMIN_ROLE, adminAddress); BLOCKS_CONTRACT = blocks_contract; transferOwnership(ownerAddress); } function _baseURI() internal view virtual override returns (string memory) { return _currentBaseURI; } function setBaseURI(string memory baseURI) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); _currentBaseURI = baseURI; } function setScriptIPFS(string memory _scriptIPFS) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); scriptIPFS = _scriptIPFS; } function setScriptArweave(string memory _scriptArweave) public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); scriptArweave = _scriptArweave; } function _isValidLength(uint256 len) internal pure returns(bool) { return (len == 2 || len == 4 || len == 6 || len == 9 || len == 16 || len == 25 || len == 36); } function _checkTotalMints(uint256 size) internal view returns(bool) { if(size == 2) { return totalMints[size] < TOTAL_MAX_2; } if(size == 4) { return totalMints[size] < TOTAL_MAX_4; } else if(size == 6) { return totalMints[size] < TOTAL_MAX_6; } else if(size == 9) { return totalMints[size] < TOTAL_MAX_9; } else if(size == 16) { return totalMints[size] < TOTAL_MAX_16; } else if(size == 25) { return totalMints[size] < TOTAL_MAX_25; } else if(size == 36) { return totalMints[size] < TOTAL_MAX_36; } return false; } function deconstruct(uint256 _tokenId) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); require(tokenBlocks[_tokenId].length > 0, "Panel is empty"); delete tokenBlocks[_tokenId]; if (tokens[_tokenId].degradationLevel < 4) tokens[_tokenId].degradationLevel++; tokens[_tokenId].name = ''; tokens[_tokenId].description = ''; tokens[_tokenId].isEmpty = true; emit PanelDeconstructed(_tokenId); } function fillEmptyToken(uint256 _tokenId, string memory _name, string memory _desc, uint256[] memory _blocksTokenIds) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); require(tokens[_tokenId].isEmpty, "Panel is not empty"); uint256 aLength = _blocksTokenIds.length; require(tokens[_tokenId].size == aLength, "Size differs from blocks count. Partial Panels not allowed"); for(uint i=0; i < aLength; i++) { uint bTid = _blocksTokenIds[i]; require(TilesBlocksCore(BLOCKS_CONTRACT).ownerOf(bTid) == ownerOf(_tokenId), "Receiver needs to own all tokens"); //also checks if token exists TilesBlocksCore(BLOCKS_CONTRACT).burn(bTid); } tokenBlocks[_tokenId] = _blocksTokenIds; tokens[_tokenId].name = _name; tokens[_tokenId].description = _desc; tokens[_tokenId].isEmpty = false; emit PanelCreated (_tokenId, _blocksTokenIds); } function mintGenesis(address _receiver, string memory _name, string memory _desc, uint16 _size, uint256[] memory _blocksTokenIds) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); require(_isValidLength(_size), "Invalid size"); require(_checkTotalMints(_size), "Exceeds total mints for this size"); bool isEmpty = false; uint256 aLength = _blocksTokenIds.length; if (aLength > 0) { //not empty require(_size == aLength, "Size differs from blocks count. Partial Panels not allowed"); for(uint i=0; i < aLength; i++) { uint bTid = _blocksTokenIds[i]; require(TilesBlocksCore(BLOCKS_CONTRACT).ownerOf(bTid) == _receiver, "Receiver needs to own all tokens"); //also checks if token exists TilesBlocksCore(BLOCKS_CONTRACT).burn(bTid); } } else { isEmpty = true; } totalGlobalMints++; uint256 token = totalGlobalMints; totalMints[_size] = totalMints[_size] + 1; tokenBlocks[token] = _blocksTokenIds; tokens[token] = Panel({name: _name, description: _desc, size: _size, degradationLevel: 0, isEmpty: isEmpty}); _safeMint(_receiver, token); emit PanelCreated (token, _blocksTokenIds); } function burn(uint256 tokenId) public { require(hasRole(MINTER_ROLE, msg.sender), "Caller is not a minter"); _burn(tokenId); } function supportsInterface(bytes4 interfaceId) public view virtual override(ERC721Enumerable, AccessControl) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } function withdrawEther() public { require(hasRole(DEFAULT_ADMIN_ROLE, msg.sender), "Caller is not admin"); uint balance = address(this).balance; payable(msg.sender).transfer(balance); } }
// SPDX-License-Identifier: MIT 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; }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Provides information about the current execution context, including the * sender of the transaction and its data. While these are generally available * via msg.sender and msg.data, they should not be accessed in such a direct * manner, since when dealing with meta-transactions the account sending and * paying for execution may not be the actual sender (as far as an application * is concerned). * * This contract is only required for intermediate, library-like contracts. */ abstract contract Context { function _msgSender() internal view virtual returns (address) { return msg.sender; } function _msgData() internal view virtual returns (bytes calldata) { return msg.data; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev String operations. */ library Strings { bytes16 private constant _HEX_SYMBOLS = "0123456789abcdef"; /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ function toString(uint256 value) internal pure returns (string memory) { // Inspired by OraclizeAPI's implementation - MIT licence // https://github.com/oraclize/ethereum-api/blob/b42146b063c7d6ee1358846c198246239e9360e8/oraclizeAPI_0.4.25.sol if (value == 0) { return "0"; } uint256 temp = value; uint256 digits; while (temp != 0) { digits++; temp /= 10; } bytes memory buffer = new bytes(digits); while (value != 0) { digits -= 1; buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); value /= 10; } return string(buffer); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ function toHexString(uint256 value) internal pure returns (string memory) { if (value == 0) { return "0x00"; } uint256 temp = value; uint256 length = 0; while (temp != 0) { length++; temp >>= 8; } return toHexString(value, length); } /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { buffer[i] = _HEX_SYMBOLS[value & 0xf]; value >>= 4; } require(value == 0, "Strings: hex length insufficient"); return string(buffer); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC165.sol"; /** * @dev Implementation of the {IERC165} interface. * * Contracts that want to implement ERC165 should inherit from this contract and override {supportsInterface} to check * for the additional interface id that will be supported. For example: * * ```solidity * function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { * return interfaceId == type(MyInterface).interfaceId || super.supportsInterface(interfaceId); * } * ``` * * Alternatively, {ERC165Storage} provides an easier to use but more expensive implementation. */ abstract contract ERC165 is IERC165 { /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override returns (bool) { return interfaceId == type(IERC165).interfaceId; } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Interface of the ERC165 standard, as defined in the * https://eips.ethereum.org/EIPS/eip-165[EIP]. * * Implementers can declare support of contract interfaces, which can then be * queried by others ({ERC165Checker}). * * For an implementation, see {ERC165}. */ interface IERC165 { /** * @dev Returns true if this contract implements the interface defined by * `interfaceId`. See the corresponding * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] * to learn more about how these ids are created. * * This function call must use less than 30 000 gas. */ function supportsInterface(bytes4 interfaceId) external view returns (bool); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../ERC721.sol"; import "./IERC721Enumerable.sol"; /** * @dev This implements an optional extension of {ERC721} defined in the EIP that adds * enumerability of all the token ids in the contract as well as all token ids owned by each * account. */ abstract contract ERC721Enumerable is ERC721, IERC721Enumerable { // Mapping from owner to list of owned token IDs mapping(address => mapping(uint256 => uint256)) private _ownedTokens; // Mapping from token ID to index of the owner tokens list mapping(uint256 => uint256) private _ownedTokensIndex; // Array with all token ids, used for enumeration uint256[] private _allTokens; // Mapping from token id to position in the allTokens array mapping(uint256 => uint256) private _allTokensIndex; /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(IERC165, ERC721) returns (bool) { return interfaceId == type(IERC721Enumerable).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721Enumerable-tokenOfOwnerByIndex}. */ function tokenOfOwnerByIndex(address owner, uint256 index) public view virtual override returns (uint256) { require(index < ERC721.balanceOf(owner), "ERC721Enumerable: owner index out of bounds"); return _ownedTokens[owner][index]; } /** * @dev See {IERC721Enumerable-totalSupply}. */ function totalSupply() public view virtual override returns (uint256) { return _allTokens.length; } /** * @dev See {IERC721Enumerable-tokenByIndex}. */ function tokenByIndex(uint256 index) public view virtual override returns (uint256) { require(index < ERC721Enumerable.totalSupply(), "ERC721Enumerable: global index out of bounds"); return _allTokens[index]; } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` cannot be the zero address. * - `to` cannot be the zero address. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual override { super._beforeTokenTransfer(from, to, tokenId); if (from == address(0)) { _addTokenToAllTokensEnumeration(tokenId); } else if (from != to) { _removeTokenFromOwnerEnumeration(from, tokenId); } if (to == address(0)) { _removeTokenFromAllTokensEnumeration(tokenId); } else if (to != from) { _addTokenToOwnerEnumeration(to, tokenId); } } /** * @dev Private function to add a token to this extension's ownership-tracking data structures. * @param to address representing the new owner of the given token ID * @param tokenId uint256 ID of the token to be added to the tokens list of the given address */ function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private { uint256 length = ERC721.balanceOf(to); _ownedTokens[to][length] = tokenId; _ownedTokensIndex[tokenId] = length; } /** * @dev Private function to add a token to this extension's token tracking data structures. * @param tokenId uint256 ID of the token to be added to the tokens list */ function _addTokenToAllTokensEnumeration(uint256 tokenId) private { _allTokensIndex[tokenId] = _allTokens.length; _allTokens.push(tokenId); } /** * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that * while the token is not assigned a new owner, the `_ownedTokensIndex` mapping is _not_ updated: this allows for * gas optimizations e.g. when performing a transfer operation (avoiding double writes). * This has O(1) time complexity, but alters the order of the _ownedTokens array. * @param from address representing the previous owner of the given token ID * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address */ function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private { // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = ERC721.balanceOf(from) - 1; uint256 tokenIndex = _ownedTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary if (tokenIndex != lastTokenIndex) { uint256 lastTokenId = _ownedTokens[from][lastTokenIndex]; _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index } // This also deletes the contents at the last position of the array delete _ownedTokensIndex[tokenId]; delete _ownedTokens[from][lastTokenIndex]; } /** * @dev Private function to remove a token from this extension's token tracking data structures. * This has O(1) time complexity, but alters the order of the _allTokens array. * @param tokenId uint256 ID of the token to be removed from the tokens list */ function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private { // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and // then delete the last slot (swap and pop). uint256 lastTokenIndex = _allTokens.length - 1; uint256 tokenIndex = _allTokensIndex[tokenId]; // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding // an 'if' statement (like in _removeTokenFromOwnerEnumeration) uint256 lastTokenId = _allTokens[lastTokenIndex]; _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index // This also deletes the contents at the last position of the array delete _allTokensIndex[tokenId]; _allTokens.pop(); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../utils/Context.sol"; /** * @dev Contract module which provides a basic access control mechanism, where * there is an account (an owner) that can be granted exclusive access to * specific functions. * * By default, the owner account will be the one that deploys the contract. This * can later be changed with {transferOwnership}. * * This module is used through inheritance. It will make available the modifier * `onlyOwner`, which can be applied to your functions to restrict their use to * the owner. */ abstract contract Ownable is Context { address private _owner; event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); /** * @dev Initializes the contract setting the deployer as the initial owner. */ constructor() { _setOwner(_msgSender()); } /** * @dev Returns the address of the current owner. */ function owner() public view virtual returns (address) { return _owner; } /** * @dev Throws if called by any account other than the owner. */ modifier onlyOwner() { require(owner() == _msgSender(), "Ownable: caller is not the owner"); _; } /** * @dev Leaves the contract without owner. It will not be possible to call * `onlyOwner` functions anymore. Can only be called by the current owner. * * NOTE: Renouncing ownership will leave the contract without an owner, * thereby removing any functionality that is only available to the owner. */ function renounceOwnership() public virtual onlyOwner { _setOwner(address(0)); } /** * @dev Transfers ownership of the contract to a new account (`newOwner`). * Can only be called by the current owner. */ function transferOwnership(address newOwner) public virtual onlyOwner { require(newOwner != address(0), "Ownable: new owner is the zero address"); _setOwner(newOwner); } function _setOwner(address newOwner) private { address oldOwner = _owner; _owner = newOwner; emit OwnershipTransferred(oldOwner, newOwner); } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./IERC721.sol"; import "./IERC721Receiver.sol"; import "./extensions/IERC721Metadata.sol"; import "../../utils/Address.sol"; import "../../utils/Context.sol"; import "../../utils/Strings.sol"; import "../../utils/introspection/ERC165.sol"; /** * @dev Implementation of https://eips.ethereum.org/EIPS/eip-721[ERC721] Non-Fungible Token Standard, including * the Metadata extension, but not including the Enumerable extension, which is available separately as * {ERC721Enumerable}. */ contract ERC721 is Context, ERC165, IERC721, IERC721Metadata { using Address for address; using Strings for uint256; // Token name string private _name; // Token symbol string private _symbol; // Mapping from token ID to owner address mapping(uint256 => address) private _owners; // Mapping owner address to token count mapping(address => uint256) private _balances; // Mapping from token ID to approved address mapping(uint256 => address) private _tokenApprovals; // Mapping from owner to operator approvals mapping(address => mapping(address => bool)) private _operatorApprovals; /** * @dev Initializes the contract by setting a `name` and a `symbol` to the token collection. */ constructor(string memory name_, string memory symbol_) { _name = name_; _symbol = symbol_; } /** * @dev See {IERC165-supportsInterface}. */ function supportsInterface(bytes4 interfaceId) public view virtual override(ERC165, IERC165) returns (bool) { return interfaceId == type(IERC721).interfaceId || interfaceId == type(IERC721Metadata).interfaceId || super.supportsInterface(interfaceId); } /** * @dev See {IERC721-balanceOf}. */ function balanceOf(address owner) public view virtual override returns (uint256) { require(owner != address(0), "ERC721: balance query for the zero address"); return _balances[owner]; } /** * @dev See {IERC721-ownerOf}. */ function ownerOf(uint256 tokenId) public view virtual override returns (address) { address owner = _owners[tokenId]; require(owner != address(0), "ERC721: owner query for nonexistent token"); return owner; } /** * @dev See {IERC721Metadata-name}. */ function name() public view virtual override returns (string memory) { return _name; } /** * @dev See {IERC721Metadata-symbol}. */ function symbol() public view virtual override returns (string memory) { return _symbol; } /** * @dev See {IERC721Metadata-tokenURI}. */ function tokenURI(uint256 tokenId) public view virtual override returns (string memory) { require(_exists(tokenId), "ERC721Metadata: URI query for nonexistent token"); string memory baseURI = _baseURI(); return bytes(baseURI).length > 0 ? string(abi.encodePacked(baseURI, tokenId.toString())) : ""; } /** * @dev Base URI for computing {tokenURI}. If set, the resulting URI for each * token will be the concatenation of the `baseURI` and the `tokenId`. Empty * by default, can be overriden in child contracts. */ function _baseURI() internal view virtual returns (string memory) { return ""; } /** * @dev See {IERC721-approve}. */ function approve(address to, uint256 tokenId) public virtual override { address owner = ERC721.ownerOf(tokenId); require(to != owner, "ERC721: approval to current owner"); require( _msgSender() == owner || isApprovedForAll(owner, _msgSender()), "ERC721: approve caller is not owner nor approved for all" ); _approve(to, tokenId); } /** * @dev See {IERC721-getApproved}. */ function getApproved(uint256 tokenId) public view virtual override returns (address) { require(_exists(tokenId), "ERC721: approved query for nonexistent token"); return _tokenApprovals[tokenId]; } /** * @dev See {IERC721-setApprovalForAll}. */ function setApprovalForAll(address operator, bool approved) public virtual override { require(operator != _msgSender(), "ERC721: approve to caller"); _operatorApprovals[_msgSender()][operator] = approved; emit ApprovalForAll(_msgSender(), operator, approved); } /** * @dev See {IERC721-isApprovedForAll}. */ function isApprovedForAll(address owner, address operator) public view virtual override returns (bool) { return _operatorApprovals[owner][operator]; } /** * @dev See {IERC721-transferFrom}. */ function transferFrom( address from, address to, uint256 tokenId ) public virtual override { //solhint-disable-next-line max-line-length require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _transfer(from, to, tokenId); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId ) public virtual override { safeTransferFrom(from, to, tokenId, ""); } /** * @dev See {IERC721-safeTransferFrom}. */ function safeTransferFrom( address from, address to, uint256 tokenId, bytes memory _data ) public virtual override { require(_isApprovedOrOwner(_msgSender(), tokenId), "ERC721: transfer caller is not owner nor approved"); _safeTransfer(from, to, tokenId, _data); } /** * @dev Safely transfers `tokenId` token from `from` to `to`, checking first that contract recipients * are aware of the ERC721 protocol to prevent tokens from being forever locked. * * `_data` is additional data, it has no specified format and it is sent in call to `to`. * * This internal function is equivalent to {safeTransferFrom}, and can be used to e.g. * implement alternative mechanisms to perform token transfer, such as signature-based. * * Requirements: * * - `from` cannot be the zero address. * - `to` cannot be the zero address. * - `tokenId` token must exist and be owned by `from`. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeTransfer( address from, address to, uint256 tokenId, bytes memory _data ) internal virtual { _transfer(from, to, tokenId); require(_checkOnERC721Received(from, to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer"); } /** * @dev Returns whether `tokenId` exists. * * Tokens can be managed by their owner or approved accounts via {approve} or {setApprovalForAll}. * * Tokens start existing when they are minted (`_mint`), * and stop existing when they are burned (`_burn`). */ function _exists(uint256 tokenId) internal view virtual returns (bool) { return _owners[tokenId] != address(0); } /** * @dev Returns whether `spender` is allowed to manage `tokenId`. * * Requirements: * * - `tokenId` must exist. */ function _isApprovedOrOwner(address spender, uint256 tokenId) internal view virtual returns (bool) { require(_exists(tokenId), "ERC721: operator query for nonexistent token"); address owner = ERC721.ownerOf(tokenId); return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender)); } /** * @dev Safely mints `tokenId` and transfers it to `to`. * * Requirements: * * - `tokenId` must not exist. * - If `to` refers to a smart contract, it must implement {IERC721Receiver-onERC721Received}, which is called upon a safe transfer. * * Emits a {Transfer} event. */ function _safeMint(address to, uint256 tokenId) internal virtual { _safeMint(to, tokenId, ""); } /** * @dev Same as {xref-ERC721-_safeMint-address-uint256-}[`_safeMint`], with an additional `data` parameter which is * forwarded in {IERC721Receiver-onERC721Received} to contract recipients. */ function _safeMint( address to, uint256 tokenId, bytes memory _data ) internal virtual { _mint(to, tokenId); require( _checkOnERC721Received(address(0), to, tokenId, _data), "ERC721: transfer to non ERC721Receiver implementer" ); } /** * @dev Mints `tokenId` and transfers it to `to`. * * WARNING: Usage of this method is discouraged, use {_safeMint} whenever possible * * Requirements: * * - `tokenId` must not exist. * - `to` cannot be the zero address. * * Emits a {Transfer} event. */ function _mint(address to, uint256 tokenId) internal virtual { require(to != address(0), "ERC721: mint to the zero address"); require(!_exists(tokenId), "ERC721: token already minted"); _beforeTokenTransfer(address(0), to, tokenId); _balances[to] += 1; _owners[tokenId] = to; emit Transfer(address(0), to, tokenId); } /** * @dev Destroys `tokenId`. * The approval is cleared when the token is burned. * * Requirements: * * - `tokenId` must exist. * * Emits a {Transfer} event. */ function _burn(uint256 tokenId) internal virtual { address owner = ERC721.ownerOf(tokenId); _beforeTokenTransfer(owner, address(0), tokenId); // Clear approvals _approve(address(0), tokenId); _balances[owner] -= 1; delete _owners[tokenId]; emit Transfer(owner, address(0), tokenId); } /** * @dev Transfers `tokenId` from `from` to `to`. * As opposed to {transferFrom}, this imposes no restrictions on msg.sender. * * Requirements: * * - `to` cannot be the zero address. * - `tokenId` token must be owned by `from`. * * Emits a {Transfer} event. */ function _transfer( address from, address to, uint256 tokenId ) internal virtual { require(ERC721.ownerOf(tokenId) == from, "ERC721: transfer of token that is not own"); require(to != address(0), "ERC721: transfer to the zero address"); _beforeTokenTransfer(from, to, tokenId); // Clear approvals from the previous owner _approve(address(0), tokenId); _balances[from] -= 1; _balances[to] += 1; _owners[tokenId] = to; emit Transfer(from, to, tokenId); } /** * @dev Approve `to` to operate on `tokenId` * * Emits a {Approval} event. */ function _approve(address to, uint256 tokenId) internal virtual { _tokenApprovals[tokenId] = to; emit Approval(ERC721.ownerOf(tokenId), to, tokenId); } /** * @dev Internal function to invoke {IERC721Receiver-onERC721Received} on a target address. * The call is not executed if the target address is not a contract. * * @param from address representing the previous owner of the given token ID * @param to target address that will receive the tokens * @param tokenId uint256 ID of the token to be transferred * @param _data bytes optional data to send along with the call * @return bool whether the call correctly returned the expected magic value */ function _checkOnERC721Received( address from, address to, uint256 tokenId, bytes memory _data ) private returns (bool) { if (to.isContract()) { try IERC721Receiver(to).onERC721Received(_msgSender(), from, tokenId, _data) returns (bytes4 retval) { return retval == IERC721Receiver.onERC721Received.selector; } catch (bytes memory reason) { if (reason.length == 0) { revert("ERC721: transfer to non ERC721Receiver implementer"); } else { assembly { revert(add(32, reason), mload(reason)) } } } } else { return true; } } /** * @dev Hook that is called before any token transfer. This includes minting * and burning. * * Calling conditions: * * - When `from` and `to` are both non-zero, ``from``'s `tokenId` will be * transferred to `to`. * - When `from` is zero, `tokenId` will be minted for `to`. * - When `to` is zero, ``from``'s `tokenId` will be burned. * - `from` and `to` are never both zero. * * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. */ function _beforeTokenTransfer( address from, address to, uint256 tokenId ) internal virtual {} }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional enumeration extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Enumerable is IERC721 { /** * @dev Returns the total amount of tokens stored by the contract. */ function totalSupply() external view returns (uint256); /** * @dev Returns a token ID owned by `owner` at a given `index` of its token list. * Use along with {balanceOf} to enumerate all of ``owner``'s tokens. */ function tokenOfOwnerByIndex(address owner, uint256 index) external view returns (uint256 tokenId); /** * @dev Returns a token ID at a given `index` of all the tokens stored by the contract. * Use along with {totalSupply} to enumerate all tokens. */ function tokenByIndex(uint256 index) external view returns (uint256); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @title ERC721 token receiver interface * @dev Interface for any contract that wants to support safeTransfers * from ERC721 asset contracts. */ interface IERC721Receiver { /** * @dev Whenever an {IERC721} `tokenId` token is transferred to this contract via {IERC721-safeTransferFrom} * by `operator` from `from`, this function is called. * * It must return its Solidity selector to confirm the token transfer. * If any other value is returned or the interface is not implemented by the recipient, the transfer will be reverted. * * The selector can be obtained in Solidity with `IERC721.onERC721Received.selector`. */ function onERC721Received( address operator, address from, uint256 tokenId, bytes calldata data ) external returns (bytes4); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "../IERC721.sol"; /** * @title ERC-721 Non-Fungible Token Standard, optional metadata extension * @dev See https://eips.ethereum.org/EIPS/eip-721 */ interface IERC721Metadata is IERC721 { /** * @dev Returns the token collection name. */ function name() external view returns (string memory); /** * @dev Returns the token collection symbol. */ function symbol() external view returns (string memory); /** * @dev Returns the Uniform Resource Identifier (URI) for `tokenId` token. */ function tokenURI(uint256 tokenId) external view returns (string memory); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; /** * @dev Collection of functions related to the address type */ library Address { /** * @dev Returns true if `account` is a contract. * * [IMPORTANT] * ==== * It is unsafe to assume that an address for which this function returns * false is an externally-owned account (EOA) and not a contract. * * Among others, `isContract` will return false for the following * types of addresses: * * - an externally-owned account * - a contract in construction * - an address where a contract will be created * - an address where a contract lived, but was destroyed * ==== */ function isContract(address account) internal view returns (bool) { // This method relies on extcodesize, which returns 0 for contracts in // construction, since the code is only stored at the end of the // constructor execution. uint256 size; assembly { size := extcodesize(account) } return size > 0; } /** * @dev Replacement for Solidity's `transfer`: sends `amount` wei to * `recipient`, forwarding all available gas and reverting on errors. * * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost * of certain opcodes, possibly making contracts go over the 2300 gas limit * imposed by `transfer`, making them unable to receive funds via * `transfer`. {sendValue} removes this limitation. * * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. * * IMPORTANT: because control is transferred to `recipient`, care must be * taken to not create reentrancy vulnerabilities. Consider using * {ReentrancyGuard} or the * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. */ function sendValue(address payable recipient, uint256 amount) internal { require(address(this).balance >= amount, "Address: insufficient balance"); (bool success, ) = recipient.call{value: amount}(""); require(success, "Address: unable to send value, recipient may have reverted"); } /** * @dev Performs a Solidity function call using a low level `call`. A * plain `call` is an unsafe replacement for a function call: use this * function instead. * * If `target` reverts with a revert reason, it is bubbled up by this * function (like regular Solidity function calls). * * Returns the raw returned data. To convert to the expected return value, * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. * * Requirements: * * - `target` must be a contract. * - calling `target` with `data` must not revert. * * _Available since v3.1._ */ function functionCall(address target, bytes memory data) internal returns (bytes memory) { return functionCall(target, data, "Address: low-level call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with * `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but also transferring `value` wei to `target`. * * Requirements: * * - the calling contract must have an ETH balance of at least `value`. * - the called Solidity function must be `payable`. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value ) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } /** * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but * with `errorMessage` as a fallback revert reason when `target` reverts. * * _Available since v3.1._ */ function functionCallWithValue( address target, bytes memory data, uint256 value, string memory errorMessage ) internal returns (bytes memory) { require(address(this).balance >= value, "Address: insufficient balance for call"); require(isContract(target), "Address: call to non-contract"); (bool success, bytes memory returndata) = target.call{value: value}(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { return functionStaticCall(target, data, "Address: low-level static call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a static call. * * _Available since v3.3._ */ function functionStaticCall( address target, bytes memory data, string memory errorMessage ) internal view returns (bytes memory) { require(isContract(target), "Address: static call to non-contract"); (bool success, bytes memory returndata) = target.staticcall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { return functionDelegateCall(target, data, "Address: low-level delegate call failed"); } /** * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], * but performing a delegate call. * * _Available since v3.4._ */ function functionDelegateCall( address target, bytes memory data, string memory errorMessage ) internal returns (bytes memory) { require(isContract(target), "Address: delegate call to non-contract"); (bool success, bytes memory returndata) = target.delegatecall(data); return verifyCallResult(success, returndata, errorMessage); } /** * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the * revert reason using the provided one. * * _Available since v4.3._ */ function verifyCallResult( bool success, bytes memory returndata, string memory errorMessage ) internal pure returns (bytes memory) { if (success) { return returndata; } else { // Look for revert reason and bubble it up if present if (returndata.length > 0) { // The easiest way to bubble the revert reason is using memory via assembly assembly { let returndata_size := mload(returndata) revert(add(32, returndata), returndata_size) } } else { revert(errorMessage); } } } }
{ "optimizer": { "enabled": false, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"address","name":"_coreBlocksAddress","type":"address"},{"internalType":"address","name":"_corePanelsAddress","type":"address"},{"internalType":"address","name":"_admin","type":"address"},{"internalType":"address","name":"_framAddress","type":"address"},{"internalType":"address","name":"_pulsAddress","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"inputs":[],"name":"BLOCK_PRICE","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_16","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_2","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_25","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_36","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_4","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_6","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"EMPTY_PANEL_PRICE_9","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"adminAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"tokenIds","type":"uint256[]"}],"name":"burnToMintBlocks","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"}],"name":"deconstructPanel","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_tokenId","type":"uint256"},{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_desc","type":"string"},{"internalType":"uint256[]","name":"_blocksTokenIds","type":"uint256[]"}],"name":"fillEmptyToken","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"_size","type":"uint256"}],"name":"getEmptyPanelPrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"user","type":"address"}],"name":"isEmergence","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"n","type":"uint256"}],"name":"mintBlocks","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"string","name":"_name","type":"string"},{"internalType":"string","name":"_desc","type":"string"},{"internalType":"uint16","name":"_size","type":"uint16"},{"internalType":"uint256[]","name":"_blocksTokenIds","type":"uint256[]"}],"name":"mintPanel","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"panelBlockLimit","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"panelMintStartBlock","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"panelMintStarted","outputs":[{"internalType":"bool","name":"","type":"bool"}],"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":[{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"setPanelBlockLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"startPanelMint","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"string","name":"str","type":"string"},{"internalType":"uint16","name":"maxChars","type":"uint16"}],"name":"validateString","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"withdrawEther","outputs":[],"stateMutability":"nonpayable","type":"function"}]
Contract Creation Code
60806040526000600460146101000a81548160ff021916908315150217905550622819a06006553480156200003357600080fd5b5060405162003c9438038062003c948339818101604052810190620000599190620002bf565b60008060006101000a81548160ff02191690831515021790555084600060016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555083600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555081600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080600460006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555082600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550620001c8620001d360201b60201c565b505050505062000440565b620001e36200028a60201b60201c565b1562000226576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016200021d9062000396565b60405180910390fd5b60016000806101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25862000271620002a060201b60201c565b60405162000280919062000379565b60405180910390a1565b60008060009054906101000a900460ff16905090565b600033905090565b600081519050620002b98162000426565b92915050565b600080600080600060a08688031215620002d857600080fd5b6000620002e888828901620002a8565b9550506020620002fb88828901620002a8565b94505060406200030e88828901620002a8565b93505060606200032188828901620002a8565b92505060806200033488828901620002a8565b9150509295509295909350565b6200034c81620003c9565b82525050565b600062000361601083620003b8565b91506200036e82620003fd565b602082019050919050565b600060208201905062000390600083018462000341565b92915050565b60006020820190508181036000830152620003b18162000352565b9050919050565b600082825260208201905092915050565b6000620003d682620003dd565b9050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b6200043181620003c9565b81146200043d57600080fd5b50565b61384480620004506000396000f3fe6080604052600436106101805760003560e01c80639ef1a6ff116100d1578063e196ce151161008a578063f877de7d11610064578063f877de7d146104e2578063f8e74eab1461051f578063fc6f94681461053b578063fdf00ed21461056657610180565b8063e196ce1514610463578063e452baa91461048e578063f02617ec146104b957610180565b80639ef1a6ff146103725780639f2aaad51461039d578063a4cac909146103c8578063aa82be41146103f1578063b663f6a31461041c578063d0fb0f8c1461044757610180565b8063569affbb1161013e5780637362377b116101185780637362377b146102f05780637ea3c1da146103075780638456cb591461033057806395fa050b1461034757610180565b8063569affbb1461025f5780635c975abb1461029c5780636296180f146102c757610180565b8062e5b6cd146101855780631f089b591461019c578063247a66cb146101c757806335c63607146101f25780633f4ba83a1461021d5780634523805c14610234575b600080fd5b34801561019157600080fd5b5061019a6105a3565b005b3480156101a857600080fd5b506101b161065e565b6040516101be9190612f61565b60405180910390f35b3480156101d357600080fd5b506101dc610669565b6040516101e99190612f61565b60405180910390f35b3480156101fe57600080fd5b50610207610675565b6040516102149190612f61565b60405180910390f35b34801561022957600080fd5b5061023261067b565b005b34801561024057600080fd5b5061024961071c565b6040516102569190612f61565b60405180910390f35b34801561026b57600080fd5b5061028660048036038101906102819190612688565b610721565b6040516102939190612f61565b60405180910390f35b3480156102a857600080fd5b506102b16107ce565b6040516102be9190612c86565b60405180910390f35b3480156102d357600080fd5b506102ee60048036038101906102e991906126da565b6107e4565b005b3480156102fc57600080fd5b50610305610b21565b005b34801561031357600080fd5b5061032e60048036038101906103299190612688565b610c07565b005b34801561033c57600080fd5b50610345610ea7565b005b34801561035357600080fd5b5061035c610f48565b6040516103699190612c86565b60405180910390f35b34801561037e57600080fd5b50610387610f5b565b6040516103949190612f61565b60405180910390f35b3480156103a957600080fd5b506103b2610f60565b6040516103bf9190612f61565b60405180910390f35b3480156103d457600080fd5b506103ef60048036038101906103ea9190612688565b610f6c565b005b3480156103fd57600080fd5b5061040661100d565b6040516104139190612f61565b60405180910390f35b34801561042857600080fd5b50610431611019565b60405161043e9190612f61565b60405180910390f35b610461600480360381019061045c9190612688565b611025565b005b34801561046f57600080fd5b50610478611420565b6040516104859190612f61565b60405180910390f35b34801561049a57600080fd5b506104a361142c565b6040516104b09190612f61565b60405180910390f35b3480156104c557600080fd5b506104e060048036038101906104db9190612548565b611432565b005b3480156104ee57600080fd5b5061050960048036038101906105049190612634565b6116fc565b6040516105169190612c86565b60405180910390f35b61053960048036038101906105349190612589565b6119ca565b005b34801561054757600080fd5b50610550612023565b60405161055d9190612baa565b60405180910390f35b34801561057257600080fd5b5061058d600480360381019061058891906124f6565b612049565b60405161059a9190612c86565b60405180910390f35b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166105e46121b4565b73ffffffffffffffffffffffffffffffffffffffff161461063a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161063190612f41565b60405180910390fd5b6001600460146101000a81548160ff02191690831515021790555043600581905550565b66b1a2bc2ec5000081565b671bc16d674ec8000081565b60065481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166106bc6121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610712576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070990612f41565b60405180910390fd5b61071a6121bc565b565b600081565b6000600282141561073557600090506107c9565b600482141561074e57670de0b6b3a764000090506107c9565b600682141561076057600090506107c9565b6009821415610779576714d1120d7b16000090506107c9565b601082141561079257671bc16d674ec8000090506107c9565b60198214156107ab57673782dace9d90000090506107c9565b60248214156107c457676f05b59d3b20000090506107c9565b600090505b919050565b60008060009054906101000a900460ff16905090565b6107ec6107ce565b158061084c5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108346121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b61088b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161088290612e01565b60405180910390fd5b60065460055461089b91906130ad565b43106108dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d390612d21565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e856040518263ffffffff1660e01b81526004016109379190612f61565b60206040518083038186803b15801561094f57600080fd5b505afa158015610963573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610987919061251f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146109f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109eb90612d01565b60405180910390fd5b6109ff8360246116fc565b610a3e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a3590612e81565b60405180910390fd5b610a498260ff6116fc565b610a88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a7f90612e61565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636296180f858585856040518563ffffffff1660e01b8152600401610ae99493929190612f7c565b600060405180830381600087803b158015610b0357600080fd5b505af1158015610b17573d6000803e3d6000fd5b5050505050505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610b626121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610bb8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610baf90612f41565b60405180910390fd5b60004790503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015610c03573d6000803e3d6000fd5b5050565b610c0f6107ce565b1580610c6f5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610c576121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b610cae576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca590612e01565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e826040518263ffffffff1660e01b8152600401610d099190612f61565b60206040518083038186803b158015610d2157600080fd5b505afa158015610d35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d59919061251f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610dc6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dbd90612d01565b60405180910390fd5b600654600554610dd691906130ad565b4310610e17576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e0e90612d41565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166302531f0d826040518263ffffffff1660e01b8152600401610e729190612f61565b600060405180830381600087803b158015610e8c57600080fd5b505af1158015610ea0573d6000803e3d6000fd5b5050505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610ee86121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610f3e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f3590612f41565b60405180910390fd5b610f4661225d565b565b600460149054906101000a900460ff1681565b600081565b670de0b6b3a764000081565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610fad6121b4565b73ffffffffffffffffffffffffffffffffffffffff1614611003576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ffa90612f41565b60405180910390fd5b8060068190555050565b6714d1120d7b16000081565b676f05b59d3b20000081565b61102d6107ce565b158061108d5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166110756121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b6110cc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110c390612e01565b60405180910390fd5b6014811115611110576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161110790612e21565b60405180910390fd5b60008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c002eb696040518163ffffffff1660e01b815260040160206040518083038186803b15801561117957600080fd5b505afa15801561118d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b19190612785565b63ffffffff16905060008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631f21bfbf6040518163ffffffff1660e01b815260040160206040518083038186803b15801561122257600080fd5b505afa158015611236573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061125a91906126b1565b905081811061129e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161129590612ee1565b60405180910390fd5b601481836112ac919061315d565b10156112c15780826112be919061315d565b92505b60006112dd8466b1a2bc2ec500006122ff90919063ffffffff16565b905080341015611322576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161131990612de1565b60405180910390fd5b6000611337823461231590919063ffffffff16565b9050600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f5414bc633876040518363ffffffff1660e01b8152600401611396929190612c2d565b600060405180830381600087803b1580156113b057600080fd5b505af11580156113c4573d6000803e3d6000fd5b505050506000811115611419573373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015611417573d6000803e3d6000fd5b505b5050505050565b673782dace9d90000081565b60055481565b61143a6107ce565b158061149a5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166114826121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b6114d9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016114d090612e01565b60405180910390fd5b60008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c002eb696040518163ffffffff1660e01b815260040160206040518083038186803b15801561154257600080fd5b505afa158015611556573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061157a9190612785565b63ffffffff16905060008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631f21bfbf6040518163ffffffff1660e01b815260040160206040518083038186803b1580156115eb57600080fd5b505afa1580156115ff573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061162391906126b1565b905081811015611668576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161165f90612f21565b60405180910390fd5b600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f7de22d684336040518363ffffffff1660e01b81526004016116c5929190612c56565b600060405180830381600087803b1580156116df57600080fd5b505af11580156116f3573d6000803e3d6000fd5b50505050505050565b6000808390506000815114156117165760019150506119c4565b8261ffff168151111561172d5760009150506119c4565b602060f81b8160008151811061176c577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156117a95760009150506119c4565b602060f81b81600183516117bd919061315d565b815181106117f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156118315760009150506119c4565b60008160008151811061186d577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b905060005b82518110156119bc5760008382815181106118c1577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b9050602060f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480156119285750602060f81b837effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b1561193a5760009450505050506119c4565b603e60f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806119935750603c60f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b156119a55760009450505050506119c4565b8092505080806119b49061326a565b91505061187d565b506001925050505b92915050565b6119d26107ce565b1580611a325750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a1a6121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b611a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a6890612e01565b60405180910390fd5b600a600554611a8091906130ad565b431180611a8e575060008151145b611acd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611ac490612dc1565b60405180910390fd5b611ada8261ffff1661232b565b611b19576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b1090612ce1565b60405180910390fd5b600460149054906101000a900460ff16611b68576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b5f90612d61565b60405180910390fd5b600654600554611b7891906130ad565b4310611bb9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bb090612d81565b60405180910390fd5b611bc48460246116fc565b611c03576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bfa90612e81565b60405180910390fd5b611c0e8360ff6116fc565b611c4d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c4490612e61565b60405180910390fd5b80518261ffff161415611e835760028261ffff161415611cf857600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611cf7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cee90612e41565b60405180910390fd5b5b60068261ffff161415611da657611d0e33612049565b80611d665750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b611da5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d9c90612ec1565b60405180910390fd5b5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed1157f733868686866040518663ffffffff1660e01b8152600401611e09959493929190612bc5565b600060405180830381600087803b158015611e2357600080fd5b505af1158015611e37573d6000803e3d6000fd5b5050505060003414611e7e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e7590612ea1565b60405180910390fd5b61201d565b600081511415611fd45760068261ffff1614158015611ea7575060028261ffff1614155b611ee6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611edd90612ca1565b60405180910390fd5b6000611ef58361ffff16610721565b9050803414611f39576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f3090612f01565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed1157f733878787876040518663ffffffff1660e01b8152600401611f9c959493929190612bc5565b600060405180830381600087803b158015611fb657600080fd5b505af1158015611fca573d6000803e3d6000fd5b505050505061201c565b80518261ffff161461201b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161201290612da1565b60405180910390fd5b5b5b50505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b81526004016120a79190612baa565b60206040518083038186803b1580156120bf57600080fd5b505afa1580156120d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120f791906126b1565b11806121ad57506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b815260040161215b9190612baa565b60206040518083038186803b15801561217357600080fd5b505afa158015612187573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121ab91906126b1565b115b9050919050565b600033905090565b6121c46107ce565b612203576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121fa90612cc1565b60405180910390fd5b60008060006101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6122466121b4565b6040516122539190612baa565b60405180910390a1565b6122656107ce565b156122a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161229c90612e01565b60405180910390fd5b60016000806101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586122e86121b4565b6040516122f59190612baa565b60405180910390a1565b6000818361230d9190613103565b905092915050565b60008183612323919061315d565b905092915050565b6000600282148061233c5750600482145b806123475750600682145b806123525750600982145b8061235d5750601082145b806123685750601982145b806123735750602482145b9050919050565b600061238d61238884612ffb565b612fd6565b905080838252602082019050828560208602820111156123ac57600080fd5b60005b858110156123dc57816123c288826124b7565b8452602084019350602083019250506001810190506123af565b5050509392505050565b60006123f96123f484613027565b612fd6565b90508281526020810184848401111561241157600080fd5b61241c8482856131f7565b509392505050565b600081359050612433816137b2565b92915050565b600081519050612448816137b2565b92915050565b600082601f83011261245f57600080fd5b813561246f84826020860161237a565b91505092915050565b600082601f83011261248957600080fd5b81356124998482602086016123e6565b91505092915050565b6000813590506124b1816137c9565b92915050565b6000813590506124c6816137e0565b92915050565b6000815190506124db816137e0565b92915050565b6000815190506124f0816137f7565b92915050565b60006020828403121561250857600080fd5b600061251684828501612424565b91505092915050565b60006020828403121561253157600080fd5b600061253f84828501612439565b91505092915050565b60006020828403121561255a57600080fd5b600082013567ffffffffffffffff81111561257457600080fd5b6125808482850161244e565b91505092915050565b6000806000806080858703121561259f57600080fd5b600085013567ffffffffffffffff8111156125b957600080fd5b6125c587828801612478565b945050602085013567ffffffffffffffff8111156125e257600080fd5b6125ee87828801612478565b93505060406125ff878288016124a2565b925050606085013567ffffffffffffffff81111561261c57600080fd5b6126288782880161244e565b91505092959194509250565b6000806040838503121561264757600080fd5b600083013567ffffffffffffffff81111561266157600080fd5b61266d85828601612478565b925050602061267e858286016124a2565b9150509250929050565b60006020828403121561269a57600080fd5b60006126a8848285016124b7565b91505092915050565b6000602082840312156126c357600080fd5b60006126d1848285016124cc565b91505092915050565b600080600080608085870312156126f057600080fd5b60006126fe878288016124b7565b945050602085013567ffffffffffffffff81111561271b57600080fd5b61272787828801612478565b935050604085013567ffffffffffffffff81111561274457600080fd5b61275087828801612478565b925050606085013567ffffffffffffffff81111561276d57600080fd5b6127798782880161244e565b91505092959194509250565b60006020828403121561279757600080fd5b60006127a5848285016124e1565b91505092915050565b60006127ba8383612b8c565b60208301905092915050565b6127cf81613191565b82525050565b60006127e082613068565b6127ea818561308b565b93506127f583613058565b8060005b8381101561282657815161280d88826127ae565b97506128188361307e565b9250506001810190506127f9565b5085935050505092915050565b61283c816131a3565b82525050565b600061284d82613073565b612857818561309c565b9350612867818560208601613206565b61287081613311565b840191505092915050565b600061288860228361309c565b915061289382613322565b604082019050919050565b60006128ab60148361309c565b91506128b682613371565b602082019050919050565b60006128ce600c8361309c565b91506128d98261339a565b602082019050919050565b60006128f160178361309c565b91506128fc826133c3565b602082019050919050565b600061291460138361309c565b915061291f826133ec565b602082019050919050565b6000612937601a8361309c565b915061294282613415565b602082019050919050565b600061295a60198361309c565b91506129658261343e565b602082019050919050565b600061297d60138361309c565b915061298882613467565b602082019050919050565b60006129a0603a8361309c565b91506129ab82613490565b604082019050919050565b60006129c360378361309c565b91506129ce826134df565b604082019050919050565b60006129e660168361309c565b91506129f18261352e565b602082019050919050565b6000612a0960108361309c565b9150612a1482613557565b602082019050919050565b6000612a2c60328361309c565b9150612a3782613580565b604082019050919050565b6000612a4f60228361309c565b9150612a5a826135cf565b604082019050919050565b6000612a7260168361309c565b9150612a7d8261361e565b602082019050919050565b6000612a95600f8361309c565b9150612aa082613647565b602082019050919050565b6000612ab860118361309c565b9150612ac382613670565b602082019050919050565b6000612adb602a8361309c565b9150612ae682613699565b604082019050919050565b6000612afe601e8361309c565b9150612b09826136e8565b602082019050919050565b6000612b2160128361309c565b9150612b2c82613711565b602082019050919050565b6000612b4460308361309c565b9150612b4f8261373a565b604082019050919050565b6000612b67601a8361309c565b9150612b7282613789565b602082019050919050565b612b86816131af565b82525050565b612b95816131dd565b82525050565b612ba4816131dd565b82525050565b6000602082019050612bbf60008301846127c6565b92915050565b600060a082019050612bda60008301886127c6565b8181036020830152612bec8187612842565b90508181036040830152612c008186612842565b9050612c0f6060830185612b7d565b8181036080830152612c2181846127d5565b90509695505050505050565b6000604082019050612c4260008301856127c6565b612c4f6020830184612b9b565b9392505050565b60006040820190508181036000830152612c7081856127d5565b9050612c7f60208301846127c6565b9392505050565b6000602082019050612c9b6000830184612833565b92915050565b60006020820190508181036000830152612cba8161287b565b9050919050565b60006020820190508181036000830152612cda8161289e565b9050919050565b60006020820190508181036000830152612cfa816128c1565b9050919050565b60006020820190508181036000830152612d1a816128e4565b9050919050565b60006020820190508181036000830152612d3a81612907565b9050919050565b60006020820190508181036000830152612d5a8161292a565b9050919050565b60006020820190508181036000830152612d7a8161294d565b9050919050565b60006020820190508181036000830152612d9a81612970565b9050919050565b60006020820190508181036000830152612dba81612993565b9050919050565b60006020820190508181036000830152612dda816129b6565b9050919050565b60006020820190508181036000830152612dfa816129d9565b9050919050565b60006020820190508181036000830152612e1a816129fc565b9050919050565b60006020820190508181036000830152612e3a81612a1f565b9050919050565b60006020820190508181036000830152612e5a81612a42565b9050919050565b60006020820190508181036000830152612e7a81612a65565b9050919050565b60006020820190508181036000830152612e9a81612a88565b9050919050565b60006020820190508181036000830152612eba81612aab565b9050919050565b60006020820190508181036000830152612eda81612ace565b9050919050565b60006020820190508181036000830152612efa81612af1565b9050919050565b60006020820190508181036000830152612f1a81612b14565b9050919050565b60006020820190508181036000830152612f3a81612b37565b9050919050565b60006020820190508181036000830152612f5a81612b5a565b9050919050565b6000602082019050612f766000830184612b9b565b92915050565b6000608082019050612f916000830187612b9b565b8181036020830152612fa38186612842565b90508181036040830152612fb78185612842565b90508181036060830152612fcb81846127d5565b905095945050505050565b6000612fe0612ff1565b9050612fec8282613239565b919050565b6000604051905090565b600067ffffffffffffffff821115613016576130156132e2565b5b602082029050602081019050919050565b600067ffffffffffffffff821115613042576130416132e2565b5b61304b82613311565b9050602081019050919050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600082825260208201905092915050565b60006130b8826131dd565b91506130c3836131dd565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156130f8576130f76132b3565b5b828201905092915050565b600061310e826131dd565b9150613119836131dd565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613152576131516132b3565b5b828202905092915050565b6000613168826131dd565b9150613173836131dd565b925082821015613186576131856132b3565b5b828203905092915050565b600061319c826131bd565b9050919050565b60008115159050919050565b600061ffff82169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600063ffffffff82169050919050565b82818337600083830152505050565b60005b83811015613224578082015181840152602081019050613209565b83811115613233576000848401525b50505050565b61324282613311565b810181811067ffffffffffffffff82111715613261576132606132e2565b5b80604052505050565b6000613275826131dd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156132a8576132a76132b3565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000601f19601f8301169050919050565b7f32783120616e64203378322050616e656c732063616e6e6f7420626520656d7060008201527f7479000000000000000000000000000000000000000000000000000000000000602082015250565b7f5061757361626c653a206e6f7420706175736564000000000000000000000000600082015250565b7f496e76616c69642073697a650000000000000000000000000000000000000000600082015250565b7f43616c6c6572206973206e6f7420746865206f776e6572000000000000000000600082015250565b7f46696c6c20706572696f64206973206f76657200000000000000000000000000600082015250565b7f4465636f6e73747275637420706572696f64206973206f766572000000000000600082015250565b7f50616e656c206d696e74206861736e2774207374617274656400000000000000600082015250565b7f4d696e7420706572696f64206973206f76657200000000000000000000000000600082015250565b7f53697a6520646966666572732066726f6d20626c6f636b7320636f756e742e2060008201527f5061727469616c2050616e656c73206e6f7420616c6c6f776564000000000000602082015250565b7f20496e2074686520666972737420313020626c6f636b732c20796f752063616e60008201527f206f6e6c79206d696e7420656d7074792070616e656c73000000000000000000602082015250565b7f496e737566696369656e742065746865722073656e7400000000000000000000600082015250565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b7f596f752063616e206f6e6c79206d696e7420757020746f20323020696e20746860008201527f652073616d65207472616e73616374696f6e0000000000000000000000000000602082015250565b7f4f6e6c7920746865206f776e65722063616e206d696e74203278312050616e6560008201527f6c73000000000000000000000000000000000000000000000000000000000000602082015250565b7f4465736372697074696f6e20697320696e76616c696400000000000000000000600082015250565b7f4e616d6520697320696e76616c69640000000000000000000000000000000000600082015250565b7f6e6f207061796d656e74206e6565646564000000000000000000000000000000600082015250565b7f4f6e6c7920456d657267656e636520686f6c646572732063616e206d696e742060008201527f3378322050616e656c7300000000000000000000000000000000000000000000602082015250565b7f416c6c20426c6f636b73207765726520616c7265616479206d696e7465640000600082015250565b7f57726f6e6720657468657220616d6d6f75740000000000000000000000000000600082015250565b7f4275726e732063616e206f6e6c7920737461727420616674657220616c6c204260008201527f6c6f636b7320617265206d696e74656400000000000000000000000000000000602082015250565b7f4f6e6c79207468652061646d696e2063616e20646f2074686973000000000000600082015250565b6137bb81613191565b81146137c657600080fd5b50565b6137d2816131af565b81146137dd57600080fd5b50565b6137e9816131dd565b81146137f457600080fd5b50565b613800816131e7565b811461380b57600080fd5b5056fea2646970667358221220222284d232fb94fb186b04a0226620c44a19022ec94648c89999041a52458f4d64736f6c6343000804003300000000000000000000000047f9dbb7b9a5157031f9ed10d00532a2b7de1c77000000000000000000000000871aefdef4784e47d5cc381984f0a7cb877ae9b10000000000000000000000005fe330099f53bc9081ee9026ec1ce3f3f25f120b000000000000000000000000bc17cd7f1a58bda5d6181618090813b3050416b5000000000000000000000000905b180268f2773022e1a10e204b0858b2e60dcf
Deployed Bytecode
0x6080604052600436106101805760003560e01c80639ef1a6ff116100d1578063e196ce151161008a578063f877de7d11610064578063f877de7d146104e2578063f8e74eab1461051f578063fc6f94681461053b578063fdf00ed21461056657610180565b8063e196ce1514610463578063e452baa91461048e578063f02617ec146104b957610180565b80639ef1a6ff146103725780639f2aaad51461039d578063a4cac909146103c8578063aa82be41146103f1578063b663f6a31461041c578063d0fb0f8c1461044757610180565b8063569affbb1161013e5780637362377b116101185780637362377b146102f05780637ea3c1da146103075780638456cb591461033057806395fa050b1461034757610180565b8063569affbb1461025f5780635c975abb1461029c5780636296180f146102c757610180565b8062e5b6cd146101855780631f089b591461019c578063247a66cb146101c757806335c63607146101f25780633f4ba83a1461021d5780634523805c14610234575b600080fd5b34801561019157600080fd5b5061019a6105a3565b005b3480156101a857600080fd5b506101b161065e565b6040516101be9190612f61565b60405180910390f35b3480156101d357600080fd5b506101dc610669565b6040516101e99190612f61565b60405180910390f35b3480156101fe57600080fd5b50610207610675565b6040516102149190612f61565b60405180910390f35b34801561022957600080fd5b5061023261067b565b005b34801561024057600080fd5b5061024961071c565b6040516102569190612f61565b60405180910390f35b34801561026b57600080fd5b5061028660048036038101906102819190612688565b610721565b6040516102939190612f61565b60405180910390f35b3480156102a857600080fd5b506102b16107ce565b6040516102be9190612c86565b60405180910390f35b3480156102d357600080fd5b506102ee60048036038101906102e991906126da565b6107e4565b005b3480156102fc57600080fd5b50610305610b21565b005b34801561031357600080fd5b5061032e60048036038101906103299190612688565b610c07565b005b34801561033c57600080fd5b50610345610ea7565b005b34801561035357600080fd5b5061035c610f48565b6040516103699190612c86565b60405180910390f35b34801561037e57600080fd5b50610387610f5b565b6040516103949190612f61565b60405180910390f35b3480156103a957600080fd5b506103b2610f60565b6040516103bf9190612f61565b60405180910390f35b3480156103d457600080fd5b506103ef60048036038101906103ea9190612688565b610f6c565b005b3480156103fd57600080fd5b5061040661100d565b6040516104139190612f61565b60405180910390f35b34801561042857600080fd5b50610431611019565b60405161043e9190612f61565b60405180910390f35b610461600480360381019061045c9190612688565b611025565b005b34801561046f57600080fd5b50610478611420565b6040516104859190612f61565b60405180910390f35b34801561049a57600080fd5b506104a361142c565b6040516104b09190612f61565b60405180910390f35b3480156104c557600080fd5b506104e060048036038101906104db9190612548565b611432565b005b3480156104ee57600080fd5b5061050960048036038101906105049190612634565b6116fc565b6040516105169190612c86565b60405180910390f35b61053960048036038101906105349190612589565b6119ca565b005b34801561054757600080fd5b50610550612023565b60405161055d9190612baa565b60405180910390f35b34801561057257600080fd5b5061058d600480360381019061058891906124f6565b612049565b60405161059a9190612c86565b60405180910390f35b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166105e46121b4565b73ffffffffffffffffffffffffffffffffffffffff161461063a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161063190612f41565b60405180910390fd5b6001600460146101000a81548160ff02191690831515021790555043600581905550565b66b1a2bc2ec5000081565b671bc16d674ec8000081565b60065481565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166106bc6121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610712576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161070990612f41565b60405180910390fd5b61071a6121bc565b565b600081565b6000600282141561073557600090506107c9565b600482141561074e57670de0b6b3a764000090506107c9565b600682141561076057600090506107c9565b6009821415610779576714d1120d7b16000090506107c9565b601082141561079257671bc16d674ec8000090506107c9565b60198214156107ab57673782dace9d90000090506107c9565b60248214156107c457676f05b59d3b20000090506107c9565b600090505b919050565b60008060009054906101000a900460ff16905090565b6107ec6107ce565b158061084c5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108346121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b61088b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161088290612e01565b60405180910390fd5b60065460055461089b91906130ad565b43106108dc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016108d390612d21565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e856040518263ffffffff1660e01b81526004016109379190612f61565b60206040518083038186803b15801561094f57600080fd5b505afa158015610963573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610987919061251f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146109f4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109eb90612d01565b60405180910390fd5b6109ff8360246116fc565b610a3e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a3590612e81565b60405180910390fd5b610a498260ff6116fc565b610a88576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610a7f90612e61565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636296180f858585856040518563ffffffff1660e01b8152600401610ae99493929190612f7c565b600060405180830381600087803b158015610b0357600080fd5b505af1158015610b17573d6000803e3d6000fd5b5050505050505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610b626121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610bb8576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610baf90612f41565b60405180910390fd5b60004790503373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015610c03573d6000803e3d6000fd5b5050565b610c0f6107ce565b1580610c6f5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610c576121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b610cae576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ca590612e01565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636352211e826040518263ffffffff1660e01b8152600401610d099190612f61565b60206040518083038186803b158015610d2157600080fd5b505afa158015610d35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610d59919061251f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610dc6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dbd90612d01565b60405180910390fd5b600654600554610dd691906130ad565b4310610e17576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610e0e90612d41565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166302531f0d826040518263ffffffff1660e01b8152600401610e729190612f61565b600060405180830381600087803b158015610e8c57600080fd5b505af1158015610ea0573d6000803e3d6000fd5b5050505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610ee86121b4565b73ffffffffffffffffffffffffffffffffffffffff1614610f3e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610f3590612f41565b60405180910390fd5b610f4661225d565b565b600460149054906101000a900460ff1681565b600081565b670de0b6b3a764000081565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610fad6121b4565b73ffffffffffffffffffffffffffffffffffffffff1614611003576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610ffa90612f41565b60405180910390fd5b8060068190555050565b6714d1120d7b16000081565b676f05b59d3b20000081565b61102d6107ce565b158061108d5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166110756121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b6110cc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016110c390612e01565b60405180910390fd5b6014811115611110576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161110790612e21565b60405180910390fd5b60008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c002eb696040518163ffffffff1660e01b815260040160206040518083038186803b15801561117957600080fd5b505afa15801561118d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b19190612785565b63ffffffff16905060008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631f21bfbf6040518163ffffffff1660e01b815260040160206040518083038186803b15801561122257600080fd5b505afa158015611236573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061125a91906126b1565b905081811061129e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161129590612ee1565b60405180910390fd5b601481836112ac919061315d565b10156112c15780826112be919061315d565b92505b60006112dd8466b1a2bc2ec500006122ff90919063ffffffff16565b905080341015611322576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161131990612de1565b60405180910390fd5b6000611337823461231590919063ffffffff16565b9050600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f5414bc633876040518363ffffffff1660e01b8152600401611396929190612c2d565b600060405180830381600087803b1580156113b057600080fd5b505af11580156113c4573d6000803e3d6000fd5b505050506000811115611419573373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015611417573d6000803e3d6000fd5b505b5050505050565b673782dace9d90000081565b60055481565b61143a6107ce565b158061149a5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166114826121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b6114d9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016114d090612e01565b60405180910390fd5b60008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c002eb696040518163ffffffff1660e01b815260040160206040518083038186803b15801561154257600080fd5b505afa158015611556573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061157a9190612785565b63ffffffff16905060008060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631f21bfbf6040518163ffffffff1660e01b815260040160206040518083038186803b1580156115eb57600080fd5b505afa1580156115ff573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061162391906126b1565b905081811015611668576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161165f90612f21565b60405180910390fd5b600060019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f7de22d684336040518363ffffffff1660e01b81526004016116c5929190612c56565b600060405180830381600087803b1580156116df57600080fd5b505af11580156116f3573d6000803e3d6000fd5b50505050505050565b6000808390506000815114156117165760019150506119c4565b8261ffff168151111561172d5760009150506119c4565b602060f81b8160008151811061176c577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156117a95760009150506119c4565b602060f81b81600183516117bd919061315d565b815181106117f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614156118315760009150506119c4565b60008160008151811061186d577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b905060005b82518110156119bc5760008382815181106118c1577f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b602001015160f81c60f81b9050602060f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161480156119285750602060f81b837effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b1561193a5760009450505050506119c4565b603e60f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614806119935750603c60f81b817effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916145b156119a55760009450505050506119c4565b8092505080806119b49061326a565b91505061187d565b506001925050505b92915050565b6119d26107ce565b1580611a325750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16611a1a6121b4565b73ffffffffffffffffffffffffffffffffffffffff16145b611a71576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611a6890612e01565b60405180910390fd5b600a600554611a8091906130ad565b431180611a8e575060008151145b611acd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611ac490612dc1565b60405180910390fd5b611ada8261ffff1661232b565b611b19576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b1090612ce1565b60405180910390fd5b600460149054906101000a900460ff16611b68576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611b5f90612d61565b60405180910390fd5b600654600554611b7891906130ad565b4310611bb9576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bb090612d81565b60405180910390fd5b611bc48460246116fc565b611c03576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611bfa90612e81565b60405180910390fd5b611c0e8360ff6116fc565b611c4d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611c4490612e61565b60405180910390fd5b80518261ffff161415611e835760028261ffff161415611cf857600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611cf7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611cee90612e41565b60405180910390fd5b5b60068261ffff161415611da657611d0e33612049565b80611d665750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b611da5576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611d9c90612ec1565b60405180910390fd5b5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed1157f733868686866040518663ffffffff1660e01b8152600401611e09959493929190612bc5565b600060405180830381600087803b158015611e2357600080fd5b505af1158015611e37573d6000803e3d6000fd5b5050505060003414611e7e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611e7590612ea1565b60405180910390fd5b61201d565b600081511415611fd45760068261ffff1614158015611ea7575060028261ffff1614155b611ee6576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611edd90612ca1565b60405180910390fd5b6000611ef58361ffff16610721565b9050803414611f39576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401611f3090612f01565b60405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed1157f733878787876040518663ffffffff1660e01b8152600401611f9c959493929190612bc5565b600060405180830381600087803b158015611fb657600080fd5b505af1158015611fca573d6000803e3d6000fd5b505050505061201c565b80518261ffff161461201b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161201290612da1565b60405180910390fd5b5b5b50505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b81526004016120a79190612baa565b60206040518083038186803b1580156120bf57600080fd5b505afa1580156120d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120f791906126b1565b11806121ad57506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b815260040161215b9190612baa565b60206040518083038186803b15801561217357600080fd5b505afa158015612187573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121ab91906126b1565b115b9050919050565b600033905090565b6121c46107ce565b612203576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016121fa90612cc1565b60405180910390fd5b60008060006101000a81548160ff0219169083151502179055507f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa6122466121b4565b6040516122539190612baa565b60405180910390a1565b6122656107ce565b156122a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161229c90612e01565b60405180910390fd5b60016000806101000a81548160ff0219169083151502179055507f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586122e86121b4565b6040516122f59190612baa565b60405180910390a1565b6000818361230d9190613103565b905092915050565b60008183612323919061315d565b905092915050565b6000600282148061233c5750600482145b806123475750600682145b806123525750600982145b8061235d5750601082145b806123685750601982145b806123735750602482145b9050919050565b600061238d61238884612ffb565b612fd6565b905080838252602082019050828560208602820111156123ac57600080fd5b60005b858110156123dc57816123c288826124b7565b8452602084019350602083019250506001810190506123af565b5050509392505050565b60006123f96123f484613027565b612fd6565b90508281526020810184848401111561241157600080fd5b61241c8482856131f7565b509392505050565b600081359050612433816137b2565b92915050565b600081519050612448816137b2565b92915050565b600082601f83011261245f57600080fd5b813561246f84826020860161237a565b91505092915050565b600082601f83011261248957600080fd5b81356124998482602086016123e6565b91505092915050565b6000813590506124b1816137c9565b92915050565b6000813590506124c6816137e0565b92915050565b6000815190506124db816137e0565b92915050565b6000815190506124f0816137f7565b92915050565b60006020828403121561250857600080fd5b600061251684828501612424565b91505092915050565b60006020828403121561253157600080fd5b600061253f84828501612439565b91505092915050565b60006020828403121561255a57600080fd5b600082013567ffffffffffffffff81111561257457600080fd5b6125808482850161244e565b91505092915050565b6000806000806080858703121561259f57600080fd5b600085013567ffffffffffffffff8111156125b957600080fd5b6125c587828801612478565b945050602085013567ffffffffffffffff8111156125e257600080fd5b6125ee87828801612478565b93505060406125ff878288016124a2565b925050606085013567ffffffffffffffff81111561261c57600080fd5b6126288782880161244e565b91505092959194509250565b6000806040838503121561264757600080fd5b600083013567ffffffffffffffff81111561266157600080fd5b61266d85828601612478565b925050602061267e858286016124a2565b9150509250929050565b60006020828403121561269a57600080fd5b60006126a8848285016124b7565b91505092915050565b6000602082840312156126c357600080fd5b60006126d1848285016124cc565b91505092915050565b600080600080608085870312156126f057600080fd5b60006126fe878288016124b7565b945050602085013567ffffffffffffffff81111561271b57600080fd5b61272787828801612478565b935050604085013567ffffffffffffffff81111561274457600080fd5b61275087828801612478565b925050606085013567ffffffffffffffff81111561276d57600080fd5b6127798782880161244e565b91505092959194509250565b60006020828403121561279757600080fd5b60006127a5848285016124e1565b91505092915050565b60006127ba8383612b8c565b60208301905092915050565b6127cf81613191565b82525050565b60006127e082613068565b6127ea818561308b565b93506127f583613058565b8060005b8381101561282657815161280d88826127ae565b97506128188361307e565b9250506001810190506127f9565b5085935050505092915050565b61283c816131a3565b82525050565b600061284d82613073565b612857818561309c565b9350612867818560208601613206565b61287081613311565b840191505092915050565b600061288860228361309c565b915061289382613322565b604082019050919050565b60006128ab60148361309c565b91506128b682613371565b602082019050919050565b60006128ce600c8361309c565b91506128d98261339a565b602082019050919050565b60006128f160178361309c565b91506128fc826133c3565b602082019050919050565b600061291460138361309c565b915061291f826133ec565b602082019050919050565b6000612937601a8361309c565b915061294282613415565b602082019050919050565b600061295a60198361309c565b91506129658261343e565b602082019050919050565b600061297d60138361309c565b915061298882613467565b602082019050919050565b60006129a0603a8361309c565b91506129ab82613490565b604082019050919050565b60006129c360378361309c565b91506129ce826134df565b604082019050919050565b60006129e660168361309c565b91506129f18261352e565b602082019050919050565b6000612a0960108361309c565b9150612a1482613557565b602082019050919050565b6000612a2c60328361309c565b9150612a3782613580565b604082019050919050565b6000612a4f60228361309c565b9150612a5a826135cf565b604082019050919050565b6000612a7260168361309c565b9150612a7d8261361e565b602082019050919050565b6000612a95600f8361309c565b9150612aa082613647565b602082019050919050565b6000612ab860118361309c565b9150612ac382613670565b602082019050919050565b6000612adb602a8361309c565b9150612ae682613699565b604082019050919050565b6000612afe601e8361309c565b9150612b09826136e8565b602082019050919050565b6000612b2160128361309c565b9150612b2c82613711565b602082019050919050565b6000612b4460308361309c565b9150612b4f8261373a565b604082019050919050565b6000612b67601a8361309c565b9150612b7282613789565b602082019050919050565b612b86816131af565b82525050565b612b95816131dd565b82525050565b612ba4816131dd565b82525050565b6000602082019050612bbf60008301846127c6565b92915050565b600060a082019050612bda60008301886127c6565b8181036020830152612bec8187612842565b90508181036040830152612c008186612842565b9050612c0f6060830185612b7d565b8181036080830152612c2181846127d5565b90509695505050505050565b6000604082019050612c4260008301856127c6565b612c4f6020830184612b9b565b9392505050565b60006040820190508181036000830152612c7081856127d5565b9050612c7f60208301846127c6565b9392505050565b6000602082019050612c9b6000830184612833565b92915050565b60006020820190508181036000830152612cba8161287b565b9050919050565b60006020820190508181036000830152612cda8161289e565b9050919050565b60006020820190508181036000830152612cfa816128c1565b9050919050565b60006020820190508181036000830152612d1a816128e4565b9050919050565b60006020820190508181036000830152612d3a81612907565b9050919050565b60006020820190508181036000830152612d5a8161292a565b9050919050565b60006020820190508181036000830152612d7a8161294d565b9050919050565b60006020820190508181036000830152612d9a81612970565b9050919050565b60006020820190508181036000830152612dba81612993565b9050919050565b60006020820190508181036000830152612dda816129b6565b9050919050565b60006020820190508181036000830152612dfa816129d9565b9050919050565b60006020820190508181036000830152612e1a816129fc565b9050919050565b60006020820190508181036000830152612e3a81612a1f565b9050919050565b60006020820190508181036000830152612e5a81612a42565b9050919050565b60006020820190508181036000830152612e7a81612a65565b9050919050565b60006020820190508181036000830152612e9a81612a88565b9050919050565b60006020820190508181036000830152612eba81612aab565b9050919050565b60006020820190508181036000830152612eda81612ace565b9050919050565b60006020820190508181036000830152612efa81612af1565b9050919050565b60006020820190508181036000830152612f1a81612b14565b9050919050565b60006020820190508181036000830152612f3a81612b37565b9050919050565b60006020820190508181036000830152612f5a81612b5a565b9050919050565b6000602082019050612f766000830184612b9b565b92915050565b6000608082019050612f916000830187612b9b565b8181036020830152612fa38186612842565b90508181036040830152612fb78185612842565b90508181036060830152612fcb81846127d5565b905095945050505050565b6000612fe0612ff1565b9050612fec8282613239565b919050565b6000604051905090565b600067ffffffffffffffff821115613016576130156132e2565b5b602082029050602081019050919050565b600067ffffffffffffffff821115613042576130416132e2565b5b61304b82613311565b9050602081019050919050565b6000819050602082019050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b600082825260208201905092915050565b600082825260208201905092915050565b60006130b8826131dd565b91506130c3836131dd565b9250827fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff038211156130f8576130f76132b3565b5b828201905092915050565b600061310e826131dd565b9150613119836131dd565b9250817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613152576131516132b3565b5b828202905092915050565b6000613168826131dd565b9150613173836131dd565b925082821015613186576131856132b3565b5b828203905092915050565b600061319c826131bd565b9050919050565b60008115159050919050565b600061ffff82169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600063ffffffff82169050919050565b82818337600083830152505050565b60005b83811015613224578082015181840152602081019050613209565b83811115613233576000848401525b50505050565b61324282613311565b810181811067ffffffffffffffff82111715613261576132606132e2565b5b80604052505050565b6000613275826131dd565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156132a8576132a76132b3565b5b600182019050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000601f19601f8301169050919050565b7f32783120616e64203378322050616e656c732063616e6e6f7420626520656d7060008201527f7479000000000000000000000000000000000000000000000000000000000000602082015250565b7f5061757361626c653a206e6f7420706175736564000000000000000000000000600082015250565b7f496e76616c69642073697a650000000000000000000000000000000000000000600082015250565b7f43616c6c6572206973206e6f7420746865206f776e6572000000000000000000600082015250565b7f46696c6c20706572696f64206973206f76657200000000000000000000000000600082015250565b7f4465636f6e73747275637420706572696f64206973206f766572000000000000600082015250565b7f50616e656c206d696e74206861736e2774207374617274656400000000000000600082015250565b7f4d696e7420706572696f64206973206f76657200000000000000000000000000600082015250565b7f53697a6520646966666572732066726f6d20626c6f636b7320636f756e742e2060008201527f5061727469616c2050616e656c73206e6f7420616c6c6f776564000000000000602082015250565b7f20496e2074686520666972737420313020626c6f636b732c20796f752063616e60008201527f206f6e6c79206d696e7420656d7074792070616e656c73000000000000000000602082015250565b7f496e737566696369656e742065746865722073656e7400000000000000000000600082015250565b7f5061757361626c653a2070617573656400000000000000000000000000000000600082015250565b7f596f752063616e206f6e6c79206d696e7420757020746f20323020696e20746860008201527f652073616d65207472616e73616374696f6e0000000000000000000000000000602082015250565b7f4f6e6c7920746865206f776e65722063616e206d696e74203278312050616e6560008201527f6c73000000000000000000000000000000000000000000000000000000000000602082015250565b7f4465736372697074696f6e20697320696e76616c696400000000000000000000600082015250565b7f4e616d6520697320696e76616c69640000000000000000000000000000000000600082015250565b7f6e6f207061796d656e74206e6565646564000000000000000000000000000000600082015250565b7f4f6e6c7920456d657267656e636520686f6c646572732063616e206d696e742060008201527f3378322050616e656c7300000000000000000000000000000000000000000000602082015250565b7f416c6c20426c6f636b73207765726520616c7265616479206d696e7465640000600082015250565b7f57726f6e6720657468657220616d6d6f75740000000000000000000000000000600082015250565b7f4275726e732063616e206f6e6c7920737461727420616674657220616c6c204260008201527f6c6f636b7320617265206d696e74656400000000000000000000000000000000602082015250565b7f4f6e6c79207468652061646d696e2063616e20646f2074686973000000000000600082015250565b6137bb81613191565b81146137c657600080fd5b50565b6137d2816131af565b81146137dd57600080fd5b50565b6137e9816131dd565b81146137f457600080fd5b50565b613800816131e7565b811461380b57600080fd5b5056fea2646970667358221220222284d232fb94fb186b04a0226620c44a19022ec94648c89999041a52458f4d64736f6c63430008040033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000047f9dbb7b9a5157031f9ed10d00532a2b7de1c77000000000000000000000000871aefdef4784e47d5cc381984f0a7cb877ae9b10000000000000000000000005fe330099f53bc9081ee9026ec1ce3f3f25f120b000000000000000000000000bc17cd7f1a58bda5d6181618090813b3050416b5000000000000000000000000905b180268f2773022e1a10e204b0858b2e60dcf
-----Decoded View---------------
Arg [0] : _coreBlocksAddress (address): 0x47f9Dbb7B9A5157031f9ED10D00532A2b7DE1C77
Arg [1] : _corePanelsAddress (address): 0x871AeFDEf4784e47D5CC381984F0A7CB877AE9B1
Arg [2] : _admin (address): 0x5fE330099F53bC9081ee9026eC1CE3F3f25F120B
Arg [3] : _framAddress (address): 0xbC17cd7f1A58bdA5d6181618090813B3050416b5
Arg [4] : _pulsAddress (address): 0x905B180268F2773022e1A10E204B0858B2e60DcF
-----Encoded View---------------
5 Constructor Arguments found :
Arg [0] : 00000000000000000000000047f9dbb7b9a5157031f9ed10d00532a2b7de1c77
Arg [1] : 000000000000000000000000871aefdef4784e47d5cc381984f0a7cb877ae9b1
Arg [2] : 0000000000000000000000005fe330099f53bc9081ee9026ec1ce3f3f25f120b
Arg [3] : 000000000000000000000000bc17cd7f1a58bda5d6181618090813b3050416b5
Arg [4] : 000000000000000000000000905b180268f2773022e1a10e204b0858b2e60dcf
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.