Compatibility with most plugin using wesjd anvil gui

This commit is contained in:
alexcrea 2024-09-22 20:12:56 +02:00
parent 74a211bc88
commit a915d5ad80
15 changed files with 267 additions and 1 deletions

View file

@ -0,0 +1,16 @@
package xyz.alexcrea.cuanvil.dependency.gui.version
import org.bukkit.craftbukkit.v1_19_R2.inventory.CraftInventoryView
import org.bukkit.inventory.InventoryView
import xyz.alexcrea.cuanvil.dependency.gui.ExternGuiTester
class v1_19R2_ExternGuiTester: ExternGuiTester {
override val wesjdAnvilGuiName = "Wrapper1_19_R2"
override fun getContainerClass(view: InventoryView): Class<Any>? {
if (view !is CraftInventoryView) return null
val container = view.handle
return container.javaClass
}
}