[SPOUT] Keybinding help

Discussion in 'Plugin Development' started by randomman159, Nov 4, 2011.

Thread Status:
Not open for further replies.
  1. Offline


    So i want to display a popup when a player presses "L". I went and created a key press event, and now can successfully tell when a player presses the key. Unfortunately it is triggered even when the player is chatting. Is there any way i can get around this?

    Secondly, in the "Controls" settings of SpoutCraft, it mentions Plugin keybinding . How can i set up keybinds like this for the plugin users to have a chance to change the binding?
  2. Offline


    if (event.getPlayer().getActiveScreen() == ScreenType.GAME_SCREEN) will be true when the player is in the normal Minecraft screen (not chatting, at the menu, in the inventory, etc.).

    For the second thing, it's easy to store keys in the config file. They all have names like KEY_A, KEY_B, etc. This page has the list.
Thread Status:
Not open for further replies.

Share This Page