Created
July 10, 2014 22:38
-
-
Save WhiteAbeLincoln/a7674bbaaef456b2646d to your computer and use it in GitHub Desktop.
Key Bindings for minecraft 1.7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.abe.tutorial; | |
import org.lwjgl.input.Keyboard; | |
import cpw.mods.fml.client.registry.ClientRegistry; | |
import net.minecraft.client.settings.KeyBinding; | |
public class KeyBindings { | |
// Declare KeyBinding pong | |
public static KeyBinding pong; | |
public static void init() { | |
// Define the "pong" binding, with (unlocalized) name "key.pong" and | |
// the category with (unlocalized) name "key.categories.mymod" and | |
// key code 25 ("P", LWJGL constant: Keyboard.KEY_P) | |
pong = new KeyBinding("key.pong", Keyboard.KEY_P, "key.categories.mymod"); | |
// Register KeyBinding to the ClientRegistry | |
ClientRegistry.registerKeyBinding(pong); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment