mirror of
https://github.com/alexcrea/CustomAnvil.git
synced 2026-06-23 08:14:00 +02:00
fix big issue extern gui wrongly tested
This commit is contained in:
parent
89eec84a66
commit
be7f4d0bcb
3 changed files with 11 additions and 9 deletions
|
|
@ -1,17 +1,16 @@
|
|||
package xyz.alexcrea.cuanvil.dependency.gui
|
||||
|
||||
import org.bukkit.inventory.InventoryView
|
||||
import xyz.alexcrea.cuanvil.dependency.util.PlatformUtil
|
||||
|
||||
interface ExternGuiTester {
|
||||
|
||||
fun getContainerClass(view: InventoryView): Class<Any>?
|
||||
|
||||
fun testIfGui(inventory: InventoryView): Boolean {
|
||||
// container class only allow default bukkit craft view class
|
||||
// container class only allow default bukkit craft view or test class
|
||||
|
||||
val clazz = getContainerClass(inventory)
|
||||
return clazz != null
|
||||
return clazz == null
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue