io.github.parzivalExe.guiApi.antlr.converter.OpenOptionConverter.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of guiapi-mc1.8 Show documentation
Show all versions of guiapi-mc1.8 Show documentation
With GuiAPI you can create Guis for your Bukkit/Spigot-Plugin in seconds while at the same time saving many lines of code
The newest version!
package io.github.parzivalExe.guiApi.antlr.converter
import io.github.parzivalExe.guiApi.components.OpenOption
class OpenOptionConverter : Converter {
override fun attributeStringToValue(attrString: String, defaultValue: Any?): Any? =
if(attrString.equals("newInventory", true))
OpenOption.NEW_INVENTORY
else if(attrString.equals("underInventory", true))
OpenOption.UNDER_INVENTORY
else
defaultValue
}