Added global F7 and F10 shortcuts.

- F7: cycles through FPS settings.
- F10: toggles mouse enable/disable state during gameplay.

Also added bar notifications for saving/loading checkpoints.

Signed-off-by: Jeffrey Han <itdelatrisu@gmail.com>
This commit is contained in:
Jeffrey Han
2015-03-05 14:40:57 -05:00
parent 235adc539e
commit cf9b22442f
9 changed files with 78 additions and 1 deletions

View File

@@ -578,8 +578,10 @@ public class Game extends BasicGameState {
break;
int position = (pauseTime > -1) ? pauseTime : trackPosition;
if (Options.setCheckpoint(position / 1000))
if (Options.setCheckpoint(position / 1000)) {
SoundController.playSound(SoundEffect.MENUCLICK);
UI.sendBarNotification("Checkpoint saved.");
}
}
break;
case Input.KEY_L:
@@ -597,6 +599,7 @@ public class Game extends BasicGameState {
MusicController.resume();
}
SoundController.playSound(SoundEffect.MENUHIT);
UI.sendBarNotification("Checkpoint loaded.");
// skip to checkpoint
MusicController.setPosition(checkpoint);
@@ -615,6 +618,12 @@ public class Game extends BasicGameState {
case Input.KEY_DOWN:
UI.changeVolume(-1);
break;
case Input.KEY_F7:
Options.setNextFPS(container);
break;
case Input.KEY_F10:
Options.toggleMouseDisabled();
break;
case Input.KEY_F12:
Utils.takeScreenShot();
break;