diff --git a/src/sig/engine/KeyBind.java b/src/sig/engine/KeyBind.java index 38a7236..3d8d329 100644 --- a/src/sig/engine/KeyBind.java +++ b/src/sig/engine/KeyBind.java @@ -79,23 +79,21 @@ public class KeyBind { //Polls all KeyBinds based on device. for (Action a : Action.values()) { boolean held = false; - KeyBind cc = null; for (KeyBind c : KEYBINDS.get(a)) { held = c.isKeyHeld(); - actionEventCheck(a,held); if (held) { - cc=c; break; } } - if (held) { + actionEventCheck(a,held); + /*if (held) { if (KEYBINDS.get(a).get(0)!=cc) { for (int i=0;i clist = KeyBind.KEYBINDS.get(selectedAction); - clist.add(new KeyBind(RabiClone.CONTROLLERS[i],e.getComponent().getIdentifier(),e.getValue())); + Identifier id = e.getComponent().getIdentifier(); + if (id==Identifier.Axis.POV) { + if (e.getValue()!=POV.DOWN&& + e.getValue()!=POV.RIGHT&& + e.getValue()!=POV.LEFT&& + e.getValue()!=POV.UP) { + continue; //Can't add ordinal directions, only cardinal. + } + } + clist.add(new KeyBind(RabiClone.CONTROLLERS[i],id,e.getValue())); KeyBind.KEYBINDS.put(selectedAction,clist); assigningKey=false; }