package ru.dbotthepony.mc.otm.compat.itemborders

import com.anthonyhilyard.itemborders.ItemBorders
import net.minecraft.world.inventory.Slot
import net.neoforged.fml.ModList
import ru.dbotthepony.mc.otm.client.render.MGUIGraphics

val isItemBordersLoaded by lazy {
	ModList.get().isLoaded("itemborders")
}

fun renderSlotBorder(graphics: MGUIGraphics, slot: Slot) {
	check(isItemBordersLoaded) { "Item Borders is not loaded!" }
	ItemBorders.renderBorder(graphics.pose, slot)
}
