All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.anti_ad.mc.common.Interfaces.kt Maven / Gradle / Ivy

Go to download

Client side Minecraft MOD that adds multiple features to help you keep your inventory organized.

There is a newer version: forge-1.17.1-1.1.1
Show newest version
package org.anti_ad.mc.common

interface Savable {
    fun save()
    fun load(clientWorld: Any? = null)
}

interface IInputHandler {
    fun onInput(lastKey: Int,
                lastAction: Int): Boolean
}

interface ScreenEventListener { // eavesdrop event/input
    fun resize( /* minecraftClient: Any, */
               width: Int,
               height: Int) {
    }

    //  fun mouseMoved(x: Double, y: Double) {}
    fun mouseClicked(x: Double,
                     y: Double,
                     button: Int) = false

    fun mouseRelease(x: Double,
                     y: Double,
                     button: Int) = false

    fun mouseDragged(x: Double,
                     y: Double,
                     button: Int,
                     dx: Double,
                     dy: Double) = false

    fun mouseScrolled(x: Double,
                      y: Double,
                      amount: Double) = false

    fun keyPressed(keyCode: Int,
                   scanCode: Int,
                   modifiers: Int) = false

    fun keyReleased(keyCode: Int,
                    scanCode: Int,
                    modifiers: Int) = false

    fun charTyped(charIn: Char,
                  modifiers: Int) = false
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy