Package vazkii.botania.api.corporea
Interface CorporeaNode
- All Known Implementing Classes:
AbstractCorporeaNode,DummyCorporeaNode,SidedVanillaCorporeaNode,VanillaCorporeaNode
public interface CorporeaNode
The unit of interaction for the Corporea network
All Corporea Sparks are attached to one of these
Note that not all implementations of this are actual inventories (e.g. interceptors)
-
Method Summary
Modifier and TypeMethodDescriptionList<net.minecraft.world.item.ItemStack> countItems(CorporeaRequest request) Counts items in the node matching the requestList<net.minecraft.world.item.ItemStack> extractItems(CorporeaRequest request) Extracts items matching request from the node.
CorporeaRequest.getStillNeeded()is updated to reflect how many items are yet to be extracted.
CorporeaRequest.getFound()andCorporeaRequest.getExtracted()are updated to reflect how many items were found and extracted.net.minecraft.core.BlockPosgetPos()getSpark()Convenience method for accessing the spark over this nodenet.minecraft.world.level.LevelgetWorld()
-
Method Details
-
getWorld
net.minecraft.world.level.Level getWorld() -
getPos
net.minecraft.core.BlockPos getPos() -
countItems
Counts items in the node matching the request- Parameters:
request- specifies what should be found- Returns:
- List of ItemStack. Individual stacks may be over-sized (exceed the item's maxStackSize) for purposes of counting huge amounts. The list should not be modified.
-
getSpark
CorporeaSpark getSpark()Convenience method for accessing the spark over this node -
extractItems
Extracts items matching request from the node.
CorporeaRequest.getStillNeeded()is updated to reflect how many items are yet to be extracted.
CorporeaRequest.getFound()andCorporeaRequest.getExtracted()are updated to reflect how many items were found and extracted.- Returns:
- List of ItemStacks to be delivered to the destination. The list should not be modified.
-