Implemented mod shortcut keys in options menu.

See for details: http://osu.ppy.sh/wiki/Shortcut_Key_Reference#Mods_screen

Signed-off-by: Jeffrey Han <itdelatrisu@gmail.com>
This commit is contained in:
Jeffrey Han
2015-01-16 02:26:13 -05:00
parent 38b3621c29
commit bcf1fa301a
2 changed files with 38 additions and 12 deletions

View File

@@ -947,6 +947,15 @@ public class Options extends BasicGameState {
currentTab = (currentTab + i) % TAB_MAX;
SoundController.playSound(SoundEffect.MENUCLICK);
break;
default:
// check mod shortcut keys
for (GameMod mod : GameMod.values()) {
if (key == mod.getKey()) {
mod.toggle(true);
break;
}
}
break;
}
}