diff --git a/src/main/kotlin/net/axay/kspigot/inventory/InventoryGUISlots.kt b/src/main/kotlin/net/axay/kspigot/inventory/InventoryGUISlots.kt index 13abd9df..1df1cc65 100644 --- a/src/main/kotlin/net/axay/kspigot/inventory/InventoryGUISlots.kt +++ b/src/main/kotlin/net/axay/kspigot/inventory/InventoryGUISlots.kt @@ -72,7 +72,12 @@ data class InventorySlot(val row: Int, val slotInRow: Int) : Comparable { + fun withInvType(invType: InventoryType): Collection + + fun realSlotsWithInvType(invType: InventoryType) + = withInvType(invType).mapNotNull { it.realSlotIn(invType.dimensions) } + } open class SingleInventorySlot internal constructor(