Source Code
Overview
ETH Balance
0 ETH
ETH Value
$0.00
Cross-Chain Transactions
Loading...
Loading
Contract Name:
RMRKBulkWriter
Compiler Version
v0.8.21+commit.d9974bed
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: Apache-2.0
pragma solidity ^0.8.21;
import {IERC721} from "@openzeppelin/contracts/token/ERC721/IERC721.sol";
import {Context} from "@openzeppelin/contracts/utils/Context.sol";
import {IERC6220} from "../equippable/IERC6220.sol";
import {IERC7401} from "../nestable/IERC7401.sol";
import {IERC6454} from "../extension/soulbound/IERC6454.sol";
import "../library/RMRKErrors.sol";
/**
* @title RMRKBulkWriter
* @author RMRK team
* @notice Smart contract of the RMRK Bulk Writer module.
* @dev Extra utility functions for RMRK contracts.
*/
contract RMRKBulkWriter is Context {
/**
* @notice Used to provide a struct for inputing unequip data.
* @dev Only used for input and not storage of data.
* @return assetId ID of the asset that we are equipping into
* @return slotPartId ID of the slot part that we are using to unequip
*/
struct IntakeUnequip {
uint64 assetId;
uint64 slotPartId;
}
/**
* @notice Reverts if the caller is not the owner of the token.
* @param collection Address of the collection that this contract is managing
* @param tokenId ID of the token we are managing
*/
modifier onlyTokenOwner(address collection, uint256 tokenId) {
_checkTokenOwner(collection, tokenId);
_;
}
/**
* @notice Initializes the contract.
*/
constructor() {}
/**
* @notice Replaces the current equipped child in the asset and slot combination with the given one.
* @dev The `IntakeEquip` stuct contains the following data:
* [
* tokenId,
* childIndex,
* assetId,
* slotPartId,
* childAssetId
* ]
* @dev This contract must have approval to manage the NFT assets, only the current owner can call this method (not an approved operator).
* @param collection Address of the collection that this contract is managing
* @param data An `IntakeEquip` struct specifying the equip data
*/
function replaceEquip(
address collection,
IERC6220.IntakeEquip memory data
) public onlyTokenOwner(collection, data.tokenId) {
IERC6220(collection).unequip(
data.tokenId,
data.assetId,
data.slotPartId
);
IERC6220(collection).equip(data);
}
/**
* @notice Performs multiple unequip and/or equip operations.
* @dev Unequip operations must run first.
* @dev Unequip operations do not need to be related to the equip operations; this method does not force you to only equip the assets into the slots that were unequipped.
* @dev `tokenId` is included as a parameter to be able to do a single check for ownership.
* @dev Every `tokenId` in the `IntakeEquip` structs must match the `tokenId` passed as the argument.
* @dev The `IntakeUnequip` stuct contains the following data:
* [
* assetId,
* slotPartId,
* ]
* @dev The `IntakeEquip` stuct contains the following data:
* [
* tokenId,
* childIndex,
* assetId,
* slotPartId,
* childAssetId
* ]
* @dev This contract must have approval to manage the NFT assets, only the current owner can call this method (not an approved operator).
* @param collection Address of the collection that this contract is managing
* @param tokenId ID of the token we are managing
* @param unequips[] An array of `IntakeUnequip` structs specifying the slots to unequip
* @param equips[] An array of `IntakeEquip` structs specifying the slots to equip
*/
function bulkEquip(
address collection,
uint256 tokenId,
IntakeUnequip[] memory unequips,
IERC6220.IntakeEquip[] memory equips
) public onlyTokenOwner(collection, tokenId) {
uint256 length = unequips.length;
for (uint256 i; i < length; ) {
IERC6220(collection).unequip(
tokenId,
unequips[i].assetId,
unequips[i].slotPartId
);
unchecked {
++i;
}
}
length = equips.length;
for (uint256 i; i < length; ) {
if (equips[i].tokenId != tokenId) {
revert RMRKCanOnlyDoBulkOperationsWithOneTokenAtATime();
}
IERC6220(collection).equip(equips[i]);
unchecked {
++i;
}
}
}
/**
* @notice Transfers multiple children from one token.
* @dev If `destinationId` is 0, the destination can be an EoA or a contract implementing the IERC721Receiver interface.
* @dev If `destinationId` is not 0, the destination must be a contract implementing the IERC7401 interface.
* @dev `childrenIndexes` MUST be in ascending order, this method will transfer the children in reverse order to avoid index changes on children.
* @dev This methods works with active children only.
* @dev This contract must have approval to manage the NFT, only the current owner can call this method (not an approved operator).
* @param collection Address of the collection that this contract is managing
* @param tokenId ID of the token we are managing
* @param childrenIndexes An array of indexes of the children to transfer
* @param to Address of the destination token or contract
* @param destinationId ID of the destination token
*/
function bulkTransferChildren(
address collection,
uint256 tokenId,
uint256[] memory childrenIndexes,
address to,
uint256 destinationId
) public onlyTokenOwner(collection, tokenId) {
IERC7401 targetCollection = IERC7401(collection);
IERC7401.Child[] memory children = targetCollection.childrenOf(tokenId);
uint256 length = childrenIndexes.length;
for (uint256 i; i < length; ) {
uint256 lastIndex = length - 1 - i;
uint256 childIndex = childrenIndexes[lastIndex];
IERC7401.Child memory child = children[childIndex];
targetCollection.transferChild(
tokenId,
to,
destinationId,
childIndex,
child.contractAddress,
child.tokenId,
false,
""
);
unchecked {
++i;
}
}
}
/**
* @notice Transfers all children from one token.
* @dev If `destinationId` is 0, the destination can be an EoA or a contract implementing the IERC721Receiver interface.
* @dev If `destinationId` is not 0, the destination must be a contract implementing the IERC7401 interface.
* @dev This methods works with active children only.
* @dev This contract must have approval to manage the NFT, only the current owner can call this method (not an approved operator).
* @param collection Address of the collection that this contract is managing
* @param tokenId ID of the token we are managing
* @param to Address of the destination token or contract
* @param destinationId ID of the destination token
*/
function bulkTransferAllChildren(
address collection,
uint256 tokenId,
address to,
uint256 destinationId
) public onlyTokenOwner(collection, tokenId) {
IERC7401 targetCollection = IERC7401(collection);
IERC7401.Child[] memory children = targetCollection.childrenOf(tokenId);
uint256 length = children.length;
for (uint256 i; i < length; ) {
uint256 lastIndex = length - 1 - i;
IERC7401.Child memory child = children[lastIndex];
bool transferable = true;
IERC6454 targetChild = IERC6454(child.contractAddress);
if (targetChild.supportsInterface(type(IERC6454).interfaceId)) {
transferable = targetChild.isTransferable(
tokenId,
address(this),
to
);
}
if (transferable) {
targetCollection.transferChild(
tokenId,
to,
destinationId,
lastIndex,
child.contractAddress,
child.tokenId,
false,
""
);
}
unchecked {
++i;
}
}
}
/**
* @notice Validates that the caller is the owner of the token.
* @dev Reverts if the caller is not the owner of the token.
* @param collection Address of the collection that this contract is managing
* @param tokenId ID of the token we are managing
*/
function _checkTokenOwner(
address collection,
uint256 tokenId
) internal view {
address tokenOwner = IERC721(collection).ownerOf(tokenId);
if (tokenOwner != _msgSender()) {
revert RMRKCanOnlyDoBulkOperationsOnOwnedTokens();
}
}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (token/ERC721/IERC721.sol)
pragma solidity ^0.8.20;
import {IERC165} from "../../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`.
*
* 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;
/**
* @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 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: Note that the caller is responsible to confirm that the recipient is capable of receiving ERC721
* or else they may be permanently lost. Usage of {safeTransferFrom} prevents loss, though the caller must
* understand this adds an external call which potentially creates a reentrancy vulnerability.
*
* 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 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 address zero.
*
* Emits an {ApprovalForAll} event.
*/
function setApprovalForAll(address operator, bool approved) external;
/**
* @dev Returns the account approved for `tokenId` token.
*
* Requirements:
*
* - `tokenId` must exist.
*/
function getApproved(uint256 tokenId) external view returns (address operator);
/**
* @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);
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.1) (utils/Context.sol)
pragma solidity ^0.8.20;
/**
* @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;
}
function _contextSuffixLength() internal view virtual returns (uint256) {
return 0;
}
}// SPDX-License-Identifier: Apache-2.0
pragma solidity ^0.8.21;
import {IERC5773} from "../multiasset/IERC5773.sol";
/**
* @title IERC6220
* @author RMRK team
* @notice Interface smart contract of the RMRK equippable module.
*/
interface IERC6220 is IERC5773 {
/**
* @notice Used to store the core structure of the `Equippable` RMRK lego.
* @return assetId The ID of the asset equipping a child
* @return childAssetId The ID of the asset used as equipment
* @return childId The ID of token that is equipped
* @return childEquippableAddress Address of the collection to which the child asset belongs to
*/
struct Equipment {
uint64 assetId;
uint64 childAssetId;
uint256 childId;
address childEquippableAddress;
}
/**
* @notice Used to provide a struct for inputing equip data.
* @dev Only used for input and not storage of data.
* @return tokenId ID of the token we are managing
* @return childIndex Index of a child in the list of token's active children
* @return assetId ID of the asset that we are equipping into
* @return slotPartId ID of the slot part that we are using to equip
* @return childAssetId ID of the asset that we are equipping
*/
struct IntakeEquip {
uint256 tokenId;
uint256 childIndex;
uint64 assetId;
uint64 slotPartId;
uint64 childAssetId;
}
/**
* @notice Used to notify listeners that a child's asset has been equipped into one of its parent assets.
* @param tokenId ID of the token that had an asset equipped
* @param assetId ID of the asset associated with the token we are equipping into
* @param slotPartId ID of the slot we are using to equip
* @param childId ID of the child token we are equipping into the slot
* @param childAddress Address of the child token's collection
* @param childAssetId ID of the asset associated with the token we are equipping
*/
event ChildAssetEquipped(
uint256 indexed tokenId,
uint64 indexed assetId,
uint64 indexed slotPartId,
uint256 childId,
address childAddress,
uint64 childAssetId
);
/**
* @notice Used to notify listeners that a child's asset has been unequipped from one of its parent assets.
* @param tokenId ID of the token that had an asset unequipped
* @param assetId ID of the asset associated with the token we are unequipping out of
* @param slotPartId ID of the slot we are unequipping from
* @param childId ID of the token being unequipped
* @param childAddress Address of the collection that a token that is being unequipped belongs to
* @param childAssetId ID of the asset associated with the token we are unequipping
*/
event ChildAssetUnequipped(
uint256 indexed tokenId,
uint64 indexed assetId,
uint64 indexed slotPartId,
uint256 childId,
address childAddress,
uint64 childAssetId
);
/**
* @notice Used to notify listeners that the assets belonging to a `equippableGroupId` have been marked as
* equippable into a given slot and parent
* @param equippableGroupId ID of the equippable group being marked as equippable into the slot associated with
* `slotPartId` of the `parentAddress` collection
* @param slotPartId ID of the slot part of the catalog into which the parts belonging to the equippable group
* associated with `equippableGroupId` can be equipped
* @param parentAddress Address of the collection into which the parts belonging to `equippableGroupId` can be
* equipped
*/
event ValidParentEquippableGroupIdSet(
uint64 indexed equippableGroupId,
uint64 indexed slotPartId,
address parentAddress
);
/**
* @notice Used to equip a child into a token.
* @dev The `IntakeEquip` stuct contains the following data:
* [
* tokenId,
* childIndex,
* assetId,
* slotPartId,
* childAssetId
* ]
* @param data An `IntakeEquip` struct specifying the equip data
*/
function equip(IntakeEquip memory data) external;
/**
* @notice Used to unequip child from parent token.
* @dev This can only be called by the owner of the token or by an account that has been granted permission to
* manage the given token by the current owner.
* @param tokenId ID of the parent from which the child is being unequipped
* @param assetId ID of the parent's asset that contains the `Slot` into which the child is equipped
* @param slotPartId ID of the `Slot` from which to unequip the child
*/
function unequip(
uint256 tokenId,
uint64 assetId,
uint64 slotPartId
) external;
/**
* @notice Used to check whether the token has a given child equipped.
* @dev This is used to prevent from transferring a child that is equipped.
* @param tokenId ID of the parent token for which we are querying for
* @param childAddress Address of the child token's smart contract
* @param childId ID of the child token
* @return isEquipped A boolean value indicating whether the child token is equipped into the given token or not
*/
function isChildEquipped(
uint256 tokenId,
address childAddress,
uint256 childId
) external view returns (bool isEquipped);
/**
* @notice Used to verify whether a token can be equipped into a given parent's slot.
* @param parent Address of the parent token's smart contract
* @param tokenId ID of the token we want to equip
* @param assetId ID of the asset associated with the token we want to equip
* @param slotId ID of the slot that we want to equip the token into
* @return canBeEquipped A boolean indicating whether the token with the given asset can be equipped into the desired slot
*/
function canTokenBeEquippedWithAssetIntoSlot(
address parent,
uint256 tokenId,
uint64 assetId,
uint64 slotId
) external view returns (bool canBeEquipped);
/**
* @notice Used to get the Equipment object equipped into the specified slot of the desired token.
* @dev The `Equipment` struct consists of the following data:
* [
* assetId,
* childAssetId,
* childId,
* childEquippableAddress
* ]
* @param tokenId ID of the token for which we are retrieving the equipped object
* @param targetCatalogAddress Address of the `Catalog` associated with the `Slot` part of the token
* @param slotPartId ID of the `Slot` part that we are checking for equipped objects
* @return equipment The `Equipment` struct containing data about the equipped object
*/
function getEquipment(
uint256 tokenId,
address targetCatalogAddress,
uint64 slotPartId
) external view returns (Equipment memory equipment);
/**
* @notice Used to get the asset and equippable data associated with given `assetId`.
* @param tokenId ID of the token for which to retrieve the asset
* @param assetId ID of the asset of which we are retrieving
* @return metadataURI The metadata URI of the asset
* @return equippableGroupId ID of the equippable group this asset belongs to
* @return catalogAddress The address of the catalog the part belongs to
* @return partIds An array of IDs of parts included in the asset
*/
function getAssetAndEquippableData(
uint256 tokenId,
uint64 assetId
)
external
view
returns (
string memory metadataURI,
uint64 equippableGroupId,
address catalogAddress,
uint64[] memory partIds
);
}// SPDX-License-Identifier: Apache-2.0
pragma solidity ^0.8.21;
import {IERC165} from "@openzeppelin/contracts/utils/introspection/IERC165.sol";
/**
* @title IERC7401
* @author RMRK team
* @notice Interface smart contract of the RMRK nestable module.
*/
interface IERC7401 is IERC165 {
/**
* @notice The core struct of RMRK ownership.
* @dev The `DirectOwner` struct is used to store information of the next immediate owner, be it the parent token or
* the externally owned account.
* @dev If the token is owned by the externally owned account, the `tokenId` should equal `0`.
* @param tokenId ID of the parent token
* @param ownerAddress Address of the owner of the token. If the owner is another token, then the address should be
* the one of the parent token's collection smart contract. If the owner is externally owned account, the address
* should be the address of this account
* @param isNft A boolean value signifying whether the token is owned by another token (`true`) or by an externally
* owned account (`false`)
*/
struct DirectOwner {
uint256 tokenId;
address ownerAddress;
}
/**
* @notice Used to notify listeners that the token is being transferred.
* @dev Emitted when `tokenId` token is transferred from `from` to `to`.
* @param from Address of the previous immediate owner, which is a smart contract if the token was nested.
* @param to Address of the new immediate owner, which is a smart contract if the token is being nested.
* @param fromTokenId ID of the previous parent token. If the token was not nested before, the value should be `0`
* @param toTokenId ID of the new parent token. If the token is not being nested, the value should be `0`
* @param tokenId ID of the token being transferred
*/
event NestTransfer(
address indexed from,
address indexed to,
uint256 fromTokenId,
uint256 toTokenId,
uint256 indexed tokenId
);
/**
* @notice Used to notify listeners that a new token has been added to a given token's pending children array.
* @dev Emitted when a child NFT is added to a token's pending array.
* @param tokenId ID of the token that received a new pending child token
* @param childIndex Index of the proposed child token in the parent token's pending children array
* @param childAddress Address of the proposed child token's collection smart contract
* @param childId ID of the child token in the child token's collection smart contract
*/
event ChildProposed(
uint256 indexed tokenId,
uint256 childIndex,
address indexed childAddress,
uint256 indexed childId
);
/**
* @notice Used to notify listeners that a new child token was accepted by the parent token.
* @dev Emitted when a parent token accepts a token from its pending array, migrating it to the active array.
* @param tokenId ID of the token that accepted a new child token
* @param childIndex Index of the newly accepted child token in the parent token's active children array
* @param childAddress Address of the child token's collection smart contract
* @param childId ID of the child token in the child token's collection smart contract
*/
event ChildAccepted(
uint256 indexed tokenId,
uint256 childIndex,
address indexed childAddress,
uint256 indexed childId
);
/**
* @notice Used to notify listeners that all pending child tokens of a given token have been rejected.
* @dev Emitted when a token removes all a child tokens from its pending array.
* @param tokenId ID of the token that rejected all of the pending children
*/
event AllChildrenRejected(uint256 indexed tokenId);
/**
* @notice Used to notify listeners a child token has been transferred from parent token.
* @dev Emitted when a token transfers a child from itself, transferring ownership to the root owner.
* @param tokenId ID of the token that transferred a child token
* @param childIndex Index of a child in the array from which it is being transferred
* @param childAddress Address of the child token's collection smart contract
* @param childId ID of the child token in the child token's collection smart contract
* @param fromPending A boolean value signifying whether the token was in the pending child tokens array (`true`) or
* in the active child tokens array (`false`)
* @param toZero A boolean value signifying whether the token is being transferred to the `0x0` address (`true`) or
* not (`false`)
*/
event ChildTransferred(
uint256 indexed tokenId,
uint256 childIndex,
address indexed childAddress,
uint256 indexed childId,
bool fromPending,
bool toZero
);
/**
* @notice The core child token struct, holding the information about the child tokens.
* @return tokenId ID of the child token in the child token's collection smart contract
* @return contractAddress Address of the child token's smart contract
*/
struct Child {
uint256 tokenId;
address contractAddress;
}
/**
* @notice Used to retrieve the *root* owner of a given token.
* @dev The *root* owner of the token is an externally owned account (EOA). If the given token is child of another
* NFT, this will return an EOA address. Otherwise, if the token is owned by an EOA, this EOA will be returned.
* @param tokenId ID of the token for which the *root* owner has been retrieved
* @return owner_ The *root* owner of the token
*/
function ownerOf(uint256 tokenId) external view returns (address owner_);
/**
* @notice Used to retrieve the immediate owner of the given token.
* @dev If the immediate owner is another token, the address returned will be the parent token's collection address.
* @param tokenId ID of the token for which the RMRK owner is being retrieved
* @return owner Address of the given token's owner
* @return parentId The ID of the parent token. Should be `0` if the owner is an externally owned account
* @return isNFT The boolean value signifying whether the owner is an NFT or not
*/
function directOwnerOf(
uint256 tokenId
) external view returns (address owner, uint256 parentId, bool isNFT);
/**
* @notice Used to burn a given token.
* @dev When a token is burned, all of its child tokens are recursively burned as well.
* @dev When specifying the maximum recursive burns, the execution will be reverted if there are more children to be
* burned.
* @dev Setting the `maxRecursiveBurn` value to 0 will only attempt to burn the specified token and revert if there
* are any child tokens present.
* @dev The approvals are cleared when the token is burned.
* @dev Requirements:
*
* - `tokenId` must exist.
* @dev Emits a {Transfer} event.
* @param tokenId ID of the token to burn
* @param maxRecursiveBurns Maximum number of tokens to recursively burn
* @return burnedChildren Number of recursively burned children
*/
function burn(
uint256 tokenId,
uint256 maxRecursiveBurns
) external returns (uint256 burnedChildren);
/**
* @notice Used to add a child token to a given parent token.
* @dev This adds the child token into the given parent token's pending child tokens array.
* @dev Requirements:
*
* - `directOwnerOf` on the child contract must resolve to the called contract.
* - the pending array of the parent contract must not be full.
* @param parentId ID of the parent token to receive the new child token
* @param childId ID of the new proposed child token
* @param data Additional data with no specified format
*/
function addChild(
uint256 parentId,
uint256 childId,
bytes memory data
) external;
/**
* @notice Used to accept a pending child token for a given parent token.
* @dev This moves the child token from parent token's pending child tokens array into the active child tokens
* array.
* @param parentId ID of the parent token for which the child token is being accepted
* @param childIndex Index of a child tokem in the given parent's pending children array
* @param childAddress Address of the collection smart contract of the child token expected to be located at the
* specified index of the given parent token's pending children array
* @param childId ID of the child token expected to be located at the specified index of the given parent token's
* pending children array
*/
function acceptChild(
uint256 parentId,
uint256 childIndex,
address childAddress,
uint256 childId
) external;
/**
* @notice Used to reject all pending children of a given parent token.
* @dev Removes the children from the pending array mapping.
* @dev This does not update the ownership storage data on children. If necessary, ownership can be reclaimed by the
* rootOwner of the previous parent.
* @dev Requirements:
*
* Requirements:
*
* - `parentId` must exist
* @param parentId ID of the parent token for which to reject all of the pending tokens.
* @param maxRejections Maximum number of expected children to reject, used to prevent from rejecting children which
* arrive just before this operation.
*/
function rejectAllChildren(
uint256 parentId,
uint256 maxRejections
) external;
/**
* @notice Used to transfer a child token from a given parent token.
* @dev When transferring a child token, the owner of the token is set to `to`, or is not updated in the event of
* `to` being the `0x0` address.
* @param tokenId ID of the parent token from which the child token is being transferred
* @param to Address to which to transfer the token to
* @param destinationId ID of the token to receive this child token (MUST be 0 if the destination is not a token)
* @param childIndex Index of a token we are transferring, in the array it belongs to (can be either active array or
* pending array)
* @param childAddress Address of the child token's collection smart contract.
* @param childId ID of the child token in its own collection smart contract.
* @param isPending A boolean value indicating whether the child token being transferred is in the pending array of
* the parent token (`true`) or in the active array (`false`)
* @param data Additional data with no specified format, sent in call to `_to`
*/
function transferChild(
uint256 tokenId,
address to,
uint256 destinationId,
uint256 childIndex,
address childAddress,
uint256 childId,
bool isPending,
bytes memory data
) external;
/**
* @notice Used to retrieve the active child tokens of a given parent token.
* @dev Returns array of Child structs existing for parent token.
* @dev The Child struct consists of the following values:
* [
* tokenId,
* contractAddress
* ]
* @param parentId ID of the parent token for which to retrieve the active child tokens
* @return children An array of Child structs containing the parent token's active child tokens
*/
function childrenOf(
uint256 parentId
) external view returns (Child[] memory children);
/**
* @notice Used to retrieve the pending child tokens of a given parent token.
* @dev Returns array of pending Child structs existing for given parent.
* @dev The Child struct consists of the following values:
* [
* tokenId,
* contractAddress
* ]
* @param parentId ID of the parent token for which to retrieve the pending child tokens
* @return children An array of Child structs containing the parent token's pending child tokens
*/
function pendingChildrenOf(
uint256 parentId
) external view returns (Child[] memory children);
/**
* @notice Used to retrieve a specific active child token for a given parent token.
* @dev Returns a single Child struct locating at `index` of parent token's active child tokens array.
* @dev The Child struct consists of the following values:
* [
* tokenId,
* contractAddress
* ]
* @param parentId ID of the parent token for which the child is being retrieved
* @param index Index of the child token in the parent token's active child tokens array
* @return child A Child struct containing data about the specified child
*/
function childOf(
uint256 parentId,
uint256 index
) external view returns (Child memory child);
/**
* @notice Used to retrieve a specific pending child token from a given parent token.
* @dev Returns a single Child struct locating at `index` of parent token's active child tokens array.
* @dev The Child struct consists of the following values:
* [
* tokenId,
* contractAddress
* ]
* @param parentId ID of the parent token for which the pending child token is being retrieved
* @param index Index of the child token in the parent token's pending child tokens array
* @return child A Child struct containting data about the specified child
*/
function pendingChildOf(
uint256 parentId,
uint256 index
) external view returns (Child memory child);
/**
* @notice Used to transfer the token into another token.
* @param from Address of the direct owner of the token to be transferred
* @param to Address of the receiving token's collection smart contract
* @param tokenId ID of the token being transferred
* @param destinationId ID of the token to receive the token being transferred
* @param data Additional data with no specified format, sent in the addChild call
*/
function nestTransferFrom(
address from,
address to,
uint256 tokenId,
uint256 destinationId,
bytes memory data
) external;
}// SPDX-License-Identifier: Apache-2.0
pragma solidity ^0.8.21;
import {IERC165} from "@openzeppelin/contracts/utils/introspection/IERC165.sol";
/**
* @title IERC6454
* @author RMRK team
* @notice A minimal extension to identify the transferability of Non-Fungible Tokens.
*/
interface IERC6454 is IERC165 {
/**
* @notice Used to check whether the given token is transferable or not.
* @dev If this function returns `false`, the transfer of the token MUST revert execution.
* @dev If the tokenId does not exist, this method MUST revert execution, unless the token is being checked for
* minting.
* @param tokenId ID of the token being checked
* @param from Address from which the token is being transferred
* @param to Address to which the token is being transferred
* @return isTransferable_ Boolean value indicating whether the given token is transferable
*/
function isTransferable(
uint256 tokenId,
address from,
address to
) external view returns (bool isTransferable_);
}// SPDX-License-Identifier: Apache-2.0 pragma solidity ^0.8.21; /// @title RMRKErrors /// @author RMRK team /// @notice A collection of errors used in the RMRK suite /// @dev Errors are kept in a centralised file in order to provide a central point of reference and to avoid error /// naming collisions due to inheritance /// Attempting to grant the token to 0x0 address error ERC721AddressZeroIsNotaValidOwner(); /// Attempting to grant approval to the current owner of the token error ERC721ApprovalToCurrentOwner(); /// Attempting to grant approval when not being owner or approved for all should not be permitted error ERC721ApproveCallerIsNotOwnerNorApprovedForAll(); /// Attempting to grant approval to self error ERC721ApproveToCaller(); /// Attempting to use an invalid token ID error ERC721InvalidTokenId(); /// Attempting to mint to 0x0 address error ERC721MintToTheZeroAddress(); /// Attempting to manage a token without being its owner or approved by the owner error ERC721NotApprovedOrOwner(); /// Attempting to mint an already minted token error ERC721TokenAlreadyMinted(); /// Attempting to transfer the token from an address that is not the owner error ERC721TransferFromIncorrectOwner(); /// Attempting to safe transfer to an address that is unable to receive the token error ERC721TransferToNonReceiverImplementer(); /// Attempting to transfer the token to a 0x0 address error ERC721TransferToTheZeroAddress(); /// Attempting to grant approval of assets to their current owner error RMRKApprovalForAssetsToCurrentOwner(); /// Attempting to grant approval of assets without being the caller or approved for all error RMRKApproveForAssetsCallerIsNotOwnerNorApprovedForAll(); /// Attempting to incorrectly configue a Catalog item error RMRKBadConfig(); /// Attempting to set the priorities with an array of length that doesn't match the length of active assets array error RMRKBadPriorityListLength(); /// Attempting to add an asset entry with `Part`s, without setting the `Catalog` address error RMRKCatalogRequiredForParts(); /// Attempting to transfer a soulbound (non-transferrable) token error RMRKCannotTransferSoulbound(); /// Attempting to accept a child that has already been accepted error RMRKChildAlreadyExists(); /// Attempting to interact with a child, using index that is higher than the number of children error RMRKChildIndexOutOfRange(); /// Attempting to find the index of a child token on a parent which does not own it. error RMRKChildNotFoundInParent(); /// Attempting to equip a `Part` with a child not approved by the Catalog error RMRKEquippableEquipNotAllowedByCatalog(); /// Attempting to use ID 0, which is not supported /// @dev The ID 0 in RMRK suite is reserved for empty values. Guarding against its use ensures the expected operation error RMRKIdZeroForbidden(); /// Attempting to interact with an asset, using index greater than number of assets error RMRKIndexOutOfRange(); /// Attempting to reclaim a child that can't be reclaimed error RMRKInvalidChildReclaim(); /// Attempting to interact with an end-user account when the contract account is expected error RMRKIsNotContract(); /// Attempting to interact with a contract that had its operation locked error RMRKLocked(); /// Attempting to add a pending child after the number of pending children has reached the limit (default limit is 128) error RMRKMaxPendingChildrenReached(); /// Attempting to add a pending asset after the number of pending assets has reached the limit (default limit is /// 128) error RMRKMaxPendingAssetsReached(); /// Attempting to burn a total number of recursive children higher than maximum set /// @param childContract Address of the collection smart contract in which the maximum number of recursive burns was reached /// @param childId ID of the child token at which the maximum number of recursive burns was reached error RMRKMaxRecursiveBurnsReached(address childContract, uint256 childId); /// Attempting to mint a number of tokens that would cause the total supply to be greater than maximum supply error RMRKMintOverMax(); /// Attempting to mint zero tokens error RMRKMintZero(); /// Attempting to pass complementary arrays of different lengths error RMRKMismachedArrayLength(); /// Attempting to transfer a child before it is unequipped error RMRKMustUnequipFirst(); /// Attempting to nest a child over the nestable limit (current limit is 100 levels of nesting) error RMRKNestableTooDeep(); /// Attempting to nest the token to own descendant, which would create a loop and leave the looped tokens in limbo error RMRKNestableTransferToDescendant(); /// Attempting to nest the token to a smart contract that doesn't support nesting error RMRKNestableTransferToNonRMRKNestableImplementer(); /// Attempting to nest the token into itself error RMRKNestableTransferToSelf(); /// Attempting to interact with an asset that can not be found error RMRKNoAssetMatchingId(); /// Attempting to manage an asset without owning it or having been granted permission by the owner to do so error RMRKNotApprovedForAssetsOrOwner(); /// Attempting to interact with a token without being its owner or having been granted permission by the /// owner to do so /// @dev When a token is nested, only the direct owner (NFT parent) can mange it. In that case, approved addresses are /// not allowed to manage it, in order to ensure the expected behaviour error RMRKNotApprovedOrDirectOwner(); /// Attempting to compose an asset wihtout having an associated Catalog error RMRKNotComposableAsset(); /// Attempting to unequip an item that isn't equipped error RMRKNotEquipped(); /// Attempting to interact with a management function without being the smart contract's owner error RMRKNotOwner(); /// Attempting to interact with a function without being the owner or contributor of the collection error RMRKNotOwnerOrContributor(); /// Attempting to transfer the ownership to the 0x0 address error RMRKNewOwnerIsZeroAddress(); /// Attempting to assign a 0x0 address as a contributor error RMRKNewContributorIsZeroAddress(); /// Attempting an operation requiring the token being nested, while it is not error RMRKParentIsNotNFT(); /// Attempting to add a `Part` with an ID that is already used error RMRKPartAlreadyExists(); /// Attempting to use a `Part` that doesn't exist error RMRKPartDoesNotExist(); /// Attempting to use a `Part` that is `Fixed` when `Slot` kind of `Part` should be used error RMRKPartIsNotSlot(); /// Attempting to interact with a pending child using an index greater than the size of pending array error RMRKPendingChildIndexOutOfRange(); /// Attempting to add an asset using an ID that has already been used error RMRKAssetAlreadyExists(); /// Attempting to equip an item into a slot that already has an item equipped error RMRKSlotAlreadyUsed(); /// Attempting to equip an item into a `Slot` that the target asset does not implement error RMRKTargetAssetCannotReceiveSlot(); /// Attempting to equip a child into a `Slot` and parent that the child's collection doesn't support error RMRKTokenCannotBeEquippedWithAssetIntoSlot(); /// Attempting to compose a NFT of a token without active assets error RMRKTokenDoesNotHaveAsset(); /// Attempting to determine the asset with the top priority on a token without assets error RMRKTokenHasNoAssets(); /// Attempting to accept or transfer a child which does not match the one at the specified index error RMRKUnexpectedChildId(); /// Attempting to reject all pending assets but more assets than expected are pending error RMRKUnexpectedNumberOfAssets(); /// Attempting to reject all pending children but children assets than expected are pending error RMRKUnexpectedNumberOfChildren(); /// Attempting to accept or reject an asset which does not match the one at the specified index error RMRKUnexpectedAssetId(); /// Attempting an operation expecting a parent to the token which is not the actual one error RMRKUnexpectedParent(); /// Attempting not to pass an empty array of equippable addresses when adding or setting the equippable addresses error RMRKZeroLengthIdsPassed(); /// Attempting to set the royalties to a value higher than 100% (10000 in basis points) error RMRKRoyaltiesTooHigh(); /// Attempting to do a bulk operation on a token that is not owned by the caller error RMRKCanOnlyDoBulkOperationsOnOwnedTokens(); /// Attempting to do a bulk operation with multiple tokens at a time error RMRKCanOnlyDoBulkOperationsWithOneTokenAtATime(); /// Attempting to pay with native token with a value different than expected error RMRKWrongValueSent(); // Attempting to send native token to a recipient that is unable to receive it error TransferFailed();
// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v5.0.0) (utils/introspection/IERC165.sol)
pragma solidity ^0.8.20;
/**
* @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: Apache-2.0
pragma solidity ^0.8.21;
import {IERC165} from "@openzeppelin/contracts/utils/introspection/IERC165.sol";
/**
* @title IERC5773
* @author RMRK team
* @notice Interface smart contract of the RMRK multi asset module.
*/
interface IERC5773 is IERC165 {
/**
* @notice Used to notify listeners that an asset object is initialized at `assetId`.
* @param assetId ID of the asset that was initialized
*/
event AssetSet(uint64 indexed assetId);
/**
* @notice Used to notify listeners that an asset object at `assetId` is added to token's pending asset
* array.
* @param tokenIds An array of token IDs that received a new pending asset
* @param assetId ID of the asset that has been added to the token's pending assets array
* @param replacesId ID of the asset that would be replaced
*/
event AssetAddedToTokens(
uint256[] tokenIds,
uint64 indexed assetId,
uint64 indexed replacesId
);
/**
* @notice Used to notify listeners that an asset object at `assetId` is accepted by the token and migrated
* from token's pending assets array to active assets array of the token.
* @param tokenId ID of the token that had a new asset accepted
* @param assetId ID of the asset that was accepted
* @param replacesId ID of the asset that was replaced
*/
event AssetAccepted(
uint256 indexed tokenId,
uint64 indexed assetId,
uint64 indexed replacesId
);
/**
* @notice Used to notify listeners that an asset object at `assetId` is rejected from token and is dropped
* from the pending assets array of the token.
* @param tokenId ID of the token that had an asset rejected
* @param assetId ID of the asset that was rejected
*/
event AssetRejected(uint256 indexed tokenId, uint64 indexed assetId);
/**
* @notice Used to notify listeners that token's prioritiy array is reordered.
* @param tokenId ID of the token that had the asset priority array updated
*/
event AssetPrioritySet(uint256 indexed tokenId);
/**
* @notice Used to notify listeners that owner has granted an approval to the user to manage the assets of a
* given token.
* @dev Approvals must be cleared on transfer
* @param owner Address of the account that has granted the approval for all token's assets
* @param approved Address of the account that has been granted approval to manage the token's assets
* @param tokenId ID of the token on which the approval was granted
*/
event ApprovalForAssets(
address indexed owner,
address indexed approved,
uint256 indexed tokenId
);
/**
* @notice Used to notify listeners that owner has granted approval to the user to manage assets of all of their
* tokens.
* @param owner Address of the account that has granted the approval for all assets on all of their tokens
* @param operator Address of the account that has been granted the approval to manage the token's assets on all of
* the tokens
* @param approved Boolean value signifying whether the permission has been granted (`true`) or revoked (`false`)
*/
event ApprovalForAllForAssets(
address indexed owner,
address indexed operator,
bool approved
);
/**
* @notice Accepts an asset at from the pending array of given token.
* @dev Migrates the asset from the token's pending asset array to the token's active asset array.
* @dev Active assets cannot be removed by anyone, but can be replaced by a new asset.
* @dev Requirements:
*
* - The caller must own the token or be approved to manage the token's assets
* - `tokenId` must exist.
* - `index` must be in range of the length of the pending asset array.
* @dev Emits an {AssetAccepted} event.
* @param tokenId ID of the token for which to accept the pending asset
* @param index Index of the asset in the pending array to accept
* @param assetId ID of the asset expected to be in the index
*/
function acceptAsset(
uint256 tokenId,
uint256 index,
uint64 assetId
) external;
/**
* @notice Rejects an asset from the pending array of given token.
* @dev Removes the asset from the token's pending asset array.
* @dev Requirements:
*
* - The caller must own the token or be approved to manage the token's assets
* - `tokenId` must exist.
* - `index` must be in range of the length of the pending asset array.
* @dev Emits a {AssetRejected} event.
* @param tokenId ID of the token that the asset is being rejected from
* @param index Index of the asset in the pending array to be rejected
* @param assetId ID of the asset expected to be in the index
*/
function rejectAsset(
uint256 tokenId,
uint256 index,
uint64 assetId
) external;
/**
* @notice Rejects all assets from the pending array of a given token.
* @dev Effecitvely deletes the pending array.
* @dev Requirements:
*
* - The caller must own the token or be approved to manage the token's assets
* - `tokenId` must exist.
* @dev Emits a {AssetRejected} event with assetId = 0.
* @param tokenId ID of the token of which to clear the pending array.
* @param maxRejections Maximum number of expected assets to reject, used to prevent from rejecting assets which
* arrive just before this operation.
*/
function rejectAllAssets(uint256 tokenId, uint256 maxRejections) external;
/**
* @notice Sets a new priority array for a given token.
* @dev The priority array is a non-sequential list of `uint64`s, where the lowest value is considered highest
* priority.
* @dev Value `0` of a priority is a special case equivalent to unitialized.
* @dev Requirements:
*
* - The caller must own the token or be approved to manage the token's assets
* - `tokenId` must exist.
* - The length of `priorities` must be equal the length of the active assets array.
* @dev Emits a {AssetPrioritySet} event.
* @param tokenId ID of the token to set the priorities for
* @param priorities An array of priorities of active assets. The succesion of items in the priorities array
* matches that of the succesion of items in the active array
*/
function setPriority(
uint256 tokenId,
uint64[] calldata priorities
) external;
/**
* @notice Used to retrieve IDs of the active assets of given token.
* @dev Asset data is stored by reference, in order to access the data corresponding to the ID, call
* `getAssetMetadata(tokenId, assetId)`.
* @dev You can safely get 10k
* @param tokenId ID of the token to retrieve the IDs of the active assets
* @return assetIds An array of active asset IDs of the given token
*/
function getActiveAssets(
uint256 tokenId
) external view returns (uint64[] memory assetIds);
/**
* @notice Used to retrieve IDs of the pending assets of given token.
* @dev Asset data is stored by reference, in order to access the data corresponding to the ID, call
* `getAssetMetadata(tokenId, assetId)`.
* @param tokenId ID of the token to retrieve the IDs of the pending assets
* @return assetIds An array of pending asset IDs of the given token
*/
function getPendingAssets(
uint256 tokenId
) external view returns (uint64[] memory assetIds);
/**
* @notice Used to retrieve the priorities of the active resoources of a given token.
* @dev Asset priorities are a non-sequential array of uint64 values with an array size equal to active asset
* priorites.
* @param tokenId ID of the token for which to retrieve the priorities of the active assets
* @return priorities An array of priorities of the active assets of the given token
*/
function getActiveAssetPriorities(
uint256 tokenId
) external view returns (uint64[] memory priorities);
/**
* @notice Used to retrieve the asset that will be replaced if a given asset from the token's pending array
* is accepted.
* @dev Asset data is stored by reference, in order to access the data corresponding to the ID, call
* `getAssetMetadata(tokenId, assetId)`.
* @param tokenId ID of the token to check
* @param newAssetId ID of the pending asset which will be accepted
* @return replacesAssetWithId ID of the asset which will be replaced
*/
function getAssetReplacements(
uint256 tokenId,
uint64 newAssetId
) external view returns (uint64 replacesAssetWithId);
/**
* @notice Used to fetch the asset metadata of the specified token's active asset with the given index.
* @dev Assets are stored by reference mapping `_assets[assetId]`.
* @dev Can be overriden to implement enumerate, fallback or other custom logic.
* @param tokenId ID of the token from which to retrieve the asset metadata
* @param assetId Asset Id, must be in the active assets array
* @return metadata The metadata of the asset belonging to the specified index in the token's active assets
* array
*/
function getAssetMetadata(
uint256 tokenId,
uint64 assetId
) external view returns (string memory metadata);
// Approvals
/**
* @notice Used to grant permission to the user to manage token's assets.
* @dev This differs from transfer approvals, as approvals are not cleared when the approved party accepts or
* rejects an asset, or sets asset priorities. This approval is cleared on token transfer.
* @dev Only a single account can be approved at a time, so approving the `0x0` address clears previous approvals.
* @dev Requirements:
*
* - The caller must own the token or be an approved operator.
* - `tokenId` must exist.
* @dev Emits an {ApprovalForAssets} event.
* @param to Address of the account to grant the approval to
* @param tokenId ID of the token for which the approval to manage the assets is granted
*/
function approveForAssets(address to, uint256 tokenId) external;
/**
* @notice Used to retrieve the address of the account approved to manage assets of a given token.
* @dev Requirements:
*
* - `tokenId` must exist.
* @param tokenId ID of the token for which to retrieve the approved address
* @return approved Address of the account that is approved to manage the specified token's assets
*/
function getApprovedForAssets(
uint256 tokenId
) external view returns (address approved);
/**
* @notice Used to add or remove an operator of assets for the caller.
* @dev Operators can call {acceptAsset}, {rejectAsset}, {rejectAllAssets} or {setPriority} for any token
* owned by the caller.
* @dev Requirements:
*
* - The `operator` cannot be the caller.
* @dev Emits an {ApprovalForAllForAssets} event.
* @param operator Address of the account to which the operator role is granted or revoked from
* @param approved The boolean value indicating whether the operator role is being granted (`true`) or revoked
* (`false`)
*/
function setApprovalForAllForAssets(
address operator,
bool approved
) external;
/**
* @notice Used to check whether the address has been granted the operator role by a given address or not.
* @dev See {setApprovalForAllForAssets}.
* @param owner Address of the account that we are checking for whether it has granted the operator role
* @param operator Address of the account that we are checking whether it has the operator role or not
* @return isApproved A boolean value indicating whether the account we are checking has been granted the operator role
*/
function isApprovedForAllForAssets(
address owner,
address operator
) external view returns (bool isApproved);
}{
"remappings": [
"@openzeppelin/contracts/=node_modules/@openzeppelin/contracts/",
"@rmrk-team/evm-contracts/=contracts/",
"hardhat/=node_modules/hardhat/"
],
"optimizer": {
"enabled": true,
"runs": 200
},
"metadata": {
"useLiteralContent": false,
"bytecodeHash": "ipfs",
"appendCBOR": true
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"abi"
]
}
},
"evmVersion": "london",
"viaIR": false
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"RMRKCanOnlyDoBulkOperationsOnOwnedTokens","type":"error"},{"inputs":[],"name":"RMRKCanOnlyDoBulkOperationsWithOneTokenAtATime","type":"error"},{"inputs":[{"internalType":"address","name":"collection","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"components":[{"internalType":"uint64","name":"assetId","type":"uint64"},{"internalType":"uint64","name":"slotPartId","type":"uint64"}],"internalType":"struct RMRKBulkWriter.IntakeUnequip[]","name":"unequips","type":"tuple[]"},{"components":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"childIndex","type":"uint256"},{"internalType":"uint64","name":"assetId","type":"uint64"},{"internalType":"uint64","name":"slotPartId","type":"uint64"},{"internalType":"uint64","name":"childAssetId","type":"uint64"}],"internalType":"struct IERC6220.IntakeEquip[]","name":"equips","type":"tuple[]"}],"name":"bulkEquip","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"collection","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"destinationId","type":"uint256"}],"name":"bulkTransferAllChildren","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"collection","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256[]","name":"childrenIndexes","type":"uint256[]"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"destinationId","type":"uint256"}],"name":"bulkTransferChildren","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"collection","type":"address"},{"components":[{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"uint256","name":"childIndex","type":"uint256"},{"internalType":"uint64","name":"assetId","type":"uint64"},{"internalType":"uint64","name":"slotPartId","type":"uint64"},{"internalType":"uint64","name":"childAssetId","type":"uint64"}],"internalType":"struct IERC6220.IntakeEquip","name":"data","type":"tuple"}],"name":"replaceEquip","outputs":[],"stateMutability":"nonpayable","type":"function"}]Contract Creation Code
608060405234801561001057600080fd5b50610dce806100206000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c80631fae5a2f14610051578063347bf7081461006657806371a5e8c8146100795780639d1104541461008c575b600080fd5b61006461005f3660046107c3565b61009f565b005b61006461007436600461089f565b6102f4565b610064610087366004610a79565b610466565b61006461009a366004610b82565b610619565b83836100ab82826106ff565b604051631bc6654760e21b81526004810186905286906000906001600160a01b03831690636f19951c90602401600060405180830381865afa1580156100f5573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261011d9190810190610bb8565b805190915060005b818110156102e85760008161013b600185610c78565b6101459190610c78565b9050600084828151811061015b5761015b610c9f565b602090810291909101810151908101516040516301ffc9a760e01b81526391a6262f60e01b60048201529192506001916001600160a01b038216906301ffc9a790602401602060405180830381865afa1580156101bc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101e09190610cb5565b1561025f576040516391a6262f60e01b8152600481018e90523060248201526001600160a01b038d811660448301528216906391a6262f90606401602060405180830381865afa158015610238573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061025c9190610cb5565b91505b81156102d957876001600160a01b031663defa80c38e8e8e888860200151896000015160006040518863ffffffff1660e01b81526004016102a69796959493929190610cde565b600060405180830381600087803b1580156102c057600080fd5b505af11580156102d4573d6000803e3d6000fd5b505050505b84600101945050505050610125565b50505050505050505050565b848461030082826106ff565b604051631bc6654760e21b81526004810187905287906000906001600160a01b03831690636f19951c90602401600060405180830381865afa15801561034a573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526103729190810190610bb8565b875190915060005b8181101561045957600081610390600185610c78565b61039a9190610c78565b905060008a82815181106103b0576103b0610c9f565b6020026020010151905060008582815181106103ce576103ce610c9f565b60200260200101519050866001600160a01b031663defa80c38e8d8d868660200151876000015160006040518863ffffffff1660e01b81526004016104199796959493929190610cde565b600060405180830381600087803b15801561043357600080fd5b505af1158015610447573d6000803e3d6000fd5b5050505083600101935050505061037a565b5050505050505050505050565b838361047282826106ff565b835160005b8181101561054157876001600160a01b031663c259a988888884815181106104a1576104a1610c9f565b6020026020010151600001518985815181106104bf576104bf610c9f565b6020026020010151602001516040518463ffffffff1660e01b81526004016105049392919092835267ffffffffffffffff918216602084015216604082015260600190565b600060405180830381600087803b15801561051e57600080fd5b505af1158015610532573d6000803e3d6000fd5b50505050806001019050610477565b5050825160005b8181101561060f578685828151811061056357610563610c9f565b6020026020010151600001511461058d5760405163411ba6b760e01b815260040160405180910390fd5b876001600160a01b03166338dcf74c8683815181106105ae576105ae610c9f565b60200260200101516040518263ffffffff1660e01b81526004016105d29190610d2f565b600060405180830381600087803b1580156105ec57600080fd5b505af1158015610600573d6000803e3d6000fd5b50505050806001019050610548565b5050505050505050565b8051829061062782826106ff565b82516040808501516060860151915163184b353160e31b8152600481019390935267ffffffffffffffff90811660248401521660448201526001600160a01b0385169063c259a98890606401600060405180830381600087803b15801561068d57600080fd5b505af11580156106a1573d6000803e3d6000fd5b5050604051630e373dd360e21b81526001600160a01b03871692506338dcf74c91506106d1908690600401610d2f565b600060405180830381600087803b1580156106eb57600080fd5b505af115801561060f573d6000803e3d6000fd5b6040516331a9108f60e11b8152600481018290526000906001600160a01b03841690636352211e90602401602060405180830381865afa158015610747573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061076b9190610d7b565b90506001600160a01b038116331461079657604051632e95f4e360e11b815260040160405180910390fd5b505050565b6001600160a01b03811681146107b057600080fd5b50565b80356107be8161079b565b919050565b600080600080608085870312156107d957600080fd5b84356107e48161079b565b93506020850135925060408501356107fb8161079b565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff811182821017156108445761084461080b565b60405290565b604051601f8201601f1916810167ffffffffffffffff811182821017156108735761087361080b565b604052919050565b600067ffffffffffffffff8211156108955761089561080b565b5060051b60200190565b600080600080600060a086880312156108b757600080fd5b85356108c28161079b565b94506020868101359450604087013567ffffffffffffffff8111156108e657600080fd5b8701601f810189136108f757600080fd5b803561090a6109058261087b565b61084a565b81815260059190911b8201830190838101908b83111561092957600080fd5b928401925b828410156109475783358252928401929084019061092e565b809750505050505061095b606087016107b3565b949793965091946080013592915050565b803567ffffffffffffffff811681146107be57600080fd5b600060a0828403121561099657600080fd5b60405160a0810181811067ffffffffffffffff821117156109b9576109b961080b565b806040525080915082358152602083013560208201526109db6040840161096c565b60408201526109ec6060840161096c565b60608201526109fd6080840161096c565b60808201525092915050565b600082601f830112610a1a57600080fd5b81356020610a2a6109058361087b565b82815260a09283028501820192828201919087851115610a4957600080fd5b8387015b85811015610a6c57610a5f8982610984565b8452928401928101610a4d565b5090979650505050505050565b60008060008060808587031215610a8f57600080fd5b8435610a9a8161079b565b9350602085810135935060408087013567ffffffffffffffff80821115610ac057600080fd5b818901915089601f830112610ad457600080fd5b8135610ae26109058261087b565b81815260069190911b8301850190858101908c831115610b0157600080fd5b938601935b82851015610b4f5785858e031215610b1e5760008081fd5b610b26610821565b610b2f8661096c565b8152610b3c88870161096c565b8189015282529385019390860190610b06565b975050506060890135935080841115610b6757600080fd5b505050610b7687828801610a09565b91505092959194509250565b60008060c08385031215610b9557600080fd5b8235610ba08161079b565b9150610baf8460208501610984565b90509250929050565b60006020808385031215610bcb57600080fd5b825167ffffffffffffffff811115610be257600080fd5b8301601f81018513610bf357600080fd5b8051610c016109058261087b565b81815260069190911b82018301908381019087831115610c2057600080fd5b928401925b82841015610c6d5760408489031215610c3e5760008081fd5b610c46610821565b8451815285850151610c578161079b565b8187015282526040939093019290840190610c25565b979650505050505050565b81810381811115610c9957634e487b7160e01b600052601160045260246000fd5b92915050565b634e487b7160e01b600052603260045260246000fd5b600060208284031215610cc757600080fd5b81518015158114610cd757600080fd5b9392505050565b9687526001600160a01b03958616602088015260408701949094526060860192909252909216608084015260a0830191909152151560c082015261010060e082018190526000908201526101200190565b600060a0820190508251825260208301516020830152604083015167ffffffffffffffff8082166040850152806060860151166060850152806080860151166080850152505092915050565b600060208284031215610d8d57600080fd5b8151610cd78161079b56fea264697066735822122031bd4ddd78986704ed521d5b7d384f144fabcb86f0393d485085c0e339d01ec864736f6c63430008150033
Deployed Bytecode
0x608060405234801561001057600080fd5b506004361061004c5760003560e01c80631fae5a2f14610051578063347bf7081461006657806371a5e8c8146100795780639d1104541461008c575b600080fd5b61006461005f3660046107c3565b61009f565b005b61006461007436600461089f565b6102f4565b610064610087366004610a79565b610466565b61006461009a366004610b82565b610619565b83836100ab82826106ff565b604051631bc6654760e21b81526004810186905286906000906001600160a01b03831690636f19951c90602401600060405180830381865afa1580156100f5573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f1916820160405261011d9190810190610bb8565b805190915060005b818110156102e85760008161013b600185610c78565b6101459190610c78565b9050600084828151811061015b5761015b610c9f565b602090810291909101810151908101516040516301ffc9a760e01b81526391a6262f60e01b60048201529192506001916001600160a01b038216906301ffc9a790602401602060405180830381865afa1580156101bc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906101e09190610cb5565b1561025f576040516391a6262f60e01b8152600481018e90523060248201526001600160a01b038d811660448301528216906391a6262f90606401602060405180830381865afa158015610238573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061025c9190610cb5565b91505b81156102d957876001600160a01b031663defa80c38e8e8e888860200151896000015160006040518863ffffffff1660e01b81526004016102a69796959493929190610cde565b600060405180830381600087803b1580156102c057600080fd5b505af11580156102d4573d6000803e3d6000fd5b505050505b84600101945050505050610125565b50505050505050505050565b848461030082826106ff565b604051631bc6654760e21b81526004810187905287906000906001600160a01b03831690636f19951c90602401600060405180830381865afa15801561034a573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526103729190810190610bb8565b875190915060005b8181101561045957600081610390600185610c78565b61039a9190610c78565b905060008a82815181106103b0576103b0610c9f565b6020026020010151905060008582815181106103ce576103ce610c9f565b60200260200101519050866001600160a01b031663defa80c38e8d8d868660200151876000015160006040518863ffffffff1660e01b81526004016104199796959493929190610cde565b600060405180830381600087803b15801561043357600080fd5b505af1158015610447573d6000803e3d6000fd5b5050505083600101935050505061037a565b5050505050505050505050565b838361047282826106ff565b835160005b8181101561054157876001600160a01b031663c259a988888884815181106104a1576104a1610c9f565b6020026020010151600001518985815181106104bf576104bf610c9f565b6020026020010151602001516040518463ffffffff1660e01b81526004016105049392919092835267ffffffffffffffff918216602084015216604082015260600190565b600060405180830381600087803b15801561051e57600080fd5b505af1158015610532573d6000803e3d6000fd5b50505050806001019050610477565b5050825160005b8181101561060f578685828151811061056357610563610c9f565b6020026020010151600001511461058d5760405163411ba6b760e01b815260040160405180910390fd5b876001600160a01b03166338dcf74c8683815181106105ae576105ae610c9f565b60200260200101516040518263ffffffff1660e01b81526004016105d29190610d2f565b600060405180830381600087803b1580156105ec57600080fd5b505af1158015610600573d6000803e3d6000fd5b50505050806001019050610548565b5050505050505050565b8051829061062782826106ff565b82516040808501516060860151915163184b353160e31b8152600481019390935267ffffffffffffffff90811660248401521660448201526001600160a01b0385169063c259a98890606401600060405180830381600087803b15801561068d57600080fd5b505af11580156106a1573d6000803e3d6000fd5b5050604051630e373dd360e21b81526001600160a01b03871692506338dcf74c91506106d1908690600401610d2f565b600060405180830381600087803b1580156106eb57600080fd5b505af115801561060f573d6000803e3d6000fd5b6040516331a9108f60e11b8152600481018290526000906001600160a01b03841690636352211e90602401602060405180830381865afa158015610747573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061076b9190610d7b565b90506001600160a01b038116331461079657604051632e95f4e360e11b815260040160405180910390fd5b505050565b6001600160a01b03811681146107b057600080fd5b50565b80356107be8161079b565b919050565b600080600080608085870312156107d957600080fd5b84356107e48161079b565b93506020850135925060408501356107fb8161079b565b9396929550929360600135925050565b634e487b7160e01b600052604160045260246000fd5b6040805190810167ffffffffffffffff811182821017156108445761084461080b565b60405290565b604051601f8201601f1916810167ffffffffffffffff811182821017156108735761087361080b565b604052919050565b600067ffffffffffffffff8211156108955761089561080b565b5060051b60200190565b600080600080600060a086880312156108b757600080fd5b85356108c28161079b565b94506020868101359450604087013567ffffffffffffffff8111156108e657600080fd5b8701601f810189136108f757600080fd5b803561090a6109058261087b565b61084a565b81815260059190911b8201830190838101908b83111561092957600080fd5b928401925b828410156109475783358252928401929084019061092e565b809750505050505061095b606087016107b3565b949793965091946080013592915050565b803567ffffffffffffffff811681146107be57600080fd5b600060a0828403121561099657600080fd5b60405160a0810181811067ffffffffffffffff821117156109b9576109b961080b565b806040525080915082358152602083013560208201526109db6040840161096c565b60408201526109ec6060840161096c565b60608201526109fd6080840161096c565b60808201525092915050565b600082601f830112610a1a57600080fd5b81356020610a2a6109058361087b565b82815260a09283028501820192828201919087851115610a4957600080fd5b8387015b85811015610a6c57610a5f8982610984565b8452928401928101610a4d565b5090979650505050505050565b60008060008060808587031215610a8f57600080fd5b8435610a9a8161079b565b9350602085810135935060408087013567ffffffffffffffff80821115610ac057600080fd5b818901915089601f830112610ad457600080fd5b8135610ae26109058261087b565b81815260069190911b8301850190858101908c831115610b0157600080fd5b938601935b82851015610b4f5785858e031215610b1e5760008081fd5b610b26610821565b610b2f8661096c565b8152610b3c88870161096c565b8189015282529385019390860190610b06565b975050506060890135935080841115610b6757600080fd5b505050610b7687828801610a09565b91505092959194509250565b60008060c08385031215610b9557600080fd5b8235610ba08161079b565b9150610baf8460208501610984565b90509250929050565b60006020808385031215610bcb57600080fd5b825167ffffffffffffffff811115610be257600080fd5b8301601f81018513610bf357600080fd5b8051610c016109058261087b565b81815260069190911b82018301908381019087831115610c2057600080fd5b928401925b82841015610c6d5760408489031215610c3e5760008081fd5b610c46610821565b8451815285850151610c578161079b565b8187015282526040939093019290840190610c25565b979650505050505050565b81810381811115610c9957634e487b7160e01b600052601160045260246000fd5b92915050565b634e487b7160e01b600052603260045260246000fd5b600060208284031215610cc757600080fd5b81518015158114610cd757600080fd5b9392505050565b9687526001600160a01b03958616602088015260408701949094526060860192909252909216608084015260a0830191909152151560c082015261010060e082018190526000908201526101200190565b600060a0820190508251825260208301516020830152604083015167ffffffffffffffff8082166040850152806060860151166060850152806080860151166080850152505092915050565b600060208284031215610d8d57600080fd5b8151610cd78161079b56fea264697066735822122031bd4ddd78986704ed521d5b7d384f144fabcb86f0393d485085c0e339d01ec864736f6c63430008150033
Deployed Bytecode Sourcemap
574:8563:5:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7239:1317;;;;;;:::i;:::-;;:::i;:::-;;5500:977;;;;;;:::i;:::-;;:::i;3654:851::-;;;;;;:::i;:::-;;:::i;2027:324::-;;;;;;:::i;:::-;;:::i;7239:1317::-;7404:10;7416:7;1272:37;1289:10;1301:7;1272:16;:37::i;:::-;7528:36:::1;::::0;-1:-1:-1;;;7528:36:5;;::::1;::::0;::::1;6761:25:9::0;;;7472:10:5;;7435:25:::1;::::0;-1:-1:-1;;;;;7528:27:5;::::1;::::0;::::1;::::0;6734:18:9;;7528:36:5::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;::::0;;::::1;-1:-1:-1::0;;7528:36:5::1;::::0;::::1;;::::0;::::1;::::0;;;::::1;::::0;::::1;:::i;:::-;7592:15:::0;;7493:71;;-1:-1:-1;7575:14:5::1;7617:933;7637:6;7633:1;:10;7617:933;;;7661:17;7694:1:::0;7681:10:::1;7690:1;7681:6:::0;:10:::1;:::i;:::-;:14;;;;:::i;:::-;7661:34;;7709:27;7739:8;7748:9;7739:19;;;;;;;;:::i;:::-;;::::0;;::::1;::::0;;;;;;;7842:21;;::::1;::::0;7882:57:::1;::::0;-1:-1:-1;;;7882:57:5;;-1:-1:-1;;;7882:57:5::1;::::0;::::1;8562:52:9::0;7739:19:5;;-1:-1:-1;7792:4:5::1;::::0;-1:-1:-1;;;;;7882:29:5;::::1;::::0;::::1;::::0;8535:18:9;;7882:57:5::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;7878:243;;;7974:132;::::0;-1:-1:-1;;;7974:132:5;;::::1;::::0;::::1;9109:25:9::0;;;8059:4:5::1;9188:18:9::0;;;9181:43;-1:-1:-1;;;;;9260:15:9;;;9240:18;;;9233:43;7974:26:5;::::1;::::0;::::1;::::0;9082:18:9;;7974:132:5::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;7959:147;;7878:243;8138:12;8134:347;;;8170:16;-1:-1:-1::0;;;;;8170:30:5::1;;8222:7;8251:2;8275:13;8310:9;8341:5;:21;;;8384:5;:13;;;8419:5;8170:296;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;8134:347;8522:3;;;;;7647:903;;;;7617:933;;;;7425:1131;;;7239:1317:::0;;;;;;:::o;5500:977::-;5704:10;5716:7;1272:37;1289:10;1301:7;1272:16;:37::i;:::-;5828:36:::1;::::0;-1:-1:-1;;;5828:36:5;;::::1;::::0;::::1;6761:25:9::0;;;5772:10:5;;5735:25:::1;::::0;-1:-1:-1;;;;;5828:27:5;::::1;::::0;::::1;::::0;6734:18:9;;5828:36:5::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;::::0;;::::1;-1:-1:-1::0;;5828:36:5::1;::::0;::::1;;::::0;::::1;::::0;;;::::1;::::0;::::1;:::i;:::-;5891:22:::0;;5793:71;;-1:-1:-1;5874:14:5::1;5923:548;5943:6;5939:1;:10;5923:548;;;5967:17;6000:1:::0;5987:10:::1;5996:1;5987:6:::0;:10:::1;:::i;:::-;:14;;;;:::i;:::-;5967:34;;6015:18;6036:15;6052:9;6036:26;;;;;;;;:::i;:::-;;;;;;;6015:47;;6076:27;6106:8;6115:10;6106:20;;;;;;;;:::i;:::-;;;;;;;6076:50;;6140:16;-1:-1:-1::0;;;;;6140:30:5::1;;6188:7;6213:2;6233:13;6264:10;6292:5;:21;;;6331:5;:13;;;6362:5;6140:261;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;6443:3;;;;;5953:518;;;5923:548;;;;5725:752;;;5500:977:::0;;;;;;;:::o;3654:851::-;3841:10;3853:7;1272:37;1289:10;1301:7;1272:16;:37::i;:::-;3889:15;;3872:14:::1;3914:258;3934:6;3930:1;:10;3914:258;;;3967:10;-1:-1:-1::0;;;;;3958:28:5::1;;4004:7;4029:8;4038:1;4029:11;;;;;;;;:::i;:::-;;;;;;;:19;;;4066:8;4075:1;4066:11;;;;;;;;:::i;:::-;;;;;;;:22;;;3958:144;;;;;;;;;;;;;;;;10363:25:9::0;;;10407:18;10461:15;;;10456:2;10441:18;;10434:43;10513:15;10508:2;10493:18;;10486:43;10351:2;10336:18;;10165:370;3958:144:5::1;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;4144:3;;;;;3914:258;;;-1:-1:-1::0;;4190:13:5;;4218:9:::1;4213:286;4233:6;4229:1;:10;4213:286;;;4282:7;4261:6;4268:1;4261:9;;;;;;;;:::i;:::-;;;;;;;:17;;;:28;4257:122;;4316:48;;-1:-1:-1::0;;;4316:48:5::1;;;;;;;;;;;4257:122;4401:10;-1:-1:-1::0;;;;;4392:26:5::1;;4419:6;4426:1;4419:9;;;;;;;;:::i;:::-;;;;;;;4392:37;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;4471:3;;;;;4213:286;;;;3862:643;3654:851:::0;;;;;;:::o;2027:324::-;2159:12;;2147:10;;1272:37;2147:10;2159:12;1272:16;:37::i;:::-;2225:12;;2251::::1;::::0;;::::1;::::0;2277:15:::1;::::0;::::1;::::0;2183:119;;-1:-1:-1;;;2183:119:5;;::::1;::::0;::::1;10363:25:9::0;;;;10407:18;10461:15;;;10441:18;;;10434:43;10513:15;10493:18;;;10486:43;-1:-1:-1;;;;;2183:28:5;::::1;::::0;::::1;::::0;10336:18:9;;2183:119:5::1;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;;2312:32:5::1;::::0;-1:-1:-1;;;2312:32:5;;-1:-1:-1;;;;;2312:26:5;::::1;::::0;-1:-1:-1;2312:26:5::1;::::0;-1:-1:-1;2312:32:5::1;::::0;2339:4;;2312:32:::1;;;:::i;:::-;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;8847:288:::0;8977:36;;-1:-1:-1;;;8977:36:5;;;;;6761:25:9;;;8956:18:5;;-1:-1:-1;;;;;8977:27:5;;;;;6734:18:9;;8977:36:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;8956:57;-1:-1:-1;;;;;;9027:26:5;;735:10:7;9027:26:5;9023:106;;9076:42;;-1:-1:-1;;;9076:42:5;;;;;;;;;;;9023:106;8946:189;8847:288;;:::o;14:131:9:-;-1:-1:-1;;;;;89:31:9;;79:42;;69:70;;135:1;132;125:12;69:70;14:131;:::o;150:134::-;218:20;;247:31;218:20;247:31;:::i;:::-;150:134;;;:::o;289:525::-;375:6;383;391;399;452:3;440:9;431:7;427:23;423:33;420:53;;;469:1;466;459:12;420:53;508:9;495:23;527:31;552:5;527:31;:::i;:::-;577:5;-1:-1:-1;629:2:9;614:18;;601:32;;-1:-1:-1;685:2:9;670:18;;657:32;698:33;657:32;698:33;:::i;:::-;289:525;;;;-1:-1:-1;750:7:9;;804:2;789:18;776:32;;-1:-1:-1;;289:525:9:o;819:127::-;880:10;875:3;871:20;868:1;861:31;911:4;908:1;901:15;935:4;932:1;925:15;951:251;1023:2;1017:9;;;1053:15;;1098:18;1083:34;;1119:22;;;1080:62;1077:88;;;1145:18;;:::i;:::-;1181:2;1174:22;951:251;:::o;1207:275::-;1278:2;1272:9;1343:2;1324:13;;-1:-1:-1;;1320:27:9;1308:40;;1378:18;1363:34;;1399:22;;;1360:62;1357:88;;;1425:18;;:::i;:::-;1461:2;1454:22;1207:275;;-1:-1:-1;1207:275:9:o;1487:183::-;1547:4;1580:18;1572:6;1569:30;1566:56;;;1602:18;;:::i;:::-;-1:-1:-1;1647:1:9;1643:14;1659:4;1639:25;;1487:183::o;1675:1238::-;1795:6;1803;1811;1819;1827;1880:3;1868:9;1859:7;1855:23;1851:33;1848:53;;;1897:1;1894;1887:12;1848:53;1936:9;1923:23;1955:31;1980:5;1955:31;:::i;:::-;2005:5;-1:-1:-1;2029:2:9;2063:18;;;2050:32;;-1:-1:-1;2133:2:9;2118:18;;2105:32;2160:18;2149:30;;2146:50;;;2192:1;2189;2182:12;2146:50;2215:22;;2268:4;2260:13;;2256:27;-1:-1:-1;2246:55:9;;2297:1;2294;2287:12;2246:55;2333:2;2320:16;2356:60;2372:43;2412:2;2372:43;:::i;:::-;2356:60;:::i;:::-;2450:15;;;2532:1;2528:10;;;;2520:19;;2516:28;;;2481:12;;;;2556:19;;;2553:39;;;2588:1;2585;2578:12;2553:39;2612:11;;;;2632:142;2648:6;2643:3;2640:15;2632:142;;;2714:17;;2702:30;;2665:12;;;;2752;;;;2632:142;;;2793:5;2783:15;;;;;;;2817:38;2851:2;2840:9;2836:18;2817:38;:::i;:::-;1675:1238;;;;-1:-1:-1;1675:1238:9;;2902:3;2887:19;2874:33;;1675:1238;-1:-1:-1;;1675:1238:9:o;2918:171::-;2985:20;;3045:18;3034:30;;3024:41;;3014:69;;3079:1;3076;3069:12;3094:691;3152:5;3200:4;3188:9;3183:3;3179:19;3175:30;3172:50;;;3218:1;3215;3208:12;3172:50;3251:2;3245:9;3293:4;3285:6;3281:17;3364:6;3352:10;3349:22;3328:18;3316:10;3313:34;3310:62;3307:88;;;3375:18;;:::i;:::-;3415:10;3411:2;3404:22;;3444:6;3435:15;;3487:9;3474:23;3466:6;3459:39;3559:2;3548:9;3544:18;3531:32;3526:2;3518:6;3514:15;3507:57;3597:37;3630:2;3619:9;3615:18;3597:37;:::i;:::-;3592:2;3584:6;3580:15;3573:62;3668:37;3701:2;3690:9;3686:18;3668:37;:::i;:::-;3663:2;3655:6;3651:15;3644:62;3740:38;3773:3;3762:9;3758:19;3740:38;:::i;:::-;3734:3;3726:6;3722:16;3715:64;;3094:691;;;;:::o;3790:719::-;3855:5;3908:3;3901:4;3893:6;3889:17;3885:27;3875:55;;3926:1;3923;3916:12;3875:55;3962:6;3949:20;3988:4;4012:60;4028:43;4068:2;4028:43;:::i;4012:60::-;4106:15;;;4168:4;4211:11;;;4199:24;;4195:33;;;4137:12;;;;4094:3;4240:15;;;4237:35;;;4268:1;4265;4258:12;4237:35;4304:2;4296:6;4292:15;4316:164;4332:6;4327:3;4324:15;4316:164;;;4398:39;4433:3;4428;4398:39;:::i;:::-;4386:52;;4458:12;;;;4349;;4316:164;;;-1:-1:-1;4498:5:9;;3790:719;-1:-1:-1;;;;;;;3790:719:9:o;4514:1722::-;4707:6;4715;4723;4731;4784:3;4772:9;4763:7;4759:23;4755:33;4752:53;;;4801:1;4798;4791:12;4752:53;4840:9;4827:23;4859:31;4884:5;4859:31;:::i;:::-;4909:5;-1:-1:-1;4933:2:9;4967:18;;;4954:32;;-1:-1:-1;5005:2:9;5043:18;;;5030:32;5081:18;5111:14;;;5108:34;;;5138:1;5135;5128:12;5108:34;5176:6;5165:9;5161:22;5151:32;;5221:7;5214:4;5210:2;5206:13;5202:27;5192:55;;5243:1;5240;5233:12;5192:55;5279:2;5266:16;5302:60;5318:43;5358:2;5318:43;:::i;5302:60::-;5396:15;;;5478:1;5474:10;;;;5466:19;;5462:28;;;5427:12;;;;5502:19;;;5499:39;;;5534:1;5531;5524:12;5499:39;5558:11;;;;5578:433;5594:6;5589:3;5586:15;5578:433;;;5674:2;5668:3;5659:7;5655:17;5651:26;5648:116;;;5718:1;5747:2;5743;5736:14;5648:116;5792:22;;:::i;:::-;5843;5861:3;5843:22;:::i;:::-;5834:7;5827:39;5904:31;5931:2;5926:3;5922:12;5904:31;:::i;:::-;5886:16;;;5879:57;5949:20;;5611:12;;;;5989;;;;5578:433;;;6030:5;-1:-1:-1;;;6088:2:9;6073:18;;6060:32;;-1:-1:-1;6104:16:9;;;6101:36;;;6133:1;6130;6123:12;6101:36;;;;6156:74;6222:7;6211:8;6200:9;6196:24;6156:74;:::i;:::-;6146:84;;;4514:1722;;;;;;;:::o;6241:369::-;6336:6;6344;6397:3;6385:9;6376:7;6372:23;6368:33;6365:53;;;6414:1;6411;6404:12;6365:53;6453:9;6440:23;6472:31;6497:5;6472:31;:::i;:::-;6522:5;-1:-1:-1;6546:58:9;6596:7;6591:2;6576:18;;6546:58;:::i;:::-;6536:68;;6241:369;;;;;:::o;6797:1254::-;6914:6;6945:2;6988;6976:9;6967:7;6963:23;6959:32;6956:52;;;7004:1;7001;6994:12;6956:52;7037:9;7031:16;7070:18;7062:6;7059:30;7056:50;;;7102:1;7099;7092:12;7056:50;7125:22;;7178:4;7170:13;;7166:27;-1:-1:-1;7156:55:9;;7207:1;7204;7197:12;7156:55;7236:2;7230:9;7259:60;7275:43;7315:2;7275:43;:::i;7259:60::-;7353:15;;;7435:1;7431:10;;;;7423:19;;7419:28;;;7384:12;;;;7459:19;;;7456:39;;;7491:1;7488;7481:12;7456:39;7515:11;;;;7535:486;7551:6;7546:3;7543:15;7535:486;;;7633:4;7627:3;7618:7;7614:17;7610:28;7607:118;;;7679:1;7708:2;7704;7697:14;7607:118;7751:22;;:::i;:::-;7806:3;7800:10;7793:5;7786:25;7854:2;7849:3;7845:12;7839:19;7871:33;7896:7;7871:33;:::i;:::-;7924:14;;;7917:31;7961:18;;7577:4;7568:14;;;;;7999:12;;;;7535:486;;;8040:5;6797:1254;-1:-1:-1;;;;;;;6797:1254:9:o;8056:225::-;8123:9;;;8144:11;;;8141:134;;;8197:10;8192:3;8188:20;8185:1;8178:31;8232:4;8229:1;8222:15;8260:4;8257:1;8250:15;8141:134;8056:225;;;;:::o;8286:127::-;8347:10;8342:3;8338:20;8335:1;8328:31;8378:4;8375:1;8368:15;8402:4;8399:1;8392:15;8625:277;8692:6;8745:2;8733:9;8724:7;8720:23;8716:32;8713:52;;;8761:1;8758;8751:12;8713:52;8793:9;8787:16;8846:5;8839:13;8832:21;8825:5;8822:32;8812:60;;8868:1;8865;8858:12;8812:60;8891:5;8625:277;-1:-1:-1;;;8625:277:9:o;9287:873::-;9682:25;;;-1:-1:-1;;;;;9781:15:9;;;9776:2;9761:18;;9754:43;9828:2;9813:18;;9806:34;;;;9871:2;9856:18;;9849:34;;;;9920:15;;;9914:3;9899:19;;9892:44;9734:3;9952:19;;9945:35;;;;10024:14;10017:22;10011:3;9996:19;;9989:51;9670:3;10071;10056:19;;10049:31;;;9641:4;10096:18;;;10089:29;10150:3;10135:19;;9287:873::o;10540:596::-;10686:4;10728:3;10717:9;10713:19;10705:27;;10765:6;10759:13;10748:9;10741:32;10829:4;10821:6;10817:17;10811:24;10804:4;10793:9;10789:20;10782:54;10883:4;10875:6;10871:17;10865:24;10908:18;10982:2;10968:12;10964:21;10957:4;10946:9;10942:20;10935:51;11054:2;11046:4;11038:6;11034:17;11028:24;11024:33;11017:4;11006:9;11002:20;10995:63;11126:2;11118:4;11110:6;11106:17;11100:24;11096:33;11089:4;11078:9;11074:20;11067:63;;;10540:596;;;;:::o;11141:251::-;11211:6;11264:2;11252:9;11243:7;11239:23;11235:32;11232:52;;;11280:1;11277;11270:12;11232:52;11312:9;11306:16;11331:31;11356:5;11331:31;:::i
Swarm Source
ipfs://31bd4ddd78986704ed521d5b7d384f144fabcb86f0393d485085c0e339d01ec8
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|
Loading...
Loading
Loading...
Loading
Loading...
Loading
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.